lingo tsp 错误代码 11 哪里错了啊MODEL:SETS:CITY / 1..20/:U;LINK( CITY,CITY):DIST,X;ENDSETSDATA:dist=0 9.7 12.2 7.8 10.4 7.6 4.6 12.8 10 11.2 10.2 16.1 9.8 10.7 17.2 14.8 9.5 11.8 7.45.1 0 10.5 6.1 8.9 5.2 9.4 3 5.7 2.8 8.3 7.8 2.9 1.2 14.9 3

来源:学生作业帮助网 编辑:作业帮 时间:2024/11/29 21:13:34
lingo tsp 错误代码 11 哪里错了啊MODEL:SETS:CITY / 1..20/:U;LINK( CITY,CITY):DIST,X;ENDSETSDATA:dist=0 9.7 12.2 7.8 10.4 7.6 4.6 12.8 10 11.2 10.2 16.1 9.8 10.7 17.2 14.8 9.5 11.8 7.45.1 0 10.5 6.1 8.9 5.2 9.4 3 5.7 2.8 8.3 7.8 2.9 1.2 14.9 3
xWKoE+-Kڲ ZoZ2  EB9p! GCD`'RgvAuWUoM0awzW=3.]~Cuec]~utpɷJk5 ?1lbojR:x:}Ԕ6_^5֦ Na7|ƕX٨P:UDq"W@$vaH‰2qZ%fTb`.# YpªPk>^Xhꟗ@hxA7 /`yT#%,`LV9]>.Aaa%D%s1 _GenA&'P^%JSgfhd2tP6tgg)QALŢm>m'&uq}^,,U rX+j-%C%< bI* OLgJSeM2ƔQ$ | u'L̷ )hF`LBv#jyZ΅i\:!ަ\HP-%ӰX1ak}'cV:^TV6)DaLHkDf]!2dZ فR6nlrŒqaa@KjI(`P4e@.SEC.悴Q,-}IcHWO)EI2 d ,(+̂DoN4CJ,zY ӰBs[3I7 22>q^YrOh4^

