lingo模型定义不正确 求帮忙!

问题描述:

lingo模型定义不正确 求帮忙!
MIN = @SUM( LINKS(I, J):COST(I, J) * VOLUME(I, J))+@SUM(AGENCY(I)|DEMAND(I)#GT#(CAPACITY(I)-@SUM(AGENCY(J):VOLUME(I,J))+@SUM(AGENCY(J):VOLUME(J,I))):DEMAND(I)-(CAPACITY(I)-@SUM(AGENCY(J):VOLUME(I,J))+@SUM(AGENCY(J):VOLUME(J,I))))*LOST(I);
错误应该是这一句
SETS:
AGENCY/Wh1..Wh20/: CAPACITY,DEMAND,LOST;
LINKS( AGENCY, AGENCY): COST, VOLUME;
ENDSETS
求帮忙看下是什么问题
测验后发现是
@SUM(AGENCY(I)|(DEMAND(I)-(CAPACITY(I)-@SUM(AGENCY(J):VOLUME(I,J))+@SUM(AGENCY(J):VOLUME(J,I)))#GT#0:
(DEMAND(I)-(CAPACITY(I)-@SUM(AGENCY(J):VOLUME(I,J))+@SUM(AGENCY(J):VOLUME(J,I)))*LOST(I));
中的条件不对 好像不能带有变量?是这样吗

@sum后面一定要带冒号的