TQRouting provides a flexible Python SDK for solving vehicle routing problems with real-world operational constraints.
This guide introduces the main workflows and capabilities, with links to detailed technical documentation and practical examples.
Start by defining the locations, customers and vehicles involved in your routing operation.
A typical routing problem includes:
Customers: Locations to visit, delivery or pickup requirements and service times.
Vehicles: Fleet size, capacity, starting locations and operating restrictions.
Depots: Locations where vehicles begin or end their routes.
Constraints: Operational requirements such as time windows, vehicle capacities and route limits.
TQRouting supports defining problems directly in Python or loading structured input data.
Documentation: Defining a Problem
TQRouting uses travel distances and durations to calculate optimised routes.
You can provide your own matrices or generate them using supported integrations.
Available options include:
Precomputed matrices: Supply your own distance or travel-time data.
Euclidean distances: Calculate distances using Cartesian coordinates.
OSRM: Generate road-network distances and travel times.
Google Maps: Use Google Maps routing data.
The appropriate approach depends on your routing environment and data requirements.
Documentation: Distance & Duration Matrices
Once your routing problem is defined, configure the optimisation settings and execute the solver.
Configuration options include optimisation time limits, computational resources and solver behaviour.
A typical workflow involves:
Prepare your routing problem and input data.
Configure the relevant optimisation settings.
Run the solver using the TQRouting Python SDK.
Review the resulting solution and performance metrics.
Documentation: Solver Configuration
TQRouting supports a range of routing scenarios and operational requirements.
Capability | Description |
|---|---|
Capacity Constraints | Account for vehicle weight or volume limitations |
Time Windows | Schedule visits within specified time periods |
Multi-Trip Routes | Allow vehicles to return to a depot and complete additional trips |
Route Limits | Restrict maximum route duration or distance |
Pickup & Delivery | Combine collection and delivery requirements |
Heterogeneous Fleets | Optimise routes across vehicles with different capacities or characteristics |
Multi-Objective Optimisation | Balance travel duration and distance |
Prize-Collecting | Prioritise selected visits based on their value |
Features can be combined to model more complex routing scenarios.
Documentation: TQRouting Features
After running an optimisation, TQRouting returns a solution containing the generated routes and associated metrics.
Results can be used to:
Review which customers are assigned to each route.
Inspect route sequences and vehicle assignments.
Check solution feasibility.
Evaluate travel duration and distance.
Compare solutions against operational objectives.
Documentation: Reading Results
For practical examples and detailed API guidance, explore the following resources:
Resource | Link |
|---|---|
Complete Documentation | |
Quick Start Guide | |
Problem Definition | |
Solver Configuration | |
GitHub Examples |
The GitHub repository includes example notebooks demonstrating common routing workflows.
For questions about routing problem configuration, solver behaviour or interpreting results, visit the Terra Quantum Help Centre.
Our Help Centre provides technical documentation, knowledge articles and AI-assisted support, with access to our Support team when needed.
Alternatively, email [email protected].
Related articles
TQRouting — Overview & Getting Started
TQRouting — Troubleshooting & FAQs
Licensing & Access
Contacting Support