1 of 30

A Heuristic for Solving the Swap-Body VRP

Oliver Lum, Xingyin Wang, Ping Chen, Bruce Golden, Edward Wasil

1

2 of 30

Swap-Body VRP

  • Models scenario in which the vehicles have detachable components, and certain customers may be visited by only the smallest vehicle possible (due to space constraints)
  • Single depot
  • Maximum route duration

2

Q = swap-body

capacity

Truck

Train

Figure 1: Truck, semi-trailer, and swap-body

Figure 2: Valid vehicle combinations (truck and train)

3 of 30

Related Problems

3

  • All single-objective
  • Closest variant is the Truck and Trailer Routing Problem (TTRP)
    • No dedicated swap locations
    • Generally load transfer is allowed
    • No vehicle fixed cost

Semet

Gerdessen

Chao

Scheuerer

Lin et al.

Caramia and Guerriero

Villegas et al.

Yu et al.

Derigs et al.

Lin et al.

Lin et al.

Derigs et al.

Drexl

Drexl

4 of 30

Swap-Body VRP Cost

  • Vehicle Cost: Cost of renting the vehicle for use

4

  • Distance: A cost / kilometer for use of the vehicle which is greater for a larger vehicle (gas costs)
  • Service Time

Cust.

Swap Location

  • Swap Action Times
  • Time: An hourly wage associated with driver cost

5 of 30

Swap-Body VRP Swap Actions / Subtours

  • At a designated Swap Location, there are four possible actions, each with an associated performance time:

5

  • Park: The entering train parks its trailing swap-body, leaving it at the swap location for pickup at a later time

Swap Location

Swap Location

Figure 3: Park

Figure 4: Pickup

6 of 30

Swap-Body VRP Swap Actions / Subtours

  • At a designated Swap Location, there are four possible actions, each with an associated performance time:

6

  • Pickup: The entering truck reattaches to the previously parked swap-body, picking it up to continue the tour

Swap Location

Swap Location

Figure 3: Park

Figure 4: Pickup

7 of 30

Swap-Body VRP Swap Actions / Subtours

  • Swap: The incoming truck changes the position of its swap-bodies, and then leaves, still a truck, with a different quantity of goods, (joining two consecutive subtours)

7

Swap Location

Swap Location

Figure 5: Swap

Figure 6: Exchange

8 of 30

Swap-Body VRP Swap Actions / Subtours

8

  • Exchange: The incoming train changes the position of its swap-bodies, parks its trailing swap-body, and leaves a truck

Swap Location

Swap Location

Figure 5: Swap

Figure 6: Exchange

9 of 30

Swap-Body VRP Swap Actions / Subtours

  • A swap-body belongs to its vehicle, and cannot be abandoned. Therefore, it must eventually return to pick up a dropped off swap-body.

9

Cust.

Swap Location

Cust.

Cust.

Cust.

10 of 30

Swap-Body VRP Swap Actions / Subtours

  • A swap-body belongs to its vehicle, and cannot be abandoned. Therefore, it must eventually return to pickup a dropped off swap-body

10

Cust.

Swap Location

Cust.

Cust.

Cust.

11 of 30

Swap-Body VRP Swap Actions / Subtours

  • A swap-body belongs to its vehicle, and cannot be abandoned. Therefore, it must eventually return to pick up a dropped off swap-body

11

Cust.

Swap Location

Cust.

Cust.

Cust.

12 of 30

Swap-Body VRP Swap Actions / Subtours

12

  • A train may choose to serve a customer from a swap-body (or partially from both), but there is no load transfer allowed

10

10

Cust.

5

Demand: 5

13 of 30

Swap-Body VRP Swap Actions / Subtours

13

10

10

Cust.

Demand: 5

8

7

  • A train may choose to serve a customer from a swap-body (or partially from both), but there is no load transfer allowed

14 of 30

Swap-Body VRP Swap Actions / Subtours

14

Subtour Demand: 7

3

5

Swap Location

  • A train may choose to serve a customer from a swap-body (or partially from both), but there is no load transfer allowed

15 of 30

Swap-Body VRP Swap Actions / Subtours

  • A simple procedure for determining the feasibility of a route’s subtours:
    • Check whether any one subtour exceeds demand, (Q), or the sum of the entire route’s demand exceeds 2Q
    • If both are not violated, use a simple dynamic programming approach to construct the closest possible solution to the partition problem (where the elements of the set correspond to the demands of the subtours). If this produces two partitions with sums P1 and P2 , then check P1 < Q and P2 < Q

  • Subtour demands: {2, 5, 6, 3, 2}, Q = 10

