用lingo求解下面程序时老出现error code50(for函数用错了),但是没错误啊,
model:
sets:
wh/wh1 wh2 wh3 wh4 wh5 wh6/:capacity;
ven/v1 v2 v3 v4 v5 v6/:demand;
links(wh,ven):cost,volume;
endsets
min=@sum(links(i,j):
cost(i,j)*volume(i,j);
@for(ven(j):
@sum(wh(i):volume(i,j))=demand(j));
@for(wh(i):
@sum(ven(j):volume(i,j))
人气:173 ℃ 时间:2020-04-03 06:36:14
解答
model:
sets:
wh/wh1..wh6/:capacity;
ven/v1..v8/:demand;
links(wh,ven):cost,volume;
endsets
min=@sum(links(i,j):
cost(i,j)*volume(i,j));
@for(ven(j):
@sum(wh(i):volume(i,j))=demand(j));
@for(wh(i):
@sum(ven(j):volume(i,j))
推荐
猜你喜欢