Search found 14 matches

by achristensen
4 months ago
Forum: Syntax
Topic: Need help with multiple indices variable definition and indice/set domains within constraints (Vehicle Routing Problem)
Replies: 1
Views: 568

Re: Need help with multiple indices variable definition and indice/set domains within constraints (Vehicle Routing Probl

Hi gravityman123, There is a lot to unpack in your post (and this won't be a complete answer) but one thing that struck me is that your problem has a network in it, but you have not defined a set that describes the arcs in your network. For all sorts of problems it's a good programming practice to s...
by achristensen
4 months ago
Forum: Modeling
Topic: Error 352
Replies: 1
Views: 193

Re: Error 352

best if you post some code.... is it possible to share publicly?

--adam
by achristensen
4 months ago
Forum: Modeling
Topic: Error 668 , 37 , 409
Replies: 2
Views: 269

Re: Error 668 , 37 , 409

just a couple typos...
you have

Code: Select all

$if exists $ include matdata.gms
it should be

Code: Select all

$if exist matdata.gms $include matdata.gms
does that fix everything?

--adam
by achristensen
4 months ago
Forum: Tools
Topic: using invert tool on Ubuntu
Replies: 1
Views: 668

Re: using invert tool on Ubuntu

if the return code from an external program is anything but zero that means that something went wrong with the execution of the external program. In this case it's because invert.exe is only windows compatible.

best,
adam
by achristensen
4 months ago
Forum: Modeling
Topic: Help with GAMS Error 140
Replies: 1
Views: 202

Re: Help with GAMS Error 140

an Error 140 is an "unknown symbol". It appears that you have not defined "Pe" or you might have a typo? Should it be "Pec" of "Ped"? BTW... when i run this, I get 25 errors... so you will need to fix more than just the last line. If you have a different number of errors, perhaps the wrong file got ...
by achristensen
4 months ago
Forum: Syntax
Topic: How to write this constraint
Replies: 4
Views: 363

Re: How to write this constraint

you cannot use a loop statement within an equation definition... you need to somehow structure your equation definition so that the looping behavior you are hoping for is taken care of entirely with set operations. This might also necessitate an alias set. While doing this you might also need to ret...
by achristensen
4 months ago
Forum: Tools
Topic: using GDXXRW on Linux Ubuntu
Replies: 1
Views: 324

Re: using GDXXRW on Linux Ubuntu

there isn't a way to do this. I might suggest using python to read the excel file (the openpyxl package will work). then you can write a gdxfile with the gdxtools package

Code: Select all

pip install gdxtools
Example file: https://github.com/boxblox/gdxtools

best,
adam
by achristensen
4 months ago
Forum: Tools
Topic: Alternatives to NEOS?
Replies: 2
Views: 880

Re: Alternatives to NEOS?

It kinda sounds like you are using gams to do scripting? This seems a bit off topic for the forum, but I like being helpful... if you are just doing a bunch of data manipulation you might want to go into a python environment and work there... or if you have a massive dataset you could put it all int...
by achristensen
4 months ago
Forum: Tools
Topic: Get a MPS file using NEOS/GAMS web interface
Replies: 1
Views: 676

Re: Get a MPS file using NEOS/GAMS web interface

Hi Omidi, I am not as clear on why you would need an MPS file... but NEOS is a great tool... so this is worth figuring out. I typically engage with NEOS through the Kestrel 'solver' rather than their webforms. https://www.gams.com/latest/docs/S_KESTREL.html By using Kestrel the gams model is package...
by achristensen
4 months ago
Forum: Syntax
Topic: Loading 4D Tables
Replies: 2
Views: 303

Re: Loading 4D Tables

Hi there ayledith, If you are familar with python you can use a tool I wrote to get data into a GDX and then you can load that data into a gams model through a $GDXIN statement... gdxtools can be installed with pip install gdxtools an example file of several different read/write operations can be fo...