GAMS [ Home | Downloads | Documentation | Solvers | APIs | Tools | Model Libraries | Resources | Sales | Support | Contact Us | Search ]

GAMS Python API - Tutorial and Examples
transport1.py File Reference

This is the 1st model in a series of tutorial examples. More...

Go to the source code of this file.

Variables

 transport1.ws = GamsWorkspace(system_directory = sys.argv[1])
 
 transport1.t1 = ws.add_job_from_file("trnsport.gms")
 
 transport1.opt = ws.add_options()
 
 transport1.all_model_types
 
 transport1.file = open(os.path.join(ws.working_directory, "xpress.opt"), "w")
 
 transport1.optfile
 

Detailed Description

This is the 1st model in a series of tutorial examples.

Here we show:

  • How to run a GAMSJob from file
  • How to specify the solver
  • How to run a job with a solver option file

Definition in file transport1.py.