My Master's thesis. It's about trains π. It is a metaheuristic solver assigning trainset types to individual connections.
Full text is here.
The solver uses libconfig library for parsing input files.
You can use cmake and the provided CMakeLists.txt:
mkdir build && cd build
cmake ..
makeThe resulting binary will be in tscp_solver file.
Solver is run as:
./tscp_solver [OPTION...] PROBLEM_FILE
Default run without options runs the simulated annealing algorithm for 2 million steps with a feasible solution using only the second trainset as the initial solution.
-v,--verboseProduce verbose output-s,--steps=NNumber of steps of the algorithm (default is 2 million)-e,--empty_initUse empty initial solution-i,--init_file=FILELoad the initial solution from csv file-o,--output_sol=FILEWrite the solution to file as csv-m,--init_temp=NInitial temperature for simulated annealing-t,--tabuUse tabu search (default is simulated annealing)-n,--neigh=NNumber of generated neighbors for tabu search-u,--tabu_len=NTabu list length-?,--helpGive this help list--usageGive a short usage message
Solver requires problem description in the libconfig format. Examples of such files can be found in the data directory.