Earl learns about belonging
How transport optimisation groups orders before it routes them, and why locations, time windows, capacities and driver skills make clustering the hard part.
11 min read →Article
The Clarke-Wright savings algorithm from 1964, still running inside commercial transport optimisers, and why chaining stops beats visiting them one at a time.
By Richard Faint · 26 July 2026 · 6 min read
The Clarke-Wright savings algorithm starts with separate depot-to-customer trips and repeatedly joins routes where the combination saves distance. It is a practical construction heuristic, but every attractive saving still has to respect vehicle capacity, time windows and other operational constraints.
The title is a joke; Clarke is not a character in the sitcom. The subject is the Clarke-Wright savings algorithm, which builds vehicle routes by merging separate out-and-back trips wherever doing so saves distance.
One of the things I enjoy about My Name Is Earl is that Earl’s list looks deceptively simple. Every item is just another person he has wronged so find them, apologise, make things right, cross them off, and move on. The difficult part isn’t deciding who to visit; it’s deciding how to visit them.
Imagine Randy planning the day. If you’ve watched the series, you can probably hear the conversation:
“We’ll leave the motel, see Lloyd about the lemon car, come back. Then we’ll go and see Joy, come back. Then we’ll head over to the Crab Shack and see Darnell, come back.”
Earl would just stare at him. “Randy… Joy and Darnell are practically next door to each other.”
Randy shrugs. “Yeah… but they’re different things on the list.”
It’s funny because we’ve all seen someone plan work exactly like that. And every day, thousands of transport planners are trying to stop vehicles doing precisely the same thing.
In my previous article, I looked at grouping—the process of deciding which deliveries belong together in the first place. Once those groups exist, another question immediately appears:-
This is known as the Vehicle Routing Problem, and while finding the perfect answer is incredibly difficult, finding a very good answer can be surprisingly elegant. One of the most influential techniques to solve it was published in 1964 by Clarke and Wright. More than sixty years later, versions of their algorithm still sit inside commercial transport optimisation software.
Let’s leave Earl for a moment and imagine a transport office in Leeds. The depot has four deliveries: Bradford, Wakefield, Huddersfield, and Halifax.
A new planner decides to keep everything simple. One vehicle leaves the depot, delivers to Bradford, and returns. Another heads to Wakefield and comes back. A third goes to Huddersfield, and a fourth to Halifax. The plan works customers receive their deliveries, drivers know where they’re going, and nobody has technically made a mistake but the vehicles spend much of the morning repeating exactly the same expensive journey leg leaving the depot and driving back again.
If you’ve ever driven across West Yorkshire, you’ll know something immediately stands out. Huddersfield and Halifax are close together, while Bradford sits naturally on the western side of Leeds. Why keep returning to Leeds after every stop when the next customer is only a few miles away? That question is the foundation of the Clarke-Wright Savings Algorithm.
The algorithm doesn’t begin by searching for the perfect route. Instead, it asks a much simpler question: which two deliveries save the most distance if we connect them?
Suppose traveling from Leeds to Huddersfield is about 18 miles, and Leeds to Halifax is roughly 25 miles. Huddersfield to Halifax, however, is only around 8 miles. Treat them separately and the vehicle drives from Leeds to Huddersfield and back, then Leeds to Halifax and back—a total of 86 miles. Connect them together, and suddenly the route becomes Leeds-Huddersfield-Halifax-Leeds, dropping the total to 51 miles.
One unnecessary journey back to Leeds has disappeared. Nothing magical has happened we’ve simply stopped wasting miles. That wasted mileage is what Clarke and Wright called the “saving,” mathematically calculated as:
Clarke and Wright called this the saving.
Saving = (Depot → A) + (Depot → B) − (A → B)
Calculate that value for every pair of customers, sort the results from highest to lowest, and start joining routes whenever it makes operational sense. It’s one of those rare algorithms that feels almost obvious once someone explains it.
Imagine Randy running a haulage company. His planning philosophy might look something like this:
“Finished in Huddersfield? Great. Better drive all the way back to Leeds before going to Halifax.”
Every experienced planner reading this is probably cringing because while Randy is technically following the delivery list, he’s completely ignoring geography. Experienced planners don’t think in lists; they think in flow. If a vehicle is already in Huddersfield, the next question isn’t “What’s next on the paperwork?” It’s “What’s nearby?” That tiny shift in thinking can remove hundreds of miles from a day’s operation, and the Clarke-Wright algorithm simply turns that instinct into mathematics.
Of course, geography isn’t the only thing that matters. Perhaps the Halifax delivery contains frozen food while Huddersfield is ambient freight. Perhaps one customer only accepts deliveries after 10:00, the combined weight exceeds the vehicle’s capacity, or one location requires a rigid vehicle while the other is scheduled on an articulated trailer.
Every proposed saving must pass these real-world constraints before it’s accepted. This is why transport optimization isn’t just about the shortest distance; it’s about finding the shortest feasible distance. The distinction matters, because a mathematically beautiful route that can’t actually be driven has no value whatsoever.
Technology has completely transformed transport. We have live GPS tracking, real-time traffic feeds, machine learning predicting arrival times, digital twins, AI assistants, and cloud-based optimization engines. Yet buried inside many of those systems is still an idea first published in 1964. This isn’t because the industry hasn’t moved on, but because Clarke and Wright solved an important part of the problem astonishingly well by producing a high-quality starting solution very quickly. Once that first route exists, newer optimization techniques can step in to improve it further.
One of the reasons My Name Is Earl worked so well is that Earl gradually learns life isn’t about blindly following a list. Sometimes fixing one mistake naturally leads to fixing another nearby. If he’s already speaking to Joy, it makes sense to see Darnell at the Crab Shack while he’s there. If he’s already helping one person, perhaps another problem can be solved on the same journey. The destination list stays exactly the same; only the order changes. That’s the essence of the Clarke-Wright Savings Algorithm. The work doesn’t change but the thinking does.
While Clarke-Wright gives us an excellent first route, it is rarely the best one. Look closely at almost any generated route and you’ll usually spot something that feels slightly e.g. inefficient two routes cross unnecessarily, or a vehicle doubles back on itself.
In the next article, we’ll look at one of the simplest and most effective optimization techniques ever developed: 2-opt. It doesn’t rebuild the route from scratch. Instead, it asks a wonderfully simple question: “What happens if we just swap these two stops?” Sometimes, that’s all it takes to turn a good route into a great one.
Try it interactively. Open the Clarke-Wright savings simulator on its own page → — full-width, with a walkthrough of what each control does.