题目
谁能帮我修改一下这个lingo程序啊啊,
MODEL:
sets:
demand/1..3/:g;
supply/1..4/:;
link(demand,supply):a,x,b,y,c,z,d,w,ea,eba,ebb,ec,ed,q;
endsets
data:
x=2.6 13.2 2.8 0.2
1.1 20.3 1.5 0.9
6.9 20.2 1.2 1.4;
y=116 395 19 52
46 143 17 48
386 106 40 91;
z=0.3 37 0.4 0.2
1.1 6.2 0.1 0.1
0.7 2.3 0.2 0.2;
w=25.9 2.4 1 13.5
9.9 1.5 3.2 12.2
61.9 1.2 9.5 22;
ea=28.77 28.77 28.77 28.77
28.77 28.77 28.77 28.77
28.77 28.77 28.77 28.77;
eba=690 690 690 690
690 690 690 690
690 690 690 690;
ebb=750 750 750 750
750 750 750 750
750 750 750 750;
ec=15.78 15.78 15.78 15.78
15.78 15.78 15.78 15.78
15.78 15.78 15.78 15.78;
ed=109.95 109.95 109.95 109.95
109.95 109.95 109.95 109.95
109.95 109.95 109.95 109.95;
g=1,1,1;
enddata
目标函数;
max=OBJ;
OBJ=@sum(link(i,j):(a(i,j)*x(i,j)*q(i,j))/ea(i,j)+(b(i,j)*y(i,j)*q(i,j))/ebb(i,j)+(c(i,j)*z(i,j)*q(i,j))/ec(i,j)+(d(i,j)*w(i,j)*q(i
MODEL:
sets:
demand/1..3/:g;
supply/1..4/:;
link(demand,supply):a,x,b,y,c,z,d,w,ea,eba,ebb,ec,ed,q;
endsets
data:
x=2.6 13.2 2.8 0.2
1.1 20.3 1.5 0.9
6.9 20.2 1.2 1.4;
y=116 395 19 52
46 143 17 48
386 106 40 91;
z=0.3 37 0.4 0.2
1.1 6.2 0.1 0.1
0.7 2.3 0.2 0.2;
w=25.9 2.4 1 13.5
9.9 1.5 3.2 12.2
61.9 1.2 9.5 22;
ea=28.77 28.77 28.77 28.77
28.77 28.77 28.77 28.77
28.77 28.77 28.77 28.77;
eba=690 690 690 690
690 690 690 690
690 690 690 690;
ebb=750 750 750 750
750 750 750 750
750 750 750 750;
ec=15.78 15.78 15.78 15.78
15.78 15.78 15.78 15.78
15.78 15.78 15.78 15.78;
ed=109.95 109.95 109.95 109.95
109.95 109.95 109.95 109.95
109.95 109.95 109.95 109.95;
g=1,1,1;
enddata
目标函数;
max=OBJ;
OBJ=@sum(link(i,j):(a(i,j)*x(i,j)*q(i,j))/ea(i,j)+(b(i,j)*y(i,j)*q(i,j))/ebb(i,j)+(c(i,j)*z(i,j)*q(i,j))/ec(i,j)+(d(i,j)*w(i,j)*q(i
提问时间:2021-04-01
答案
程序没问题,变量太多,建议用破解版,下面运行结果
Local optimal solution found.
Objective value: 0.6803255E+23
Extended solver steps: 0
Total solver iterations: 562
Variable Value
OBJ 0.6803255E+23
G( 1) 1.000000
G( 2) 1.000000
G( 3) 1.000000
A( 1, 1) 0.1087510E+19
A( 1, 2) 0.5301699E+23
A( 1, 3) 0.5778205E+18
A( 1, 4) 0.1717300E+20
A( 2, 1) 0.4724470E+13
A( 2, 2) 0.8754769E+12
A( 2, 3) 0.6123658E+22
A( 2, 4) 0.8098128E+13
A( 3, 1) 0.2773187E+23
A( 3, 2) 0.2907188E+13
A( 3, 3) 0.9178877E+14
A( 3, 4) 0.6035426E+14
X( 1, 1) 2.600000
X( 1, 2) 13.20000
X( 1, 3) 2.800000
X( 1, 4) 0.2000000
X( 2, 1) 1.100000
X( 2, 2) 20.30000
X( 2, 3) 1.500000
X( 2, 4) 0.9000000
X( 3, 1) 6.900000
X( 3, 2) 20.20000
X( 3, 3) 1.200000
X( 3, 4) 1.400000
B( 1, 1) 0.5845987E+18
B( 1, 2) 1.898734
B( 1, 3) 0.2219825E+19
B( 1, 4) 0.1721846E+19
B( 2, 1) 0.2605479E+13
B( 2, 2) 0.1724445E+08
B( 2, 3) 44.11765
B( 2, 4) 0.3666754E+13
B( 3, 1) 1.943005
B( 3, 2) 0.1308282E+14
B( 3, 3) 0.6603740E+14
B( 3, 4) 0.2284487E+14
Y( 1, 1) 116.0000
Y( 1, 2) 395.0000
Y( 1, 3) 19.00000
Y( 1, 4) 52.00000
Y( 2, 1) 46.00000
Y( 2, 2) 143.0000
Y( 2, 3) 17.00000
Y( 2, 4) 48.00000
Y( 3, 1) 386.0000
Y( 3, 2) 106.0000
Y( 3, 3) 40.00000
Y( 3, 4) 91.00000
C( 1, 1) 0.5440398
C( 1, 2) 0.4264865
C( 1, 3) 0.2236766
C( 1, 4) 0.1940367
C( 2, 1) 0.3479533
C( 2, 2) 1.834718
C( 2, 3) 157.8000
C( 2, 4) 0.1891810
C( 3, 1) 22.54286
C( 3, 2) 0.3913580
C( 3, 3) 0.1867302
C( 3, 4) 0.1937094
Z( 1, 1) 0.3000000
Z( 1, 2) 37.00000
Z( 1, 3) 0.4000000
Z( 1, 4) 0.2000000
Z( 2, 1) 1.100000
Z( 2, 2) 6.200000
Z( 2, 3) 0.1000000
Z( 2, 4) 0.1000000
Z( 3, 1) 0.7000000
Z( 3, 2) 2.300000
Z( 3, 3) 0.2000000
Z( 3, 4) 0.2000000
D( 1, 1) 0.4172172E+18
D( 1, 2) 0.2621301E+22
D( 1, 3) 0.6183101E+19
D( 1, 4) 0.9722945E+18
D( 2, 1) 0.2058459E+13
D( 2, 2) 0.1003008E+14
D( 2, 3) 1174057.
D( 2, 4) 0.2332678E+13
D( 3, 1) 0.6515336E+23
D( 3, 2) 0.1844107E+15
D( 3, 3) 0.4431230E+14
D( 3, 4) 0.1468593E+14
W( 1, 1) 25.90000
W( 1, 2) 2.400000
W( 1, 3) 1.000000
W( 1, 4) 13.50000
W( 2, 1) 9.900000
W( 2, 2) 1.500000
W( 2, 3) 3.200000
W( 2, 4) 12.20000
W( 3, 1) 61.90000
W( 3, 2) 1.200000
W( 3, 3) 9.500000
W( 3, 4) 22.00000
EA( 1, 1) 28.77000
EA( 1, 2) 28.77000
EA( 1, 3) 28.77000
EA( 1, 4) 28.77000
EA( 2, 1) 28.77000
EA( 2, 2) 28.77000
EA( 2, 3) 28.77000
EA( 2, 4) 28.77000
EA( 3, 1) 28.77000
EA( 3, 2) 28.77000
EA( 3, 3) 28.77000
EA( 3, 4) 28.77000
EBA( 1, 1) 690.0000
EBA( 1, 2) 690.0000
EBA( 1, 3) 690.0000
EBA( 1, 4) 690.0000
EBA( 2, 1) 690.0000
EBA( 2, 2) 690.0000
EBA( 2, 3) 690.0000
EBA( 2, 4) 690.0000
EBA( 3, 1) 690.0000
EBA( 3, 2) 690.0000
EBA( 3, 3) 690.0000
EBA( 3, 4) 690.0000
EBB( 1, 1) 750.0000
EBB( 1, 2) 750.0000
EBB( 1, 3) 750.0000
EBB( 1, 4) 750.0000
EBB( 2, 1) 750.0000
EBB( 2, 2) 750.0000
EBB( 2, 3) 750.0000
EBB( 2, 4) 750.0000
EBB( 3, 1) 750.0000
EBB( 3, 2) 750.0000
EBB( 3, 3) 750.0000
EBB( 3, 4) 750.0000
EC( 1, 1) 15.78000
EC( 1, 2) 15.78000
EC( 1, 3) 15.78000
EC( 1, 4) 15.78000
EC( 2, 1) 15.78000
EC( 2, 2) 15.78000
EC( 2, 3) 15.78000
EC( 2, 4) 15.78000
EC( 3, 1) 15.78000
EC( 3, 2) 15.78000
EC( 3, 3) 15.78000
EC( 3, 4) 15.78000
ED( 1, 1) 109.9500
ED( 1, 2) 109.9500
ED( 1, 3) 109.9500
ED( 1, 4) 109.9500
ED( 2, 1) 109.9500
ED( 2, 2) 109.9500
ED( 2, 3) 109.9500
ED( 2, 4) 109.9500
ED( 3, 1) 109.9500
ED( 3, 2) 109.9500
ED( 3, 3) 109.9500
ED( 3, 4) 109.9500
Q( 1, 1) 0.000000
Q( 1, 2) 1.000000
Q( 1, 3) 0.000000
Q( 1, 4) 0.000000
Q( 2, 1) 0.000000
Q( 2, 2) 0.3041414E-06
Q( 2, 3) 1.000000
Q( 2, 4) 0.000000
Q( 3, 1) 1.000000
Q( 3, 2) 0.000000
Q( 3, 3) 0.000000
Q( 3, 4) 0.000000
Local optimal solution found.
Objective value: 0.6803255E+23
Extended solver steps: 0
Total solver iterations: 562
Variable Value
OBJ 0.6803255E+23
G( 1) 1.000000
G( 2) 1.000000
G( 3) 1.000000
A( 1, 1) 0.1087510E+19
A( 1, 2) 0.5301699E+23
A( 1, 3) 0.5778205E+18
A( 1, 4) 0.1717300E+20
A( 2, 1) 0.4724470E+13
A( 2, 2) 0.8754769E+12
A( 2, 3) 0.6123658E+22
A( 2, 4) 0.8098128E+13
A( 3, 1) 0.2773187E+23
A( 3, 2) 0.2907188E+13
A( 3, 3) 0.9178877E+14
A( 3, 4) 0.6035426E+14
X( 1, 1) 2.600000
X( 1, 2) 13.20000
X( 1, 3) 2.800000
X( 1, 4) 0.2000000
X( 2, 1) 1.100000
X( 2, 2) 20.30000
X( 2, 3) 1.500000
X( 2, 4) 0.9000000
X( 3, 1) 6.900000
X( 3, 2) 20.20000
X( 3, 3) 1.200000
X( 3, 4) 1.400000
B( 1, 1) 0.5845987E+18
B( 1, 2) 1.898734
B( 1, 3) 0.2219825E+19
B( 1, 4) 0.1721846E+19
B( 2, 1) 0.2605479E+13
B( 2, 2) 0.1724445E+08
B( 2, 3) 44.11765
B( 2, 4) 0.3666754E+13
B( 3, 1) 1.943005
B( 3, 2) 0.1308282E+14
B( 3, 3) 0.6603740E+14
B( 3, 4) 0.2284487E+14
Y( 1, 1) 116.0000
Y( 1, 2) 395.0000
Y( 1, 3) 19.00000
Y( 1, 4) 52.00000
Y( 2, 1) 46.00000
Y( 2, 2) 143.0000
Y( 2, 3) 17.00000
Y( 2, 4) 48.00000
Y( 3, 1) 386.0000
Y( 3, 2) 106.0000
Y( 3, 3) 40.00000
Y( 3, 4) 91.00000
C( 1, 1) 0.5440398
C( 1, 2) 0.4264865
C( 1, 3) 0.2236766
C( 1, 4) 0.1940367
C( 2, 1) 0.3479533
C( 2, 2) 1.834718
C( 2, 3) 157.8000
C( 2, 4) 0.1891810
C( 3, 1) 22.54286
C( 3, 2) 0.3913580
C( 3, 3) 0.1867302
C( 3, 4) 0.1937094
Z( 1, 1) 0.3000000
Z( 1, 2) 37.00000
Z( 1, 3) 0.4000000
Z( 1, 4) 0.2000000
Z( 2, 1) 1.100000
Z( 2, 2) 6.200000
Z( 2, 3) 0.1000000
Z( 2, 4) 0.1000000
Z( 3, 1) 0.7000000
Z( 3, 2) 2.300000
Z( 3, 3) 0.2000000
Z( 3, 4) 0.2000000
D( 1, 1) 0.4172172E+18
D( 1, 2) 0.2621301E+22
D( 1, 3) 0.6183101E+19
D( 1, 4) 0.9722945E+18
D( 2, 1) 0.2058459E+13
D( 2, 2) 0.1003008E+14
D( 2, 3) 1174057.
D( 2, 4) 0.2332678E+13
D( 3, 1) 0.6515336E+23
D( 3, 2) 0.1844107E+15
D( 3, 3) 0.4431230E+14
D( 3, 4) 0.1468593E+14
W( 1, 1) 25.90000
W( 1, 2) 2.400000
W( 1, 3) 1.000000
W( 1, 4) 13.50000
W( 2, 1) 9.900000
W( 2, 2) 1.500000
W( 2, 3) 3.200000
W( 2, 4) 12.20000
W( 3, 1) 61.90000
W( 3, 2) 1.200000
W( 3, 3) 9.500000
W( 3, 4) 22.00000
EA( 1, 1) 28.77000
EA( 1, 2) 28.77000
EA( 1, 3) 28.77000
EA( 1, 4) 28.77000
EA( 2, 1) 28.77000
EA( 2, 2) 28.77000
EA( 2, 3) 28.77000
EA( 2, 4) 28.77000
EA( 3, 1) 28.77000
EA( 3, 2) 28.77000
EA( 3, 3) 28.77000
EA( 3, 4) 28.77000
EBA( 1, 1) 690.0000
EBA( 1, 2) 690.0000
EBA( 1, 3) 690.0000
EBA( 1, 4) 690.0000
EBA( 2, 1) 690.0000
EBA( 2, 2) 690.0000
EBA( 2, 3) 690.0000
EBA( 2, 4) 690.0000
EBA( 3, 1) 690.0000
EBA( 3, 2) 690.0000
EBA( 3, 3) 690.0000
EBA( 3, 4) 690.0000
EBB( 1, 1) 750.0000
EBB( 1, 2) 750.0000
EBB( 1, 3) 750.0000
EBB( 1, 4) 750.0000
EBB( 2, 1) 750.0000
EBB( 2, 2) 750.0000
EBB( 2, 3) 750.0000
EBB( 2, 4) 750.0000
EBB( 3, 1) 750.0000
EBB( 3, 2) 750.0000
EBB( 3, 3) 750.0000
EBB( 3, 4) 750.0000
EC( 1, 1) 15.78000
EC( 1, 2) 15.78000
EC( 1, 3) 15.78000
EC( 1, 4) 15.78000
EC( 2, 1) 15.78000
EC( 2, 2) 15.78000
EC( 2, 3) 15.78000
EC( 2, 4) 15.78000
EC( 3, 1) 15.78000
EC( 3, 2) 15.78000
EC( 3, 3) 15.78000
EC( 3, 4) 15.78000
ED( 1, 1) 109.9500
ED( 1, 2) 109.9500
ED( 1, 3) 109.9500
ED( 1, 4) 109.9500
ED( 2, 1) 109.9500
ED( 2, 2) 109.9500
ED( 2, 3) 109.9500
ED( 2, 4) 109.9500
ED( 3, 1) 109.9500
ED( 3, 2) 109.9500
ED( 3, 3) 109.9500
ED( 3, 4) 109.9500
Q( 1, 1) 0.000000
Q( 1, 2) 1.000000
Q( 1, 3) 0.000000
Q( 1, 4) 0.000000
Q( 2, 1) 0.000000
Q( 2, 2) 0.3041414E-06
Q( 2, 3) 1.000000
Q( 2, 4) 0.000000
Q( 3, 1) 1.000000
Q( 3, 2) 0.000000
Q( 3, 3) 0.000000
Q( 3, 4) 0.000000
举一反三
已知函数f(x)=x,g(x)=alnx,a∈R.若曲线y=f(x)与曲线y=g(x)相交,且在交点处有相同的切线,求a的值和该切线方程.
我想写一篇关于奥巴马的演讲的文章,写哪一篇好呢?为什么好
奥巴马演讲不用看稿子.为什么中国领导演讲要看?
想找英语初三上学期的首字母填空练习……
英语翻译
最新试题
- 1如何通过斜二测画法将直观图还原回原图
- 2有一个英语句子有点困惑.
- 37744是四位数中唯一一个前两位数字相同,后两位也相同的完全平方数吗?
- 4已知关于xy的方程组{x+2y=5m,x-2y=9m}的解满足方程3x+2y=19,求M
- 5Jim is ____but Kate is ____.A an English ; American B English ; American C English ; an American.
- 6等差数列{an}、{bn}的前n项和分别为Sn、Tn,若Sn/Tn=2n/3n+1,求an/bn
- 7三个“鱼”怎么读
- 8英语翻译
- 9在空气中微波的传播速度等于光速,则此时飞机于雷达的距离为()米
- 10在一个底面半径为30厘米的圆柱形水桶里浸没一个高为24厘米的圆锥形实物.当把这个实物从桶中取出时,水面下降2厘米,这个圆锥形实物的底面半径是多少厘米?
热门考点
- 1萨顿假说认为"基因是由染色体携带者从亲代传递给下一代的".萨顿得出此推测的依
- 2小星星幼儿园大班有35人,中班有31人,小班有24人,张阿姨准备180块巧克力按班级人数的比,分给三个
- 3一道难的化学计算题!
- 4已知关于X的二次函数y=x²+(2k-1)x+k²-1 ,若关于x的一元二次方程x²+(2k-1)x+k²-1=0的两根平方和为9,求k的值和 ※抛物线的顶点坐
- 5请问do well in后面加动词的什么形式?
- 6求函数y=1/3x³-4x+4的极值
- 7苹果的单价比大白菜的单价的2倍好多0.4元,已知2千克苹果与5千克大白菜的价钱一样,每千克苹果、大白菜各是多少元?(用方程解)
- 8P是三角形ABC所在平面外一点,PA、PB、PC两两相互垂直,PH垂直平面于H,求证1/PA2+1/PB2+1/PC2=1/PH2
- 9把his,is,to,he,showing,friend,his,stamps.连成一句话.
- 10When I got home,my father was sleeping改为同义句When I got home,my father had-------- -----------