Search found 108 matches

by cladelpino
6 years ago
Forum: Modeling
Topic: Avoiding unnecessary scanning of solution Space
Replies: 1
Views: 2379

Re: Avoiding unnecessary scanning of solution Space

Nice analysis! I have a warning and a suggestion to make: The warning: Have in mind that in most cases CPLEX chooses to use its propietary and secret "dynamic search"... It is (AFAIK) "impossible" (unless you stop the solver at every iteration) to really know which nodes are bein...
by cladelpino
6 years ago
Forum: Modeling
Topic: Constraint Problem
Replies: 2
Views: 2719

Re: Constraint Problem

I didn't understand well... but, I want that when x11 is equal to 1 (i1=math and k1=booklet1), z11 is equal to y11 or z12 is equal to y12 or z13 is equal to y13 or z14 is equal to y14. What about something like ? Uses an auxiliary variable w(i,k,o) z(i,o)-y(k,o) =l= ( 1- w(i,k,o) ) for all o z(i,o)-...
by cladelpino
6 years ago
Forum: Syntax
Topic: remove element from a set
Replies: 2
Views: 4932

Re: remove element from a set

This is totally valid GAMS: Set G /'A','B','C'/ G1 /'A','B'/ G2 /'A','C'/; display G,G1,G2; G('A')=no; display G,G1,G2; The secret, as the original error message stated, is not to use G as the domain of G1/G2 and any other symbol. This is the positive side of not having domain definitions. The negat...
by cladelpino
6 years ago
Forum: Syntax
Topic: Set labels based on another
Replies: 0
Views: 2474

Set labels based on another

Hi all, I am facing a situation with model structure which I don't know what would be an elegant way to solve. In a prior version of a model I have a symbol which has dimension three: aSymbol(*,*,*) But now I want to use this symbol projected over a fourth set. aSymbol(aSet,*,*,*). This is of course...
by cladelpino
6 years ago
Forum: Syntax
Topic: Error 57 with MIP code
Replies: 1
Views: 13627

Re: Error 57 with MIP code

by cladelpino
6 years ago
Forum: Modeling
Topic: how to get index of variables and constraints
Replies: 0
Views: 2844

Re: how to get index of variables and constraints

Do you mean, Which of the elements of set time appear together with device B on a constraint or variable ?
by cladelpino
6 years ago
Forum: Syntax
Topic: equation control
Replies: 0
Views: 3057

Re: equation control

Hi Yan: Check out this example, inspired with the help of the great Erwin at http://yetanothermathprogrammingconsultant.blogspot.it/2015/04/operating-on-empty-set.html $onempty set a /a1*a10/ set b(*) / /; variable x(a),dummy; equation r1,fobj; r1(a,b).. x(a)=e=1; fobj.. dummy=e=1; model c /all/; so...
by cladelpino
6 years ago
Forum: Syntax
Topic: Writing results to Excel
Replies: 2
Views: 3131

Re: Writing results to Excel

Hi:

What do you want to accomplish ? Why not directly write the set IOZ to the file?

A parameter is intended to store a value mapped to each element of a set.

Good luck
by cladelpino
6 years ago
Forum: Syntax
Topic: How to find the set elements that verify a condition
Replies: 2
Views: 3318

Re: How to find the set elements that verify a condition

Hi Lenilein, Is TC(i,j) a parameter (fixed in an instance of a solve) or a variable ? I get from your question that you intend to use it as a variable. Be aware that if it is a variable in your model, the smin() operator would require a DNLP solver ( http://old.gams.com/latest/docs/userguides/mccarl...