betaFeedback

WorksMathematics

The stacking number of a tree

Abstract

Csernák and Soukup introduced the stacking number of a graph: the least integer t≥2t\ge2 such that every configuration of tt pebbles can be transformed by pebbling moves into a configuration supported on one vertex. They conjectured an explicit formula for the stacking number of a tree in terms of the degrees of its vertices and their distances from a chosen root. We prove this conjecture for every finite tree with at least two vertices. We also show that whether a configuration on a tree can be stacked at a given vertex is decided exactly by the sign of an integer score built from recursive branch messages; consequently, stackability can be tested with a linear number of arithmetic operations. The proof combines this criterion with an explicit zero-score obstruction and a weighted cancellation argument for arbitrary nonstackable configurations. The main theorem and the stackability criterion are formalized in Lean 4, and the main theorem has passed Palomar mechanical verification; it is publicly registered as PALOMAR-2026-09-25-000010.

Introduction

A pebbling move removes two pebbles from a vertex and puts one pebble on an adjacent vertex. Csernák and Soukup [3] introduced the stacking number: how many pebbles guarantee that all remaining pebbles can be brought to a single vertex, whose location may depend on the configuration? They conjectured an explicit formula for trees and verified it computationally for every tree of order at most seven.

For a finite tree TT and r∈V(T)r \in V(T), put

ℓT(r)=∣{v≠r:deg⁡T(v)=1}∣(1)\ell_T(r)=\left|\{v \ne r:\deg_T(v)=1\}\right| \tag*{(1)}
σT(r)=1+∑v∈V(T)v=r or deg⁡T(v)>1deg⁡T(v)2dT(r,v)(2)\sigma_T(r)=1+\sum_{\substack{v\in V(T)\\v=r\text{ or }\deg_T(v)>1}}\deg_T(v)2^{d_T(r,v)} \tag*{(2)}
ET(r)=σT(r)+ℓT(r),estim⁡(T)=max⁡r∈V(T)ET(r).(3)E_T(r)=\sigma_T(r)+\ell_T(r),\qquad\operatorname{estim}(T)=\max_{r\in V(T)}E_T(r). \tag*{(3)}

Here dTd_T denotes graph distance. We retain the source notation σT\sigma_T and estim⁡\operatorname{estim}; our ℓT(r)\ell_T(r) is its leaf⁡(r)\operatorname{leaf}(r), and ETE_T abbreviates its rooted estimator. Conjecture 10.3 of [3] asserts stack⁡(T)=estim⁡(T)\operatorname{stack}(T)=\operatorname{estim}(T).

The definition of the stacking number minimizes over t≥2t \ge2. Thus the one-vertex tree has stacking number 2, whereas the displayed estimator is 1. We state the conjecture with the explicit hypothesis ∣V(T)∣≥2|V(T)| \ge2; this isolates a boundary convention in the definitions.

Theorem 1.1. For every finite tree TT with at least two vertices,

stack⁡(T)=estim⁡(T).\operatorname{stack}(T)=\operatorname{estim}(T).

In a subsequent preprint [2], Csernák and Soukup prove the lower bound stack⁡(T)≥estim⁡(T)\operatorname{stack}(T) \ge\operatorname{estim}(T) and derive the matching upper bound from their Almost Stacked Hypothesis. Theorem 1.1 shows that the equality holds unconditionally. That preprint also normalizes the estimator as max⁡{2,estim⁡(T)}\max\{2,\operatorname{estim}(T)\}; with this convention the equality extends to the one-vertex tree.

The proof yields an exact criterion of independent interest. For a configuration CC and a vertex rr, § 3 defines an integer score Sr(C)S_r(C) by a recursion over the branches at rr, and Theorem 3.3 shows that CC can be stacked at rr if and only if Sr(C)>0S_r(C)>0. All the scores can be computed together with O(∣V(T)∣)O(|V(T)|) arithmetic operations (Corollary 3.5), so the stackability of a given configuration on a tree can be decided without any search over sequences of moves.

We prove the tree-stacking estimator conjecture of Csernák and Soukup for nontrivial trees. The proof has three structural ingredients. A branch sends an integer message across its boundary edge, recording the optimal gain or cost of clearing it. An empty branch is a separate state. These messages give an exact criterion Sr(C)>0S_r(C)>0 for stacking a configuration CC at rr, including necessity for arbitrary move order. An explicit configuration of mass estim⁡(T)−1\operatorname{estim}(T)-1 has every score zero. For the reverse bound, the nonnegative defects −Sv(C)-S_v(C) satisfy local two-sided edge equations. We assign the excess contributions to distinct endpoints and cancel them against weighted defects. A consolidation lemma then bounds the auxiliary height weights by distances from one root.

Classical graph pebbling prescribes a target vertex; see Chung [1] and Hurlbert [5]. Cover pebbling prescribes positive demands at all vertices. Sjöstrand’s theorem [6] reduces its universal threshold to distance potentials of configurations concentrated at one vertex. In stacking, every vertex outside the eventual target must be empty. The messages below account for this exact clearing condition.

Configurations and the estimator

All graphs in this paper are finite, simple and undirected. A tree is a nonempty connected acyclic graph. Unless expressly stated otherwise, TT has at least two vertices. We write u∼vu\sim v for adjacency, and omit the subscript TT from degrees and distances when no confusion is possible. The natural numbers include zero.

A configuration is a function C:V(T)→NC:V(T)\to\mathbb{N}; its mass is ∣C∣=∑vC(v)|C|=\sum_v C(v) and its support is supp⁡(C)={v:C(v)>0}\operatorname{supp}(C)=\{v:C(v)>0\}. The source writes ∥c∥\lVert c\rVert for mass; we use ∣C∣|C|. The move u→vu\to v is legal when u∼vu\sim v and C(u)≥2C(u)\ge2. It replaces C(u)C(u) by C(u)−2C(u)-2 and C(v)C(v) by C(v)+1C(v)+1. Reachability permits a finite sequence of legal moves, including the empty sequence. Each move decreases mass by one.

