# 4 Vehicle Routing 1
# 4 Vehicle Routing 1
# 4 Vehicle Routing 1
Large shipments reduce transportation costs but increase inventory costs EOQ trades off these two costs Reduce shipment size without increasing transportation costs? Combine shipments on one vehicle
TL vs LTL
Inventory Inventory
?
Transport Transport?
Shared Loads
Issues
Design Routes that
Minimize the transportation cost Respect the capacity of the vehicle
This may require several routes
Classical VRP
n customers must be served from a single depot utilizing vehicles with capacity Q for delivering goods Each customer requires a quantity qi Q of goods Customer orders cannot be split
Graphical Representation
Depot
Additional Features
Depots
Multiple locations
Routes
Maximum time Link costs
Vehicles
Multiple vehicle types and capacities Release, maximum and down times
Objective Functions
Minimize total traveled distance Minimize total traveled time Minimize number of vehicles Maximize quality of service Multiple objective functions
Customers
Time windows (soft or hard) Accessibility restrictions Priority Pickup and delivery
Backhauls
Complications
Simplest Model: TSP
Vehicle Routing
Find best vehicle route(s) to serve a set of orders from customers. Best route may be
minimum cost, minimum distance, or minimum travel time.
Orders may be
Delivery from depot to customer. Pickup at customer and return to depot. Pickup at one place and deliver to another place.
General Setup
Assign customer orders to vehicle routes (designing routes).
Model
Nodes: physical locations
Depot. Customers.
1 4 5 6 3 6 8 8 4 4
Arcs or Links
Transportation links.
depot
depot
depot
depot
TSP
VRP
depot
depot
depot
Can pickups and deliveries be made on same trip? Can they be interspersed?
Not Interspersed
depot
Separate routes
depot
depot
Interspersed Routes
F For clockwise trip: Load at depot ACDFIJK D E A G H
Pickup Delivery
I
K J
Stop 1: Deliver A
Stop 2: Pickup B Stop 3: Deliver C Stop4: Deliver D etc.
CDFIJK
BCDFIJK BDFIJK BFIJK
C
B
depot
Pickup-Delivery Problems
Pickup at one or more origin and delivery to one or more destinations. Often long haul trips.
C B
A
C
depot
Pickup Delivery
Backhauls
If vehicle does not end at depot, should it return empty (deadhead) or find a backhaul?
How far out of the way should it look for a backhaul?
C
Pickup Delivery depot A B A C B
Backhauls
Compare profit from deadheading and carrying backhaul.
Pickup Delivery B A depot A Empty Return D Backhaul C B
Complications
Multiple vehicle types. Multiple vehicle capacities.
Weight, Cubic feet, Floor space, Value.
Many Costs:
Fixed charge. Variable costs per loaded mile & per empty mile. Waiting time; Layover time. Cost per stop (handling). Loading and unloading cost.
More Complications
Time windows for pickup and delivery.
Hard vs. soft
Compatibility
Vehicles and customers. Vehicles and orders. Order types. Drivers and vehicles.
Simple Models
Homogeneous vehicles. One capacity (weight or volume). Minimize distance. No time windows or one time window per customer.
No compatibility constraints.
No DOT rules.
One vehicle. No capacities. Minimize distance. No time windows. No compatibility constraints. No DOT rules.
Multiple Routes
Capacitated VRP: vehicles have capacities.
Weight, Cubic feet, Floor space, Value.
Time windows
Pickup. Delivery. Hard or Soft.
Construction Heuristics
Heuristics that Grow Fragments
Strip Heuristic Nearest neighbor Double-ended nearest neighbor
x
x x x
Sweep Algorithm
Draw a ray starting from the depot. Sweep clockwise (or counter-clockwise) and add customers to the route as encountered.
Sweep Algorithm
Suppose each vehicle capacity = 4 customers
depot
depot
Nearest Neighbor
1. 2. 3. Randomly select a starting node Add to the last node the closest node until no more nodes are available Connect the last node with the first node O(n2) running time
Nearest Neighbor
Add nearest customer to end of the route.
depot
depot
depot
Nearest Neighbor
Add nearest customer to end of the route.
depot
depot
depot
Nearest Neighbor
x x x x x x x x
x x
x
x x
depot
First route
depot
depot
Third route
depot
Nearest Insertion
1. Select a node and the node nearest to it and build a two-node tour 2. Insert in the tour the closest node y until no more nodes are available
O(n2) running time
Nearest Insertion
Insert customer closest to the route in the best sequence. 1 2 3
depot
depot
depot
Nearest Insertion
Insert customer closest to the route in the best sequence. 4 5 6
depot
depot
depot
Nearest Insertion
x x x x x x x x x x x x x x
Nearest Insertion
x x x x x x x x x x x x x x
Nearest Insertion
x x x x x x x x x x x x x x
Nearest Insertion
x x x x x x x x x x x x x x
Nearest Insertion
x x x x x x x x x x x x x x
Nearest Insertion
x x x x x x x x x x x x x x
Nearest Insertion
x x x x x x x x x x x x x x
Nearest Insertion
x x x x x x x x x x x x x x
Nearest Insertion
x x x x x x x x x x x x x x
Nearest Insertion
x x x x x x x x x x x x x x
Nearest Insertion
x x x x x x x x x x x x x x
Nearest Insertion
x x x x x x x x x x x x x x
Nearest Insertion
x x x x x x x x x x x x x x
Nearest Insertion
x x x x x x x x x x x x x x
Nearest Insertion
x x x x x x x x x x x x x x
Farthest Insertion
1. Select a node and the node farthest to it and build a two-node tour 2. Insert in the tour the farthest node y until no more nodes are available
O(n2) running time
Random Insertion
This heuristic adds points to the tour in a random order
x x
x
x x x x x
x
16
18 17
x
19 20
13
12
11
x
10 9
x
23
x
21 4
x
6
x
7
8x
x
26 25
22
x
3
28
x
24
27
x x
29
x
30
x
16
18 17
x
19 20
13
12
11
x
10 9
x
23
x
21 4
x
6
x
7
8x
x
26 25
22
x
3
28
x
24
27
x x
29
x
30
x
16
18 17
x
19 20
13
12
11
x
10 9
x
23
x
21 4
x
6
x
7
8x
x
26 25
22
x
3
28
x
24
27
x x
29
x
30
Christofides Heuristic
Construct an MST[Min. Spanning Tree] Construct a matching of all vertices with odd degree Combine the matching edges with the MST edges, so that now all vertices have an even degree Compute an Eulerian tour through the graph
Savings Method
Start with an initial solution where each customer is serviced individually from the depot
1 3
Clarke G. and J. W. Wright (1964) Scheduling of vehicles from a central depot to a number of delivery points, Operations Research, vol. 12, pp. 568-581.
Savings Method
Savings Calculation
i
cij
c0i
0
cj0
Savings Method
Procedure
1. Compute savings sij for all pairs 2. Choose the pair with the largest savings and join customers in a new route if feasible. 3. If all positive savings have been examined, stop. Otherwise go to 2.
Savings Method
Start with separate one stop routes from depot to each customer. Calculate all savings for joining two customers and eliminating a trip back to the depot.
Sij = Ci0 + C0j - Cij
Order savings from largest to smallest. Form route by linking customers according to savings.
Savings Method
Remove
Add
depot
depot
Savings Method
3
S12
1
5
S13
1
5
3 4
depot
depot
depot
S14
1 2 4
S15
1 5 2 4
3 5
S16
1 2 4
3 5
depot
depot
depot
Small savings
Savings Method
S23
1 2
4 3
S24
1
5
S25
1
5
3 4
depot
depot
depot
S26
1 2 4
S34
1 5 2 4
3 5
S35
1 2 4
3 5
depot
depot
Large savings
Savings Method
S36
1 2
4 3
Large savings
S45
1
5
S46
1
5
3 4
depot
depot
depot
S56
1 2 4
depot
Savings Method
Order savings from largest to smallest.
S35 S34 S45 S36 S56 S23 S46 S24 S25 S12 S26 S13 etc.
Savings Method
Form route by linking customers according to savings.
S35:link 3&5
3
1 2 4
depot
depot
0-3-5-0
0-4-3-5-0
Savings Method
Form route by linking customers according to savings.
S35 S34 S45 S36 S56 S23 S46 S24 S25 S12 S26 S13 etc. 0-3-5-0 0-4-3-5-0
Savings Method
S45: skip
3 1 2
S36: skip
3 1 5 2
S56:link 5&6
3 1 5 2
depot
depot
depot
Savings Method
S23: skip
3 1 2
S46: skip
3 1 5 2
S24:link 2&4
3 1 5 2
depot
depot
depot
Savings Method
S25: skip
1 2 4 3 5
depot
depot
Savings Method
Form route by linking customers according to savings.
S35 S34 S45 S36 S56 S23 S46 S24 S25 S12 0-3-5-0 0-4-3-5-0 skip skip 0-4-3-5-6-0 skip skip 0-2-4-3-5-6-0 skip 0-1-2-4-3-5-6-0
Different Approaches
Route First
Vehicle Cap: 15
4 6
x2 x3
x6
x
2
5
x
x5
5
x
3
x
4
x
6
x
5
x5
Cluster First
Sweep Heuristic
4
Vehicle Cap: 15
6
x2 x3
x6
x
2
5
x
x5
5
x
4
x
6
x
5
x5
Cluster Algorithms
Select certain customers as seed points for routes.
Farthest from depot. Highest priority. Equally spaced.
depot
depot
Select 3 seeds
depot
depot
depot
depot
Select 3 seeds
depot
depot
Improvement Heuristics
Intra-route improvement
Inter-route improvement
depot
depot
Starting routes
Improved routes
Move a customer from one route to another. Switch two customers between routes.
K-opt Exchange
Replace k arcs in a given route by k new arcs so the result is a route with lower cost. 2-opt: Replace 4-5 and 3-6 by 4-3 and 5-6.
Original route
3 1 2
Improved route
3 5
2
4 5
depot
depot
2-opt Exchange
2-Opt
x x x x x x x x x x x
x
x
3-opt Exchange
3-opt: Replace 2-3, 5-4 and 4-6 by 2-4, 4-3 and 5-6.
Original route
3 1 2 4 5 1
Improved route
3 2 4 6 5
depot
depot
Improvement Heuristics
Cluster with Nearest Neighbor
depot
depot
Starting routes
Optimized routes