set already undercontrol

Problems with syntax of GAMS
Post Reply
Abich1414.
User
User
Posts: 7
Joined: 1 year ago

set already undercontrol

Post by Abich1414. »

Dear GAMS familly,
I want to run the following command,but it says set is already under control. I know the problem comes as the indexes I use for SUM in the first overlaps the one I used in the second. But don't know how to fix it. I appreciate if you help me.

AAVEt(i,r,s) =SUM((i_org,r_org,s_org)$(aggI(I,I_org)*aggR(R,R_org)*aggS(S,S_org)), AVEt(i_org, r_org,s_org)* trade(i_org,r_org,s_org)/SUM(i_org,r_org,s_org)$(aggI(I,I_org)*aggR(R,R_org)*aggS(S,S_org)),trade(i_org,r_org,s_org)));
User avatar
bussieck
Moderator
Moderator
Posts: 1033
Joined: 7 years ago

Re: set already undercontrol

Post by bussieck »

Has nothing to do with i. You just have wrong parenthesis. Close the first sum before you open the division sum.

-Michael
Post Reply