Writing

Why I'm writing about routing

9 Aug 2025 · 2 min read

  • meta
  • routing

I’ve spent the last eight years turning logistics problems into production systems, and most of that time has gone into one question: given a fleet, a pile of orders and a long list of rules, what is the best plan? Most of what I’ve learned lives in design docs, Slack threads and my own head. This blog is where I’ll write it down.

The VRP series

The main project here is a series on vehicle routing: 70 posts in 13 parts, written for someone starting from zero. It starts with the Traveling Salesman Problem and goes all the way to how production routing engines are built.

  • Parts 0–7 build up the field step by step: exact methods, construction heuristics, local search, iterated local search, the wider metaheuristic family, and finally the jump from TSP to VRP. Each post ends with a limitation that the next post fixes.
  • Parts 8–12 are reference parts on VRP variants, uncertainty and scale, running routing in the real world, evaluating solvers, and where the research is heading.

Every post uses the same running example, berlin52 from TSPLIB (52 cities, optimal tour length 7,542), so you can see exactly how far each method lands from optimal. The early parts use plain Python you can read line by line; from Part 5 on, the code uses PyVRP and reinterpretcat/vrp.

Other things I’ll write about

  • Running OSRM and Valhalla yourself, and when that beats paying for an API.
  • AI agents that do real work, like the dispatch agent that took route planning from six hours to twenty minutes.
  • How I use Claude Code, Cursor and MCP day to day.
// The sweep heuristic behind the map on this site's home page:
// order stops by angle around the depot, then cut them into routes by capacity
const routes = chunk(stops.sort((a, b) => angle(a) - angle(b)), capacity);

← All writing