Minimum Steiner forest calculator for undirected terminal pairs

Your numbers

Labels are 0 through n−1; include isolated vertices.
One row: u v integer-cost. No loops or duplicate unordered pairs.
One row: s t, distinct zero-based endpoints.1–4 different pairs.

Calculated on your device. Your inputs aren’t sent to us.

Your result

Ready when you are

Enter your inputs and select Calculate.

QuickCalculators · Full calculator and methodology ↗