Algorithm Search⌘K

Theoremcore

Hanan's theorem

Also called Hanan grid.

Some rectilinear Steiner minimal tree of a finite point set has all its Steiner points at crossings of the horizontal and vertical lines drawn through the points.

Hanan's theorem says that a shortest network of horizontal and vertical wires that joins a finite set of points can always be found on the grid of lines through the points. For a set PP of points, draw a vertical line through every point and a horizontal line through every point. The crossings of these lines form the Hanan grid, which has at most n2n^2 points for nn points of PP. M. Hanan proved in 1966 that some rectilinear Steiner minimal tree of PP has all its Steiner points, and in fact all its bends, at these crossings, and runs only along these lines. This turns the rectilinear Steiner tree problem, which allows Steiner points anywhere in the plane, into a Steiner tree problem on a finite graph. In electronic design automation (EDA) it is the reason why Steiner tree methods such as iterated 1-Steiner and FLUTE only consider grid points.

Statement

Let PP be a finite set of n≥1n \ge 1 points in the plane, with the set XX of their xx coordinates and the set YY of their yy coordinates. A rectilinear Steiner tree of PP is a finite union of horizontal and vertical segments that is connected and contains PP. Its length is the total length of the segments. The grid graph Γ(P)\Gamma(P) has the vertex set X×YX \times Y, and an edge between two vertices that are next to each other on a horizontal or a vertical line, with its L1 length.

Theorem (Hanan 1966). For every rectilinear Steiner tree TT of PP there is a tree in Γ(P)\Gamma(P) that contains PP and is no longer than TT. Hence a rectilinear Steiner minimal tree of PP exists, and some rectilinear Steiner minimal tree is a subtree of Γ(P)\Gamma(P): all its Steiner points and bends are in X×YX \times Y and all its segments lie on the lines x=ax = a for a∈Xa \in X and y=by = b for b∈Yb \in Y.

The theorem says "some", not "every". Other optimal trees off the grid can exist, as the section on tightness shows.

In plain words

You must join some pins with wire that runs only left, right, up and down. You may add branch points anywhere. Where should they go?

Hanan's answer: draw a vertical line and a horizontal line through every pin. You never need a branch point or a bend that is not on a crossing of these lines.

The reason is a sliding argument. Take a vertical piece of wire that is not on one of the lines. Push it a little to the left or to the right. The horizontal wires that end on it get longer on one side and shorter on the other. Push it toward the side with more of them, and the total does not grow. Keep pushing until it lands on another vertical piece, which brings it closer to the lines. Do the same for the horizontal pieces.

Proof

Step 0: a tree as a graph. Split the segments of TT at every endpoint, bend, crossing and point of PP. This gives a finite connected graph GG drawn in the plane, whose edges are horizontal or vertical segments, and whose total edge length is the length of TT. A spanning tree of GG still connects PP and is no longer. From now on we work with an abstract tree GG and a position pos(u)\mathrm{pos}(u) for each vertex uu, with three invariants:

  1. every edge joins two vertices with the same xx or the same yy, so it is horizontal or vertical;
  2. the vertices that are points of PP keep their positions;
  3. the length ℓ(G)=∑uvdist(pos(u),pos(v))\ell(G) = \sum_{uv} \mathrm{dist}(\mathrm{pos}(u), \mathrm{pos}(v)) over the edges never grows.

Edges may overlap in the plane. The drawn union of the edges is connected, contains PP and has length at most ℓ(G)\ell(G).

Step 1: one slide. Let c∉Xc \notin X be the xx coordinate of some vertex. Let UU be the set of vertices with x=cx = c. None of them is a point of PP. Let AA be the number of horizontal edges with one end in UU and the other end at x<cx < c, and BB the number with the other end at x>cx > c. Every other edge at a vertex of UU has both ends in UU, since it joins two points with x=cx = c, and a move of all of UU keeps its length. Because GG is connected and contains a point of PP, which is not in UU, we have A+B≥1A + B \ge 1.

Move every vertex of UU to x=c+δx = c + \delta and keep its yy. The edges inside UU keep their length, the AA edges to the left change by +δ+\delta and the BB edges to the right change by −δ-\delta, as long as no vertex is passed. So ℓ(G)\ell(G) changes by (A−B) δ(A - B)\,\delta. If A≤BA \le B, then B≥1B \ge 1, and we take δ>0\delta > 0 up to the nearest xx coordinate c′>cc' > c of a vertex outside UU, which exists because the BB edges have their other ends there. If A>BA > B, we take δ<0\delta < 0 up to the nearest c′<cc' < c of a vertex outside UU, which exists because A≥1A \ge 1. In both cases (A−B) δ≤0(A - B)\,\delta \le 0, and no edge reaches negative length on the way, since no vertex outside UU has its xx strictly between cc and c′c'. All three invariants hold. After the move, the set of xx coordinates of the vertices has lost cc and gained nothing.

Step 2: all slides. Repeat Step 1 while some vertex has an xx coordinate not in XX. Each slide removes one value from the finite set of xx coordinates of vertices and adds none, so after finitely many slides every vertex has x∈Xx \in X. Now do the same with the roles of xx and yy exchanged. A vertical slide changes only yy coordinates, so the xx coordinates stay in XX. At the end every vertex is in X×YX \times Y.

Step 3: back to the grid. Each edge now joins two points of X×YX \times Y on the same horizontal or vertical line, so it is a path of grid edges of Γ(P)\Gamma(P) with the same length. The union HH of these grid paths is a connected subgraph of Γ(P)\Gamma(P) that contains PP, and its length is at most ℓ(G)≤∣T∣\ell(G) \le |T|, with equality when no two paths share a grid edge. A spanning tree of HH is a tree in Γ(P)\Gamma(P) that contains PP and is no longer than TT.