15

2

2

5

3

6

Swap-Body 2

10

Swap-Body 1

16 of 30

Swap-Body VRP Swap Actions / Subtours

  • After a route is determined, its optimal orientation can be found by solving the main tour orientation separately from the subtour
  • Because an exchange is the most costly operation, we minimize the number of exchanges, which means minimizing the number of transitions in a binary representation of the subtour swap-body string:

    • Suppose the string was {1,1,0,0,1}
    • This corresponds to {exchange, no action, exchange, no action, exchange}
    • First rule: serve first subtour from swap-body 1 (can always flip and maintain feasibility)
    • Idea: exchange swap-bodies that serve subtours to get consecutive subtours on the same swap-body

16

17 of 30

Swap-Body VRP Example

17

18 of 30

Heuristic

  • Idea: try to repurpose and reuse existing code as much as possible, (in this case, COIN-OR’s VRPH Code from Chris Groër)
    • Flexible for drop-in solver, (i.e., any capacitated vehicle routing problem solver may be used for initialization)
    • When compared to heuristics specifically designed for the SB-VRP and/or exact solvers, solution quality can help quantify the ‘difficulty’ of the variant (the gap is a proxy for the difference in structure)
    • Cuts down development time

18

19 of 30

Heuristic: Two Stages

  • We approach the problem using a two-stage heuristic:

    • In the first stage, we ignore subtours entirely, and model as many elements of the problem as a traditional VRP, (homogeneous fleet, with service times), that allows us to use any VRP solver to obtain a feasible initial solution.

    • In the second stage, we apply improvement procedures, some of which are designed to introduce subtours into the solution, and some of which are slightly modified versions of VRP local search operators.

19

Stage 1

Stage 2

20 of 30

Heuristic: Stage 1

  • (Asymmetric) VRP Model
    • If there are truck-only customers, fleet only contains trucks
    • Service time added to the depot to reflect the vehicle cost

    • Weights in the graph are according to time (since a max route duration exists)
  • Used codes in the VRPH library, with minor modifications to solve the VRP model

20

21 of 30

Heuristic: Stage 2

  • Improvement Procedures
    • 2-Swap between main tours.
    • 2-Opt on a main tour.
    • Distance-constrained evacuation.
    • Distance-constrained exchange.
    • Truck-only customer migration.
  • Perturbation: Exchange several random strings of nodes between main tours.

21

2-Swap

2-Opt

22 of 30

Heuristic: Stage 2

  • Improvement Procedures
    • 2-Swap between main tours.
    • 2-Opt on a main tour.
    • Distance-constrained evacuation.
    • Distance-constrained exchange.
    • Truck-only customer migration.
  • Perturbation: Exchange several random strings of nodes between main tours.

22

Distance-constrained evacuation

23 of 30

Heuristic: Stage 2

  • Improvement Procedures
    • 2-Swap between main tours.
    • 2-Opt on a main tour.
    • Distance-constrained evacuation.
    • Distance-constrained exchange.
    • Truck-only customer migration.
  • Perturbation: Exchange several random strings of nodes between main tours.

23

Distance-constrained exchange

24 of 30

Heuristic: Stage 2

  • Improvement Procedures
    • 2-Swap between main tours.
    • 2-Opt on a main tour.
    • Distance-constrained evacuation.
    • Distance-constrained exchange.
    • Truck-only customer migration.
  • Perturbation: Exchange several random strings of nodes between main tours.

24

Truck-only customer migration

25 of 30

Test Instances

  • VeRoLog 2014 Solver Challenge
    • 27 teams
    • Common set of test data
      • 9 public instances
        • 3 small, 3 medium, and 3 large instances
        • For each size, the three instances were identical, except for the restrictions on which vehicle types could visit the customers
          • In one instance, all customers could be reached by all vehicle types
          • In one instance, all customers could only be reached by trucks
          • In one instance, some customers could be reached by trains, and some could not
      • 3 hidden instances
        • Teams provided only with their performance on these instances
  • Platform
    • Algorithm written in C++
    • Core i7 2.8 GHz (2009), 8 GB RAM PC

25

26 of 30

Computational Results

26

Instance

nSL

nC

VRPH

Improvement

Small

20

57

