You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Add plan for #407: [Model] RootedTreeArrangement
* Implement #407: [Model] RootedTreeArrangement
* chore: remove plan file after implementation
* Fix paper solve command to include --solver brute-force
RootedTreeArrangement has no ILP reduction path, so the default
pred solve fails. Add --solver brute-force as required.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
"OptimalLinearArrangement": [Optimal Linear Arrangement],
126
+
"RootedTreeArrangement": [Rooted Tree Arrangement],
126
127
"RuralPostman": [Rural Postman],
127
128
"MixedChinesePostman": [Mixed Chinese Postman],
128
129
"StackerCrane": [Stacker Crane],
@@ -2026,6 +2027,30 @@ is feasible: each set induces a connected subgraph, the component weights are $2
2026
2027
]
2027
2028
]
2028
2029
}
2030
+
#{
2031
+
let x = load-model-example("RootedTreeArrangement")
2032
+
let nv = graph-num-vertices(x.instance)
2033
+
let ne = graph-num-edges(x.instance)
2034
+
let edges = x.instance.graph.edges.map(e => (e.at(0), e.at(1)))
2035
+
let K = x.instance.bound
2036
+
[
2037
+
#problem-def("RootedTreeArrangement")[
2038
+
Given an undirected graph $G = (V, E)$ and a non-negative integer $K$, is there a rooted tree $T = (U, F)$ with $|U| = |V|$ and a bijection $f: V -> U$ such that every edge $\{u, v\} in E$ maps to two nodes lying on a common root-to-leaf path in $T$, and $sum_(\{u, v\} in E) d_T(f(u), f(v)) <= K$?
2039
+
][
2040
+
Rooted Tree Arrangement is GT45 in Garey and Johnson @garey1979. It generalizes Optimal Linear Arrangement by allowing the host layout to be any rooted tree rather than a single path. Garey and Johnson cite Gavril's NP-completeness proof via reduction from Optimal Linear Arrangement @gavril1977.
2041
+
2042
+
The connection to Optimal Linear Arrangement is immediate: if the rooted tree is restricted to a chain, the stretch objective becomes the linear-arrangement objective. This explains why the two problems live in the same arrangement family. For tree-oriented ordering problems, Adolphson and Hu give a polynomial-time algorithm for optimal linear ordering on trees @adolphsonHu1973, showing that the difficulty here comes from simultaneously choosing both the rooted-tree topology and the vertex-to-node bijection.
2043
+
2044
+
*Example.* Consider the graph with $n = #nv$ vertices, $|E| = #ne$ edges, and edge set ${#edges.map(((u, v)) => $(v_#u, v_#v)$).join(", ")}$. With bound $K = #K$, the chain tree encoded by parent array $(0, 0, 1, 2)$ and identity mapping $(0, 1, 2, 3)$ is a valid witness: every listed edge lies on the unique root-to-leaf chain, and the total stretch is $1 + 2 + 1 + 1 = 5 <= #K$. Therefore this canonical instance is a YES instance.
0 commit comments