lingo tsp 错误代码 11 哪里错了啊MODEL:SETS:CITY / 1..20/:U;LINK( CITY,CITY):DIST,X;ENDSETSDATA:dist=0 9.7 12.2 7.8 10.4 7.6 4.6 12.8 10 11.2 10.2 16.1 9.8 10.7 17.2 14.8 9.5 11.8 7.45.1 0 10.5 6.1 8.9 5.2 9.4 3 5.7 2.8 8.3 7.8 2.9 1.2 14.9 3
lingo tsp 错误代码 11 哪里错了啊
MODEL:
SETS:
CITY / 1..20/:U;
LINK( CITY,CITY):DIST,X;
ENDSETS
DATA:
dist=0 9.7 12.2 7.8 10.4 7.6 4.6 12.8 10 11.2 10.2 16.1 9.8 10.7 17.2 14.8 9.5 11.8 7.4
5.1 0 10.5 6.1 8.9 5.2 9.4 3 5.7 2.8 8.3 7.8 2.9 1.2 14.9 3.6 0.7 3.4 3.1
2.3 3.7 0 3.6 1.9 6 15.5 11.1 15.6 8.6 17.8 9.1 13.2 10.1 5.2 10.9 11 9.2 8.4
2.6\x053.2\x054\x050\x053.5\x050.7\x0510.3\x057.8\x0510.6\x055.3\x0512.6\x058.9\x058.3\x056.1\x0510.2\x058.7\x056.3\x055.9\x053.2
3.6\x057.5\x054.1\x056\x050\x054.2\x0513.7\x0510\x0513.9\x057.4\x0516.1\x059\x0511.6\x058.8\x056.9\x0510.2\x059.4\x058\x056.7
15\x0513.1\x0513\x0515.3\x0513.6\x050\x058.9\x057.2\x059.8\x054.9\x0511.9\x058.7\x057.6\x055.5\x0510.9\x058.3\x055.6\x055.5\x052.6
1.3\x053.6\x052.4\x051.8\x054.2\x0514.1\x050\x0512.4\x057.1\x0511.7\x056.3\x0517.1\x058.1\x0510.6\x0520.5\x0514.8\x058.9\x0512.4\x058.4
3.9\x055.1\x056.2\x052.3\x057.4\x0517.5\x053.8\x050\x057.9\x052.6\x0510.3\x055.7\x054.9\x052\x0514.5\x052.5\x053.6\x053.1\x057.3
6.6\x058.9\x055.8\x058.6\x053.6\x0510.6\x056.7\x0510.4\x050\x058.4\x052.8\x0513.2\x052.8\x056.6\x0520.2\x0510.1\x055.1\x059.1\x057
9.3\x059.4\x0511.7\x057.6\x0512.8\x0522.4\x059.4\x055.5\x0515.9\x050\x0511\x055.3\x055.5\x051.7\x0512.4\x053.6\x053.4\x050.7\x053.9
2.6\x053.9\x050.7\x053.4\x053.6\x0512.4\x051.7\x055.5\x055.3\x0511\x050\x0515.9\x055.5\x059.4\x0522.4\x0512.8\x057.6\x0511.7\x059.4
6.6\x057\x059.1\x055.1\x0510.1\x0520.2\x056.6\x052.8\x0513.2\x052.8\x058.4\x050\x0510.4\x056.7\x0510.6\x053.6\x058.6\x055.8\x058.9
1.1\x057.3\x053.1\x053.6\x052.5\x0514.5\x052\x054.9\x055.7\x0510.3\x052.6\x057.5\x050\x053.8\x0517.5\x057.4\x052.3\x056.2\x055.1
11.3\x058.4\x0512.4\x058.9\x0514.8\x0520.5\x0510.6\x058.1\x0517.1\x056.3\x0511.7\x057.1\x0512.4\x050\x0514.1\x054.2\x051.8\x052.4\x053.6
6.8\x052.6\x055.5\x055.6\x058.3\x0510.9\x055.5\x057.6\x058.7\x0511.9\x054.9\x059.8\x057.2\x058.9\x050\x0513.6\x0515.3\x0513\x0513.1
10\x056.7\x058\x059.4\x0510.2\x056.9\x058.8\x0511.6\x059\x0516.1\x057.4\x0513.9\x0510\x0513.7\x054.2\x050\x056\x054.1\x057.5
7.4\x053.2\x055.9\x056.3\x058.7\x0510.2\x056.1\x058.3\x058.9\x0512.6\x055.3\x0510.6\x057.8\x0510.3\x050.7\x053.5\x050\x054\x053.2
11.3\x058.4\x059.2\x0511\x0510.9\x055.2\x0510.1\x0513.2\x059.1\x0517.8\x058.6\x0515.6\x0511.1\x0515.5\x056\x051.9\x053.6\x050\x053.7
2.2\x053.1\x053.4\x050.7\x053.6\x0514.9\x051.2\x052.9\x057.8\x058.3\x052.8\x055.7\x053\x059.4\x055.2\x058.9\x056.1\x0510.5\x050
11.9\x057.4\x0511.8\x059.5\x0514.8\x0517.2\x0510.7\x059.8\x0516.1\x0510.2\x0511.2\x0510\x0512.8\x054.6\x057.6\x0510.4\x057.8\x0512.2\x059.7
ENDDATA
N = @SIZE( CITY);
MIN = @SUM( LINK:DIST * X);
@FOR( CITY( K):
@SUM( CITY( I)| I #NE# K:X( I,K)) = 1;
@SUM( CITY( J)| J #NE# K:X( K,J)) = 1;
@FOR( CITY( J)| J #GT# 1 #AND# J #NE# K:
U( J) >= U( K) + X ( K,J) -
( N - 2) * ( 1 - X( K,J)) +
( N - 3) * X( J,K));
);
@FOR( LINK:@BIN( X));
@FOR( CITY( K)| K #GT# 1:
U( K) = 1 + ( N - 2) * X( K,1)
);
END
这个是我们的BT老师让我们做的,20个点的tsp问题.前提是我们之前没有学过lingo,这个我是找的一个算是模板吧,输入20X20的数据后提示错误代码11.

lingo tsp 错误代码 11 哪里错了啊MODEL:SETS:CITY / 1..20/:U;LINK( CITY,CITY):DIST,X;ENDSETSDATA:dist=0 9.7 12.2 7.8 10.4 7.6 4.6 12.8 10 11.2 10.2 16.1 9.8 10.7 17.2 14.8 9.5 11.8 7.45.1 0 10.5 6.1 8.9 5.2 9.4 3 5.7 2.8 8.3 7.8 2.9 1.2 14.9 3
数据后面有分号 数据个数也不对