桂林理工大学理学院
运筹学上机报告
实验一
一、 实验目的
学会用lingo求解LP,ILP问题
二、 实验内容与步骤
进一步熟悉基解的概念;掌握变量定界函数;能够利用lingo求解LP,ILP问题。
三、 实验程序
(LP1)model:
title 会计09-1班;
max = -3*x1 - x2 + 5*x3 + 2*x4;
x1+5*x2+2*x3-x4<2;
2*x1-x2+4*x3+3*x4<5;
6*x1+2*x2+x3+3*x4<3;
End
(LP2)model:
title 会计09-1班3090825;
min = x1 - 3*x2 - 2*x3;
3*x1-x2+2*x3<7;
-2*x1+4*x2<12;
4*x1+3*x2+8*x3<10;
end
(LP3)model:
title 会计09-1班3090825;
min = 2*x1 + 3*x2 + x3;
x1+4*x2+2*x3>8;
3*x1+2*x3>6;
x1+8*x2+x3>18;
end
(LP4)model:
title 会计09-1班309082511;
max = 3*x1 + 4*x2;
3*x1+4*x2<8;
x2<6;
@free(x1);
end
四、 国产rav4实验结果
(LP1)315汽车Global optimal solution found.
Objective value: 5.900000
Infeasibilities: 0.000000
Total solver iterations: 3
Model Title: 会计09-1班3090825
Variable Value Reduced Cost
X1 0.000000 5.500000
X2 0.000000 3.600000
X3 1.100000 0.000000
X4 0.2000000 0.000000
Row Slack or Surplus Dual Price
1 5.900000 1.000000
2 0.000000 0.7000000
3 0.000000 0.9000000
4 1.300000 0.000000
(LP2) Global optimal solution found.
Objective value: -9.250000
Infeasibilities: 0.000000福特猛禽f-150
Total solver iterations: 2
Model Title: 会计09-1班3090825
Variable Value Reduced Cost
X1 0.000000 0.8750000
X2 3.000000 0.000000
X3 0.1250000 0.000000
Row Slack or Surplus Dual Price
1 -9.250000 -1.000000
2 9.750000 0.000000
3 0.000000 0.5625000
4 0.000000 0.2500000
(LP3) Global optimal solution found.
Objective value: 8.625000
Infeasibilities: 0.000000
Total solver iterations: 2
Model Title: 会计09-1班3090825
Variable Value Reduced Cost
X1 0.000000 0.6875000
深圳限行时间2022春节 X2 1.875000 0.000000
X3 3.000000 0.000000
Row Slack or Surplus Dual Price
1 8.625000 -1.000000
2 5.500000 0.000000
3 0.000000 -0.3125000
4 0.000000 -0.3750000
Objective value: 8.000000
Infeasibilities: 0.000000
Total solver iterations: 0
Model Title: 会计09-1班3090825
Variable Value Reduced Cost
X1 2.666667 0.000000
X2 0.000000 0.000000
Row Slack or Surplus Dual Price
1 8.000000 1.000000
2 0.000000 1.000000
3 6.000000 0.000000
(ILP5) Global optimal solution found.
Objective value: -3.000000
Objective bound: -3.000000
Infeasibilities: 0.000000
Extended solver steps: 0
Total solver iterations: 0
Model Title: 会计09-1班30908251
Variable Value Reduced Cost
X1 2.000000 -1.000000
X2 1.000000 -1.000000
Row Slack or Surplus Dual Price
1 -3.000000 -1.000000
2 5.000000 0.000000
3 1.000000 0.000000
4 1.000000 0.000000
(ILP6) Global optimal solution found.
Objective value: 2.000000
女车手飞出赛道 Objective bound: 2.000000
Infeasibilities: 0.000000
Extended solver steps: 0
Total solver iterations: 0
Model Title: 会计09-1班3090825
Variable Value Reduced Cost
X1 0.000000 4.000000
X2 0.000000 3.000000
X3 1.000000 2.000000
Row Slack or Surplus Dual Price
1 2.000000 -1.000000
2 1.000000 0.000000
发布评论