Search found 219 matches

by Renger
2 days ago
Forum: Syntax
Topic: Alias Dynamic Sets
Replies: 1
Views: 36

Re: Alias Dynamic Sets

Hi Richard
I probably don't get your question right, but you set an alias for a dynamic set
alias(myset, myset1);
Cheers
Renger
by Renger
2 days ago
Forum: Syntax
Topic: Create a set (or a list) as a set
Replies: 2
Views: 87

Re: Create a set (or a list) as a set

Hi
It would be easier to answer if you would provide the code with the actual elements in those sets.
Cheers
Renger
by Renger
5 days ago
Forum: Tools
Topic: MySQL, GAMS and Unix
Replies: 3
Views: 89

Re: MySQL, GAMS and Unix

Thanks!
Is there already an API for python 3.7 available (that is why I used the $call instead of embedding as I have Python 3.7 installed).
Cheers
Renger
by Renger
6 days ago
Forum: Modeling
Topic: Problem implementing a Model
Replies: 2
Views: 64

Re: Problem implementing a Model

Hi Lizzy One trick to have an equation only for the M-1 elements is by using the cardinal of a set (the number of elements): card(m) and the order: myconstraint(m$(ord(m) ne card(m)).. With respect to your second question: A variable is defined over a set, e.g. X(i), but can't be defined over a vari...
by Renger
6 days ago
Forum: Tools
Topic: Reading Data from Excel , except some Cells
Replies: 6
Views: 83

Re: Reading Data from Excel , except some Cells

Hi You can use mappings to exclude not-allowed options: set mapArcs(i,j,mode) / 1.2.1 1.2.2 1.2.4 1.3.1 1.3.2 ... / Now you can use the mapping in your equations: inflow_eq(i,ode).. IF(i,mode) =E= sum(j,$map(i,j,mode), X(i,j,mode)); ... [/code] You can also use gdxxrw to define the mapping: set map(...
by Renger
1 week ago
Forum: Tools
Topic: MySQL, GAMS and Unix
Replies: 3
Views: 89

MySQL, GAMS and Unix

Hi I am preparing my model for running on a Unix server. Until now, I have come up with the following procedure: - Read the data from the MySQL database with a python script called from my GAMS file and save the data as a CSV file. - Read the CSV file using csv2gdx. The advantage of using the python...
by Renger
1 week ago
Forum: Tools
Topic: Reading Data from Excel , except some Cells
Replies: 6
Views: 83

Re: Reading Data from Excel , except some Cells

Please give an example and why it is necessary to skip a cell. If there is no value, there is no value in the data you read...
Cheers
Renger
by Renger
1 week ago
Forum: Modeling
Topic: Help me model the first question in GAMS
Replies: 2
Views: 82

Re: Help me model the first question in GAMS

Hi
Please read the Rules to this forum. Don't expect that people take the time to guess what your questions are.
Cheers
Renger
by Renger
2 weeks ago
Forum: Modeling
Topic: Cant build a mode binpacking problem
Replies: 1
Views: 53

Re: Cant build a mode binpacking problem

Hi
If you want help from the forum, be sure to read the "Rules". (app.php/rules).
Cheers
Renger
by Renger
2 weeks ago
Forum: Syntax
Topic: Loop for objective function
Replies: 5
Views: 1978

Re: Loop for objective function

2xyes