## Search found 11 matches

- 1 week ago
- Forum: Announcements
- Topic: GAMS Studio
- Replies:
**1** - Views:
**87**

### GAMS Studio

We’ve received some user feedback recently that went like this: “I am confused. Rumor has it that the GAMS folks are working on a new IDE. Is GMS-Manager the new GAMS-supported IDE?” This is an important question that deserves a good answer. GMS-Manager is software developed by Ingo Huck and is dist...

- 1 month ago
- Forum: Solvers
- Topic: CPU time for large-scale instances
- Replies:
**2** - Views:
**123**

### Re: CPU time for large-scale instances

Moosavi, I would not call the problem size you mention - 23k vars and 4k constraints - large-scale. If this is an LP, there is nothing remarkable about solving such a problem in seconds. You say it is a MIP, but you don't say how many of these 23k vars are discrete. And even if many are discrete, th...

- 1 month ago
- Forum: Syntax
- Topic: Edist Function
- Replies:
**1** - Views:
**108**

### Re: Edist Function

Bilal, I tried out the search function within our documentation on our Web site (not the Web site search, but the search within the documentation) . I could search just within model libraries and found a nice example where the edist function is used in the the relief model: https://www.gams.com/late...

- 1 month ago
- Forum: Syntax
- Topic: LOOP Problem
- Replies:
**3** - Views:
**196**

### Re: LOOP Problem

Have you had a chance to look over the rules for this forum (see the Rules tab)? It's good form to provide your name and affiliation. That increases the chance you'll get a helpful answer. In this case, divide and conquer is a good strategy. The first loop in the BASIC code computes L and Z, but it ...

- 1 month ago
- Forum: Modeling
- Topic: HELP with (LHS = 0, INFES = 1 ****) and Local Optimum
- Replies:
**2** - Views:
**189**

### Re: HELP with (LHS = 0, INFES = 1 ****) and Local Optimum

Deepak, If you solve with a local solver, you get a local result, i.e. a result that satisfies local optimality conditions. The solver may not know your model is convex: in this case, it cannot say it is returning a global solution. The equation listing you mention is created by GAMS/Base before the...

- 6 months ago
- Forum: Syntax
- Topic: Multiplication and Addition with alias numbers and the error 148 & 133
- Replies:
**4** - Views:
**353**

### Re: Multiplication and Addition with alias numbers and the error 148 & 133

It looks like there is an asterisk (i.e. a '*') in the first column of one of the lines defining your equations. In other columns, a '*' can mean multiplication, but in the first column, it indicates that this line is a comment.

-Steve

-Steve

- 6 months ago
- Forum: Syntax
- Topic: how to model abs(variable) linearly
- Replies:
**20** - Views:
**1201**

### Re: how to model abs(variable) linearly

Hi Steve, May I suggest changing equation f into: f .. sqr(x-cx) + sqr(-y-cy) =L= 1; This way you y will be negative and it shows better that the abs tricks work best, Gideon Gideon, Thanks for the suggestion. Indeed, it helps to show the reform tricks are working when the abs() function is "evalua...

- 7 months ago
- Forum: Syntax
- Topic: how to model abs(variable) linearly
- Replies:
**20** - Views:
**1201**

### Re: how to model abs(variable) linearly

Yanzhiping, I am attaching a little example that has 3 versions of the same model. A variant of this will be in the updated docs so I thought I'd give it a trial run here. The first uses abs() and therefore solves as a DNLP. This is not the recommended way. It is what you want to avoid. The second r...

- 7 months ago
- Forum: Syntax
- Topic: how to model abs(variable) linearly
- Replies:
**20** - Views:
**1201**

### Re: how to model abs(variable) linearly

I was just editing something in the next generation of GAMS documentation about this very example, so I'll comment here that you need to be minimizing abs(Q). If you're maximizing then you'll have to go to a MIP or perhaps a nonlinear formulation, but the nonlinear problem will be nonconvex so you m...

- 9 months ago
- Forum: Modeling
- Topic: condition to define a constraint
- Replies:
**5** - Views:
**882**

### Re: condition to define a constraint

The quick way to do this is with a dollar condition in the constraint: set i /1*10/ alias(i, j); equations myconstraint(i,j); myconstraint(i,j)$[not sameas(i,j)] .. function(i,j) =e= 0; The logic is all part of the myconstraint definition. Since it's simple, that works well. For more complicated con...