0% found this document useful (0 votes)
33 views33 pages

Software Tutorial: Huntington Beach, CA April 2012

This document provides an overview and introduction to GAMS, a modeling system for mathematical optimization. It summarizes what GAMS is, its key features including a balanced mix of declarative and procedural elements, platform independence, and hassle-free switching between solution methods. The document also outlines what's new in GAMS, such as support for asynchronous execution, extended mathematical programming, interfaces to other languages, and advances in stochastic programming capabilities.

Uploaded by

vazzoleralex6884
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
33 views33 pages

Software Tutorial: Huntington Beach, CA April 2012

This document provides an overview and introduction to GAMS, a modeling system for mathematical optimization. It summarizes what GAMS is, its key features including a balanced mix of declarative and procedural elements, platform independence, and hassle-free switching between solution methods. The document also outlines what's new in GAMS, such as support for asynchronous execution, extended mathematical programming, interfaces to other languages, and advances in stochastic programming capabilities.

Uploaded by

vazzoleralex6884
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 33

Software Tutorial

Pete Steacy [email protected]


GAMS Development Corp.
www.gams.com

Huntington Beach, CA April 2012

Agenda

What is GAMS?
What is new?

Agenda
What is GAMS?
GAMS at a Glance
A simple Example
Interfacing with other Applications

What does this modeler


have to think about?
Application
Mathematics
Computer Code
GAMS eases the transitions
between these domains.

GAMS Development / Software at a Glance


Roots: World Bank, 1976
Went commercial in 1987
GAMS Development Corp. (US)
GAMS Software GmbH (Europe)
Technical tool provider (Software)
Broad academic & commercial user
community and network
GAMS is used in more than 120
countries
Half of licenses commercially
used

Broad Academic and Commercial Network

Downloads (March 2012)

Total: 495 GB ~ 5,500 monthly downloads

Agenda
What is GAMS?
GAMS at a Glance
A simple Example
Interfacing with other Applications

GAMS at a Glance

Balanced mix of declarative and procedural elements

Platform independence

Hassle-free switch of solution methods

Open architecture and interfaces to other systems

Independent layers

GAMS at a Glance: Balanced mix..


Balanced mix of declarative and procedural elements
Algebra (Expressions): model equations
Relational Algebra (SQL) for data manipulation
Mathematical Notation

10

Notation in GAMS

GAMS at a Glance: Balanced Mix..


Balanced mix of declarative and procedural elements
For
Loop/If

While
Macros
User defined function libraries
11

GAMS at a Glance
Balanced mix of
declarative and procedural
elements

10+ Supported Platforms

Sola

ris 6

Open architecture and


interfaces to other
systems
Independent Layers
12

AXU
Windows
64

Solaris
Sparc
Linux 64

Linux 32

Hassle-free switch of
solution methods

AIX

Windows 32

Mac

Platform independence

HP

GAMS at a Glance

CP

13

XA
COIN-OR
PT
O
C
DI
BDMLP
JAMS

XPRESS

T
CONOP

OS
BARON

MIN

LINDOGLOBAL

EK

Hassle-free switch of
solution methods
Open architecture and
interfaces to other
systems
Independent Layers

GLOMIQO

MOS

H AE

Platform independence

28+ Integrated Solvers

ALP

Balanced mix of
declarative and procedural
elements

GUROBI

CPLEX
SCIP
LINDO

GAMS at a Glance
Balanced mix of
declarative and procedural
elements
Platform independence
Hassle-free switch of
solution methods
Open architecture and
interfaces to other
systems
Independent Layers
14

ASCII
Gams Data eXchange (Binary)
MS Excel, Access
Databases
.
APIs
Component Libraries
.NET Integration

GAMS at a Glance
Independence of

Model and data


Model and solution methods (solver)
Model and operating system
Model and user interface
Interface

Data

Model

Models benefit from

15

Advancing hardware
Enhanced / new solver technology
Improved / upcoming interfaces to other systems

Solver

GAMS at a Glance: Development Environm.


