issue is maximizing benefit from 3 items:clock,radio,phone each has it's cost of supply,workforce,demand,price this is my first program in first day in gamps please help me with errors I have errors in part of equation
Update:This outputs me now hope it is correct
asked 15 Jan '12, 07:57 nik 
This looks a little bit like a homework problem, but I will at least give you a hint. You can't both "sum" over an index (I) and have the constraint hold 'for each' (I). GAMS will say: 125 Set is under control already I guess you don't want the SUPPLY and Worker constraints to be indexed over (I). Hope this helps. answered 15 Jan '12, 09:13 Jeff Linderoth Thanks Jeff,I couldn't understand your mean exactly, in the line of SUPPLY I wanted to compute cost of supply for items so I should have this:
(16 Jan '12, 00:18)
nik
@nik: What @Jeff told you is correct. You could not simultaneously use an index in both "for each" and "summation" sections of a constraint. The "for each" section iteratively fixes the index to specific values, say 2. The "summation" section tries to sum over all possible index values from 1 to n (in your case, 3). This is a contradiction from a mathematical point of view (your index could not simultaneously be both 1 and 2, just one of them). Therefore, you should use your indices in just one place, either "for each" section or "summation" section.
(16 Jan '12, 02:28)
Ehsan ♦
good to see you Ehsan from the same country nice 2 meet u n Thanks hope it is correct now.I updated no errors Now.
(17 Jan '12, 08:00)
nik

GAMS has great online documentation. In particular for gaining "first experience", the tutorial is what you need. answered 16 Jan '12, 01:14 Marco Luebbecke ♦ Thank you Marco I used this one too
(17 Jan '12, 08:02)
nik
