|
Duplicate names - error N |
Top Previous Next |
|
Multiple declarations of items with the same name will cause message $195. The example shorterr18.gms illustrates such errors under the use of the errmsg=1 option which repositions the error message explanatory text.
8 PARAMETER PRICE(PROCESS) PRODUCT PRICES BY PROCESS 9 /makechair 6.5 ,maketable 3, makelamp 0.5/ 10 Yield(process) yields per unit of the process 11 /Makechair 2 ,maketable 6 ,makelamp 3/ 12 PRODCOST(PROCESS) COST BY PROCESS 13 /Makechair 10 ,Maketable 6, Makelamp 1/ 14 RESORAVAIL(RESOURCE) RESOURCE AVAILABLITY 15 /plantcap 10 ,salecontrct 3/; 16 TABLE RESOURUSE(RESOURCE,PROCESS) RESOURCE USAGE 17 Makechair Maketable Makelamp 18 plantcap 3 2 1.1 19 salecontrct 1 -1; 20 POSITIVE VARIABLES PRODUCTION(PROCESS) ITEMS PRODUCED BY PROCESS; 21 VARIABLES PROFIT TOTALPROFIT; 22 EQUATIONS OBJT OBJECTIVE FUNCTION ( PROFIT ) 23 RESORAVAIL(RESOURCE) RESOURCES AVAILABLE ; **** $195 **** 195 Symbol redefined with a different type |