GAMS IDE
Project management
Editor / Syntax coloring / Spell checking
Launching and monitoring of (multiple) GAMS processes
Listing file / Tree view / Syntax-error navigation
Solver selection / Option selection
GDX viewer
Data cube
Data export (e.g. to MS Excel)
Charting facilities
Model libraries
Documentation
16

Agenda
What is new?
GAMS System
Platforms
Solvers
Interfaces
Stochastic Programming

17

What is new: GAMS System


Support for user-defined
Macros
Function libraries
External equations
Asynchronous execution
Extended Mathematical Programming (EMP)
More and further details: http://www.gams.com/docs/
release/release.htm

18

What is new: Asynchronous Execution


$Call / Execute / put_utility 'Exec':
Start jobs from GAMS
Start Job

Wait

Start Job

Wait

Three ways to start a job asynchronously,


at compile time (CT):
$Call.ASync
at execution time (ET):
Execute.Async '';
put_utility 'Exec.ASync' / '';
19

What is new: Platforms


Support for MAC OS X
Cross- platform licenses
Wine (Linux, Mac)

20

What is new: Solvers


GloMIQO: Branch-and-bound global optimization
for mixed-integer quadratic models
Lindo: Global and stochastic optimization
Gather-Update-Solve-Scatter
(Stochastic) EMP

21

What is new: Gather-Update-Solve-Scatter


Setting
cost..

Solve time (secs)


z=e=sum((i,j),f*d(i,j)/1000*x(i,j));
set dict / s.scenario.''
Solvelink=0 (default)
40.297
d.param
.dd
f.param
.ff
Solvelink=%Solvelink.LoadLibrary%
03.625
x.level
.xx /
GUSS
00.797 lp scenario dict;
solve mymodel min z using

Updates model data instead of matrix coefficients/rhs


Hot start (keeps the model hot inside the solver and uses
solvers best update mechanism)
Saves model generation and solver setup time
Model unchanged from scenario to scenario
A priori knowledge of all scenario data
22

What is new: Solving Data Related Models


The common way:

GAMS generates model


and writes it to hd
GAMS writes database to
scratch files on hd
GAMS calls solver and
vacates memory
After solver is done:
GAMS restarts and swaps
database
23

What is new: Solving Data Related Models


The new way:

24

What is new: Interfaces


APIs for various programming
languages (C, Fortran, Delphi)
Component libraries
Better integration into Python

25

What is new: Distributed GAMS APIs


Component Libraries
GAMS
GDX
Option

Supported languages

C, C++, C#
Delphi
Fortran
Java
VBA, VB.Net
Python

Examples/Documentation
26

What is new: GAMS Component Libraries

27

What is new: Calling GAMS from Python

Creating Input for GAMS Model


Callout to GAMS
Reading Solution from GAMS Model
28

What is new: .Net Integration

29

Agenda
What is new?
GAMS System
Platforms
Solvers
Interfaces
Stochastic Programming

30

Stochastic Programming Claims and Facts


Lots of application areas (Finance, Energy,
Telecommunication)
Mature field (Dantzig 55)
Variety of SP problem classes with specialized
solution algorithms (e.g. Benders Decomposition)
Small fraction compared to deterministic
mathematical programming (NEOS)
Few commercially supported solvers for SP
Various frustrations with industrial SP projects
31

Extended Mathematical Programming

Embedded Complementarity Systems


Disjunctive Programs
Bilevel Programs
Extended Nonlinear Programs
Stochastic Programming

Breakouts of traditional MP classes


No conventional syntax
Limited support with common model representation
Incomplete/experimental solution approaches
Lack of reliable/any software
32

Thank You !

33

USA

Europe

GAMS Development Corp.


1217 Potomac Street, NW
Washington, DC 20007
USA

GAMS Software GmbH


Eupener Str. 135-137
50933 Cologne
Germany

Phone: +1 202 342 0180


Fax:
+1 202 342 0181

Phone: +49 221 949 9170


Fax:
+49 221 949 9171

http://www.gams.com
[email protected]
[email protected]

http://www.gams.com
[email protected]
[email protected]

You might also like