Are there any R packages to solve Vehicle Routing Problem
I looked around but could not find any… Any leads?
VRP is a classic combinatorial optimization challenge and has been an active area of research for operations research gurus for 30+ years. Although a lot of research and progress has been made in academia, enterprises are far behind in using this technology effectively, primarily because of lack of integration with business friendly tools (a.k.a Excel).
Problem description: I need to solve a VRP-TW (VRP with Time Window) problem. I’ve a list of jobs that need to be serviced by a group of vehicles. The schedule created to service these jobs should minimize the total distance traveled by vehicles, with the following conditions:
– Customer SLA (time window promised to customer) should be met
– The parts in the vehicle should match what the job requires
I have the following information available about the jobs and vehicles
– Job ID, Job address, Job duration, Job priority, Earliest start time, Latest finish time, Date, Parts required
– Vehicle ID, Base location (address), Start time, End time, Parts
Currently, such problems are solved in enterprises using commercial softwares like Matlab (sample code
), iLog etc. But I’m wondering if there’s any solution available using R.
MY RESEARCH SO FAR
Disclaimer: I’m completely new to Operations Research, so this might be amateurish
1. I found open source implementations in C, C++ and Java on COmputational INfrastructure forOperations Research website.
2. Commercial solvers like Concorde seem to get great reviews in solving Traveling Salesman Problem (TSP)
package helps with Traveling Salesman Problem but I’m not sure how to use it for multiple Travelling Salesmen Problem (mTSP), which is similar to VRP. TSP offers a simple API and hooks to several solvers including Concorde
package is a wrapper on COIN’s Symphony
project (a solver for mixed integer linear programs) but lacks any useful documentation on solving mTSP or VRP problems using it
– Zimpl is open source but can only solve small scale problems e.g. less than 19 vehicles! Here are some Zimpl examples
. You can try TSP and Capacitated Facility Location Problem in Zimpl user guide
– My team mate had tried GAMS but found it lacking for large scale problems
– AMPL examples (TSP
) seemed difficult to scale to mid-large scale problems. Their documentation
and user interface wasn’t easy
– AIMMS looked interesting, It allowed me to access its complete functionality in its free trial download and offered several examples that looked promising (great user interface) – Gate assignment, Distribution center, Transport, Employee Scheduling, Travelling Salesman Problem. Here’s a AIMMS case study
6. Some consumer apps
offer a great user interface but aren’t suitable for mid-large scale problems (100+ jobs, 50+ technicians).