lingo错误1017MODELSETS:POLICE/P1..P4/;ROAD/R1,R2,R3,R4/;LINKS(POLICE,ROAD):TIME,X;ENDSETSDATA:TIME=12,12,23,12,34,12,43,32,23,43,54,43,54,32,12,12;ENDDATAMIN=@SUM(LINKS:TIME*X);@FOR(POLICE(I):@SUM(ROAD(J):X(I,J))=1);@FOR(ROAD(J):@SUM(POLICE(I):X(I,J))=1);@FOR(LINKS:@BIN(X));END
问题描述:
lingo错误1017
MODEL
SETS:
POLICE/P1..P4/;
ROAD/R1,R2,R3,R4/;
LINKS(POLICE,ROAD):TIME,X;
ENDSETS
DATA:
TIME=12,12,23,12,
34,12,43,32,
23,43,54,43,
54,32,12,12;
ENDDATA
MIN=@SUM(LINKS:TIME*X);
@FOR(POLICE(I):@SUM(ROAD(J):X(I,J))=1);
@FOR(ROAD(J):@SUM(POLICE(I):X(I,J))=1);
@FOR(LINKS:@BIN(X));
END
答
model后面要加:
MODEL:
SETS:
POLICE/P1..P4/;
ROAD/R1,R2,R3,R4/;
LINKS(POLICE,ROAD):TIME,X;
ENDSETS
DATA:
TIME=12,12,23,12,
34,12,43,32,
23,43,54,43,
54,32,12,12;
ENDDATA
MIN=@SUM(LINKS:TIME*X);
@FOR(POLICE(I):@SUM(ROAD(J):X(I,J))=1);
@FOR(ROAD(J):@SUM(POLICE(I):X(I,J))=1);
@FOR(LINKS:@BIN(X));
END