Layout optimisation
When you generate a pipe layout using the MST (Minimum Spanning Tree) tool, TESSA connects all buildings with the shortest total pipe length. That is fast and always produces a connected tree, but it may not be the cheapest network to build or operate: a short detour through an existing road corridor can sometimes be worth the extra length, and a layout that minimises cost may differ from one that minimises heat loss.
The Optimise layout tool lets you re-run the layout with a cost-aware objective function.
How the default MST layout works
The default layout algorithm:
- Takes the candidate pipe routes (roads or straight-line connections, depending on your settings) and forms a distance matrix between all potential connection points.
- Computes the Minimum Spanning Tree — the connected sub-graph with the minimum total edge weight (distance).
- Routes pipes along those edges, attaching building substations as leaves.
The result is the shortest-length tree network. It is always connected, never contains loops, and is quick to compute.
The optimisation algorithm
The Optimise layout tool applies a heuristic refinement loop on top of the MST. It works by randomly perturbing the edge lengths in the distance matrix and re-computing the MST, checking at each iteration whether the new layout improves the chosen objective.
At each candidate layout, the tool runs the full pipe-sizing and simulation pipeline (including DNCosts) to compute the objective. This means each iteration is slower than a plain MST but the result is grounded in the actual cost model.
Optimisation objectives
| Objective | What it minimises | When to use |
|---|---|---|
cost |
Total pipe investment cost (installation + material, from the cost table) | Most common; minimises CAPEX |
heat_total |
Total heat transported through the network | Minimises heat carried over long distances |
heat_loss |
Total thermal losses along pipes | Useful when loss reduction is the priority (e.g. high supply temperatures or long routes) |
The cost objective is usually the right choice. heat_loss is worth trying when the supply temperature is high and the network spans a large area.
When to use optimisation
The optimisation tool runs significantly longer than the MST tool — each iteration re-sizes and re-simulates the network. For a district with hundreds of buildings it may take several minutes.
Use it when:
- The initial MST layout looks like it takes unnecessarily long routes.
- You have defined exclusion zones and want to find the lowest-cost routing around them.
- You want to verify that the MST layout is close to optimal before finalising the design.
For a quick first-pass design the default MST layout is usually sufficient.
Exclusion zones
Like the MST tool, the optimiser respects exclusion zones — areas where pipes cannot be routed. Define exclusion zones in the study area layer editor before running either tool.
Where to go next
- Auto-generate layout — how to run the MST and optimise tools from the UI.
- Network sizing and hydraulics — pipe sizing that runs as part of each optimisation iteration.
- Heat loss and simulation — the heat loss model used in the
heat_lossobjective.