🧩 Constraint Solving POTD:Problem of the Day: Vehicle Routing Problem with Time Windows (VRPTW) #59704
Closed
Replies: 1 comment
|
This discussion has been marked as outdated by Constraint Solving — Problem of the Day. A newer discussion is available at Discussion #59949. |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Problem Statement
The Vehicle Routing Problem with Time Windows (VRPTW) asks: given a depot, a set of customers with demands and time windows (earliest and latest service times), and a fleet of homogeneous vehicles with limited capacity, find a set of routes that:
Concrete Instance (5-node example):
This route respects capacity (1+2+2+3 = 8, exceeds—so infeasible; try Depot → C1 → C4 → Depot instead).
Input: Locations, demands, time windows, vehicle capacity, travel-time matrix.
Output: Assignment of customers to routes, arrival/departure times at each stop, or "infeasible" if no solution exists.
Why It Matters
Modeling Approaches
Approach 1: Mixed-Integer Programming (MIP)
Paradigm: Linear constraints over binary and continuous variables.
Decision Variables:
x_{i,j,k}∈ {0,1}: vehicle k travels directly from customer i to customer jt_{i,k}≥ 0: arrival time at customer i using vehicle kload_{k}≥ 0: vehicle k's load at any pointKey Constraints:
a_i ≤ t_{i,k} ≤ b_i∀i,k (wherea_i,b_iare earliest/latest times)t_{j,k} ≥ t_{i,k} + service_i + dist(i,j) − M(1 − x_{i,j,k})(big-M constraint)Trade-offs:
Approach 2: Constraint Programming (CP)
Paradigm: Rich global constraints, domain propagation, backtracking search.
Decision Variables:
succ[i]∈ Customers ∪ {Depot}: successor of customer i in its routevehicle[i]∈ {1..k}: vehicle assigned to customer iarrival[i]∈ [0, horizon]: arrival time at customer iKey Constraints:
circuit(succ)ensures routes form valid cyclesall_different(vehicle)distributed across routes; or usetableconstraint for allowed sequencesarrival[j] ≥ arrival[i] + service_i + dist(i, j)wheresucc[i] = ja_i ≤ arrival[i] ≤ b_icumul(succ, demand) ≤ capacityusing cumulative/lex_chain global constraintTrade-offs:
Key Techniques
1. Time-Based Constraint Propagation
Time windows couple arrival times across the route. The
cumulativeconstraint and its variants (e.g.,circuitwith time) efficiently propagate:b_i, and travel to i takesd_mintime, then predecessor j must leave byb_i − d_min − service_i.2. Vehicle Routing Heuristics & Local Search
For large instances, exact methods are often impractical. Metaheuristics are essential:
3. Symmetry Breaking & Search Strategy
Routes are inherently symmetric (Depot → A → B → Depot ≡ Depot → B → A → Depot with reversed directions). Symmetry-breaking constraints can reduce search:
Challenge Corner
Open Questions for You:
Model Reduction: Can you reformulate VRPTW with fewer variables (e.g., only
succ[i]andarrival[i], deriving vehicle assignment implicitly) without losing propagation strength? What trade-offs emerge?Symmetry & Canonical Solutions: In a VRPTW with multiple identical vehicles,
k!route permutations represent the same solution. Propose three symmetry-breaking constraints that do NOT artificially limit optimal solutions.Hybrid Strategies: How would you combine CP (for time-window propagation and feasibility finding) with Mixed-Integer Programming (for final optimization)? Sketch a Benders' decomposition or column-generation approach.
Practical Extensions: Real-world VRPTW adds:
Which extension would you tackle first, and why?
References
Solomon, M. M. (1987). "Algorithms for the Vehicle Routing and Scheduling Problems with Time Window Constraints." Operations Research, 35(2), 254–265.
Hooker, J. N. (2005). "Planning and Scheduling by Logic-Based Benders Decomposition." Operations Research, 55(3), 588–602.
Shaw, P. (1998). "Using Constraint Programming and Local Search Methods to Solve Vehicle Routing Problems." CP-98 Principles and Practice, LNCS 1520.
OR-Tools Vehicle Routing Library (Google). [(developers.google.com/redacted)(developers.google.com/redacted)
Happy problem-solving! Whether you reach for MIP, CP, or a hybrid approach, VRPTW offers a rich playground for optimization techniques. 🚚
All reactions