求问lingo代码错误error11 5
model:sets:tasks/task1..task11/;PRED(tasks,tasks)/task1,task2,task1,task3,task2,task4...
model:sets:
tasks/task1.. task11/;
PRED(tasks,tasks)/
task1,task2, task1,task3,
task2,task4, task2,task5,
task4,task6, task5,task7,
task6,task9, task7,task9,
task3,task8, task8,task10,
task9,task11, task9,task11/;
endsets
@for(tasks:time=(ta+4*tm+tb)/6;sigma=(tb-ta)/6;);@for(tasks(i)|i#LT# ltask:
ls(i)=@min(pred(i,j):ls(j)-time(i)));
@for(tasks(j)|j#GT# 1:es(j)=@max(pred(i,j):es(i)+time(i)););
@for(tasks(i):slack(i)=ls(i)-es(i));
es(1)=0;
ltask=@size(tasks);
ls(ltask)=es(ltask);
tbar=@sum(tasks(i)|slack(i)#eq#0:time(i));
s^2=@sum(tasks(i)|slack(i)#eq#0:(sigma(i))^2);
@for(tasks(i):p=@psn((tmax-(es(i)+time(i)))/s));
p_projeck=@psn((tmax-(es(ltask)+time(ltask)))/s);
0.95=@psn((days-(es(ltask)+time(ltask)))/s);
data:
tmaz=40;
ta=0,3,2,6,2,8,3,3,1,4,0;
tm=0,6,5,12,5,11,6,9,4,19,0;
tb=0,15,14,30,8,17,15,27,7,28,0;
enddata
end
其中 ls(i)=@min(pred(i,j):ls(j)-time(i)));显示错误 展开
tasks/task1.. task11/;
PRED(tasks,tasks)/
task1,task2, task1,task3,
task2,task4, task2,task5,
task4,task6, task5,task7,
task6,task9, task7,task9,
task3,task8, task8,task10,
task9,task11, task9,task11/;
endsets
@for(tasks:time=(ta+4*tm+tb)/6;sigma=(tb-ta)/6;);@for(tasks(i)|i#LT# ltask:
ls(i)=@min(pred(i,j):ls(j)-time(i)));
@for(tasks(j)|j#GT# 1:es(j)=@max(pred(i,j):es(i)+time(i)););
@for(tasks(i):slack(i)=ls(i)-es(i));
es(1)=0;
ltask=@size(tasks);
ls(ltask)=es(ltask);
tbar=@sum(tasks(i)|slack(i)#eq#0:time(i));
s^2=@sum(tasks(i)|slack(i)#eq#0:(sigma(i))^2);
@for(tasks(i):p=@psn((tmax-(es(i)+time(i)))/s));
p_projeck=@psn((tmax-(es(ltask)+time(ltask)))/s);
0.95=@psn((days-(es(ltask)+time(ltask)))/s);
data:
tmaz=40;
ta=0,3,2,6,2,8,3,3,1,4,0;
tm=0,6,5,12,5,11,6,9,4,19,0;
tb=0,15,14,30,8,17,15,27,7,28,0;
enddata
end
其中 ls(i)=@min(pred(i,j):ls(j)-time(i)));显示错误 展开
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询