Search found 108 matches

by cladelpino
6 years ago
Forum: Syntax
Topic: How can I force GAMS to compile this code in its written order?
Replies: 4
Views: 4165

Re: How can I force GAMS to compile this code in its written order?

In fact, I want the first display Z.l shows the value "a" and the second display Z.l shows the value of "b". To make it more clear from my post and Gideon's: you can't . I think you missed my line opening the code example: Therefore, your code is actually executed in this way by...
by cladelpino
6 years ago
Forum: Syntax
Topic: dynamic growth syntax without max/min solve statement
Replies: 1
Views: 2059

Re: dynamic growth syntax without max/min solve statement

(Using GAMS is overkill for this)

Perhaps

Code: Select all

display pop
is what you are missing ?
by cladelpino
6 years ago
Forum: Syntax
Topic: How can I force GAMS to compile this code in its written order?
Replies: 4
Views: 4165

Re: How can I force GAMS to compile this code in its written order?

GAMS makes two different "passes" of the file when "preparing" the model, they are usually referred to as "compile" and "execution" phase or time. "compile" comes first, then "execution". As you can see in https://www.gams.com/latest/docs/U...
by cladelpino
6 years ago
Forum: Modeling
Topic: Individual LP v.s. Integrated LP in GAMS
Replies: 6
Views: 5166

Re: Individual LP v.s. Integrated LP in GAMS

The issue may not be so simple, look at this post by the great Michael Bussieck: https://forum.gamsworld.org/viewtopic.php?t=10080#p23097 But, as far as I understand, no, "Execution" in this context means GAMS execution, not the solver. From the page I linked: This is the time required for...
by cladelpino
6 years ago
Forum: Modeling
Topic: Individual LP v.s. Integrated LP in GAMS
Replies: 6
Views: 5166

Re: Individual LP v.s. Integrated LP in GAMS

Hi, why did you discard your first hypothesis ? If you look at the .lst file, you can see that the time is in fact spent in GAMS "execution" and "generation", rather than in the actual "solve" time (which is detailed as "resource use" of each solve. Check: htt...
by cladelpino
6 years ago
Forum: Syntax
Topic: Errors 654, 409, 148,125
Replies: 2
Views: 3108

Re: Errors 654, 409, 148,125

First. Read https://www.gams.com/products/simple-example/ , you've got all your sum() operators syntax wrong. (this is your 148) Second. In equation cograde, it is written for every " i ". So, when you mean sum( (i,j), ... ) do you really mean " i " again, or do you mean sum(j,.....
by cladelpino
6 years ago
Forum: Syntax
Topic: index set control
Replies: 3
Views: 3393

Re: index set control

I don't know VRP models and sincerely I can't understand from your description what this constraint is supposed to achieve. Do you mean: "If a vehicle arrives at a point p, it must also leave it" ? If so, this can be written as: arrAndDep(k,p).. sum(i$(not sameas(i,p)),x(i,p,k)) =e= sum(i$...
by cladelpino
6 years ago
Forum: Syntax
Topic: index set control
Replies: 3
Views: 3393

Re: index set control

Hmm, this line is incorrect:

arrive(k).. sum((i,pp),x(i,pp,k)) - sum((p,j)$(p.val=pp.val),x(p,j,k))=e=0;

You don't have "control" of set pp at that point, more informally, which element of pp do you mean to appear ?

What is the constraint supposed to achieve ?
by cladelpino
6 years ago
Forum: Syntax
Topic: Getting error (rPower: FUNC DOMAIN: x**y, x < 0)
Replies: 4
Views: 5252

Re: Getting error (rPower: FUNC DOMAIN: x**y, x < 0)

What do you think of this intrinsic function ?

signPower(x,Y)

It will get you the value of the real branch when it exists (which is your case).
by cladelpino
6 years ago
Forum: Modeling
Topic: Stuck at some tolerance value
Replies: 1
Views: 2141

Re: Stuck at some tolerance value

Is this a MILP model ? Which solver are you using ?