A configuration is stacked at rr when supp⁡(C)={r}\operatorname{supp}(C)=\{r\}. Write StackableAt⁡(T,C,r)\operatorname{StackableAt}(T,C,r) if a configuration stacked at rr is reachable from CC. The configuration is stackable if this holds for some rr. In particular, the zero configuration is not stacked or stackable. The stacking number is the least integer t≥2t\ge2 for which every configuration of mass exactly tt is stackable. Our proof will also establish the existence of such an integer for trees.

Let LL be the number of degree-one vertices of TT. The estimator has the following useful form, uniform in the root:

ET(r)−1=L+∑deg⁡(v)>1deg⁡(v)2d(r,v).(4)E_T(r)-1=L+\sum_{\deg(v)>1}\deg(v)2^{d(r,v)}. \tag*{(4)}

If rr is internal, this follows directly from the definition. If rr is a leaf, its degree-one term in σT(r)\sigma_T(r) replaces the leaf omitted from ℓT(r)\ell_T(r). Also

ET(r)≥∣V(T)∣+1.(5)E_T(r)\ge|V(T)|+1. \tag*{(5)}

Indeed, in the expansion 1+deg⁡(r)+ℓT(r)+∑v≠r, deg⁡(v)>1deg⁡(v)2d(r,v)1+\deg(r)+\ell_T(r)+\sum_{v\ne r,\ \deg(v)>1}\deg(v)2^{d(r,v)}, the root degree is at least one and each of the other ∣V(T)∣−1|V(T)|-1 vertices contributes at least one.

Branch messages and rooted stackability

For an oriented edge v→pv\to p, let Bv∣pB_{v|p} be the component containing vv after deleting vpvp. Its root is vv and its external boundary vertex is pp. The children are the branches Bu∣vB_{u|v} with u∼vu\sim v, u≠pu\ne p. Call a branch occupied when its restriction of CC is nonzero.

Define the integer transfer function by