Step 4: existence and the conclusion. Γ(P)\Gamma(P) is finite, so among its trees that contain PP there is a shortest one, T∗T^*. Every grid tree is a rectilinear Steiner tree, and by Step 3 every rectilinear Steiner tree is at least as long as some grid tree, so at least as long as T∗T^*. Hence T∗T^* is a rectilinear Steiner minimal tree, and all its vertices, Steiner points and bends included, are in X×YX \times Y. □\square

Example. Take P={(0,0),(0,4),(3,2)}P = \{(0, 0), (0, 4), (3, 2)\} and the tree with a trunk on x=1x = 1 from (1,0)(1, 0) to (1,4)(1, 4) and the arms (0,0)(0, 0) to (1,0)(1, 0), (0,4)(0, 4) to (1,4)(1, 4) and (1,2)(1, 2) to (3,2)(3, 2). Its length is 4+1+1+2=84 + 1 + 1 + 2 = 8, and 1∉X={0,3}1 \notin X = \{0, 3\}. On the line x=1x = 1 there are A=2A = 2 arms to the left and B=1B = 1 to the right, so the slide goes left with change (2−1)δ(2 - 1)\delta for δ<0\delta < 0. At x=0x = 0 the trunk meets the pins, and the length is 8−1=78 - 1 = 7. This is the half perimeter 3+43 + 4 of the bounding box, which no tree can beat, so the grid tree is optimal.

Consequences

  • A finite problem. The rectilinear Steiner tree problem is the Steiner tree problem in the graph Γ(P)\Gamma(P) with at most n2n^2 vertices. Exact methods search this graph, and the brute force of trying every set of at most n−2n - 2 grid points with a rectilinear minimum spanning tree on each is correct.
  • In NP. The decision form, "is there a tree of length at most LL", has a certificate of polynomial size: a subtree of Γ(P)\Gamma(P). Garey and Johnson (1977) showed that it is NP-complete.
  • Candidate points. Heuristics need only try the at most n2n^2 grid points as Steiner points, as in iterated 1-Steiner.
  • Lengths are linear in the gaps. The length of a grid tree is a sum of gaps between neighboring xx values and neighboring yy values, with integer coefficients. For a fixed order of the points in xx and in yy, the optimum is the least of finitely many such linear forms. FLUTE stores these forms in tables.
  • Three points. For n≤3n \le 3 the optimum is the half-perimeter wirelength of the bounding box, reached by a star from the grid point with the median xx and the median yy.

Tightness

  • Not every optimal tree is on the grid. For the four corners (0,0)(0, 0), (3,0)(3, 0), (0,4)(0, 4) and (3,4)(3, 4) of a 3 by 4 rectangle, the two horizontal sides and one vertical bridge between them give length 3+3+4=103 + 3 + 4 = 10, which is optimal. The bridge can be at any xx in [0,3][0, 3], for example at x=1x = 1, where its two Steiner points (1,0)(1, 0) and (1,4)(1, 4) are not on the grid. Here A=B=1A = B = 1 on the line of the bridge, and the slide keeps the length the same.
  • Steiner points that are not pins are needed. For the plus shape (1,0)(1, 0), (0,1)(0, 1), (2,1)(2, 1), (1,2)(1, 2), the optimum 4 uses the grid point (1,1)(1, 1), which is not one of the points. Every tree with no Steiner points has length at least 6.
  • The grid does not shrink in general. The theorem gives a set of n2n^2 candidates, and a minimal tree uses at most n−2n - 2 of them, but which ones depends on the gaps between the coordinates, as the example on the FLUTE page shows for one order of four points.
  • Other metrics. In the Euclidean plane the Steiner points of a minimal tree are at 120 degree junctions and are not on any fixed finite grid, so the theorem has no direct Euclidean form.

History

M. Hanan studied the Steiner problem with rectilinear distance in 1966 and proved that a minimal tree can be found on the grid of lines through the given points. He also gave exact solutions for small numbers of points. F. K. Hwang studied the shape of full rectilinear Steiner trees in 1976 and proved the bound 3/2 on the ratio of the minimum spanning tree to the minimal tree, see Hwang's theorem. Garey and Johnson showed in 1977 that the problem is NP-complete, and the grid shows that its decision form is in NP. The grid is now the standard search space of rectilinear Steiner tree methods in VLSI routing.

References

  1. M. Hanan, On Steiner's problem with rectilinear distance, SIAM Journal on Applied Mathematics 14(2), 255 to 265, 1966, the theorem that a minimal tree can be found on the grid of lines through the given points, and the exact solutions for small numbers of points
  2. M. R. Garey and D. S. Johnson, The rectilinear Steiner tree problem is NP-complete, SIAM Journal on Applied Mathematics 32(4), 1977, the NP-completeness of the decision problem
  3. Frank K. Hwang, Dana S. Richards and Pawel Winter, The Steiner Tree Problem, Annals of Discrete Mathematics 53, North-Holland, 1992, Part III, the rectilinear Steiner problem (general locator)

Where this leads

About this page

The build computes these levels from the evidence in the repository. Each row says what the next level needs. Read what the levels mean.

LadderLevelWhat the next level needs
Human proofH0 no proof
  • add a proof in proofs/ (06.5)
LeanL0 no Lean part
  • name a Lean module in the lean field (07)
VisualV0 none
  • add viz/scene.ts or a figure (10)
WritingW4 complete
  • a review of the text: no review record reviews/1GZ7DZ/text.yaml