對照了網上的表,感覺也沒少括號啊,求教

model:
sets:
factory /1..9/:b,q,H,D,F,X;
plant /1..16/:m,c;
cooperation (plant,factory):a;
endsets
data:
b=600,600,600, 900, 900, 900, 1200, 1200, 1200;
q=300,300,300,600, 600, 600, 900, 900, 900;
c=0.88,0.60,0.93,0.90,0.90,0.78,0.70,0.83,0.95,0.87,0.65,0.75,0.8,0.68,0.87,0.83;
m=300,500,200,500,300,400,300,300,400,600,100,600,500,400,300,300;
D=2,2,2,1.8,1.8,1.8,1.6,1.6,1.6;
F=600,600,600,900,900,900,1200,1200,1200;
enddata
min=@sum(factory(j):@sum(plant(i):a(i,j)*D(j)+F(j)*x(j)));
@for(factory(j):@sum(plant(i):a(i,j))<=b(j));
@for(factory(j):@sum(plant(i):a(i,j))>=q(j));
@for(factory(j):@sum(plant(i)|i#ne#10:a(i,j))>0);
@for(factory(j):@sum(plant(i):a(i,j)*c(i))>=0.8*@sum(plant(i):a(i,j));
@for(factory(j):@sum(plant(i):a(i,j))>0);
@for(plant(i):@sum(factory(j):a(i,j))=m(j));
@for(factory(j):x(j)=@if(@sum(plant(i):a(i,j))#gt#0,1,0 ));
end
發的專區有誤,實在不知道發在哪里
轉載請註明出處,本文鏈接:https://www.uj5u.com/houduan/11131.html
標籤:語言基礎/算法/系統設計
