Quick Wins with Optimization

Our mini-series on route planning focuses on the advantages and possibilities of mathematical optimization for route planning. In part one we showed how you can gain a lot and make considerable savings with just simple means. However, optimization can do a great deal more. Once you have a model and the first optimization, other aspects can be included quite easily and you can save on CO2, to name one example, along the way.


Let’s use our example from part 1 –  the delivery service that uses motor scooters to supply its customers. Automated route planning is effected every day now. Now the question is how easy it is to consider the CO2 emissions in route planning?

CO₂ – just a cost factor?

It is quite obvious that a net surplus of CO2 emissions is a major cause of climate change. Furthermore, combating its impact is going to cost somebody some money one day, a lot of money in fact.

However, if you don’t want to wait around until the impact needs to be combatted but want to start making savings now, there are various options available:

  • You can add the CO2 price to the fuel price per kilometer
  • You can consider the alternatives, e.g. a cargo bike (electric) instead of motor scooters.

It’s easy to calculate with money!

As soon as CO2 emissions start to cost money, integrating them into the optimization is child’s play: Either the fuel price will increase or you add the CO-2 costs to the fuel consumption of the scooters and increase the kilometer costs accordingly. Such adjustments can be made without having to adjust anything else, the model does not have to be changed in this case.

Substituting one (or more) scooters with cargo bikes does indeed have an effect on the model. The rapid prototype from part 1 has so far only reduced the length of the routes and in doing so lowered the actual fuel costs have only been reduced indirectly. However, scooters and cargo bikes have different costs per kilometer. Yet even these changes require little effort because no change has been made to the planning, we’ve just added new data to it.

The model adjusts itself

Instead of developing a model directly, first ask yourself the following questions:

  1. Does the problem change fundamentally or is it simply a variation which the model has already responded to?
  2. Which data has changed?
  3. Which new data do we need?

It is often the case that new questions can already be answered. This means that the model normally does not need to be developed anew as it is a tool. It does not assume the task of stipulating the daily tours but it does help to find the most favorable ones. However, it does not decide what is defined as favorable – this is what the planner does; in this case using the kilometer price.

So, we are still looking for a cost-optimal tour composition. The data has changed, though,  because there is no longer a flat-rate kilometer price; insteady there are two prices: one for the scooters and one for the energy consumption of the cargo bike.

But is that really all? Basically, yes, but this change to the initial situation has a couple of cross-influences because now we also have vehicle classes to consider.

This results in a couple of adjustments to the specific formulation. These slight changes are customary for this kind of data adjustment.

  • (D1.1) The connection between two locations on the map is either part of a tour for a certain vehicle class or it isn’t.

  • (D2.2) How many drivers actually need to be deployed for each vehicle class?

Are you interested in learning more about all of the formulas of the mathematical model?

From a mathematical point of view this change also runs through the formulation of the constraints. As far as the content is concerned, there are only two extra points: The fact that a cargo bike has more capacity than a scooter as well as a constraint which obviously appears which the optimization model has to be explicitly informed of.

  • (P8.2) Each vehicle class has its own load capacity
  • (C8) A driver does not change the vehicle class during the journey

There is no change to the actual target – only the formulation refers to the new decision and naturally has to include the vehicle-related prices.

  • (T1.2) The total sum of the costs of all the routes should be minimal whereby the costs result from the length of the route and the kilometer price of the vehicle class

This has an interesting side-effect as the electricity for the cargo bike is clearly cheaper in comparison to the fuel for the motor scooter and it also has more load capacity than the scooter: the routes are not necessarily shorter.

The CO2 costs could actually have been used as changed kilometer costs without having to make any change to the route planning. In this way, however, with barely any adjustment, the potential of the cargo bike suddenly becomes evident when we view the figures and reinforces the idea that deploying one would pay off.

Now it would be useful to calculate what would happen if we substituted all the scooters with cargo bikes…

Mathematical optimization is normally developed for a specific problem. Even if it has many facets: If you start with the core facet, extending it to the next aspect is often fairly easy. Behind which core question lies great potential for you?