F(x)={2x−3,x≤1,x/2,x≥2 even,(x−3)/2,x≥3 odd.(6)F(x)= \begin{cases} 2x-3, & x\le1,\\ x/2, & x\ge2\ \text{even},\\ (x-3)/2, & x\ge3\ \text{odd}. \end{cases} \tag*{(6)}

In particular, F(2)=1F(2)=1 and F(3)=0F(3)=0. Messages take values in the disjoint union {EMPTY}⊔Z\{\mathrm{EMPTY}\}\sqcup\mathbb{Z}. For an empty branch put mv→p=EMPTYm_{v\to p}=\mathrm{EMPTY}. For an occupied branch put

mv→p=dv→p:=F(C(v)+∑u∼v, u≠pBu∣v occupieddu→v).(7)m_{v\to p}=d_{v\to p}:=F\left(C(v)+\sum_{\substack{u\sim v,\ u\ne p\\ B_{u\mid v}\ \mathrm{occupied}}}d_{u\to v}\right). \tag*{(7)}

The recursion terminates because each child branch has fewer vertices. Only integer messages are summed. When writing a sum over all neighbours we use the numerical contribution dˉu→v\bar d_{u\to v}, equal to du→vd_{u\to v} on occupied branches and 00 on empty branches. This convention for sums does not identify the states EMPTY and 00. The rooted score is

Sr(C)=C(r)+∑u∼rdˉu→r.(8)S_r(C)=C(r)+\sum_{u\sim r}\bar d_{u\to r}. \tag*{(8)}

Theorem 3.1 (Exact boundary invariant). Let B=Bv∣pB=B_{v\mid p} be occupied with message d=dv→pd=d_{v\to p}. Work on the subtree induced by B∪{p}B\cup\{p\}, with initial configuration C↾BC\mathbin{\upharpoonright}B on $B and q≥0q\ge0 pebbles at pp. A positive stack at pp with BB empty is reachable if and only if q+d>0q+d>0. In that case the greatest possible final pile at pp is q+dq+d.

We prove necessity in a form that also applies when other branches interleave their moves at pp.

Lemma 3.2 (Boundary flux). Suppose a legal sequence clears Bv∣pB_{v\mid p}. Let mabm_{ab} count its moves from aa to bb, and put ϕv∣p=mvp−2mpv\phi_{v\mid p}=m_{vp}-2m_{pv}. If the branch is occupied initially, then

ϕv∣p≤dv→p,ϕv∣p≡dv→p(mod3).\phi_{v\mid p}\le d_{v\to p},\qquad\phi_{v\mid p}\equiv d_{v\to p}\pmod{3}.

If it is empty initially, then ϕv∣p=−3k\phi_{v\mid p}=-3k for some k≥0k\ge0. Moves elsewhere in the tree are permitted.

Proof. The move counts satisfy, at every cleared vertex ww,

C(w)+∑z∼wmzw−2∑z∼wmwz=0.(9)C(w)+\sum_{z\sim w}m_{zw}-2\sum_{z\sim w}m_{wz}=0. \tag*{(9)}

For each initially occupied branch which is cleared, at least one move crosses its boundary outwards. Indeed, consider the move after which that branch becomes empty for the last time. An internal move leaves a pebble inside, and an inward move also does so. Thus this move is an outward boundary move. This observation applies to every occupied child branch, independently of the moves outside it.

First consider an initially empty branch. Sum (9) over its vertices. If II is the number of internal moves and a=mvpa=m_{vp}, b=mpvb=m_{pv}, the result is b−2a−I=0b-2a-I=0. Hence its boundary flux is a−2b=−3a−2I≤0a-2b=-3a-2I\le0. It is divisible by three: give the boundary vertex sign +1+1 and alternate signs along tree edges. The signed sum of the balance equations over the branch is congruent to minus its boundary flux modulo three, because each internal move contributes a multiple of three. The initial and final signed sums on the empty branch vanish. This proves the assertion for empty branches, even when they are used temporarily. For an occupied branch, induct on its size. By induction, each occupied child has flux di−3kid_i-3k_i with ki≥0k_i\ge0, and each empty child has flux −3ki-3k_i. Put x=C(v)+∑dix=C(v)+\sum d_i and K=∑kiK=\sum k_i, where the first sum runs over occupied children. At vv, equation (9) reads

y+b−2a=0,y=x−3K,a=mvp≥1,b=mpv≥0.y+b-2a=0,\qquad y=x-3K,\qquad a=m_{vp}\ge1,\qquad b=m_{pv}\ge0.

For any integer yy, these conditions imply

a−2b=2y−3a≤F(y),a−2b≡F(y)(mod3).(10)a-2b=2y-3a\le F(y),\qquad a-2b\equiv F(y)\pmod{3}. \tag*{(10)}

To see this, the least possible aa is max⁡(1,⌈y/2⌉)\max(1,\lceil y/2\rceil); substituting this value gives precisely the three cases of (6). Any increase in aa lowers the flux by three.

The transfer function satisfies

F(z−3)≤F(z),F(z)≡2z(mod3).(11)F(z-3)\le F(z),\qquad F(z)\equiv2z\pmod{3}. \tag*{(11)}

For the inequality, the difference F(z)−F(z−3)F(z)-F(z-3) is 6 when z≤1z\le1, 6, 3, 3 at z=2,3,4z=2,3,4, respectively, and is 0 for odd z≥5z\ge5 and 3 for even z≥6z\ge6. The congruence follows from each case in (6). Thus F(x−3K)≤F(x)F(x-3K)\le F(x) and F(x−3K)≡F(x)(mod3)F(x-3K)\equiv F(x)\pmod{3}. Apply (10) to finish the induction. □

Proof of Theorem 3.1. The final boundary pile in any allowed clearing sequence is q+ϕq+\phi, so Lemma 3.2 proves necessity and the upper bound. For attainment we induct on the branch size.

We use the following scheduling observation. Suppose disjoint occupied child branches have gains did_i, and a vertex initially has a≥0a\ge0 pebbles. If a+∑idi>0a+\sum_i d_i>0, process branches with positive gain first, then those with zero gain, then those with negative gain. A positive-gain task has positive final pile even when begun at zero. Before a zero-gain task the pile is positive, since the total remaining gains are nonpositive and the final total is positive. During the negative-gain tasks the pile after each task is at least the final positive total. The inductive boundary invariant therefore realizes every task and leaves exactly a+∑idia+\sum_i d_i. Tasks touch only their branch and the common boundary; no other task’s initial interior configuration is changed.

Let x=C(v)+∑idix=C(v)+\sum_i d_i for the occupied children of BB. If x≥2x\ge2, the observation clears the children and leaves xx at vv. For x=2kx=2k, make kk moves from vv to pp; the final boundary pile is q+k=q+F(x)q+k=q+F(x). For x=2k+1≥3x=2k+1\ge3, make kk moves from vv to pp, leaving one pebble at vv. The assumption q+F(x)=q+k−1>0q+F(x)=q+k-1>0 implies q+k≥2q+k\ge2. One move p→vp\to v followed by one move v→pv\to p is therefore legal; it clears vv and leaves q+k−1q+k-1 at pp.

If x≤1x\le1, put j=2−x≥1j=2-x\ge1. The assumption q+F(x)=q−2j+1>0q+F(x)=q-2j+1>0 implies q≥2jq\ge2j. Make jj moves p→vp\to v. The children’s effective total at vv is now x+j=2x+j=2. The observation clears them leaving two pebbles at vv, and one final move v→pv\to p gives pile q−2j+1=q+F(x)q-2j+1=q+F(x). These constructions also cover the case with no children and complete the induction. □

Theorem 3.3 (Exact rooted stackability). For every configuration CC on a finite tree and every vertex rr,

StackableAt⁡(T,C,r)  ⟺  Sr(C)>0.\operatorname{StackableAt}(T,C,r)\iff S_r(C)>0.

Consequently CC is nonstackable if and only if all its scores are nonpositive.

Proof. If the score is positive, apply the scheduling observation to the occupied branches incident with rr, starting with C(r)C(r) pebbles. It gives a stack of size exactly Sr(C)S_r(C) at rr. Conversely, in any sequence ending in a stack at rr, every incident branch is cleared. Lemma 3.2 bounds the flux from each occupied branch by its message and from each empty branch by zero. The final pile is therefore at most Sr(C)S_r(C), and it is positive. The final equivalence follows by quantifying over all targets. □

Remark 3.4. An occupied one-vertex branch containing three pebbles has message F(3)=0F(3)=0. It can be cleared to its boundary only when the boundary has a positive initial pile. An empty branch may be left alone even when that pile is zero. This is why the recursive state must retain EMPTY separately from the integer zero.

Corollary 3.5 (Computing stackability). Let TT be a tree with nn vertices and let CC be a configuration on TT. All messages mv→pm_{v\to p} and all scores Sr(C)S_r(C), r∈V(T)r\in V(T), can be computed with O(n)O(n) arithmetic operations. Consequently, O(n)O(n) arithmetic operations suffice to decide whether CC is stackable and to list every vertex at which it is stackable.

Proof. Fix a vertex ρ\rho and list the vertices of TT in breadth-first order from ρ\rho. Scanning this list backwards, determine for each v≠ρv\ne\rho, with parent pp, whether Bv∣pB_{v|p} is occupied and, if it is, compute dv→pd_{v\to p} by (7). The inputs are C(v)C(v) and the states of the branches Bu∣vB_{u|v} at the children uu of vv, all found earlier in the scan.

Next scan the list forwards. When a vertex pp is reached, the states of all branches Bu∣pB_{u|p} with u∼pu\sim p are known: those at the children of pp from the first scan, and the one at its parent earlier in this scan. Put

Σ(p)=C(p)+∑u∼pdˉu→p,ω(p)=∣{u∼p:Bu∣p occupied}∣.\Sigma(p)=C(p)+\sum_{u\sim p}\bar d_{u\to p},\qquad\omega(p)=\lvert\{u\sim p:B_{u|p}\text{ occupied}\}\rvert.

Let vv be a child of pp. The branch Bp∣vB_{p|v} is occupied exactly when C(p)>0C(p)>0 or Bu∣pB_{u|p} is occupied for some neighbour u≠vu\ne v of pp; the number of such neighbours is ω(p)−1\omega(p)-1 if Bv∣pB_{v|p} is occupied and ω(p)\omega(p) otherwise. If Bp∣vB_{p|v} is occupied, then (7) gives

dp→v=F(Σ(p)−dˉv→p).d_{p\to v}=F\bigl(\Sigma(p)-\bar d_{v\to p}\bigr).

At each vertex vv each scan uses O(deg⁡(v)+1)O(\deg(v)+1) arithmetic operations, so both scans together use O(n)O(n). Finally Sr(C)=Σ(r)S_r(C)=\Sigma(r) by (8), and Theorem 3.3 converts the signs of the scores into the stated decisions. □

An extremal zero-score configuration

Fix r∈V(T)r\in V(T) and root the tree at rr. Define

Cr(v)={σT(r)−1,v=r,1,v≠r and deg⁡(v)=1,0,otherwise.(12)C_r(v)= \begin{cases} \sigma_T(r)-1, & v=r,\\ 1, & v\ne r\text{ and }\deg(v)=1,\\ 0, & \text{otherwise}. \end{cases} \tag*{(12)}

For a nonroot vertex vv, write TvT_v for its descendant subtree and put

Hv={1,v has no children,3+2∑u child of vHu,otherwise.(13)H_v= \begin{cases} 1, & v\text{ has no children},\\ 3+2\sum_{u\text{ child of }v}H_u, & \text{otherwise}. \end{cases} \tag*{(13)}

These are positive integers, with closed form

Hv=1+2∑w∈V(Tv)deg⁡T(w)>1deg⁡T(w)2d(v,w).(14)H_v=1+2\sum_{\substack{w\in V(T_v)\\\deg_T(w)>1}}\deg_T(w)2^{d(v,w)}. \tag*{(14)}

For a leaf this is immediate. For a nonleaf v≠rv\ne r, the number of children is deg⁡T(v)−1\deg_T(v)-1. Substitution of the formula at its children gives

3+2∑uHu=1+2deg⁡T(v)+4∑u∑w∈V(Tu)deg⁡T(w)>1deg⁡T(w)2d(u,w),3+2\sum_u H_u=1+2\deg_T(v)+4\sum_u\sum_{\substack{w\in V(T_u)\\\deg_T(w)>1}}\deg_T(w)2^{d(u,w)},

which is (14) at vv. Summing this closed form over the children of rr yields

∑u child of rHu=deg⁡T(r)+∑w≠rdeg⁡T(w)>1deg⁡T(w)2d(r,w)=σT(r)−1.(15)\sum_{u\text{ child of }r}H_u=\deg_T(r)+\sum_{\substack{w\ne r\\\deg_T(w)>1}}\deg_T(w)2^{d(r,w)}=\sigma_T(r)-1. \tag*{(15)}

Theorem 4.1. For the configuration CrC_r,

Sv(Cr)=0(v∈V(T)),∣Cr∣=ET(r)−1.S_v(C_r)=0 \quad(v\in V(T)), \qquad|C_r|=E_T(r)-1.

In particular, CrC_r is nonstackable.

Proof. Every descendant branch is occupied, since it contains a leaf other than rr. The opposite side is occupied as well, since Cr(r)=σT(r)−1≥deg⁡T(r)≥1C_r(r)=\sigma_T(r)-1\ge\deg_T(r)\ge1. Induction from the leaves gives upward messages dv→p=−Hvd_{v\to p}=-H_v: at a leaf this is F(1)=−1F(1)=-1; at an internal nonroot vertex the effective input is −∑uHu-\sum_u H_u, so its message is −3−2∑uHu=−Hv-3-2\sum_u H_u=-H_v. Equation (15) implies Sr(Cr)=0S_r(C_r)=0.

Now suppose pp has score zero and vv is its child. Removing the contribution −Hv-H_v from its score gives effective input HvH_v on the pp-side of pvpv, hence dp→v=F(Hv)d_{p\to v}=F(H_v). If vv is a leaf, its score is 1+F(1)=01+F(1)=0. Otherwise let K=∑u child of vHu≥1K=\sum_{u\text{ child of }v}H_u\ge1. Then Hv=3+2KH_v=3+2K, F(Hv)=KF(H_v)=K, and the score at vv is −K+K=0-K+K=0. Propagation away from rr proves the assertion at every vertex. Finally, the total mass is σT(r)−1+ℓT(r)=ET(r)−1\sigma_T(r)-1+\ell_T(r)=E_T(r)-1. Nonstackability follows from Theorem 3.3.

Corollary 4.2. There is a nonstackable configuration of mass estim⁡(T)−1\operatorname{estim}(T)-1 whose score is zero at every vertex.

Proof. Choose a root maximizing ETE_T and apply Theorem 4.1.

The arbitrary-defect upper bound

We now bound the mass of every configuration whose scores are all nonpositive. All degrees, paths and distances in this section belong to the original tree. In particular, the argument retains the empty branches: their contributions will be cancelled separately from the contributions of edges with occupied support on both sides.

Let TT be a finite tree with at least two vertices, and let CC satisfy Sv(C)≤0S_v(C)\le0 for every vv. Set

δv=−Sv(C)≥0.\delta_v=-S_v(C)\ge0.

If CC is identically zero the desired bound is immediate. Henceforth choose an occupied vertex oo, so that C(o)>0C(o)>0. This vertex is used to assign edge owners; the estimator root obtained at the end may be different.

Retained edges and the local defect equations

For adjacent vertices u,vu,v, write Tu∣vT_{u\mid v} for the component containing uu after deleting uvuv. Call uvuv retained if both Tu∣vT_{u\mid v} and Tv∣uT_{v\mid u} contain an occupied vertex. Its two messages are then integers. For any edge, let

d‾u→v={du→v,Tu∣v is occupied,0,Tu∣v is empty.\overline{d}_{u\to v}= \begin{cases} d_{u\to v}, & T_{u\mid v}\text{ is occupied},\\ 0, & T_{u\mid v}\text{ is empty}. \end{cases}

This notation records the numerical contribution of a message in a score; it does not identify the message EMPTY with the integer message zero. Thus

C(v)=−δv−∑u∼vd‾u→v.(16)C(v)=-\delta_v-\sum_{u\sim v}\overline{d}_{u\to v}. \tag*{(16)}

Lemma 5.1 (Support separation). The two sides of an edge partition V(T)V(T). Every nonretained edge has exactly one empty side. A retained edge lies on a path between two occupied vertices, and every edge of a path between two occupied vertices is retained. More specifically, if uvuv is retained and xx is an occupied vertex in Tu∣vT_{u\mid v}, every edge on the path from uu to xx is retained. If uvuv is retained and no other retained edge is incident with uu, then C(u)>0C(u)>0. Finally, an endpoint on the empty side of an edge is incident with no retained edge.

Proof. Deleting an edge of a tree produces exactly two components, giving the partition. Since C(o)>0C(o)>0, at least one component is occupied. If both are occupied, choose one occupied vertex in each; their unique path crosses the deleted edge. Conversely, deleting any edge on the path between two occupied vertices separates those vertices, so that edge is retained.

For the more specific assertion, choose an occupied vertex yy in Tv∣uT_{v|u}. The path from xx to yy consists of the path from xx to uu, the edge uvuv, and the path from vv to yy. Every edge on its xx–uu segment is therefore retained. If uu is unoccupied, an occupied vertex xx on its side is distinct from uu, and the edge of that segment incident with uu is a retained edge other than uvuv. This proves the next assertion by contraposition.

For the last assertion, let Tv∣uT_{v|u} be empty. The edge uvuv itself is nonretained. For every other neighbour ww of vv, the component Tw∣vT_{w|v} lies inside Tv∣uT_{v|u} and is empty. Hence wvwv is also nonretained.

For a retained edge uvuv, put a=du→va=d_{u\to v} and b=dv→ub=d_{v\to u}. Removing the opposite message from each endpoint score gives the two effective branch inputs. The message recursion therefore yields

a=F(−δu−b),b=F(−δv−a).(17)a=F(-\delta_u-b),\qquad b=F(-\delta_v-a). \tag*{(17)}

These equations are only asserted for retained edges.

Lemma 5.2 (Classification of retained edge states). The solutions of (17) with δu,δv≥0\delta_u,\delta_v\geq0 have exactly the following forms, up to exchanging uu and vv:

(1) An oriented state, with

a=k≥0,b=−2(k+δv)−3,δu=2δv or δu=2δv+3.(18)a=k\geq0,\qquad b=-2(k+\delta_v)-3,\qquad\delta_u=2\delta_v\text{ or }\delta_u=2\delta_v+3. \tag*{(18)}

The latter alternative requires k>0k>0. We direct this edge u→vu\to v.

(2) A two-negative state, with unique r,q∈Nr,q\in\mathbb{N} such that

a=−(2r+1),b=−(2q+1),δu=r+2q,δv=q+2r.(19)a=-(2r+1),\qquad b=-(2q+1),\qquad\delta_u=r+2q,\qquad\delta_v=q+2r. \tag*{(19)}

Both messages cannot be nonnegative.

Proof. The definition of FF gives

F(z)<0⟺z≤1,F(z)<0\Longleftrightarrow z\leq1,
F(z)=−(2r+1)⟺z=1−r(r≥0),F(z)=-(2r+1)\Longleftrightarrow z=1-r\qquad(r\geq0),
F(z)=k⟺(k>0 and z=2k) or z=2k+3(k≥0).F(z)=k\Longleftrightarrow(k>0\text{ and }z=2k)\text{ or }z=2k+3\qquad(k\geq0).

Indeed, the first two statements use F(z)=2z−3F(z)=2z-3 for z≤1z\leq1; the even positive and odd positive cases of FF give the third, including the unique preimage 33 of zero.

If a=k≥0a=k\geq0, then −δv−k≤0-\delta_v-k\leq0, so the second edge equation gives b=−2(k+δv)−3<0b=-2(k+\delta_v)-3<0. Substituting this into the first equation and using the nonnegative preimages gives either −δu+2k+2δv+3=2k+3-\delta_u+2k+2\delta_v+3=2k+3, or the same left side equals 2k2k with k>0k>0. These are exactly the two defect alternatives in (18). The case b≥0b\geq0 is symmetric.

If both messages are negative, the first two identities express them uniquely as −(2r+1)-(2r+1) and −(2q+1)-(2q+1), with r,q≥0r,q\geq0. Their unique preimages give −δu+2q+1=1−r-\delta_u+2q+1=1-r and −δv+2r+1=1−q-\delta_v+2r+1=1-q, proving (19). Conversely, substitution verifies every displayed state, subject to the stated restriction when k=0k=0.

Call an oriented state defective if its head defect δv\delta_v is positive. Call a two-negative state defective if r+q>0r+q>0. The remaining two-negative state is the neutral state (−1,−1)(-1,-1), with both endpoint defects zero. The defective retained edges form a forest, since they are a subset of the edges of TT.

Owners, orientations and auxiliary weights

Lemma 5.3 (Injective incident owners). For each edge e=uve=uv, let ω(e)\omega(e) be the endpoint farther from oo. Then ω\omega is well defined and injective on E(T)E(T). If Tv∣uT_{v|u} is empty, then ω(uv)=v\omega(uv)=v.

Proof. The unique path from oo crosses uvuv precisely when reaching the endpoint on the side not containing oo. Thus the endpoint distances differ by one. The owner is the more distant endpoint. Each vertex other than oo has exactly one neighbour preceding it on its unique path from oo; consequently it owns exactly that predecessor edge. In particular two edges cannot share an owner. If Tv∣uT_{v|u} is empty, the occupied vertex oo lies on the uu side, so vv is the farther endpoint. □

Define an auxiliary partial orientation of TT as follows. Keep the direction of every oriented state, including those with zero head defect. Direct each defective two-negative edge toward its owner. Leave neutral edges and nonretained edges unoriented. The classification ensures that no edge has both directions. Since TT has no undirected cycle, this directed graph has no directed cycle.

Let h(v)h(v) be the maximum length of a directed path ending at vv, allowing the path of length zero, and set

Av=2h(v).(20)A_v = 2^{h(v)}. \tag*{(20)}

The maximum exists because a directed path has no repeated vertex. For an auxiliary arrow u→vu \to v, a longest path ending at uu can be extended by this arrow: if it already contained vv, it would give a directed cycle. Hence

h(v)≥h(u)+1,Av≥2Au.(21)h(v) \ge h(u) + 1,\qquad A_v \ge2A_u. \tag*{(21)}

A vertex has positive height exactly when it has an incoming auxiliary arrow. Since every auxiliary arrow is retained, Lemma 5.1 also shows that the endpoint on the empty side of any edge has height zero and weight one.

Local charges and global defect cancellation

For an undirected edge e=uve=uv, define its weighted message contribution by

Ee=−(Avdˉu→v+Audˉv→u).E_e = -\left(A_v\bar d_{u\to v} + A_u\bar d_{v\to u}\right).

Define two nonnegative charges, with disjoint conditions of application:

Qeret={Aω(e)δω(e),e is retained and defective,0,otherwise,Q_e^{\mathrm{ret}} = \begin{cases} A_{\omega(e)}\delta_{\omega(e)}, & e\text{ is retained and defective},\\ 0, & \text{otherwise}, \end{cases}
Qeemp={Aω(e)δω(e),e is nonretained,0,otherwise.Q_e^{\mathrm{emp}} = \begin{cases} A_{\omega(e)}\delta_{\omega(e)}, & e\text{ is nonretained},\\ 0, & \text{otherwise}. \end{cases}

Lemma 5.4 (Retained-edge charge). For every retained edge uvuv,

Euv≤Au+Av+Quvret.E_{uv} \le A_u + A_v + Q_{uv}^{\mathrm{ret}}.

Proof. First consider an oriented state u→vu \to v with parameter k≥0k \ge0. By (18) and (21),

Euv=Au(2(k+δv)+3)−Avk=3Au+k(2Au−Av)+2Auδv≤Au+Av+2Auδv.\begin{aligned} E_{uv} &= A_u(2(k+\delta_v)+3)-A_vk\\ &= 3A_u+k(2A_u-A_v)+2A_u\delta_v\\ &\le A_u+A_v+2A_u\delta_v. \end{aligned}

The excess 2Auδv2A_u\delta_v is zero when the edge is nondefective. Otherwise either endpoint can pay it: the local defect relation gives Auδu≥2AuδvA_u\delta_u \ge2A_u\delta_v, and doubling gives Avδv≥2AuδvA_v\delta_v \ge2A_u\delta_v. Thus it is bounded by the charge at the prescribed owner, regardless of whether that owner is the tail or head.

For a defective two-negative state, name its endpoints so that the auxiliary direction is u→vu \to v, with v=ω(uv)v = \omega(uv), and use the parameters in (19). Then

Euv=Au+Av+2Avr+2Auq≤Au+Av+Av(2r+q)=Au+Av+Avδv.E_{uv} = A_u + A_v + 2A_vr + 2A_uq \le A_u + A_v + A_v(2r+q) = A_u + A_v + A_v\delta_v.

Here q≥0q \ge0 and 2Au≤Av2A_u \le A_v justify the inequality. A neutral edge has r=q=0r=q=0 and contributes exactly Au+AvA_u+A_v, completing the proof. □

Lemma 5.5 (Empty-side cancellation). If Tv∣uT_{v|u} is empty, then

Euv=Avδv=Quvemp.E_{uv}=A_v\delta_v=Q_{uv}^{\mathrm{emp}}.

Proof. The message mv→um_{v\to u} is literally EMPTY. At vv, the initial pile is zero, and every incident branch other than the uu side is empty. Consequently Sv(C)=du→vS_v(C)=d_{u\to v}, where this last message is an integer because the uu side contains oo. Thus d‾v→u=0\overline{d}_{v\to u}=0 and du→v=−δvd_{u\to v}=-\delta_v, giving Euv=AvδvE_{uv}=A_v\delta_v. By Lemma 5.3, vv is the owner. In addition Av=1A_v=1, as observed above. No integer defect-state equations were applied to the empty message. □

Proposition 5.6 (Weighted cancellation). The auxiliary weighted mass satisfies

∑vAvC(v)≤∑vdeg⁡T(v)Av.(22)\sum_v A_vC(v)\le\sum_v \deg_T(v)A_v. \tag*{(22)}

Proof. Grouping (16) by undirected edges gives the exact identity

∑vAvC(v)=∑e∈E(T)Ee−∑vAvδv.(23)\sum_v A_vC(v)=\sum_{e\in E(T)}E_e-\sum_v A_v\delta_v. \tag*{(23)}

Lemmas 5.4 and 5.5 give, uniformly over all ambient edges,

Euv≤Au+Av+Quvret+Quvemp.E_{uv}\le A_u+A_v+Q_{uv}^{\mathrm{ret}}+Q_{uv}^{\mathrm{emp}}.

Each sum of the two charges is at most its one owner budget Aω(e)δω(e)A_{\omega(e)}\delta_{\omega(e)}. Owners are injective on all edges, and every vertex budget is nonnegative, so

∑e(Qeret+Qeemp)≤∑eAω(e)δω(e)≤∑vAvδv.\sum_e\left(Q_e^{\mathrm{ret}}+Q_e^{\mathrm{emp}}\right) \le\sum_e A_{\omega(e)}\delta_{\omega(e)} \le\sum_v A_v\delta_v.

Substitution in (23) cancels the budgets. Finally, each vertex weight occurs once for each incident edge, so ∑uv∈E(T)(Au+Av)=∑vdeg⁡T(v)Av\sum_{uv\in E(T)}(A_u+A_v)=\sum_v\deg_T(v)A_v. □

Removing leaf weights

Let LL be the number of ambient vertices of degree one.

Lemma 5.7 (Ambient leaf slack). Every degree-one vertex vv with Av>1A_v>1 is occupied. Consequently

∣C∣≤L+∑deg⁡T(v)>1deg⁡T(v)2h(v).(24)|C|\le L+\sum_{\deg_T(v)>1}\deg_T(v)2^{h(v)}. \tag*{(24)}

Proof. If Av>1A_v>1, then h(v)>0h(v)>0, so there is an incoming auxiliary arrow at vv. Its underlying edge is retained. As vv has degree one, its side of that edge is the singleton {v}\{v\}; retention implies C(v)≥1C(v)\ge1. For any degree-one vertex, therefore,

Av−1≤(Av−1)C(v):A_v-1\le(A_v-1)C(v):

:::`

if Av=1A_v=1 both sides are zero, and otherwise C(v)≥1C(v) \ge1 proves it. Since Av≥1A_v \ge1 at every vertex, all configuration slack terms are nonnegative. Using Proposition 5.6,

∣C∣=∑vAvC(v)−∑v(Av−1)C(v)≤∑vdeg⁡T(v)Av−∑deg⁡T(v)=1(Av−1)=L+∑deg⁡T(v)>1deg⁡T(v)Av.\begin{aligned} |C| &= \sum_v A_v C(v)-\sum_v(A_v-1)C(v)\\ &\le\sum_v \deg_T(v)A_v-\sum_{\deg_T(v)=1}(A_v-1)\\ &=L+\sum_{\deg_T(v)>1}\deg_T(v)A_v. \end{aligned}

The last equality uses that every vertex of a nontrivial tree has positive degree. Replacing AvA_v by 2h(v)2^{h(v)} proves the claim. Thus occupied leaves pay the required slack, while unoccupied ambient leaves have unit weight and require no payment. □

Consolidation to one ambient root

We prove a pointwise statement about heights before applying the estimator. A set of vertices is called connected here if the unique tree path between any two of its vertices stays in the set. This agrees with connectedness of the induced subgraph, by uniqueness of paths in a tree.

Lemma 5.8 (Source partition). The vertices of TT can be partitioned into connected sets PiP_i with vertices si∈Pis_i \in P_i such that

h(v)=dT(si,v)(v∈Pi).h(v)=d_T(s_i,v)\qquad(v\in P_i).

Proof. For every vv of positive height, choose once and for all an incoming auxiliary arrow p(v)→vp(v) \to v with h(p(v))=h(v)−1h(p(v))=h(v)-1. Such an arrow exists by taking the last edge of a longest directed path ending at vv: its prefix has length h(v)−1h(v)-1, and (21) at the level of heights prevents the height of its penultimate vertex from being larger.

Iterating pp decreases height by exactly one each time and ends at a vertex s(v)s(v) of height zero after h(v)h(v) steps. No vertex repeats, so this predecessor chain is the unique tree path from vv to s(v)s(v) and h(v)=dT(s(v),v)h(v)=d_T(s(v),v). Every vertex on the chain has the same terminal source, since its subsequent predecessor choices are fixed. Each nonempty fibre Ps={v:s(v)=s}P_s=\{v:s(v)=s\} therefore contains ss and the full path from each of its vertices to ss. The path between two vertices of PsP_s is contained in the union of their paths to ss, hence stays in PsP_s. The nonempty fibres give the required connected partition. □

Lemma 5.9 (Merging height-dominated parts). Let A,BA,B be disjoint nonempty connected vertex sets joined by an edge xyxy, with x∈Ax\in A and y∈By\in B. Suppose a∈Aa\in A, b∈Bb\in B and g:V(T)→Ng:V(T)\to\mathbb{N} satisfy

g(v)≤dT(a,v)(v∈A),g(v)≤dT(b,v)(v∈B).g(v)\le d_T(a,v)\qquad(v\in A),\qquad g(v)\le d_T(b,v)\qquad(v\in B).

Then A∪BA\cup B is connected, and one of a,ba,b satisfies the same domination on all of A∪BA\cup B.

Proof. Paths within the two sets, together with xyxy, connect their union. If z∈Az\in A and w∈Bw\in B, concatenate the path from zz to xx in AA, the edge xyxy, and the path from yy to ww in BB. Disjointness makes this a simple path, so it is the unique tree path and

dT(z,w)=dT(z,x)+1+dT(y,w).(25)d_T(z,w)=d_T(z,x)+1+d_T(y,w). \tag*{(25)}

Put α=dT(a,x)\alpha=d_T(a,x) and β=dT(b,y)\beta=d_T(b,y). If β≤α+1\beta\le\alpha+1, then for every v∈Bv\in B the triangle inequality and (25) give

g(v)≤dT(b,v)≤β+dT(y,v)≤α+1+dT(y,v)=dT(a,v).g(v)\le d_T(b,v)\le\beta+d_T(y,v)\le\alpha+1+d_T(y,v)=d_T(a,v).

The pre-existing domination on AA is unchanged, so aa works. Otherwise β>α+1\beta>\alpha+1, which implies α≤β+1\alpha\le\beta+1; the same argument with the two sets exchanged shows that bb works. □

Proposition 5.10 (Height-dominating root). There exists a vertex r∈V(T)r\in V(T) such that

h(v)≤dT(r,v)(v∈V(T)).(26)h(v)\le d_T(r,v)\qquad(v\in V(T)). \tag*{(26)}

Proof. Begin with the connected source partition of Lemma 5.8; each part is height-dominated by its own source. If there is more than one part, connectedness of TT provides an edge joining two parts: for example, follow a path from a vertex in one part to a vertex outside it and take its first exit edge. Lemma 5.9, with g=hg=h, merges those two parts and supplies a root that height-dominates their union. The resulting sets are still a partition into connected, height-dominated parts. Each merge reduces the number of parts by one, so finitely many merges leave the whole vertex set and one dominating root. □

Theorem 5.11 (Arbitrary-defect upper bound). For every configuration CC on a finite tree TT with at least two vertices,

(Sv(C)≤0 for all v)⟹∣C∣≤estim⁡(T)−1.\left(S_v(C) \le0\ \text{for all }v\right) \Longrightarrow|C| \le\operatorname{estim}(T)-1.

Proof. For C=0C=0, the bound follows from the positive estimator formula. Otherwise the preceding construction applies. Choose the root rr from Proposition 5.10. Since 2x2^x increases with xx, Lemma 5.7 gives

∣C∣≤L+∑deg⁡T(v)>1deg⁡T(v)2h(v)≤L+∑deg⁡T(v)>1deg⁡T(v)2dT(r,v)≤L+max⁡s∈V(T)∑deg⁡T(v)>1deg⁡T(v)2dT(s,v)=estim⁡(T)−1.\begin{aligned} |C| \le L+\sum_{\deg_T(v)>1}\deg_T(v)2^{h(v)} \\ &\le L+\sum_{\deg_T(v)>1}\deg_T(v)2^{d_T(r,v)} \\ &\le L+\max_{s\in V(T)}\sum_{\deg_T(v)>1}\deg_T(v)2^{d_T(s,v)}=\operatorname{estim}(T)-1. \end{aligned}

The final equality is the estimator identity (4). Every quantity in this calculation uses the ambient tree. □

Together with the exact score criterion (Theorem 3.3), Theorem 5.11 implies that every non-stackable configuration has mass at most estim⁡(T)−1\operatorname{estim}(T)-1, and hence every configuration of mass estim⁡(T)\operatorname{estim}(T) is stackable.

The stacking formula

One final point is required because the stacking number uses exact sizes.

Lemma 6.1. Let GG be a connected graph on n≥2n \ge2 vertices. If t≥2t \ge2 and every configuration of mass tt is stackable, then t>nt>n and every configuration of mass t+1t+1 is stackable.

Proof. If 2≤t≤n2 \le t \le n, put one pebble on each of tt distinct vertices. This configuration admits no legal move and is not stacked, a contradiction. Now let ∣C∣=t+1|C|=t+1. Since t+1>nt+1>n, some vertex has at least two pebbles. It has a neighbour by connectedness and n≥2n \ge2. One legal move produces a configuration of mass tt, which is stackable by hypothesis. Prepend that move to a stacking sequence. □

Proof of Theorem 1.1. Theorem 5.11 implies that every configuration of mass estim⁡(T)\operatorname{estim}(T) is stackable. By (5), this is an admissible threshold at least two, so stack⁡(T)≤estim⁡(T)\operatorname{stack}(T) \le\operatorname{estim}(T). On the other hand, Corollary 4.2 provides a nonstackable configuration of mass estim⁡(T)−1\operatorname{estim}(T)-1. If a universal exact size t≥2t \ge2 were smaller than estim⁡(T)\operatorname{estim}(T), repeated application of Lemma 6.1 would make every configuration of mass estim⁡(T)−1\operatorname{estim}(T)-1 stackable. This contradiction proves the reverse inequality. □

The proof also gives an exact extremal statement:

Corollary 6.2. For every nontrivial finite tree,

max⁡{∣C∣:C is not stackable}=max⁡{∣C∣:Sv(C)=0 for every v}=estim⁡(T)−1.\max\{|C|: C\text{ is not stackable}\}=\max\{|C|: S_v(C)=0\text{ for every }v\}=\operatorname{estim}(T)-1.

Proof. Every zero-score configuration is nonstackable by Theorem 3.3. The upper bound is Theorem 5.11, and the zero-score obstruction attains it. □

For the singleton tree, every positive configuration is already stacked. Consequently stack⁡(K1)=2\operatorname{stack}(K_1)=2 under the source threshold convention, while (1)–(3) give estim⁡(K1)=1\operatorname{estim}(K_1)=1.

Formal verification and reproducibility

The complete theorem, including the message characterization, obstruction, weighted cancellation and exact-size threshold argument, has been formalized in Lean. The headline declaration is

TreeStack.stack_eq_estim_of_two_le_card.

Its hypothesis and conclusion are, respectively,

2≤Fintype.card⁡V,TreeStack.stack⁡T=TreeStack.estim⁡T2 \le\operatorname{Fintype.card} V,\qquad\operatorname{TreeStack.stack} T = \operatorname{TreeStack.estim} T

for a finite tree TT on VV. The formalization proves the result for arbitrary finite trees, without an order bound. Theorem 3.3 is the declaration

TreeStack.stackableAt_iff_score_pos.

Corollary 3.5 is an algorithmic consequence of that theorem and is not part of the formal development.

The source and reproduction instructions are available in the public repository [4]. The immutable formal-verification revision is

4d4969703a9f0ca7a51cbe7edf0f0338cc95cafb.

It pins Lean 4.35.0-rc2 and a specific Mathlib revision. The theorem-level audit records only the standard axioms propext, Quot.sound and Classical.choice. The proved declaration is separate from Palomar’s protected Challenge statement. Palomar mechanical verification succeeded, including comparison with that statement and independent NanoDa kernel replay. Its automated review identified no problems. The verified result is publicly registered in Palomar, version 1, under identifier PALOMAR-2026-09-25-000010. The public verification record is: https://palomar-registry.org/entry.html?id=PALOMAR-2026-09-25-000010&version=1. This is a record of mechanical verification, not human peer review.

The repository includes a theorem-to-source correspondence for this paper, the pinned dependency files, and commands for the Lean build and axiom audit. It also provides independent Python implementations of legal reachability and branch messages, and bounded regression checks. Those computations support reproduction and testing; the proofs above do not depend on finite enumeration. Later publication commits preserve the immutable verification revision.

Use of AI tools

Use of AI tools. This work was developed with extensive assistance from AI tools (OpenAI’s ChatGPT and Codex), under the direction of the author, including mathematical exploration, Lean development, proof auditing and preparation of the exposition. The author selected the problem and scope and directed validation. The proofs in this paper are written to be checked without the formal development; those of the main theorem were also cross-checked against the Lean declarations, and the main theorem is verified in Lean as described above. The author takes full responsibility for the content of the paper. This disclosure follows the development provenance recorded in the repository.

References

  1. [1]Fan R. K. Chung, Pebbling in hypercubes, SIAM Journal on Discrete Mathematics 2 (1989), no. 4, 467–472.
  2. [2]Tamás Csernák and Lajos Soukup, The Almost Stacked Hypothesis: a conjectural analogue of Sjöstrand’s cover pebbling theorem, 2026, arXiv:2610.09650.arxiv.org/abs/2610.09650
  3. [3]______, Stacking and clearing in group pebbling, 2026, arXiv:2604.22341.arxiv.org/abs/2604.22341
  4. [4]John Fairfax-Ball, TreeStack: Structural certificates for stacking on trees, GitHub repository, https://github.com/jfairfaxball-348/TreeStack-Structural-Certificates-for-Stacking-on-Trees, 2026, Lean formalization; revision 4d4969703a9f0ca7a51cbe7edf0f0338cc95cafb.
  5. [5]Glenn Hurlbert, A survey of graph pebbling, Congressus Numerantium 139 (1999), 41–64, arXiv:math/0406024.
  6. [6]Jonas Sjöstrand, The cover pebbling theorem, The Electronic Journal of Combinatorics 12 (2005), no. 1, N22, arXiv:math/0410129.DOI

Paper details

vlnc:W_8wj8a9vm
Version
v1 · latest
Published
Fresh — added to the Hub within the last 30 days
Added
License
CC BY 4.0
Usage

views · 0

downloads · 0

A view counts once per browser per day, a download each time the PDF is requested.

  • Mathematics

Not recorded for this paper

View statement
Looking for related papers…
Contents