Skip to content

cintrano/p-median

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

22 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

p-median

Description

This is a framework in C++ to solve the p-median problem.

Build

You can use the make file

$ cd project_path 
$ make

Or use command line compilation

$ g++ -static -std=c++11 -static-libgcc -static-libstdc++ -O3 *.cpp -o run

It is also recomended the use of the flags: -Wall -Werror -Wextra -pedantic

Usage

After compile the project in the run file, you can use as follows:

$ run P N F FLAG_LIST

where:

  • P the parameter p of the p-median problem.
  • N the number of customers.
  • F the number of facilities.
  • FLAG_LIST the rest of the parameters to configurate the instance. The parameter options are:
    • --input the inputs files.
    • --output path to the output files.
    • --no-output if it is necessary to write output files. Default value is TRUE.
    • --debug print the logs. Default value is FALSE.
    • --seed NUMBER seed to the random number generator.
    • --algo OPT algorithm to execute, the implemented algorithms are: VNS, GA.
    • --pop SIZE population size.
    • --iter maximum number of iterations
    • --neighborhood OPT neighbourhood strategy.
    • --k SIZE neighbourhood size.
    • --gen OPT process to generate the initial population.
    • --kmax NUMBER parameter of the VNS.
    • --Kmayus NUMBER parameter of the VNS.
    • --lambda NUMBER parameter of the GA.
    • --m NUMBER parameter of the VNS.
    • --accept OPT NUMBER parameter of the VNS.
    • --next OPT NUMBER parameter of the VNS.
    • --change OPT parameter of the VNS.
    • --shake OPT parameter of the VNS.
    • --ls1 OPT PARAM local search 1.
    • --ls2 OPT PARAM local search 2.
    • --ga-sel OPT selection operator of the GA.
    • --ga-cross OPT crossover operator of the GA.
    • --ga-mut OPT PROB mutation operator of the GA.
    • --ga-repl OPT replacement operator of the GA.

Publications

Cintrano C., Chicano F., Stützle T., Alba E. (2018) Studying Solutions of the p-Median Problem for the Location of Public Bike Stations. Advances in Artificial Intelligence. CAEPIA 2018. Lecture Notes in Computer Science, vol 11160. Springer, Cham. DOI: https://doi.org/10.1007/978-3-030-00374-6_19

Thanks

About

Framework in C++ to solve the p-median problem.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published