SolveEngine

Introduction

GAMS/SolveEngine allows users to solve GAMS models using solvers from the Satalia SolveEngine. The SolveEngine aggregates different solution algorithms for optimization problems and automatically selects an algorithm that seems to suite best for a given model instance. Currently, LP and MIP problems can be handled by the SolveEngine.

The GAMS/SolveEngine link comes for free with any licensed GAMS system. Users must have an API key for the Satalia SolveEngine to submit jobs. The GAMS/SolveEngine link submits a GAMS model instance to the SolveEngine server, schedules it for processing, and waits until the problem has been solved.

Usage

To run GAMS/SolveEngine, specify to use solveengine as solver. For example, if one wishes to solve the trnsport.gms model, one would run

> gams trnsport.gms solver=solveengine

A SolveEngine API key is necessary to submit jobs to the SolveEngine. Once a user has registered for SolveEngine, the API key is available after login. To make GAMS/SolveEngine aware of this key, either set the environment variable SOLVEENGINE_APIKEY to the key string, or use the option apikey.

Currently, only the GAMS option reslim is supported by the GAMS/SolveEngine link. When a running SolveEngine job is interrupted before it is completed (either by hitten the timelimit or by receiving a user-interrupt signal (Ctrl+C)), no solution will be available.

All GAMS/SolveEngine specific options are described in the section Options.

Log

Running model trnsport using GAMS/SolveEngine gives the following log:

> gamslib trnsport
Copy ASCII : trnsport.gms
> gams trnsport.gms lp solveengine optfile 1
--- Job trnsport Start 07/14/17 15:00:27 24.9.0 r60947 LEX-LEG x86 64bit/Linux
GAMS 24.9.0   Copyright (C) 1987-2017 GAMS Development. All rights reserved
--- Starting compilation
--- trnsport.gms(69) 3 Mb
--- Starting execution: elapsed 0:00:00.001
--- trnsport.gms(45) 4 Mb
--- Generating LP model transport
--- trnsport.gms(66) 4 Mb
---   6 rows  7 columns  19 non-zeroes
--- Executing SOLVEENGINE: elapsed 0:00:00.002
This is the GAMS link to Satalia SolveEngine.
Reading parameter(s) from "solveengine.opt"
>>  apikey ***secret***
Finished reading from "solveengine.opt"
Submitting Job.
Scheduling Job. ID: 57636b79317861c7be20e9f0088d4136120f37ba
     1.0s Job Status: queued
     2.2s Job Status: completed
Retrieving results.
Status: optimal
Objective Value: 1.5367500000e+02
--- Restarting execution
--- trnsport.gms(66) 2 Mb
--- Reading solution for model transport
***
*** Solver did not provide marginals for model transport
***
--- trnsport.gms(68) 3 Mb
*** Status: Normal completion
--- Job trnsport.gms Stop 07/14/17 15:00:30 elapsed 0:00:03.565

First, the options file solveengine.opt is read and echoed to the log. While doing so, echoing the API key itself is suppressed. Then a "job" is created on the SolveEngine server, to which the model instance is submitted. Next, the job is scheduled to be solved. Here, also the ID of the job on the SolveEngine server is printed. Further, a progress report on the solve status is printed. Finally, results are retrieved from SolveEngine and passed back to GAMS.

Options

The following options can be set via a solver options file:

Option Description Default
apikey Satalia SolveEngine API key
debug Enabling debug output
Range: [0, 2]
0
printjoblist Prints list of SolveEngine jobs 0
verifycert Whether to verify SSL certificate using the machines CA certificates storage 1

Troubleshooting

If submitting a job to the SolveEngine fails with an SSL certificate problem, then one may disable the corresponding check by using the option verifycert.

Attention
Disabling verification of the certificate makes the communication insecure as it cannot be ensured anymore that GAMS is indeed communicating with the Satalia SolveEngine server.