Loading...
Searching...
No Matches
tsp Namespace Reference

Variables

str GAMS_MODEL
 
sys sys_dir = sys.argv[1] if len(sys.argv) > 1 else None
 
GamsWorkspace ws = GamsWorkspace(system_directory=sys_dir)
 
int cuts_per_round = 10
 
int cur_cut = 0
 
int cmax = 0
 
GamsWorkspace cut_data = ws.add_database()
 
GamsWorkspace cc = cut_data.add_set("cc", 1)
 
GamsWorkspace acut = cut_data.add_parameter("acut", 3)
 
GamsWorkspace rhscut = cut_data.add_parameter("rhscut", 1)
 
list n = []
 
GamsWorkspace job = ws.add_job_from_string(GAMS_MODEL)
 
GamsWorkspace cp = ws.add_checkpoint()
 
GamsWorkspace opt = ws.add_options()
 
 gams_options
 
 checkpoint
 
GamsWorkspace mi = cp.add_modelinstance()
 
GamsWorkspace mi_acut = mi.sync_db.add_parameter("acut", 3)
 
GamsWorkspace mi_rhscut = mi.sync_db.add_parameter("rhscut", 1)
 
dict graph = {}
 
list not_visited = list(n)
 
list i = not_visited[0]
 
list sub_tour = [i]
 
 value
 
 end
 

Variable Documentation

◆ acut

GamsWorkspace tsp.acut = cut_data.add_parameter("acut", 3)

Definition at line 95 of file tsp.py.

◆ cc

GamsWorkspace tsp.cc = cut_data.add_set("cc", 1)

Definition at line 94 of file tsp.py.

◆ checkpoint

tsp.checkpoint

Definition at line 117 of file tsp.py.

◆ cmax

int tsp.cmax = 0

Definition at line 90 of file tsp.py.

◆ cp

GamsWorkspace tsp.cp = ws.add_checkpoint()

Definition at line 107 of file tsp.py.

◆ cur_cut

int tsp.cur_cut = 0

Definition at line 87 of file tsp.py.

◆ cut_data

GamsWorkspace tsp.cut_data = ws.add_database()

Definition at line 93 of file tsp.py.

◆ cuts_per_round

int tsp.cuts_per_round = 10

Definition at line 84 of file tsp.py.

◆ end

tsp.end

Definition at line 167 of file tsp.py.

◆ GAMS_MODEL

str tsp.GAMS_MODEL

Definition at line 18 of file tsp.py.

◆ gams_options

tsp.gams_options

Definition at line 117 of file tsp.py.

◆ graph

dict tsp.graph = {}

Definition at line 138 of file tsp.py.

◆ i

dict tsp.i = not_visited[0]

Definition at line 146 of file tsp.py.

◆ job

GamsWorkspace tsp.job = ws.add_job_from_string(GAMS_MODEL)

Definition at line 106 of file tsp.py.

◆ mi

GamsWorkspace tsp.mi = cp.add_modelinstance()

Definition at line 125 of file tsp.py.

◆ mi_acut

GamsWorkspace tsp.mi_acut = mi.sync_db.add_parameter("acut", 3)

Definition at line 126 of file tsp.py.

◆ mi_rhscut

GamsWorkspace tsp.mi_rhscut = mi.sync_db.add_parameter("rhscut", 1)

Definition at line 127 of file tsp.py.

◆ n

list tsp.n = []

Definition at line 98 of file tsp.py.

◆ not_visited

list tsp.not_visited = list(n)

Definition at line 144 of file tsp.py.

◆ opt

tsp.opt = ws.add_options()

Definition at line 108 of file tsp.py.

◆ rhscut

GamsWorkspace tsp.rhscut = cut_data.add_parameter("rhscut", 1)

Definition at line 96 of file tsp.py.

◆ sub_tour

list tsp.sub_tour = [i]

Definition at line 147 of file tsp.py.

◆ sys_dir

sys tsp.sys_dir = sys.argv[1] if len(sys.argv) > 1 else None

Definition at line 80 of file tsp.py.

◆ value

tsp.value

Definition at line 155 of file tsp.py.

◆ ws

GamsWorkspace tsp.ws = GamsWorkspace(system_directory=sys_dir)

Definition at line 81 of file tsp.py.