--
You received this message because you are subscribed to the Google Groups "numericjs" group.
To unsubscribe from this group and stop receiving emails from it, send an email to numericjs+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Sebasien, thanks for your respond. But I still have problems.
It looks like that I’m missing something, because I got weird results. I've create data according your suggestion and got the solution where some variables have negative values.
Could you please point me in the right direction.
Here the example:
Minimize:
0.0269*c1 + 0.00001*c2 + 0.00001*c3 + 0.00001*c4 + 0.00001*c5 + 0.00001*c6 + 0.264*c7 + 0.0774*c8 + 0.0267*c9 + 0.053*c10 + 0.0006*c11
subject to
6.54*x1 + 0.01*x2 + 0.01*x3 + 1.76*x4 + 3.16*x5 + 1.82*x6 + 3.62*x7 + 2.39*x8 + 0.98*x9 + 0.56*x10 + 7.17*x11 <= 1600
-0.1523*x1 - 0.0012*x2 - 0*x3 - 0.2563*x4 - 0.1802*x5 - 0.035*x6 - 0.078*x7 - 0.167*x8 - 0.1112*x9 - 0.041*x10 - 0.0085*x11 >= 40
0.1523*x1 + 0.0012*x2 + 0*x3 + 0.2563*x4 + 0.1802*x5 + 0.035*x6 + 0.078*x7 + 0.167*x8 + 0.1112*x9 + 0.041*x10 + 0.0085*x11 <= 140
-0.6521*x1 - 0.0002*x2 - 0*x3 - 0.0819*x4 - 0.2241*x5 - 0.049*x6 - 0.018*x7 - 0.14*x8 - 0.043*x9 - 0.02*x10 - 0.8111*x11 >= 35.56
0.6521*x1 + 0.0002*x2 + 0*x3 + 0.0819*x4 + 0.2241*x5 + 0.049*x6 + 0.01*x7 + 0.14*x8 + 0.043*x9 + 0.02*x10 + 0.8111*x11 <= 65.78
-0.1371*x1 + 0*x2 - 0.003*x3 - 0*x4 - 0.1057*x5 - 0.3075*x6 - 0.85*x7 - 0.116*x8 - 0.0338*x9 - 0.053*x10 - 0.0006*x11 >= 180
0.1371*x1 + 0*x2 + 0.003*x3 + 0*x4 + 0.1057*x5 + 0.3075*x6 + 0.85*x7 + 0.116*x8 + 0.0338*x9 + 0.053*x10 + 0.0006*x11 <= 260
0.06126*x1 + 0.00002*x2 + 0.00002*x3 + 0.03244*x4 + 0.04915*x5 + 0.00763*x6 + 0.004*x7 + 0.0879*x8 + 0.01718*x9 + 0.01242*x10 + 0.50489*x11 <= 12.44
The data and solution
=============================================================================================
c: [ 0.0269, 0.00001, 0.00001, 0.00001, 0.00001, 0.00001, 0.264, 0.0774, 0.0267, 0.053, 0.0006 ]
A: [
[ 6.54, 0.01, 0.01, 1.76, 3.16, 1.82, 3.62, 2.39, 0.98, 0.56, 7.17 ],
[ -0.1523, -0.0012, 0, -0.2563, -0.1802, -0.035, -0.078, -0.167, -0.1112, -0.041, -0.0085 ],
[ 0.1523, 0.0012, 0, 0.2563, 0.1802, 0.035, 0.078, 0.167, 0.1112, 0.041, 0.0085 ],
[ -0.6521, -0.0002, 0, -0.0819, -0.2241, -0.049, -0.018, -0.14, -0.043, -0.02, -0.8111 ],
[ 0.6521, 0.0002, 0, 0.0819, 0.2241, 0.049, 0.01, 0.14, 0.043, 0.02, 0.8111 ],
[ -0.1371, 0, -0.003, 0, -0.1057, -0.3075, -0.85, -0.116, -0.0338, -0.053, -0.0006 ],
[ 0.1371, 0, 0.003, 0, 0.1057, 0.3075, 0.85, 0.116, 0.0338, 0.053, 0.0006 ],
[ 0.06126, 0.00002, 0.00002, 0.03244, 0.04915, 0.00763, 0.004, 0.0879, 0.01718, 0.01242, 0.50489 ]
]
b: [ 1600, -40, 148, -35.56, 65.78, -180, 260, 12.44]
----------------------------------------------
SOLUTION x (iterations = 21 ):
x0: 4468.396450071527
x1: 6001.613696047467
x2: 3074.6191257127675
x3: 8927.839670335821
x4: 83444.57804672404
x5: 16198.26554441951
x6: -3777.4999999975894
x7: -58046.32498587716
x8: -60105.89789008526
x9: -42614.80254297848
x10: -14144.971656543916
Yefim
--
You received this message because you are subscribed to the Google Groups "numericjs" group.
To unsubscribe from this group and stop receiving emails from it, send an email to numericjs+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.