5452,99

4959

Small (Trailer)

20

57

4930,06

4868,67

Small (Truck)

20

57

5357,03

5356,36

Medium

41

206

8735,81

8293,06

Medium (Trailer)

41

206

8434,87

8330,78

Medium (Truck)

41

206

8698,13

8614,46

Large

99

548

22851,1

21463,2

Large (Trailer)

99

548

21160,5

21020,3

Large (Truck)

99

548

22593,4

22468,7

New

NA

NA

NA

26712,4

New (Trailer)

NA

NA

NA

26658,1

New (Truck)

NA

NA

NA

26712,4

NA = Not Available

nSL = number of swap locations

nC = number of customers

27 of 30

Conclusions

  • Solving the SB-VRP as VRP gives good performance (outperformed initial clustering approach, and two-stage approach to subtour formation)
  • VRPH leverages existing solvers, but the subtour structure seems suboptimal
  • Parts of the swap-body VRP can be simplified (e.g., subtour feasibility, separate fixed vehicle costs and time costs).
  • Most difficult aspect is understanding the interaction between subtours and neighboring routes

27

28 of 30

References

  • Caramia, M., Guerriero, F., 2010. A heuristic approach for the truck and trailer routing problem. Journal of the Operational Research Society 61(7), 1168 – 1180.
  • Chao, I., 2002. A tabu search method for the truck and trailer routing problem. Computers & Operations Research 29(1), 33 – 51
  • Derigs, U., Pullmann, M., Vogel, U., 2013. Truck and trailer routing- problems, heuristics and computational experience. Computers & Oper- ations Research 40(2), 536 – 546.
  • Drexl, M., 2011. Branch-and-price and heuristic column generation for the generalized truck-and-trailer routing problem. Revista De Metodos Cuan- titativos Para La Economia Y La Empresa 12, 5–38.
  • Drexl, M., 2007. On some generalized routing problems. Ph.D thesis, RWTH Aachen University, Germany.
  • Drexl, M., 2014. Branch-and-cut algorithms for the vehicle routing problem with trailers and transshipments. Networks 63(1), 119 – 133.
  • Gerdessen, J. C., 1996. Vehicle routing problem with trailers. European Journal of Operational Research 93(1), 135 – 147.
  • .

28

29 of 30

References

  • Groër, C., 2011. VRPH. http://www.coin-or.org/projects/VRPH.xml.
  • Hansen, P., Mladenovic, N., 2001. Variable neighborhood search: Principles and applications. European Journal of Operational Research 130(3), 449 – 467.
  • Lin, S. W., Yu, V. F., Chou, S. Y., 2009. Solving the truck and trailer routing problem based on a simulated annealing heuristic. Computers & Operations Research 36(5), 1683 – 1692. 24 References
  • Lin, S. W., Yu, V. F., Chou, S. Y., 2010. A note on the truck and trailer routing problem. Expert Systems with Applications 37(1), 899 – 903.
  • Lin, S. W., Yu, V. F., Lu, C. C., 2011. A simulated annealing heuristic for the truck and trailer routing problem with time windows. Expert Systems with Applications 38(12), 15244 – 15252.
  • Scheuerer, S., 2006. A tabu search heuristic for the truck and trailer routing problem. Computers & Operations Research 33(4), 894 – 909.
  • Semet, F., 1995. A two-phase algorithm for the partial accessibility con- strained vehicle routing problem. Annals of Operations Research 61(1), 45–65.

29

30 of 30

References

  • VeRoLog, 2014. http://verolog.deis.unibo.it/news-events/general-news /verolog-solver-challenge-2014.
  • VeRoLog, 2014. http://verolog.deis.unibo.it/sites/verolog.deis.unibo.it/files /VSC2014 %20Problem.pdf.
  • Villegas, J. G., Prins, C., Prodhon, C., Medaglia, A. L., Velasco, N., 2011. A GRASP with evolutionary path relinking for the truck and trailer routing problem. Computers & Operations Research 38(9), 1319 – 1334.
  • Villegas, J. G., Prins, C., Prodhon, C., Medaglia, A. L., Velasco, N., 2013. A matheuristic for the truck and trailer routing problem. European Journal of Operational Research 230(2), 231 – 244.
  • Yu, V., Lin, T., Lu, C., 2011. An ant colony system for solving the truck and trailer routing problem. Journal of the Chinese Institute of Transportation 23(2), 199 – 218.

30