The purpose of this program is to solve the Vehicle Routing Problem using the Clarke and Wright algorithm
To do so, the program performs the following steps:
- Generate a set of random 2D points from a given range
- Generate a random quantity of needs for each point
- Calculate the distance matrix
- Create a DiGraph from the distance matrix
- Create a VRP problem, with given vehicle capacity
- Solve the VRP problem using the Clarke and Wright algorithm
- Check if none of the vehicles was overloaded
- Plot the best route you have found
- Create a random route through all the points and compare it to the best route (optional)
- You can choose the number of points and the range of their coordinates
- There is only one magazine, which is the first point in the list
- The coordinates of the magazine are generated somewhere in the middle of the standard points range
- You can choose the needs range
- You can choose the vehicle capacity and the number of vehicles
- You can choose the time limit for the algorithm
- You can choose to use all the vehicles or only the ones that are needed
- If any of the vehicles is overloaded, the program will raise an exception
- You can choose to create a random route through all the points and compare it to the solution