linear programming - Algorithm of choosing several items with best characteristics to maximize profit -
let's have items a1-a10
different characteristics. example a1 (x1=4; x2=2; x3=1; x4=3)
. , have 5 categories c1-c5
put items into.
x1 - matters category 1, x2 - category 2, x3 - category 3, x4 - categories 4 , 5.
it must @ least 1 item in each category.
our goal put items different categories way - output maximum.
example:
let's have 4 items a1 (x1=3; x2=1; x3=1), a2 (x1=2; x2=1; x3=2); a3 (x1=1; x2=1; x3=3); a4(x1=1; x2=3; x3=1) , 3 categories c1(x1); c2(x2); c3(x3).
here best way put a1 category c1 (+3 on output); a3 category c3 (+3 on output); a4 category c2 (+3 on output) , a2 either category c1 or c3 (+2 on output). our output 11.
here's picture bad solution of given example output 4.
but easy example. have complex solve.
Comments
Post a Comment