<s>
In	O
theoretical	O
computer	O
science	O
,	O
the	O
continuous	B-Algorithm
knapsack	I-Algorithm
problem	I-Algorithm
(	O
also	O
known	O
as	O
the	O
fractional	B-Algorithm
knapsack	I-Algorithm
problem	I-Algorithm
)	O
is	O
an	O
algorithmic	O
problem	O
in	O
combinatorial	O
optimization	O
in	O
which	O
the	O
goal	O
is	O
to	O
fill	O
a	O
container	O
(	O
the	O
"	O
knapsack	O
"	O
)	O
with	O
fractional	O
amounts	O
of	O
different	O
materials	O
chosen	O
to	O
maximize	O
the	O
value	O
of	O
the	O
selected	O
materials	O
.	O
</s>
<s>
It	O
resembles	O
the	O
classic	O
knapsack	B-Algorithm
problem	I-Algorithm
,	O
in	O
which	O
the	O
items	O
to	O
be	O
placed	O
in	O
the	O
container	O
are	O
indivisible	O
;	O
however	O
,	O
the	O
continuous	B-Algorithm
knapsack	I-Algorithm
problem	I-Algorithm
may	O
be	O
solved	O
in	O
polynomial	O
time	O
whereas	O
the	O
classic	O
knapsack	B-Algorithm
problem	I-Algorithm
is	O
NP-hard	O
.	O
</s>
<s>
It	O
is	O
a	O
classic	O
example	O
of	O
how	O
a	O
seemingly	O
small	O
change	O
in	O
the	O
formulation	O
of	O
a	O
problem	O
can	O
have	O
a	O
large	O
impact	O
on	O
its	O
computational	B-General_Concept
complexity	I-General_Concept
.	O
</s>
<s>
An	O
instance	O
of	O
either	O
the	O
continuous	O
or	O
classic	O
knapsack	B-Algorithm
problems	I-Algorithm
may	O
be	O
specified	O
by	O
the	O
numerical	O
capacity	O
of	O
the	O
knapsack	O
,	O
together	O
with	O
a	O
collection	O
of	O
materials	O
,	O
each	O
of	O
which	O
has	O
two	O
numbers	O
associated	O
with	O
it	O
:	O
the	O
weight	O
of	O
material	O
that	O
is	O
available	O
to	O
be	O
selected	O
and	O
the	O
total	O
value	O
of	O
that	O
material	O
.	O
</s>
<s>
In	O
the	O
classic	O
knapsack	B-Algorithm
problem	I-Algorithm
,	O
each	O
of	O
the	O
amounts	O
must	O
be	O
either	O
zero	O
or	O
;	O
the	O
continuous	B-Algorithm
knapsack	I-Algorithm
problem	I-Algorithm
differs	O
by	O
allowing	O
to	O
range	O
continuously	O
from	O
zero	O
to	O
.	O
</s>
<s>
The	O
continuous	B-Algorithm
knapsack	I-Algorithm
problem	I-Algorithm
may	O
be	O
solved	O
by	O
a	O
greedy	B-Algorithm
algorithm	I-Algorithm
,	O
first	O
published	O
in	O
1957	O
by	O
George	O
Dantzig	O
,	O
that	O
considers	O
the	O
materials	O
in	O
sorted	O
order	O
by	O
their	O
values	O
per	O
unit	O
weight	O
.	O
</s>
