This feature is configurable via .json
input, without the need for code customization and is available for both the Marketplace app and Platform. You can find a list of all available features here.
This how-to guide assumes you already completed the get started with vehicle routing tutorial.
Field name | Required | Data type | SI Unit | Defined on | Example | Configurable via defaults |
---|---|---|---|---|---|---|
mixing_items | No | map of string to mix_item | NA | stop | {"mixing_items": {"hazchem": {"name": "F-A-W-E","quantity": 1}} | ➖ |
mix_item
Field name Required Data type Description Example name
Yes string
Name of the "ingredient" to avoid mixing. {"id": "vegan"}
quantity
Yes int
Quantity the stop adds / removes of the "ingredient" {"quantity": 1}
In vehicle routing problems, sometimes stops can not be on a vehicle at the same time if they have a conflict. We refer to this as a mixing, or rather no-mixing, constraint. For example, some countries may require that vegan food is never in a vehicle at the same time as meat products. The vehicle can service both vegan and meat products in the route, but they can never be in the vehicle at the same time.
The no mix
feature allows you to define mixing items and quantities on stops, and the engine will avoid routes which mix items of different types at the same time on the vehicle.
Here is an example that defines mixing items on stops. A sample output obtained after solving the problem is also shown.