Skip to contents

SavingsRoutes: Clarke-Wright savings for a customer subset. VrptwInsertion: Solomon I1 insertion with time windows. MultiDepotVrp: nearest-depot assignment then savings. PickupDeliveryRoutes: paired cheapest insertion. PeriodicVrp: pattern assignment then savings per day. TripGeneration: cross-classification. Locations are zero-based as in the Python arm morie.fn.vrpext.

Usage

SavingsRoutes(D, customers, demand, capacity, depot = 0)

TripGeneration(households, rates)

Arguments

D

Distance (travel time) matrix.

customers

Customer indices (zero-based).

demand

Demands by location.

capacity

Vehicle capacity.

depot

Depot index (zero-based).

households

Zones by classes matrix.

rates

Trip rate per class.

Value

A list, or a vector for TripGeneration.

References

Clarke, G. and Wright, J. W. (1964). Operations Research 12, 568-581.

Solomon, M. M. (1987). Algorithms for the vehicle routing and scheduling problems with time window constraints. Operations Research 35, 254-265.

Savelsbergh, M. W. P. and Sol, M. (1995). The general pickup and delivery problem. Transportation Science 29, 17-29.

Beltrami, E. J. and Bodin, L. D. (1974). Networks and vehicle routing for municipal waste collection. Networks 4, 65-94.

Examples

D <- rbind(c(0, 2, 2, 3), c(2, 0, 1, 4), c(2, 1, 0, 3), c(3, 4, 3, 0))
SavingsRoutes(D, 1:3, c(0, 1, 1, 1), 2)$routes
#> [[1]]
#> [1] 1 2
#> 
#> [[2]]
#> [1] 3
#> 
TripGeneration(rbind(c(10, 5), c(0, 20)), c(2, 4.5))
#> [1] 42.5 90.0