Please share an example that allows other forum users to do what you are doing as suggested in the forum rules.
Fred
Search found 373 matches
- 2 years ago
- Forum: Tools
- Topic: Data Import from Excel
- Replies: 8
- Views: 8026
Re: CSV2gdx
Here is the documentation of csv2gdx that comes with many examples.
You do not say what you would like to do with your example csv file. Should those numbers be elements of a one-dimensional set? If so, use
I hope this helps.
Fred
You do not say what you would like to do with your example csv file. Should those numbers be elements of a one-dimensional set? If so, use
Code: Select all
csv2gdx CSV_Test.csv id=myset index=1 colcount=1
Fred
- 2 years ago
- Forum: Syntax
- Topic: Error 492 Symbol not in GDX
- Replies: 8
- Views: 8847
Re: Error 492 Symbol not in GDX
You are right. This is because you define t as 1,2,...,51 in your code but in your data you use t1, t2, ..., t51. By default, GAMS does a filtered load meaning that zero records are loaded. The following should work. Sets t "time" /t1*t51/ Parameters X(t) Price for x at time t Y(t) Price f...
- 2 years ago
- Forum: Syntax
- Topic: Error 492 Symbol not in GDX
- Replies: 8
- Views: 8847
Re: Error 492 Symbol not in GDX
Hi, the index is part of the range you are reading. So start reading at A2 instead of B2 par=X rng=priceX!A2:B51 cdim=0 rdim=1 par=Y rng=priceY!A2:B51 cdim=0 rdim=1 par=Z rng=priceZ!A2:B51 cdim=0 rdim=1 Also note that the excel file name doe snot fit with your example code. I hope this helps! Fred
- 2 years ago
- Forum: Modeling
- Topic: FLP integer infeasible
- Replies: 3
- Views: 1588
Re: FLP integer infeasible
Setting limrow and limcol to 0 was already a god idea. In addition you might want to set solprint=0 to suppress the solution listing.
Fred
Fred
- 2 years ago
- Forum: Solvers
- Topic: How to write Difference Sign in GAMS?
- Replies: 3
- Views: 3681
Re: How to write Difference Sign in GAMS?
Hi, Assuming your set C contains the elements {i,j,k,l}, and j is just an element. Then, you can write the following: sum(C$(not C('j')), function_here) This is not exactly doing what was asked for. If C('j') exists this will result in not summing over any elements in C. I think what isinsuyildiz i...
- 2 years ago
- Forum: Modeling
- Topic: FLP integer infeasible
- Replies: 3
- Views: 1588
Re: FLP integer infeasible
Hi Johannes, You are most likely suffering from numerical issues due to the poor scaling of the model. With the latest version of GAMS and different solvers I get the following for 20220315_Modell_Vereinfacht_V3. - CBC: feasible - Cplex: integer infeasible - Gurobi: feasible - SCIP: infeasible - Xpr...
- 2 years ago
- Forum: Tools
- Topic: Data Import from Excel
- Replies: 8
- Views: 8026
Re: Data Import from Excel
Nope. Even though Excel is available on the Mac, it does not support the MS Office OLE interface required by gdxxrw which is why gdxxrw is not available for mac/linux (see platform/tool availability matrix in our docs . So you either run gdxxrw on Windows and bring the GDX over to the Mac or export ...
- 2 years ago
- Forum: Tools
- Topic: Data Import from Excel
- Replies: 8
- Views: 8026
Re: Data Import from Excel
Hi,
GDXXRW is a Windows only tool. Are you eventually trying to use it under a different OS?
Fred
GDXXRW is a Windows only tool. Are you eventually trying to use it under a different OS?
Fred
- 2 years ago
- Forum: Modeling
- Topic: Endogenous $-control operations not allowed
- Replies: 2
- Views: 1544
Re: Endogenous $-control operations not allowed
Hi,
The post How do I formulate logical expressions in equations? from the FAQ may be helpful:
I hope this helps!
Fred
The post How do I formulate logical expressions in equations? from the FAQ may be helpful:
I hope this helps!
Fred