运行lingo程序时出现unexpected jacobian overflow,代码贴在下面,SETS:CITY/V1,V2,V3,V4,V5,V6/:LVL;LINK(CITY,CITY):DIST,X;ENDSETSDATA:DIST=从 v1 v2 v3 v4 v5 v6;从v1; 0 6 1 5 10^5 10^56 0 5 10^5 3 10^51 5 0 5 6 45 10^5 5 0 10^5 210^5 3 6 10^
来源:学生作业帮助网 编辑:作业帮 时间:2024/11/09 06:17:44
运行lingo程序时出现unexpected jacobian overflow,代码贴在下面,SETS:CITY/V1,V2,V3,V4,V5,V6/:LVL;LINK(CITY,CITY):DIST,X;ENDSETSDATA:DIST=从 v1 v2 v3 v4 v5 v6;从v1; 0 6 1 5 10^5 10^56 0 5 10^5 3 10^51 5 0 5 6 45 10^5 5 0 10^5 210^5 3 6 10^
运行lingo程序时出现unexpected jacobian overflow,代码贴在下面,
SETS:
CITY/V1,V2,V3,V4,V5,V6/:LVL;
LINK(CITY,CITY):DIST,X;
ENDSETS
DATA:
DIST=
从 v1 v2 v3 v4 v5 v6;
从v1; 0 6 1 5 10^5 10^5
6 0 5 10^5 3 10^5
1 5 0 5 6 4
5 10^5 5 0 10^5 2
10^5 3 6 10^5 0 6
10^5 10^5 4 2 6 0;
enddata
n=@size(city);
min=@sum(link:dist*x);
lvl(1)=0;
@for(city(k)|k#gt#1:
@sum(city(i)|i#ne#k:x(1,k))=1;
@for(city(j)|j#ne#k:
lvl(k)>=lvl(j)+x(j,k)-(n-2)*(1-x(j,k))+(N-3)*X(K,J);););
@SUM(CITY(J)|J#GT#1:X(1,J))>=1;
@FOR(LINK:@BIN(X););
@FOR(CITY(K)|K#GT#1:
@BND(1,LVL(K),999999);
LVL(K)
运行lingo程序时出现unexpected jacobian overflow,代码贴在下面,SETS:CITY/V1,V2,V3,V4,V5,V6/:LVL;LINK(CITY,CITY):DIST,X;ENDSETSDATA:DIST=从 v1 v2 v3 v4 v5 v6;从v1; 0 6 1 5 10^5 10^56 0 5 10^5 3 10^51 5 0 5 6 45 10^5 5 0 10^5 210^5 3 6 10^
@sum(city(i)|i#ne#k:x(1,k))=1;
这个是干什么的 不知道对i求和有什么用