Error 66 even when all symbols are defined and assigned... help! Topic is solved

Problems with syntax of GAMS
Post Reply
renebaez86
User
User
Posts: 2
Joined: 4 years ago

Error 66 even when all symbols are defined and assigned... help!

Post by renebaez86 »

I checked other subjects related to error 66 but I couldn't find an answer for my problem. I get the following:

66 The symbol shown has not been defined or assigned
A wild shot: You may have spurious commas in the explanatory
text of a declaration. Check symbol reference list.
256 Error(s) in analyzing solve statement. More detail appears
Below the solve statement above
299 Unexpected end of file

The problem is in the objective function. It does not say which symbol is undefined or unassigned.

I used "$onSymXRef " to check if everything was declared and defined and it was perfect. Why am I getting the same error? Here is my code and the include files.

HELP ME, PLEASE!
Attachments
include files.rar
(314.39 KiB) Downloaded 232 times
MEPI.gms
(9.21 KiB) Downloaded 245 times
Fred
Posts: 372
Joined: 7 years ago

Re: Error 66 even when all symbols are defined and assigned... help!

Post by Fred »

Hi,

If you look into the listing file, the first error you get is

Code: Select all

****  $66,256,299  UNEXPECTED END OF FILE (1)

**** 3 ERROR(S)   0 WARNING(S)
After adding a semicolon after the solve statement yo get

Code: Select all

79414  solve MEPI using mip minimizing of;
****                                     $66,256
**** LINE    251 INPUT       C:\Users\user\Documents\support\mepi\MEPI.gms
****  66  The symbol shown has not been defined or assigned
****         A wild shot: You may have spurious commas in the explanatory
****         text of a declaration. Check symbol reference list.
**** 256  Error(s) in analyzing solve statement. More detail appears
****      Below the solve statement above
**** The following MIP errors were detected in model MEPI:
****  66 equation mnghyd.. symbol "CA" has no values assigned
You might want to assign values to CA and then it should work.

Fred
renebaez86
User
User
Posts: 2
Joined: 4 years ago

Re: Error 66 even when all symbols are defined and assigned... help!

Post by renebaez86 »

Thank you so much! It worked! I thought I had assigned all values...
Fred wrote: 4 years ago Hi,

If you look into the listing file, the first error you get is

Code: Select all

****  $66,256,299  UNEXPECTED END OF FILE (1)

**** 3 ERROR(S)   0 WARNING(S)
After adding a semicolon after the solve statement yo get

Code: Select all

79414  solve MEPI using mip minimizing of;
****                                     $66,256
**** LINE    251 INPUT       C:\Users\user\Documents\support\mepi\MEPI.gms
****  66  The symbol shown has not been defined or assigned
****         A wild shot: You may have spurious commas in the explanatory
****         text of a declaration. Check symbol reference list.
**** 256  Error(s) in analyzing solve statement. More detail appears
****      Below the solve statement above
**** The following MIP errors were detected in model MEPI:
****  66 equation mnghyd.. symbol "CA" has no values assigned
You might want to assign values to CA and then it should work.

Fred
Post Reply