解释下数学建模LINGO模型中每句的具体含义 20
model:sets:task/1..4/:t;man/1..4/:m;link(man,task):c,x;endsetsdata:c=17,18,15,24,19,2...
model:
sets:
task/1..4/:t;
man/1..4/:m;
link(man,task):c,x;
endsets
data:
c=17,18,15,24,19,23,22,18,16,17,16,19,19,21,23,17;
enddata
[obj]min=@sum(link:c*x);
@for(task(j):@sum(man(i):x(i,j))=1);
@for(man(i):@sum(task(j):x(i,j))=1);
@for(link:@bin(x)); 展开
sets:
task/1..4/:t;
man/1..4/:m;
link(man,task):c,x;
endsets
data:
c=17,18,15,24,19,23,22,18,16,17,16,19,19,21,23,17;
enddata
[obj]min=@sum(link:c*x);
@for(task(j):@sum(man(i):x(i,j))=1);
@for(man(i):@sum(task(j):x(i,j))=1);
@for(link:@bin(x)); 展开
展开全部
model: !表示模型的开头与结束词end搭配;
sets: !集合开头词与结束词endsets搭配;
ren/r1..r4/; !表示隐式列举一维集有4个元素;
job/j1..j4/;
link(ren,job):a,x; !表示多维集有32个元素;
endsets
data: !表示数据部分;
a=15,18,21,24
19,23 22,18
26,17,16,19
19,21,23,17;
enddata
min=@sum(link(ren,job):a*x); !目标函数;
@For(ren(i):@sum(job(j):x(i,j))=1); !约束条件;
@For(job(j):@sum(ren(i):x(i,j))=1);
@For(link(ren,job):@BIN(x));
end
你仿照这个程序试试可以么。。。。希望你解决这个问题
sets: !集合开头词与结束词endsets搭配;
ren/r1..r4/; !表示隐式列举一维集有4个元素;
job/j1..j4/;
link(ren,job):a,x; !表示多维集有32个元素;
endsets
data: !表示数据部分;
a=15,18,21,24
19,23 22,18
26,17,16,19
19,21,23,17;
enddata
min=@sum(link(ren,job):a*x); !目标函数;
@For(ren(i):@sum(job(j):x(i,j))=1); !约束条件;
@For(job(j):@sum(ren(i):x(i,j))=1);
@For(link(ren,job):@BIN(x));
end
你仿照这个程序试试可以么。。。。希望你解决这个问题
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询