Angel Ivanov Raychev

Rectangle searches: detailed proofs

The active manuscript concerns two-dimensional rectangles, constant daily budgets, and full initial uncertainty. Exact evaluators are distinguished from the intended explicit value-and-strategy endpoint. The complete classification remains open.

Rectangle overview · Progress reconciliation · Coverage and remaining gaps · Parked companion · PDF from the same source

Introduction and results

A princess moves through a building every night. Each morning a searcher may open several doors. The princess knows the search plan, may start anywhere, and must move to an adjacent room after each unsuccessful day. The problem is to guarantee capture as quickly as possible. Even on a single corridor the answer has a parity correction: dividing the amount of uncertainty by the apparent daily progress is not always enough.

This is a minimum-time version of the Hunters and Rabbit game. Our active objective concerns two-dimensional rectangles only. A path PnP_n has nn vertices, and Pn1PndP_{n_1}\mathbin{\square}\cdots\mathbin{\square}P_{n_d} denotes the Cartesian box with those side lengths. Write Tm(G)T_m(G) for the optimal guaranteed number of inspection days, with value \infty when no finite guarantee exists. Section 2 specifies the order of inspection and compulsory movement precisely.

The fixed completion criterion

For every a,b1a,b\ge1 and constant daily budget k0k\ge0, the numerical research goal is a fixed-size closed-form expression for Tk(a,b)T_k(a,b), including its infinite cases. Evaluation must use an absolute O(1)O(1) number of standard numerical operations, independent of a,b,ka,b,k. Arithmetic, powers, roots, floors, ceilings and a fixed finite case list are permitted. This is an operation-count goal, not constant bit complexity. Parameter-length sums or products, recurrences, iterative arrays, shortest paths and parameter-dependent preprocessing do not satisfy it. Renaming an algorithm as one operation does not change this. We do not claim that the goal has been attained or is necessarily attainable.

A separate requirement is a directly specified optimal sequence St(a,b,k)S_t(a,b,k) when the answer is finite, with proofs of capture and of minimality against every competing inspection sequence. Printing the sequence need not take O(1)O(1) time. Strategy existence, reconstruction by optimization, and direct inspection rules are distinguished below. The graph notation Tm(G)T_m(G) and the local width/length letters in older proofs are retained, with Tk(a,b)=Tk(PaPb)T_k(a,b)=T_k(P_a\mathbin{\square}P_b) and w=min(a,b)w=\min(a,b), n=max(a,b)n=\max(a,b).

Relevant exact evaluators, lower and upper bounds, counterexamples, partial-state arguments and general proof tools remain in this paper. Their inclusion records progress; it does not lower the completion criterion. Independent higher-dimensional classifications and applications are preserved at https://angelraychev.com/princess/extensions/ with a separate manuscript, sources, formalization map and parked restart notes. Scope selection is not mathematical unification, and this separation establishes no new cases.

Current rectangle coverage

Feasibility already has a bounded numerical criterion: Tk(a,b)<kmin(a,b)/2+1.T_k(a,b)<\infty \quad\Longleftrightarrow\quad k\ge\left\lfloor\min(a,b)/2\right\rfloor+1. For both sides at least two this is the rectangular-grid theorem of Abramovskaya et al. (2016, Theorem 2); paths and the one-room case are covered separately below. Thus the infinite-value cases do not remain an open part of the rectangle classification.

Fixed numerical formulas and attaining constructions are available for all budgets on rectangles with at most five rows, and above the stated quadratic budget thresholds at every width and side parity. Every seven-row odd-length budget is now covered (Theorem 30.2), as is the even-width budget curve k=r(r1)k=r(r-1) on width 2r2r, r3r\ge3, at every length (Theorem 31.4). The finite constants in the minimum-budget theorem also give fixed formulas at its listed widths through fifteen. These are proved ranges, not a complete arbitrary-width classification.

Every odd rectangle has exact compatible neighborhood profiles and an exact joint evaluator. Theorem 6.1 places its time in {2τ1,2τ}\{2\tau-1,2\tau\}; the bounded joint frontier in Theorem 7.1 decides which value occurs. The solo-residual rule suffices beyond the explicit threshold in Theorem 7.5 and at every length in the additional ranges of Theorem 30.5 and Corollary 30.6. In general these recurrences still require reduction to bounded numerical expressions. Even the all-width minimum- budget identity Tb+1(2b+1,n)=2(2b+1)nC2b+1T_{b+1}(2b+1,n)=2(2b+1)n-C_{2b+1}, for odd n2b+1n\ge2b+1, retains a width-only O(b)O(b) clock in C2b+1C_{2b+1} (Theorem 21.1). It is an exact general theorem, but not numerical completion when bb varies.

For even-area rectangles, exact static neighborhood profiles and the physical interface theorem 27.1 retain the actual boundary choices. The symbolic transition theorem 13.3 evaluates the interior connections. Parameter-dependent boundary preprocessing and shortest-path optimization remain. The constants hidden in Ow,k(1)O_{w,k}(1) are not an absolute O(1)O(1) bound independent of all three parameters.

Uniform bounds also narrow a broad even-area region to one day: Theorem 29.19 covers k4w/3k\ge\lceil4w/3\rceil, and Corollary 29.21 improves the threshold to 13w/10\lceil13w/10\rceil for even widths. The physical upper strategies are explicit, while choosing the optimal endpoint and evaluating every underlying clock in fixed size remain separate obligations.

The common corner-capacity and propagation arguments remain as tools for these gaps. The target is the optimum from the full rectangle. Universal optimality from every partial state, or classification of every legal boundary transition, is not an additional completion condition.

The exact narrow-grid formulas

On a path, Tm(Pn)=1T_m(P_n)=1 if nmn\le m. With one inspection per day, T1(P2)=2T_1(P_2)=2 and T1(Pn)=2n4T_1(P_n)=2n-4 for n3n\ge3. For n>m2n>m\ge2, Tm(Pn)=2n42m1+ε, T_m(P_n)=\left\lceil\frac{2n-4}{2m-1}\right\rceil+\varepsilon, (1) where ε=1\varepsilon=1 exactly when nm+1(mod2m1)n\equiv m+1\pmod{2m-1} and n,mn,m are not both even. This theorem is the domain-corrected result of the author’s original 2019–2020 work. We give a shorter construction and a matching-based lower proof, and formalize the complete statement in Lean.

For two rows and n2n\ge2, one daily inspection is insufficient, and m2nm\ge2n gives one day. In the remaining range put N=n1N=n-1, M=m1M=m-1. Then Tm(P2Pn)=2NM+1{M even and NM/2(modM)}. T_m(P_2\mathbin{\square}P_n)=\left\lceil\frac{2N}{M}\right\rceil+\mathbf{1}_{\{M\text{ even and }N\equiv M/2\pmod M\}}. (2)

For three rows and n2n\ge2, the one-day threshold is 3n3n, the two-day threshold is 3n/2\left\lfloor 3n/2\right\rfloor, and one inspection is insufficient. For 2m<3n/22\le m<\left\lfloor 3n/2\right\rfloor, write 3n4=q(2m3)+r3n-4=q(2m-3)+r, 0r<2m30\le r<2m-3. The answer is {2q,r=0,2q+1,r>0 and mr+41{n even, q odd},2q+2,otherwise. \begin{cases} 2q,&r=0,\\ 2q+1,&r>0\text{ and }m\ge r+4-\mathbf{1}_{\{n\text{ even},\ q\text{ odd}\}},\\ 2q+2,&\text{otherwise}. \end{cases} (3)

For four rows and n4n\ge4, the one-day threshold is 4n4n, the two-day threshold is 2n2n, and budgets at most two are insufficient. For 3m<2n3\le m<2n, write 2n2=q(m2)+r2n-2=q(m-2)+r, 0r<m20\le r<m-2. The answer is {2q,r=0,2q+1,r=1 or (r2 and m2r+4),2q+2,otherwise. \begin{cases} 2q,&r=0,\\ 2q+1,&r=1\text{ or }(r\ge2\text{ and }m\ge2r+4),\\ 2q+2,&\text{otherwise}. \end{cases} (4) Rotating a shorter four-row board reduces it to a preceding family. In particular the minimum feasible budgets give T2(P3Pn)=6n8T_2(P_3\mathbin{\square}P_n)=6n-8 and T3(P4Pn)=4n4T_3(P_4\mathbin{\square}P_n)=4n-4 in their stated nondegenerate ranges. For five rows and n5n\ge5, the minimum feasible budget is three, and T3(P5Pn)=10n20. T_3(P_5\mathbin{\square}P_n)=10n-20. (5) The even-length proof uses a finite symbolic boundary certificate valid for every length, together with a history-dependent potential. The odd-length proof follows from the explicit neighborhood profiles. For every even n6n\ge6, putting h=5n/2h=5n/2 also gives T4(P5Pn)=22h83.T_4(P_5\mathbin{\square}P_n)=2\left\lceil\frac{2h-8}{3}\right\rceil. Theorem 19.5 gives a closed quotient-and-remainder formula for every larger budget on these even-length boards. Theorem 19.7 supplies the closed answer for every odd length as well. In particular, four inspections per day take 2(5n9)/3+21{3n}2\left\lceil(5n-9)/3\right\rceil+2\mathbf{1}_{\{3\mid n\}} days when n5n\ge5 is odd. Together with rotation of shorter boards, these give explicit formulas and attaining strategies for every five-row board and every budget. The wider odd-rectangle theorem extends the closed analysis to every width 2b+12b+1 when mb2+1m\ge b^2+1.

Optimal time at the smallest feasible daily budget for four narrow families and the five-row three-probe theorem. Each line is a proved formula, not a fit to search data.

Shared proof tools and proof status

The common difficulty is temporal. A smallest next neighborhood need not contain an equally favorable survivor for the following day. Whole- strategy compression, attained inverse-profile arithmetic, corner capacities, physical propagation and efficient-frontier arguments address different parts of that obstruction. General statements are retained where they are natural dependencies of rectangle proofs; their independent box applications are in the parked companion.

The exact fixed-deadline minimum constant budget is an inverse formulation of the same capture relation. Section 28 therefore retains its rectangle consequence and proof. It is not silently turned into a varying-budget objective.

Ordinary proofs, independent finite checks and physical-game Lean verification are different evidence layers. Section 32 states the precise boundary. A compiled collection of reusable components does not formally verify every unbounded theorem appearing here.

Prior work and provenance

Britnell and Wildon (Britnell and Wildon 2013) studied the princess puzzle with one daily inspection, including the path value 2n42n-4. Haslegrave studied the associated evasion game (Haslegrave 2014); related moving- target search appears in Beluhov and Kolev (Beluhov and Kolev 2017). Abramovskaya, Fomin, Golovach, and Pilipczuk (Abramovskaya et al. 2016) developed Hunters and Rabbit results, including the rectangular-grid feasibility threshold min(a,b)/2+1\left\lfloor\min(a,b)/2\right\rfloor+1. Bolkema and Groothuis proved isoperimetric nesting and the hunting number for hypercubes (Bolkema and Groothuis 2019). We use precise versions of these results; minimum-time claims do not follow from feasibility alone. Parity-restricted boundary minimization on the binary cube goes back to Körner and Wei (Körner and Wei 1984). Compression proofs and local-to-global principles have a substantial earlier literature, including Bezrukov and Serra (Bezrukov and Serra 2002); their closed-neighborhood theorem is distinct from the open-neighborhood argument given here.

Dmitry Kamenetsky recorded conjectural two- and three-inspection path formulas in March 2018 (Kamenetsky 2018a, 2018b). Equation (1) proves those special cases and extends them to arbitrary budgets. The author’s independent path work took place between October 2019 and March 2020 and was written in two Bulgarian conference manuscripts (Raychev and Rusev 2020; Raychev 2020). The one-probe restriction omitted from a printed general formula is made explicit here. The original conference documents are preserved.

The time-budget inverse parameter is also considered in recent work (Ben-Ameur et al. 2026); we do not claim the general optimization question as new. Recontamination can matter substantially on general graphs (Dissaux et al. 2025), so a presumed monotone search is never used as an unproved lower-bound assumption. The parked companion separately records the classical closed-neighborhood isoperimetry used for its higher-dimensional applications. Those applications do not supply the open-neighborhood argument for odd rectangles.

Remark 1.1 (Status of this manuscript). This is a research manuscript in preparation, not an arXiv submission. The ordinary theorems have internal independent proof reviews; exact Lean coverage is stated in Section 32. Attribution of the 2026 extensions is still undergoing a focused literature review. The manuscript makes no blanket claim that every derived ingredient is new to the literature.

The game and its possible positions

Let G=(V,E)G=(V,E) be a finite simple graph without isolated vertices, and let m1m\geq1 be the daily inspection budget. Every connected board with at least two rooms satisfies this graph assumption; a one-room board takes one inspection and is treated separately. The target chooses an unknown initial vertex. On day t=1,2,t=1,2,\ldots, the searcher inspects a set StVS_t\subseteq V with Stm|S_t|\leq m. If the target occupies a vertex of StS_t, it is caught. Otherwise it must move along exactly one edge before the next day. Inspections within a day are simultaneous. The searcher receives no information about an unsuccessful inspection other than the miss.

Write Tm(G)T_m(G) for the minimum number of days in which capture can be guaranteed, and put Tm(G)=T_m(G)=\infty if there is no finite guarantee. For positive rectangle side lengths define Tk(a,b):=Tk(PaPb)=Tk(b,a).T_k(a,b):=T_k(P_a\mathbin{\square}P_b)=T_k(b,a). The daily inspection set is St(a,b,k)S_t(a,b,k), with St(a,b,k)k|S_t(a,b,k)|\le k. We use kk for the global budget and retain the legacy letter mm in individual proofs; locally w=min(a,b)w=\min(a,b) and n=max(a,b)n=\max(a,b). The separate no-inspection convention is T0(a,b)=T_0(a,b)=\infty, including the one-room board: inability to move is not capture. This convention is not derived from a vacuous target-walk quantifier. The associated feasibility threshold is h(G)=min{m1:Tm(G)<}.h(G)=\min\{m\geq1:T_m(G)<\infty\}. We consider deterministic guarantees. Before capture, every observation is a miss. Thus an adaptive strategy has only one continuing observation history and is represented by a sequence (St)t1(S_t)_{t\geq1}. This sequence formulation does not restrict the searcher’s guaranteed performance.

For AVA\subseteq V, its open neighborhood is N(A)={vV:some uA satisfies uvE}.N(A)=\{v\in V:\text{some }u\in A\text{ satisfies }uv\in E\}. Define the possible-position sets immediately before inspection by B1=V,Bt+1=N(BtSt).B_1=V,\qquad B_{t+1}=N(B_t\setminus S_t). The following elementary interpretation is used in every subsequent argument.

Lemma 2.1. For each t1t\geq1, a vertex vv belongs to BtB_t if and only if there is a walk v1,,vt=vv_1,\ldots,v_t=v in GG such that viSiv_i\notin S_i for every 1i<t1\leq i<t. Consequently capture is guaranteed by day tt exactly when BtStB_t\subseteq S_t.

Proof. The assertion about walks follows by induction. At t=1t=1 every vertex is an admissible initial position. For the inductive step, vBt+1v\in B_{t+1} means that some neighbor uBtu\in B_t avoids StS_t. Append vv to a walk ending at uu supplied by the induction hypothesis. Conversely, the penultimate vertex of any such walk belongs to BtStB_t\setminus S_t, so its final vertex belongs to Bt+1B_{t+1}.

A walk ending outside StS_t avoids all inspections through day tt, whereas every surviving walk is caught that day if its endpoint lies in StS_t. This is exactly the stated inclusion. ◻

Since GG has no isolated vertices, a nonempty set has a nonempty open neighborhood. Hence the capture condition is also equivalent to Bt+1=B_{t+1}=\varnothing. We use this equivalent form only under that hypothesis. A board with a single room is handled directly: one inspection on the first day suffices. Thus an inability to make a move is never silently treated as capture.

Two monotonicity observations will be useful. Starting from fewer possible positions cannot make a fixed inspection sequence less successful, and adding inspected vertices cannot make it less successful. Both follow by induction from monotonicity of NN and set difference in their respective arguments. In particular, probes outside the current possible-position set may be wasted, but they cause no problem for the model or the lower bounds.

Two initial parity classes

Suppose GG is bipartite, with vertex classes V0,V1V_0,V_1. Keep track of the two possible initial colors separately: R1s=Vs,Rt+1s=N(RtsSt),s{0,1}.R^s_1=V_s,\qquad R^s_{t+1}=N(R^s_t\setminus S_t),\qquad s\in\{0,1\}. Then Bt=Rt0˙Rt1,RtsVs+t1(mod2).B_t=R^0_t\mathbin{\dot\cup}R^1_t, \qquad R^s_t\subseteq V_{s+t-1\pmod2}. Indeed, neighborhood and deletion distribute over unions, and every edge reverses color. The two sets therefore stay disjoint while exchanging their current colors each night. Allocations to the two initial classes sum to at most the day’s inspection budget. We will state explicitly whether a pair of counts is indexed by initial color or by current color; the latter convention swaps the two counts after every move.

This separates the bookkeeping common to the path, ladder, and grid arguments. The work specific to a graph is to determine how small a neighborhood can be after a given number of inspections, and when a sequence of such bounds can actually be attained.

Compressing entire strategies

An isoperimetric inequality bounds one neighborhood. To preserve an optimal search, the replacement sets must also respect containment and remain compatible after successive moves. The following criterion provides that stronger conclusion.

Definition 3.1. A strategy compression on GG is a map C:2V2VC:2^V\to2^V satisfying AB    C(A)C(B),C(A)=A,N(C(A))C(N(A)).\begin{aligned} A\subseteq B&\implies C(A)\subseteq C(B), \\ |C(A)|&=|A|, \\ N(C(A))&\subseteq C(N(A)). \end{aligned}(6, 7, 8) Idempotence is an additional property, not part of this definition.

Theorem 3.2 (Strategy comparison and a fixed-state normal form). Let CC be a strategy compression. Every successful strategy from AA with prescribed daily budgets m1,,mTm_1,\ldots,m_T has a successful strategy from C(A)C(A) with the same budgets. If CC is idempotent, every starting set fixed by CC has an optimal strategy whose possible-position sets and post-inspection survivor sets are all fixed by CC.

Proof. Let AtA_t be the original possible-position set before day tt, and RtR_t its survivors, so At+1=N(Rt)A_{t+1}=N(R_t) and AtRtmt|A_t|-|R_t|\leq m_t. Maintain a new actual possible-position set BtC(At)B_t\subseteq C(A_t), initially B1=C(A1)B_1=C(A_1). Inspect Qt=BtC(Rt).Q_t=B_t\setminus C(R_t). Monotonicity and equal cardinalities give QtC(At)C(Rt)=AtRtmt.|Q_t|\leq |C(A_t)\setminus C(R_t)|=|A_t|-|R_t|\leq m_t. The new survivors are BtC(Rt)B_t\cap C(R_t), and Bt+1=N(BtC(Rt))N(C(Rt))C(N(Rt))=C(At+1).B_{t+1}=N(B_t\cap C(R_t)) \subseteq N(C(R_t))\subseteq C(N(R_t))=C(A_{t+1}). When the original survivors are empty, C(Rt)=C(R_t)=\varnothing, so the new strategy also captures every remaining possibility.

Fixed sets are closed under intersections: if X,YX,Y are fixed, monotonicity gives C(XY)XYC(X\cap Y)\subseteq X\cap Y, and cardinality forces equality. They are closed under neighborhoods for the same reason: N(X)C(N(X))N(X)\subseteq C(N(X)) when XX is fixed. If CC is idempotent, C(Rt)C(R_t) is fixed. Starting the preceding construction from a fixed B1B_1, every actual survivor BtC(Rt)B_t\cap C(R_t) and every next possible-position set is therefore fixed. Restricted strategies are actual strategies, so their optimum equals the unrestricted optimum. ◻

Products and simultaneous compression

Lemma 3.3 (Product lift). A strategy compression on a graph AA lifts to AHA\mathbin{\square}H by applying it separately in every HH-indexed AA-fiber. Idempotence is preserved.

Proof. Write ShS_h for the fiber at hh. Its neighborhood is N(S)h=NA(Sh)uhSu.N(S)_h=N_A(S_h)\cup\bigcup_{u\sim h}S_u. For the lifted operator C^\widehat C, the corresponding neighborhood is N(C^(S))h=NA(C(Sh))uhC(Su)C(NA(Sh))uhC(Su)C(NA(Sh)uhSu).\begin{aligned} N(\widehat C(S))_h &=N_A(C(S_h))\cup\bigcup_{u\sim h}C(S_u)\\ &\subseteq C(N_A(S_h))\cup\bigcup_{u\sim h}C(S_u)\\ &\subseteq C\left(N_A(S_h)\cup\bigcup_{u\sim h}S_u\right). \end{aligned} The last inclusion uses monotonicity separately on each input subset of the union. Cardinality, monotonicity and idempotence hold fiber by fiber. ◻

Compositions of strategy compressions are strategy compressions, since N(C(D(S)))C(N(D(S)))C(D(N(S))).N(C(D(S)))\subseteq C(N(D(S)))\subseteq C(D(N(S))). Suppose finitely many such operators strictly decrease a common nonnegative integer potential whenever they change a set. If that potential has a uniform upper bound BB, cycling through all operators B+1B+1 times reaches a common fixed point for every input. A cycle with a change decreases the potential, and a cycle without a change fixes every operator. The resulting map is a composition with a uniform number of factors, hence is monotone and cardinality preserving; it is also idempotent. This avoids assuming that an input-dependent stopping rule preserves monotonicity.

Odd path fibers

Lemma 3.4 (Odd-path compression). On P2q+1P_{2q+1}, q1q\geq1, number vertices 0,,2q0,\ldots,2q. Replace the selected vertices of each parity by the same number of vertices at the beginning of 0,2,,2qor1,3,,2q1.0,2,\ldots,2q\qquad\text{or}\qquad1,3,\ldots,2q-1. This is an idempotent, parity-preserving strategy compression.

Proof. Monotonicity, cardinality and idempotence follow from the definition. An even-parity kk-set has at least min(k,q)\min(k,q) odd neighbors. If kqk\leq q, omit an unselected even vertex 2j2j and match 2i2i to 2i+12i+1 for i<ji<j, and to 2i12i-1 for i>ji>j. These matches are distinct and include every selected even vertex. If k=q+1k=q+1, all qq odd vertices are neighbors. A nonempty odd-parity kk-set has at least k+1k+1 even neighbors: its consecutive blocks in the spacing-two order each have one more neighbor than their size, and different blocks have disjoint neighbor intervals. The two prefixes attain these bounds, and their neighborhoods are prefixes of the opposite parity. Consequently each part of N(C(S))N(C(S)) is contained in the corresponding same-cardinality prefix of N(S)N(S), proving (8) even when SS contains both colors. ◻

For several odd coordinates, combine their lifted operators. Every changing operation decreases the sum of coordinates, so simultaneous compression has the normal form of Theorem 3.2. Its fixed sets satisfy vS    v2eiSv\in S\implies v-2e_i\in S whenever the latter vertex belongs to the box. These are lower ideals separately in each coordinate-parity pattern. They need not be lower ideals in the whole checkerboard color: for example, {(1,1)}\{(1,1)\} in a 3×33\times3 square is fixed by the two path operators but does not contain (0,0)(0,0).

Exact recurrences on odd cylinders

For the rectangle objective take H=PwH=P_w below. The prefix-fiber argument is retained in its natural generality as an exact evaluator; independent non-rectangle applications are parked in the companion.

Let G=HP2q+1G=H\mathbin{\square}P_{2q+1}, where HH is any finite graph and q1q\geq1. The product lift and Theorem 3.2 give an exact normal form from the full board. It uses two vectors indexed by V(H)V(H): av0a_v^0 counts even path coordinates in fiber vv, and av1a_v^1 counts odd path coordinates. Their ranges are 0av0q+1,0av1q.0\leq a_v^0\leq q+1,\qquad0\leq a_v^1\leq q. Thus they refer to the parity of the path coordinate, and do not require HH to be bipartite. Define ϕ0(k)=min(k,q),ϕ1(k)={0,k=0,k+1,k>0.\phi_0(k)=\min(k,q),\qquad \phi_1(k)=\begin{cases}0,&k=0,\\k+1,&k>0.\end{cases} For survivor vectors b0a0b^0\leq a^0, b1a1b^1\leq a^1, the exact next state F(b)F(b) is F(b)v0=max(ϕ1(bv1),maxuvbu0),F(b)v1=max(ϕ0(bv0),maxuvbu1),\begin{aligned} F(b)^0_v&=\max\left(\phi_1(b_v^1),\max_{u\sim v}b_u^0\right),\\ F(b)^1_v&=\max\left(\phi_0(b_v^0),\max_{u\sim v}b_u^1\right), \end{aligned}(9, 10) with an empty maximum interpreted as zero. Path edges supply the first term, and HH-edges the second. All contributions in a fiber are prefixes of the same parity, so their union has exactly the maximum length. The required number of inspections is d(a,b)=vV(H)(av0bv0+av1bv1).d(a,b)=\sum_{v\in V(H)}(a_v^0-b_v^0+a_v^1-b_v^1). They are realized by inspecting the removed suffix of each prefix.

For a fixed budget mm, form an edge aF(b)a\to F(b) whenever bab\leq a and d(a,b)md(a,b)\leq m. Then Tm(a)T_m(a) is exactly the shortest-path distance to zero in this state graph, or infinity if zero is unreachable. Equivalently, Tm(a)=1+minbad(a,b)mTm(F(b)),Tm(0)=0, T_m(a)=1+\min_{\substack{b\leq a\\d(a,b)\leq m}}T_m(F(b)), \qquad T_m(0)=0, (11) where the shortest-path interpretation specifies the solution of the possibly cyclic equations. For all budgets simultaneously, let Wt(a)W_t(a) be the least constant budget that wins within tt days. Then Wt+1(a)=minbamax{d(a,b),Wt(F(b))}, W_{t+1}(a)=\min_{b\leq a}\max\{d(a,b),W_t(F(b))\}, (12) with W0(0)=0W_0(0)=0, W0(a)=W_0(a)=\infty for a0a\ne0. Backpointers in either recurrence give actual inspection sets.

If A=V(H)A=|V(H)|, the number of states is exactly K=((q+1)(q+2))A(2q+2)2A.K=((q+1)(q+2))^A\leq(2q+2)^{2A}. There are at most K2K^2 state–survivor pairs. Explicit construction of their transitions takes O((A+E(H))K2)O((A+|E(H)|)K^2) elementary operations, apart from integer bit costs. For fixed HH, this is polynomial in the odd longitudinal length. Any successful path can have cycles removed, so a finite optimum is at most K1K-1. This proves an exact algorithm, not a uniform polynomial bound in dimension or a closed time formula.

When HH is bipartite, one may instead index vectors by global color. For a coloring χ\chi, put εp(v)=pχ(v)(mod2)\varepsilon_p(v)=p-\chi(v)\pmod2. A single current color has transition [Φp(b)]v=max(ϕεp(v)(bv),maxuvbu).[\Phi_p(b)]_v=\max\left(\phi_{\varepsilon_p(v)}(b_v), \max_{u\sim v}b_u\right). The two current-color vectors then become (Φ1(b1),Φ0(b0))(\Phi_1(b^1),\Phi_0(b^0)). This convention is useful when comparing the cylinder recurrence with the two-color grid arguments below.

Square fibers and equal-sided boxes

Abramovskaya, Fomin, Golovach and Pilipczuk (Abramovskaya et al. 2016, sec. 3.1, Lemma 2) prove that diagonal shifts do not increase the neighborhood size of a one-color set in a square. The following fiber calculation strengthens the scalar comparison to (8) and applies it to both colors. That stronger statement is what allows whole strategies to be compressed.

Lemma 3.5 (Square diagonal compression). On {0,,n1}2\{0,\ldots,n-1\}^2, compress each line x+y=kx+y=k toward increasing priority for smaller yy, keeping its selected cardinality. This is an idempotent, parity-preserving strategy compression. The same is true on lines xy=kx-y=k, again toward smaller yy.

Proof. Only the neighborhood inclusion needs proof. Consecutive square diagonals have lengths differing by one. Index both from the common increasing-yy end. From a diagonal of length LL to one of length L+1L+1, a selected index jj has neighbors j,j+1j,j+1. A nonempty aa-set therefore has at least a+1a+1 neighbors; a prefix attains this bound with a prefix. From length LL to length L1L-1, the indices are j1,jj-1,j, clipped to the valid range. A proper nonempty aa-set has at least aa neighbors, and the full set has L1L-1. Indeed, if it has cc consecutive blocks and occupies ee endpoints, its neighbor count is a+cea+c-e; for a proper set cec\geq e. Prefixes again attain the bounds with prefixes.

Fix an output diagonal. Its two input diagonals, after compression, contribute prefixes from the same end. Their union is the longer prefix. Each contributing length is no larger than its original contribution, hence no larger than the original union’s size. The compressed union is therefore contained in the prefix selected by compressing that original neighborhood. This argument works on either parity and on their union. Reflecting xx proves the other diagonal direction. ◻

Remark 3.6 (Why even path factors require another idea). Every parity-preserving strategy compression on an even path is the identity. Each endpoint is the unique degree-one vertex in its color. Applying (8) to its singleton forces that singleton to be fixed. Fixed sets are closed under neighborhoods, so every NtN^t of either endpoint is fixed. These are the spacing-two prefixes from the two ends. Intersections of suitable prefixes isolate every singleton; fixed intersections follow from monotonicity and cardinality, without idempotence. Thus all singletons, and consequently all sets, are fixed. This rules out a nontrivial even-path factor reduction within this specific comparison framework. It does not rule out richer state labels or different comparison theorems.

One quadrant profile for every forbidden initial triangle

The square-root and pronic-root bounds have a common extension that retains prescribed omissions near a corner. Neighborhoods below are always taken in the whole nonnegative quadrant. Forbidden rooms constrain the support; they are not deleted from the graph.

Theorem 4.1 (Punctured-quadrant profile). Fix a checkerboard color p{0,1}p\in\{0,1\} and an integer r0r\ge0. Require a finite color-pp support to omit the diagonals x+y=p,p+2,,p+2(r1)x+y=p,p+2,\ldots,p+2(r-1), and put h=2r+ph=2r+p. For every integer s0s\ge0, the largest possible support with neighborhood surplus at most ss has cardinality Ch(s)=max{s(s1)2, s(sh)}. C_h(s)=\max\left\{\frac{s(s-1)}2,\ s(s-h)\right\}. (13) Every cardinality up to this maximum is attainable with surplus at most ss. Consequently the exact minimum neighborhood size of a kk-room support, k>0k>0, is k+min{s0:kCh(s)}.k+\min\{s\ge0:k\le C_h(s)\}. Thus its surplus is the smaller of two integer quadratic roots.

For h=0h=0 and h=1h=1 the formula gives respectively k\left\lceil\sqrt{k}\right\rceil and the least ss with ks(s1)k\le s(s-1). The case h=2h=2 forbids the even origin; h=3h=3 forbids both odd neighbors of the origin. These exact static profiles do not assert that their minimizers can be chained inside arbitrary earlier beliefs.

Proof. Use Lemma 3.5 inside a square large enough that neither the original nor compressed support or neighborhood reaches its far edges. It compresses each diagonal toward smaller yy, preserving cardinality and all the forbidden diagonals, without increasing the neighborhood. Let aja_j be the resulting count on x+y=2j+px+y=2j+p, whose length is j=2j+p+1\ell_j=2j+p+1, and put ϵj=1{aj=j}\epsilon_j=\mathbf{1}_{\{a_j=\ell_j\}}. Counts with j<rj<r vanish. The exact output count on x+y=2j+p+1x+y=2j+p+1 is nj=max{aj+1{aj>0}, aj+1ϵj+1}.n_j=\max\{a_j+\mathbf{1}_{\{a_j>0\}},\ a_{j+1}-\epsilon_{j+1}\}. The two contributions are prefixes of the same diagonal. The upper input contracts by one only when full. There is also an initial output count n1=a0ϵ0n_{-1}=a_0-\epsilon_0; for p=0p=0 this is identically zero, correctly representing the nonexistent lower diagonal.

Put δj=njaj\delta_j=n_j-a_j for j0j\ge0, and δ1=n1\delta_{-1}=n_{-1}. These numbers are nonnegative and sum to the compressed surplus δ\delta. Moreover δj1{aj>0},δjaj+1ajϵj+1.\delta_j\ge\mathbf{1}_{\{a_j>0\}},\qquad \delta_j\ge a_{j+1}-a_j-\epsilon_{j+1}. List the occupied diagonals as j1<<jLj_1<\cdots<j_L and let ftf_t count the full ones through jtj_t. Telescoping below jtj_t gives surplus at least ajtfta_{j_t}-f_t; the remaining output has surplus at least Lt+1L-t+1. Hence ajtδL+t1+ft. a_{j_t}\le\delta-L+t-1+f_t. (14)

If no occupied diagonal is full, the initial contribution is positive, so Lδ1L\le\delta-1. Summing (14) with ft=0f_t=0 gives SLδL(L+1)2δ(δ1)2.|S|\le L\delta-\frac{L(L+1)}2 \le\frac{\delta(\delta-1)}2. If the first full diagonal has occupied rank uu, then fu=1f_u=1 and jur+u1j_u\ge r+u-1, so its size is at least h+2u1h+2u-1. Equation (14) gives Lδhu+1δhL\le\delta-h-u+1\le\delta-h. Summing the same equation with fttf_t\le t now gives SLδδ(δh)|S|\le L\delta\le\delta(\delta-h). The empty set is separate. Since ChC_h is nondecreasing on nonnegative integers, compression proves the upper bound for every original set of surplus at most ss.

Two nested constructions prove sharpness. For h1h\ge1, use the proper diagonal counts ar+i=i+1(0is2).a_{r+i}=i+1\qquad(0\le i\le s-2). Their initial surplus is one, and each occupied diagonal contributes one more. Their size is s(s1)/2s(s-1)/2 and their surplus is ss. For sh+1s\ge h+1, instead use the shs-h full consecutive diagonals ar+i=h+1+2i(0i<sh).a_{r+i}=h+1+2i\qquad(0\le i<s-h). Their initial surplus is hh, and each full diagonal contributes one. Their size is s(sh)s(s-h) and surplus is again ss.

A partial last diagonal interpolates between consecutive capacities in either family. After a nonempty completed ramp or full block, its downward contribution fits in the existing neighborhood, and a positive partial fill increases surplus by exactly one. For the first full block, a partial first diagonal of v<h+1v<h+1 rooms has surplus v+1h+1v+1\le h+1; the full first diagonal has surplus h+1h+1. The full-block branch dominates when s2h1s\ge2h-1. For h2h\ge2 its first dominant positive level is within its valid range sh+1s\ge h+1; for h=1h=1 it starts at s=2s=2. Thus whichever family supplies the new maximum also fills every gap above the preceding maximum. For h=0h=0, the full blocks alone give s2s^2, starting with the origin, and partial final diagonals fill every intermediate size. This proves all asserted attainments. ◻

Lemma 4.2 (Two candidates for convex capacities). Let A,B:NNA,B:\mathbb{N}\to\mathbb{N} be nondecreasing, unbounded and discretely convex, with A(0)=B(0)=0A(0)=B(0)=0. Define α(k)=min{s:kA(s)}\alpha(k)=\min\{s:k\le A(s)\} and β(k)=min{s:kB(s)}\beta(k)=\min\{s:k\le B(s)\}. For integers 0luS0\le l\le u\le S, the minimum of α(y)+β(Sy)\alpha(y)+\beta(S-y) over lyul\le y\le u is attained at one of y1=min{u,A(α(l))},y2=max{l,SB(β(Su))}.y_1=\min\{u,A(\alpha(l))\},\qquad y_2=\max\{l,S-B(\beta(S-u))\}.

Proof. Take any feasible yy of cost tt, and put a=α(y)a=\alpha(y), b=β(Sy)b=\beta(S-y). Then a+b=ta+b=t, aα(l)a\ge\alpha(l), bβ(Su)b\ge\beta(S-u) and A(a)+B(b)SA(a)+B(b)\ge S. Discrete convexity puts the maximum of A(z)+B(tz)A(z)+B(t-z) on the integer interval α(l)ztβ(Su)\alpha(l)\le z\le t-\beta(S-u) at an endpoint. At the first endpoint, A(α(l))+B(tα(l))SA(\alpha(l))+B(t-\alpha(l))\ge S. The point y1y_1 has first cost at most α(l)\alpha(l) and second count at most B(tα(l))B(t-\alpha(l)): if clipped to uu, use β(Su)tα(l)\beta(S-u)\le t-\alpha(l) and monotonicity of BB. It therefore has total cost at most tt. The other endpoint gives y2y_2 symmetrically; if clipped to ll, use α(l)tβ(Su)\alpha(l)\le t-\beta(S-u). Both candidates lie in [l,u][l,u]. Applying this to a minimizing yy proves the assertion, including flat capacities, zero roots and singleton intervals. ◻

Each ChC_h in (13) is the maximum of two convex quadratics and is nondecreasing on N\mathbb{N}. The lemma therefore optimizes sums of any two punctured-quadrant root costs without searching their allocation interval. It also applies to the capacities s(s+1)s(s+1) and s2s^2 used in the inverse-profile calculation below.

Exact neighborhood profiles on odd rectangles

Let G=P2a+1P2b+1G=P_{2a+1}\mathbin{\square}P_{2b+1}, where ab1a\geq b\geq1, with coordinates (x,y)(x,y); thus xx is the long coordinate. Write V0,V1V_0,V_1 for its even and odd checkerboard classes, and E=V0=G+12,M=V1=E1.E=|V_0|=\frac{|G|+1}{2},\qquad M=|V_1|=E-1. Define the two open-neighborhood profiles by gp(k)=min{N(S):SVp, S=k}.g_p(k)=\min\{|N(S)|:S\subseteq V_p,\ |S|=k\}. It is convenient to use the integer functions R(k)=k,Q(k)=min{r1:kr(r1)}.R(k)=\left\lceil\sqrt{k}\right\rceil,\qquad Q(k)=\min\{r\geq1:k\leq r(r-1)\}. In particular R(0)=0R(0)=0 and Q(0)=1Q(0)=1.

Theorem 5.1 (Odd-rectangle profiles and compatible orders). Both profiles have gp(0)=0g_p(0)=0. For nonempty sets, g0(k)=k+min{R(k),b,R(Ek)1},1kE,g1(k)=k+min{Q(k),b+1,Q(Mk)},1kM.\begin{aligned} g_0(k)&=k+\min\{R(k),b,R(E-k)-1\}, &&1\leq k\leq E, \\ g_1(k)&=k+\min\{Q(k),b+1,Q(M-k)\}, &&1\leq k\leq M. \end{aligned}(15, 16) Order each parity by increasing (x+y,x)(x+y,x), and let Ip(k)I_p(k) be its prefix of size kk. Every prefix attains the corresponding minimum, and N(Ip(k))=I1p(gp(k)).N(I_p(k))=I_{1-p}(g_p(k)). (5.1)

The order fills the short direction first within a diagonal. Its direction is significant on an unequal rectangle. For example, the opposite tie order on 7×57\times5 gives the five-element even prefix {(0,0),(0,2),(1,1),(2,0),(4,0)}\{(0,0),(0,2),(1,1),(2,0),(4,0)\}, with eight neighbors; the set {(0,0),(0,2),(0,4),(1,1),(1,3)}\{(0,0),(0,2),(0,4),(1,1),(1,3)\} has seven.

Minimizing even prefixes on a 9×79\times7 rectangle. The three regimes are controlled by a corner, the short width, and the complement.

Quadrant bounds

Apply the odd-coordinate compressions of Lemma 3.4 in both directions. Their common fixed sets are lower closed under decreasing either coordinate by two, and compression does not increase the neighborhood size. We may therefore assume that each coordinate-parity pattern of SS is a lower Ferrers diagram. Let eie_i and oio_i be the selected counts in rows y=2iy=2i and y=2i+1y=2i+1, respectively. These are separately nonincreasing sequences. For source color 00 they count even-xx and odd-xx vertices, whereas for source color 11 they count odd-xx and even-xx vertices.

Lemma 5.2 (Quadrant area and row bounds). Regard a finite set with this Ferrers property as a subset of the infinite nonnegative quadrant. Put δ=N(S)S\delta=|N(S)|-|S|. If SS has color 00, then ei>0    ei+iδ,oi>0    oi+i+1δ,Sδ2.e_i>0\implies e_i+i\leq\delta,\qquad o_i>0\implies o_i+i+1\leq\delta, \qquad |S|\leq\delta^2. (5.2) If SS has color 11, then ei>0    ei+i+1δ,oi>0    oi+i+1δ,Sδ(δ1).e_i>0\implies e_i+i+1\leq\delta,\qquad o_i>0\implies o_i+i+1\leq\delta, \qquad |S|\leq\delta(\delta-1). (5.2) A nonempty set has surplus at least one in color 00 and at least two in color 11.

Proof. The sequences eventually vanish. A nonempty odd-xx prefix of length tt has t+1t+1 even-xx neighbors in the quadrant; an even-xx prefix has tt odd-xx neighbors. Contributions from neighboring rows are also prefixes, so their unions are given by maxima. Subtracting the source row sizes therefore yields, in color 00, δ=(o0e0)++i0[max{eioi,1{oi>0}}+(oiei+1)+]. \delta=\left(o_0-e_0\right)_+ +\sum_{i\geq0}\left[ \max\{e_i-o_i,\mathbf{1}_{\{o_i>0\}}\}+\left(o_i-e_{i+1}\right)_+ \right]. (17) For color 11 the identity is δ=max{1{e0>0},o0e0}+i0[(eioi)++max{oiei+1,1{ei+1>0}}]. \delta=\max\{\mathbf{1}_{\{e_0>0\}},o_0-e_0\} +\sum_{i\geq0}\left[ \left(e_i-o_i\right)_++\max\{o_i-e_{i+1},\mathbf{1}_{\{e_{i+1}>0\}}\} \right]. (18) All terms displayed are nonnegative.

Suppose first that SS has color 00 and ei>0e_i>0. In (17), each of the first ii paired summands is at least one. If its odd count is positive, the first term is at least one; otherwise its even count is positive. The tail from ii onward is at least the telescoping sum ji((ejoj)+(ojej+1))=ei.\sum_{j\geq i}\bigl((e_j-o_j)+(o_j-e_{j+1})\bigr)=e_i. Thus δi+ei\delta\geq i+e_i. If oi>0o_i>0, every preceding pair contributes at least one, as does the first term of pair ii. The second term of pair ii and the subsequent pairs have sum at least oio_i, by the same telescoping argument. This gives δi+1+oi\delta\geq i+1+o_i.

For color 11 and ei>0e_i>0, the initial term of (18) is at least one, and the first ii pairs each contribute at least one because ej+1>0e_{j+1}>0 for j<ij<i. The remaining tail is at least eie_i. If oi>0o_i>0, the initial term is again at least one. Every preceding pair contributes at least one: either ej+1>0e_{j+1}>0, or the positive ojo_j appears in its second term. The tail after the first term of pair ii is at least oio_i. These are the two claimed bounds for color 11.

Finally sum the row bounds. In color 00 the maximum possible total is i0max(δi,0)+i0max(δi1,0)=δ2.\sum_{i\geq0}\max(\delta-i,0) +\sum_{i\geq0}\max(\delta-i-1,0)=\delta^2. In color 11 both sums have the second form, giving δ(δ1)\delta(\delta-1). The row inequalities also give the stated positive surplus bounds for nonempty sets. ◻

The two far edges

Lemma 5.3 (Corner, strip, or complement). Let SVpS\subseteq V_p have the Ferrers property. Put δ=NG(S)S\delta=|N_G(S)|-|S|, and let FF and ZZ count its vertices on the far edges x=2ax=2a and y=2by=2b, respectively. If exactly one of F,ZF,Z is positive, then δb+p\delta\geq b+p. If neither is positive, the quadrant bounds apply to SS without change. If both are positive, NG(S)N_G(S) covers both near edges in color 1p1-p, and the set V1pNG(S),V_{1-p}\setminus N_G(S), reflected in both coordinate midlines, has the Ferrers property and no far-edge vertices.

Proof. Viewing the same SS in the quadrant adds exactly one neighbor beyond the rectangle for every selected far-edge vertex. These F+ZF+Z vertices are distinct, even when the far corner is selected. Hence δquadrant=δ+F+Z. \delta_{\mathrm{quadrant}}=\delta+F+Z. (19) If F=0F=0 and Z>0Z>0, the last even row has eb=Ze_b=Z. The row bound in Lemma 5.2 gives δ+ZZ+b+p\delta+Z\geq Z+b+p. If F>0F>0 and Z=0Z=0, swap the axes to get the stronger bound δa+p\delta\geq a+p. If F=Z=0F=Z=0, there is no clipping.

Suppose now that both are positive. In color 00, the Ferrers property forces every even-xx vertex of row y=0y=0 and every even-yy vertex of column x=0x=0 into SS. They cover both opposite-color near edges. In color 11, far-xx occupancy forces the full even-xx row y=1y=1, covering the even-xx near edge y=0y=0. Far-yy occupancy forces (1,2i)S(1,2i)\in S for every 0ib0\leq i\leq b, covering the even-yy near edge x=0x=0.

The neighborhood of a fixed set is fixed under the two path operators, so its complement is upper closed within each coordinate-parity pattern. The two reflections convert it to a lower Ferrers set. They preserve checkerboard color because both side lengths are odd. The near-edge coverage just proved means the reflected complement has no far-edge vertices, as required. ◻

Lower bounds in Theorem 5.1

Let SV0S\subseteq V_0, S=k>0|S|=k>0, and put δ=N(S)k\delta=|N(S)|-k. If δb\delta\geq b the desired lower bound is immediate. Otherwise Lemma 5.3 leaves two possibilities. With no clipping, kδ2k\leq\delta^2. With both far edges occupied, let TT be the reflected opposite-color complement of N(S)N(S). It has size t=Mkδt=M-k-\delta. Before reflection, its neighborhood is contained in V0SV_0\setminus S, so its quadrant surplus is at most δ+1\delta+1. For δ1\delta\geq1, Lemma 5.2 gives Mkδ=tδ(δ+1),kE(δ+1)2.M-k-\delta=t\leq\delta(\delta+1),\qquad k\geq E-(\delta+1)^2. (5.3) If δ=1\delta=-1 or 00, TT must be empty, since a nonempty quadrant color-11 set has surplus at least two. This yields respectively k=Ek=E or k=Mk=M, the same conclusion. No smaller δ\delta is possible: pairing along each row, then vertically in the unpaired last column, gives a matching covering all vertices except the far even corner, and hence N(S)k1|N(S)|\geq k-1. In all cases, δmin{R(k),b,R(Ek)1}.\delta\geq\min\{R(k),b,R(E-k)-1\}.

For SV1S\subseteq V_1, the same matching gives δ0\delta\geq0. Below b+1b+1, the unclipped case gives kδ(δ1)k\leq\delta(\delta-1). In the complement case, TT has size EkδE-k-\delta and quadrant color-00 surplus at most δ1\delta-1. The case δ=0\delta=0 is impossible: TT is nonempty because kM<Ek\leq M<E, but would have negative surplus. For δ1\delta\geq1, Ekδ(δ1)2,kMδ(δ1).E-k-\delta\leq(\delta-1)^2,\qquad k\geq M-\delta(\delta-1). The unclipped nonempty case also has δ1\delta\geq1. Thus δmin{Q(k),b+1,Q(Mk)}.\delta\geq\min\{Q(k),b+1,Q(M-k)\}. These prove the lower bounds in both formulas.

For comparison, the two exact profiles of any bipartite graph obey the complement-inverse identity g1(y)=Emax{x:g0(x)My}. g_1(y)=E-\max\{x:g_0(x)\leq M-y\}. (20) Indeed, the existence of nonadjacent sets of sizes xx and yy in the two colors is equivalent to g0(x)Myg_0(x)\leq M-y, and also to g1(y)Exg_1(y)\leq E-x. Thus the second formula can alternatively be checked from the first by exact inversion.

Attainment and neighborhood nesting

The vertices on diagonal x+y=dx+y=d have xx in the interval Ld=max(0,d2b)xmin(2a,d),L_d=\max(0,d-2b)\leq x\leq\min(2a,d), whose length is (d)=min(2a,d)max(0,d2b)+1,0d2a+2b.\ell(d)=\min(2a,d)-\max(0,d-2b)+1, \qquad0\leq d\leq2a+2b. A nonempty prefix ends after jj vertices of diagonal dd, for some 1j(d)1\leq j\leq\ell(d), and has size k=s<dsd(mod2)(s)+j. k=\sum_{\substack{s<d\\s\equiv d\pmod2}}\ell(s)+j. (21) All earlier opposite-color diagonals belong to its neighborhood. On diagonal d+1d+1, each selected xx contributes xx or x+1x+1 when the corresponding step stays inside the board. Their union is the initial interval there, of length f(d,j)=j+11{d2b}1{Ld+j1=2a}. f(d,j)=j+1-\mathbf{1}_{\{d\geq 2b\}}-\mathbf{1}_{\{L_d+j-1=2a\}}. (22) The first indicator removes the unavailable step past the short-direction boundary, and the second removes the step past the long-direction boundary. At the far corner both are present and f=0f=0. The initial minority diagonal d=1d=1 additionally covers the corner on diagonal zero, already included among the earlier opposite diagonals. Consequently N(Ip(k))=s<ds≢d(mod2)(s)+f(d,j),|N(I_p(k))|=\sum_{\substack{s<d\\s\not\equiv d\pmod2}}\ell(s)+f(d,j), and this neighborhood is exactly a prefix of the other color.

To evaluate its surplus, let Δ(d)\Delta(d) be the earlier opposite-color sum minus the earlier same-color sum. The recurrence Δ(0)=0\Delta(0)=0, Δ(d+1)=(d)Δ(d)\Delta(d+1)=\ell(d)-\Delta(d) gives Δ(d)={d/2,d2b,b+(dmod2),2bd2a,a+bd/2+(dmod2),d2a.\Delta(d)= \begin{cases} \left\lceil d/2\right\rceil,&d\leq2b,\\ b+(d\bmod2),&2b\leq d\leq2a,\\ a+b-\left\lfloor d/2\right\rfloor+(d\bmod2),&d\geq2a. \end{cases} The formulas agree at their shared endpoints. The exact surplus is Δ(d)+1\Delta(d)+1 minus the two indicators in (22). Complete even diagonals through sum 2r22r-2 contain r2r^2 vertices, and complete odd diagonals through sum 2r12r-1 contain r(r+1)r(r+1). Substitution into (21) yields

Color Size range Prefix surplus
00 1kb21\leq k\leq b^2 R(k)R(k)
00 b2<k<Eb2b^2<k<E-b^2 bb
00 Eb2kEE-b^2\leq k\leq E R(Ek)1R(E-k)-1
11 1kb(b+1)1\leq k\leq b(b+1) Q(k)Q(k)
11 b(b+1)<k<Mb(b+1)b(b+1)<k<M-b(b+1) b+1b+1
11 Mb(b+1)kMM-b(b+1)\leq k\leq M Q(Mk)Q(M-k)

For a square, the shared minority endpoint has surplus b+1b+1 in both rows; empty ranges are omitted. The table equals the two lower bounds. It proves attainment and the compatible-neighborhood assertion, completing the proof of Theorem 5.1.

An exact two-count game

Corollary 5.4. For every daily budget on every odd-by-odd rectangle, the unrestricted minimum capture time is exactly the shortest-path distance from (E,M)(E,M) to (0,0)(0,0) in the following two-count state graph: (u,v)(g1(j),g0(i)),0iu,0jv,u+vijm.(u,v)\longrightarrow (g_1(j),g_0(i)),\qquad 0\leq i\leq u,\quad0\leq j\leq v,\quad u+v-i-j\leq m. A shortest path gives an optimal physical strategy by deleting suffixes of the two current-color prefix orders. The reduction also respects arbitrary prescribed daily budgets.

Proof. Define C(S)=I0(SV0)I1(SV1).C(S)=I_0(|S\cap V_0|)\cup I_1(|S\cap V_1|). It is monotone, cardinality preserving and idempotent. By the exact profiles and nesting, N(C(S))V1p=I1p(gp(SVp))I1p(N(SVp)).N(C(S))\cap V_{1-p} =I_{1-p}(g_p(|S\cap V_p|)) \subseteq I_{1-p}(|N(S\cap V_p)|). The last set is the corresponding part of C(N(S))C(N(S)). Apply Theorem 3.2. Every displayed transition is also the exact neighborhood of the indicated survivors, so it has a physical realization. Shortest paths, with infinity for an unreachable zero state, settle both feasibility and minimum time. ◻

The corollary is an exact recurrence for every parameter, rather than a closed expression for its shortest-path distance. It avoids imposing an unproved sequential allocation to the two initial colors: both may receive inspections on any day.

Every budget on odd rectangles: a one-day determination

Retain E=M+1E=M+1 and the exact profiles of Theorem 5.1. The following reduction has no restriction on width, length, or feasible budget. It reduces the answer to one binary choice. Section 7 resolves that choice by an exact bounded-state calculation. The same section proves a scalar criterion after an explicit onset at every budget. Theorems below also settle the all-length linear and superlinear budget ranges; only the shorter boards outside the proved ranges remain open.

Write ιp(z)=max{k:gp(k)z}\iota_p(z)=\max\{k:g_p(k)\le z\} for the inverse profiles. Define D0(0)=D1(0)=0D_0(0)=D_1(0)=0 and D0(t+1)=ι0(min{M,D1(t)+m}),D1(t+1)=ι1(min{E,D0(t)+m}). D_0(t+1)=\iota_0(\min\{M,D_1(t)+m\}),\qquad D_1(t+1)=\iota_1(\min\{E,D_0(t)+m\}). (23) Here Dp(t)D_p(t) is the largest possible deficit in current color pp after tt inspection-and-movement steps devoted entirely to that cohort. Compatible prefixes attain these values. Let τ\tau be the first tt for which D0(t)=ED_0(t)=E or D1(t)=MD_1(t)=M.

Theorem 6.1 (Uniform one-day determination). For every feasible budget on every odd rectangle, 2τ1Tm2τ.2\tau-1\le T_m\le2\tau. Moreover Tm=2τ1T_m=2\tau-1 whenever E+MD0(τ1)D1(τ1)m. E+M-D_0(\tau-1)-D_1(\tau-1)\le m. (24) Necessity follows after the explicit onset in Theorem 7.5, as well as in the all-length minimum-budget and high-budget ranges and the additional ranges of Theorem 30.5 and Corollary 30.6. It remains open outside the proved ranges. The exact two-count algorithm determines the answer in all cases. The solo calculation itself uses at most 4b+24b+2 arithmetic stages, as shown below.

Concentrating the deficit before the first possible capture

Put q(z)=Q(z)1q(z)=Q(z)-1. Complement duality gives ι0(z)=zA(z),A(z)=min{q(z),b,q(Mz)},0z<M,ι0(M)=E,ι1(z)=zB(z),B(z)=min{R(z),b+1,1+R(Ez)},0zE.\begin{aligned} \iota_0(z)&=z-A(z),& A(z)&=\min\{q(z),b,q(M-z)\},&&0\le z<M,\\ \iota_0(M)&=E,\\ \iota_1(z)&=z-B(z),& B(z)&=\min\{R(z),b+1,1+R(E-z)\},&&0\le z\le E. \end{aligned} In particular ι0(0)=ι1(0)=ι1(1)=0\iota_0(0)=\iota_1(0)=\iota_1(1)=0.

Lemma 6.2 (Inverse concentration). For x,y0x,y\ge0 with x+yMx+y\le M, ι0(x)+ι1(y)ι0(x+y).\iota_0(x)+\iota_1(y)\le\iota_0(x+y). If x2x\ge2, also ι1(x)+ι0(y)ι1(x+y)\iota_1(x)+\iota_0(y)\le\iota_1(x+y).

Proof. The function qq is subadditive: ur(r+1)u\le r(r+1) and vs(s+1)v\le s(s+1) imply u+v(r+s)(r+s+1)u+v\le(r+s)(r+s+1). The minimum AA remains subadditive below MM. Indeed, if either minimizing branch is its cap or its decreasing reflected branch, that branch alone bounds A(x+y)A(x+y); otherwise use subadditivity of qq. Each branch of B(y)B(y) dominates the corresponding branch of A(y)A(y). Hence A(x)+B(y)A(x+y)A(x)+B(y)\ge A(x+y), proving the first inequality below MM. At x+y=Mx+y=M, each proper inverse is at most its argument, whereas ι0(M)=M+1\iota_0(M)=M+1; the endpoint x=M,y=0x=M,y=0 is equality.

For the second inequality, x2x\ge2 and y<My<M. If the cap or reflected branch minimizes B(x)B(x), then B(x+y)B(x)B(x+y)\le B(x). Otherwise B(x)=R(x)2B(x)=R(x)\ge2. If A(y)=q(y)A(y)=q(y), writing r=R(x)r=R(x) and s=q(y)s=q(y) gives x+yr2+s(s+1)(r+s)2x+y\le r^2+s(s+1)\le(r+s)^2. If A(y)=bA(y)=b, use R(x)+bb+1B(x+y)R(x)+b\ge b+1\ge B(x+y). Finally, if A(y)=q(My)A(y)=q(M-y), put z=Myxz=M-y\ge x. Since R(z)Q(z)R(z)\le Q(z), B(x+y)1+R(z+1x)1+Q(z)R(x)+Q(z)1.B(x+y)\le1+R(z+1-x)\le1+Q(z) \le R(x)+Q(z)-1. These are exactly the required cost inequalities. ◻

Lemma 6.3 (Exact total deficit before τ\tau). Let dp(t)d_p(t) be the deficit in current color pp for an arbitrary physical strategy after tt inspections and moves. For t<τt<\tau, d0(t)+d1(t)max{D0(t),D1(t)}.d_0(t)+d_1(t)\le\max\{D_0(t),D_1(t)\}. Equality is attainable by devoting the budget to one cohort.

Proof. Always dp(t)Dp(t)d_p(t)\le D_p(t) by the neighborhood lower bounds and monotonicity. Induct on tt. When t+1<τt+1<\tau, the endpoint values of the inverses imply max{D0(t),D1(t)}+mM. \max\{D_0(t),D_1(t)\}+m\le M. (25) For useful quotas p,qp,q with p+qmp+q\le m, put X=d0(t)+pX=d_0(t)+p, Y=d1(t)+qY=d_1(t)+q. Complement duality bounds the new deficits by ι0(Y),ι1(X)\iota_0(Y),\iota_1(X), and X+YmaxDp(t)+mMX+Y\le\max D_p(t)+m\le M. If D1(t)D0(t)D_1(t)\ge D_0(t), the first inverse inequality bounds their sum by ι0(D1(t)+m)=D0(t+1)\iota_0(D_1(t)+m)=D_0(t+1). Otherwise, when X2X\ge2, the second bounds it by ι1(D0(t)+m)=D1(t+1)\iota_1(D_0(t)+m)=D_1(t+1). When X1X\le1, the latter inverse vanishes and the individual bound on d1(t)d_1(t) suffices. The induction begins with zero deficits. ◻

The midpoint argument and attaining searches

Proof of Theorem 6.1. For τ=1\tau=1 the lower bound is immediate. Otherwise put L=τ1L=\tau-1 and suppose a schedule wins in 2L2L days, padding a shorter schedule by empty inspections if necessary. Its first LL inspections, each followed by movement, leave a belief FF on day L+1L+1. The preceding lemma gives FE|F|\ge E.

Read the last LL inspections backward along the undirected edges. Use L1L-1 inspection-and-movement steps and then one inspection without movement. The resulting set RR is also on day L+1L+1. Its deficit is at most maxDp(L1)+mM\max D_p(L-1)+m\le M, by (25) with the noncapturing time LL. Thus RE|R|\ge E. Since G=2E1|G|=2E-1, the sets intersect. Concatenating their forward and backward avoiding walks contradicts success. Hence Tm2τ1T_m\ge2\tau-1.

If A1,,AτA_1,\ldots,A_\tau captures one initial parity, use A1,,Aτ,Aτ,,A1.A_1,\ldots,A_\tau,A_\tau,\ldots,A_1. The first half captures that parity. Reversing an avoiding walk in the second half gives a walk of that initial parity avoiding the first half, so the opposite cohort is captured as well. This proves the upper bound with an explicit legal schedule.

Finally prepare one physical color optimally for LL steps before a central inspection, and the other physical color for LL reversed steps after it. Each half leaves the other cohort full. Their intersection therefore consists of the two solo residual sets, of total size E+MD0(L)D1(L)E+M-D_0(L)-D_1(L). Inspect that intersection centrally. Condition (24) makes this a legal (2τ1)(2\tau-1)-day search. ◻

Evaluating the solo recurrence without iterating over days

Put C0=E,C1=MC_0=E,C_1=M, fp(k)=gp((km)+)f_p(k)=g_p(\left(k-m\right)_+), and Pp=f1pfpP_p=f_{1-p}\circ f_p. The two-day map returns a cohort to its original physical color. Extend ιp(z)=Cp\iota_p(z)=C_p for zC1pz\ge C_{1-p}.

Proposition 6.4 (A bounded number of arithmetic stages). For any canonical one-cohort prefix, its exact solo capture time and its remaining count at any prescribed day can be evaluated using at most 4b+24b+2 translation intervals and integer floor divisions. The number of stages is independent of the longer side and the number of search days. This evaluates the solo part of Theorem 6.1; by itself it does not decide the scalar midpoint condition in the remaining unresolved parameter range.

Proof. Every change in the surplus gp(k)kg_p(k)-k at a positive argument belongs to B0={r2+1:0r<b}{Er2:0rb},B1={r(r1)+1:1rb}{Mr(r1):1rb}.\begin{aligned} \mathcal B_0&=\{r^2+1:0\le r<b\}\cup\{E-r^2:0\le r\le b\},\\ \mathcal B_1&=\{r(r-1)+1:1\le r\le b\} \cup\{M-r(r-1):1\le r\le b\}. \end{aligned} Include 11 and discard points outside the appropriate profile domain. These are the change points of the two capped root terms; their minimum cannot change elsewhere. Set cp=min{Cp,m+ιp(m)}c_p=\min\{C_p,m+\iota_p(m)\}. Exactly the counts kcpk\le c_p disappear in at most two days. Above cpc_p, the change points of PpP_p are contained in {m+s:sBp}{m+ιp(m+s1)+1:sB1p}.\{m+s:s\in\mathcal B_p\}\cup \{m+\iota_p(m+s-1)+1:s\in\mathcal B_{1-p}\}. The second set is the inverse image of the first argument at which the second surplus changes. Add cp+1,Cp+1c_p+1,C_p+1 and clip to this interval. Between consecutive endpoints l,u+1l,u+1, the map is kkdk\mapsto k-d, where d2m2b11d\ge2m-2b-1\ge1 and every output is positive. There are at most 4b+24b+2 such intervals.

Process them from top to bottom. If the current count klk\ge l, exactly 1+(kl)/d1+\left\lfloor(k-l)/d\right\rfloor consecutive pairs have their source in [l,u][l,u]. Subtract this multiple of dd and add twice that many days. The next count is below ll, so no interval is revisited. On reaching kcpk\le c_p, add zero, one, or two final days according as k=0k=0, 0<km0<k\le m, or k>mk>m. For a prescribed day, truncate the appropriate number of pairs and use one application of fpf_p if needed. All operations are exact integer arithmetic. Sorting the endpoints uses O(blogb)O(b\log b) comparisons; the number of division stages is O(b)O(b). ◻

Lemma 6.5 (Two candidates for opposed roots). Write q(y)=Q(y)1q(y)=Q(y)-1, with q(0)=0q(0)=0. For integers 0luS0\le l\le u\le S, the minimum of q(y)+R(Sy)q(y)+R(S-y) over lyul\le y\le u is attained at one of min{u,q(l)(q(l)+1)},max{l,SR(Su)2}.\min\{u,q(l)(q(l)+1)\},\qquad \max\{l,S-R(S-u)^2\}.

Proof. Apply Lemma 4.2 to A(s)=s(s+1)A(s)=s(s+1) and B(s)=s2B(s)=s^2, whose inverse capacities are qq and RR. It includes zero roots and singleton intervals; the two candidates need not be the original endpoints l,ul,u. The module RootConvolution verifies the exact attaining minimum with internally defined integer roots. ◻

Exact transfer through the affine middle

This second reduction preserves joint states and does not assume that optimal searches finish one cohort before starting the other. Set K=b2+1K=b^2+1, L=K+mL=K+m, U=EKU=E-K. Both profiles have constant surplus on every residual obtained by allocating at most mm inspections to a count in [L,U][L,U]. Track the initial cohorts, the first currently in color z{0,1}z\in\{0,1\}, and put Bz(t)=bt+(t+z)/2B_z(t)=bt+\left\lfloor(t+z)/2\right\rfloor.

Theorem 6.6 (Exact middle transfer). Assume mb+1m\ge b+1 and (a,d),(a,d)[L,U]2(a,d),(a',d')\in[L,U]^2. A tt-day full-budget trajectory remaining in this band joins the two states if and only if a+d=a+d+(2b+1m)t,0a+Bz(t)amt.a'+d'=a+d+(2b+1-m)t,\qquad 0\le a+B_z(t)-a'\le mt. The statement includes a construction of all daily allocations.

Proof. Write Sj=a+d+(2b+1m)jS_j=a+d+(2b+1-m)j. The attainable first counts at time jj form exactly the integer interval [max{L,SjU,a+Bz(j)mj},min{U,SjL,a+Bz(j)}].[\max\{L,S_j-U,a+B_z(j)-mj\}, \min\{U,S_j-L,a+B_z(j)\}]. For one step the first count changes by b+(z+jmod2)pb+(z+j\bmod2)-p, 0pm0\le p\le m. Taking the union over this integer interval and intersecting the two band constraints gives the displayed interval at j+1j+1: both alternating surpluses lie between zero and mm. The intervals are nonempty whenever 2LSj2U2L\le S_j\le2U; pairwise comparison of their three lower and upper bounds proves this directly. Since SjS_j is affine, the initial and final band conditions ensure these inequalities at every intermediate time. For a prescribed next count xx', choose the preceding count to be the larger of the current lower endpoint and xb(z+jmod2)x'-b-(z+j\bmod2). It lies in the current interval and gives an allocation between zero and mm. Backtracking constructs the trajectory. Necessity follows by summing its allocations. ◻

The Lean module MiddleIntervalTransfer verifies this interval statement, including constructive sufficiency. The identification of the band with physical rectangle profiles remains an ordinary proof. Replacing maximal interior excursions by these transfers gives an exact boundary graph with O((b2+m)E)O((b^2+m)E) retained states: retain states outside [L,U]2[L,U]^2 and a collar of width m+1m+1 inside its boundary. Every one-day entry or exit crosses that collar, and the theorem expands each added transfer back into legal moves. This reduction does not itself evaluate the remaining boundary optimization in closed form.

A bounded joint-state calculation for every odd rectangle

The one-day ambiguity in Theorem 6.1 can be resolved without exploring a state space that grows with the longer side. The reduction below retains the exceptional mixed histories. We then prove that, after an explicit width- and budget-dependent length threshold, the two solo endpoints alone decide the answer. The later Theorem 30.5 and Corollary 30.6 also establish scalar necessity at every length in their budget ranges. The shorter boards outside the proved ranges remain open.

Fix odd nw=2b+13n\ge w=2b+1\ge3 and a feasible budget mb+1m\ge b+1. Retain E=M+1E=M+1, the inverse profiles ιp\iota_p, and the solo deficits Dp(t)D_p(t). Define the following constants, depending only on w,mw,m: d=2mw1,H=b2+1,Γ=m1,K=H1+2m(Γ/w+1),W=Γ+K+1,J=2K+Γ+2m+H+2.\begin{gather} d=2m-w\ge1,\qquad H=b^2+1,\qquad \Gamma=m-1,\notag\\ K=H-1+2m\left(\left\lfloor\Gamma/w\right\rfloor+1\right),\qquad W=\Gamma+K+1,\notag\\ J=2K+\Gamma+2m+H+2. \end{gather}(26)

Theorem 7.1 (Exact evaluation with a length-independent state bound). The minimum capture time on PwPnP_w\mathbin{\square}P_n can be evaluated using at most F=2+2Γ(K+1)F=2+2\Gamma(K+1) retained joint states and at most 4J/d+W+84\left\lceil J/d\right\rceil+W+8 ordinary state updates, together with integer floor divisions and a final optimization over pairs of retained states. Each update considers at most m+1m+1 quota splits per state. All bounds are independent of nn. The calculation determines the exact choice between 2τ12\tau-1 and 2τ2\tau and gives a winning strategy through the compatible prefixes. The bit lengths of the arithmetic inputs still depend on logn\log n.

The endpoint cases are immediate: one day suffices exactly when mE+Mm\ge E+M, and Mm<E+MM\le m<E+M gives two days by inspecting one entire color and then the surviving other cohort. We therefore discuss m<Mm<M.

The exact central optimization

Write A(t)=maxDp(t)A(t)=\max D_p(t) and B(t)=minDp(t)B(t)=\min D_p(t). A deficit pair is exceptional at time t<τt<\tau if its total exceeds B(t)B(t). At each layer retain the two pure solo pairs (D0(t),0),(0,D1(t))(D_0(t),0),(0,D_1(t)) and the attainable exceptional mixed pairs, optionally discarding pairs dominated componentwise. Their exact transition, for quota pp in current color zero, is (x,y)(ι0(y+mp),ι1(x+p)),0pm. (x,y)\longmapsto \bigl(\iota_0(y+m-p),\iota_1(x+p)\bigr),\qquad0\le p\le m. (27) The noncapture bound (25) ensures the inputs are proper whenever the successor time is below τ\tau.

Lemma 7.2 (Discarding low-total mixed states). Iterating (27), retaining only the types just described, gives the exact minimum central inspection requirement CL=min(x,y),(u,v)RL((Exu)++(Myv)+),L=τ1. C_L=\min_{(x,y),(u,v)\in\mathcal R_L} \bigl(\left(E-x-u\right)_++\left(M-y-v\right)_+\bigr),\qquad L=\tau-1. (28) Here RL\mathcal R_L is the retained frontier. The answer is 2τ12\tau-1 exactly when CLmC_L\le m, and is 2τ2\tau otherwise.

Proof. First, a mixed exceptional successor cannot come from a pair whose total is at most B(t)B(t). Apply both inequalities of Lemma 6.2 to the common total input, at most B(t)+mB(t)+m. The second applies because a positive new minority deficit requires its inverse argument to be at least two. The resulting total is at most both next solo capacities. This is the persistence property used below.

By induction every attainable exceptional pair is dominated by a retained attainable pair: mixed exceptional successors have exceptional predecessors, and pure successors are dominated by the corresponding solo endpoint. The transition is monotone. Conversely every retained pair is attained by the exact prefix recurrence of Corollary 5.4. A discarded pair has total at most BB, while every other pair has total at most AA, by Lemma 6.3. Its capped union with any other pair is therefore at most A+B=D0+D1A+B=D_0+D_1, already attained by the two opposite solo endpoints. It cannot improve the central cut.

For completeness, cut a putative (2L+1)(2L+1)-day winning schedule at its central inspection. The first LL inspections and moves give a forward belief; the last LL, read backward along the undirected edges, give a reverse belief on that same day. Their intersection must be inspected. In color pp its size is at least the positive part of the color size minus the two deficits. Canonical domination and the preceding retention argument give the lower bound (28). Conversely realize one retained pair by prefixes and the other by reflecting both coordinates of its prefix construction. On an odd rectangle the reflection preserves colors and reverses their orders. The two beliefs therefore intersect in exactly the displayed positive parts. Inspect that intersection centrally and reverse the second half-schedule. This attains the bound whenever it is at most mm. The uniform one-day theorem gives the alternative 2τ2\tau. ◻

Lemma 7.3 (The ancestry of an exceptional state). Every retained exceptional mixed pair has a realization whose most recent pure ancestor belongs to the currently faster initial cohort. All such pairs at a fixed time therefore have the same primary ancestry. The secondary deficit means the coordinate of the other initial cohort; it need not a priori be the numerically smaller coordinate.

Proof. Replace every pure successor by its solo endpoint, and discard low-total mixed successors by Lemma 7.2. Label a mixed history by its most recent pure ancestor. A slower pure endpoint has total at most BB and cannot produce an exceptional mixed successor.

Suppose an exceptional source has primary physical color zero. Its total ss is at most D0(t)D_0(t). The second inverse concentration inequality bounds a mixed successor’s total by ι1(s+m)ι1(D0(t)+m)=D1(t+1)\iota_1(s+m)\le\iota_1(D_0(t)+m)=D_1(t+1). If the successor is exceptional, color one must consequently be strictly faster. With primary color one, the first concentration inequality instead bounds its total by D0(t+1)D_0(t+1), forcing color zero to be faster. The primary color flips in both cases, exactly as its initial cohort does under movement. Proper inputs hold before τ\tau; positive minority output supplies the extra hypothesis of the second concentration inequality. Persistence excludes low-total mixed predecessors. This proves the assertion inductively, including rebirth from a pure endpoint. At a solo tie no exceptional pair exists. ◻

Only bounded endpoint collars can be exceptional

Lemma 7.4 (Uniform collar bound). For t<τt<\tau, D0(t)D1(t)Γ|D_0(t)-D_1(t)|\le\Gamma. Every attainable exceptional mixed pair satisfies min(x,y)K\min(x,y)\le K.

Proof. The solo recurrence is monotone from its zero initial pair. Write its proper step as (a,c)=(ι0(c+m),ι1(a+m))(a',c')=(\iota_0(c+m),\iota_1(a+m)). Every input is at least m2m\ge2. The three deficit branches of ι0\iota_0 are all at least one, and those of ι1\iota_1 are all at least two. Thus ac+m1a'\le c+m-1 and ca+m2c'\le a+m-2. Since aaa'\ge a and ccc'\ge c, acm1,cam2.a'-c'\le m-1,\qquad c'-a'\le m-2. The initial tie satisfies the symmetric bound as well. This argument includes the final precapture layer; no full inverse endpoint is used.

Put s=x+ys=x+y. If x,yHx,y\ge H at a source layer with a precapture successor, the inverse inputs X,YX,Y satisfy X,YHX,Y\ge H and X+Y=s+mMX+Y=s+m\le M. These inequalities put every lower and reflected root argument beyond its corner: q(Y),q(MY)bq(Y),q(M-Y)\ge b, R(X)b+1R(X)\ge b+1, and 1+R(EX)b+11+R(E-X)\ge b+1. Thus ι0(Y)=Yb,ι1(X)=X(b+1),s=s+mw.\iota_0(Y)=Y-b,\qquad\iota_1(X)=X-(b+1),\qquad s'=s+m-w. Each solo capacity gains at least d=2mwd=2m-w over two proper steps, since its inverse deficit is at most bb or b+1b+1. Consequently two successive bulk source states give (As)(t+2)(As)(t)+w.(A-s)(t+2)\ge(A-s)(t)+w. An exceptional state has 0As<ABΓ0\le A-s<A-B\le\Gamma. A consecutive run of bulk exceptional states therefore has at most 2Γ/w+12\left\lfloor\Gamma/w\right\rfloor+1 transitions.

For a target exceptional mixed state, trace backward to the most recent state with smaller coordinate below HH; such a state exists at time zero. Every intervening bulk state is mixed and exceptional by the persistence property in Lemma 7.2. At entry its smaller coordinate is at most H1+mH-1+m. Each subsequent step increases the smaller coordinate by at most mm, because each proper inverse is at most its argument. The run-length bound gives precisely H1+2m(Γ/w+1)=KH-1+2m(\left\lfloor\Gamma/w\right\rfloor+1)=K. ◻

There are at most Γ\Gamma integer totals strictly between BB and AA including the upper endpoint. For each, at most 2(K+1)2(K+1) pairs have a coordinate at most KK. Adding the two pure endpoints proves the state bound FF in Theorem 7.1.

The long middle forgets its initial mixed histories

Call a layer safe when JD0,D1MJJ\le D_0,D_1\le M-J. These layers form an interval. At a safe layer encode a retained mixed pair by (j,k,)(j,k,\ell): jj is its larger coordinate’s color, kk its smaller deficit, and =Djdj\ell=D_j-d_j its loss relative to the solo capacity in that color. Then 0kK,0Γ+K.0\le k\le K,\qquad0\le\ell\le\Gamma+K. The primary coordinate is greater than KK, so its color is unambiguous. Define the bottom inverses h0(z)=zmin{q(z),b},h1(z)=zmin{R(z),b+1}.h_0(z)=z-\min\{q(z),b\},\qquad h_1(z)=z-\min\{R(z),b+1\}. If rr of the inspections are devoted to the smaller-deficit cohort, the exact normalized transition is (j,k,)(1j,hj(k+r),+r),0rm. (j,k,\ell)\longmapsto (1-j,h_j(k+r),\ell+r),\qquad0\le r\le m. (29) The primary input and the corresponding solo input lie in the same affine profile band; their difference therefore increases by rr. The smaller input is at most K+mK+m and uses only the bottom inverse. To check all margins explicitly, the primary input is between HH and MHM-H, its output remains greater than KK, and safety implies M2JM\ge2J, excluding the reflected branch for an input at most K+mK+m. The definition of JJ ensures these inequalities even on the last safe source step. If its successor remains mixed and exceptional, the collar lemma forces its smaller output to be at most KK.

The solo transition in this region is (D0,D1)=(D1+mb,D0+mb1),Dp(t+2)=Dp(t)+d.(D_0',D_1')=(D_1+m-b,D_0+m-b-1),\qquad D_p(t+2)=D_p(t)+d. Thus its color difference and the exceptional-state filter k<DjminDp\ell-k<D_j-\min D_p are periodic with period two. Moreover, whenever the smaller output is positive, hj(z)z1h_j(z)\le z-1, and (29) gives kk+1.\ell'-k'\ge\ell-k+1. At entry kK\ell-k\ge-K, whereas exceptionality requires k<Γ\ell-k<\Gamma. An initial mixed history cannot persist for Γ+K\Gamma+K safe transitions. Becoming pure resets its relevant history to the dominating solo endpoint; becoming low-total erases its future relevance until a pure state is reached. A new mixed history born from a solo endpoint starts from k==0k=\ell=0 and has bounded age by the same inequality. After W=Γ+K+1W=\Gamma+K+1 safe transitions, every relevant mixed history comes from a recent pure endpoint. Its rules, births and filters depend only on the two-day phase. Therefore the normalized retained frontier is exactly periodic with period two. Pareto pruning preserves this statement: dominance within a primary color depends only on (k,)(k,\ell), and opposite primary colors are incomparable.

Completion of Theorem 7.1. Iterate the retained recurrence until capture or until both solo capacities reach JJ. This takes at most 2J/d+12\left\lceil J/d\right\rceil+1 updates, because every proper pair of steps raises both capacities by at least dd. If a safe interval is entered at t0t_0, its last layer is explicit. For p=0,1p=0,1, let Ap=maxDj(t0+p)A_p=\max D_j(t_0+p); omit a parity with Ap>MJA_p>M-J. Its final safe layer is t0+p+2(MJAp)/d.t_0+p+2\left\lfloor(M-J-A_p)/d\right\rfloor. The larger of these is the last safe layer. Perform at most W+2W+2 updates in the safe interval. If it is longer, stabilization permits an even jump to its last matching parity: for each skipped pair, add dd to both solo capacities and to every retained primary coordinate, leaving smaller coordinates unchanged. Complete the at most one remaining safe transition normally.

After leaving the safe interval, some solo capacity exceeds MJM-J; that cohort has at most JJ rooms remaining, including the majority’s extra room. At most 2J/d+22\left\lceil J/d\right\rceil+2 further steps give capture. If the safe interval was empty when the lower threshold was reached, the same upper-collar bound applies. Stop one layer before the first solo capture and use (28). The generous displayed update bound covers the two collars, warm-up, and parity endpoints.

Every retained history is attainable. At an accelerated layer recover its bounded recent history from a pure solo endpoint, realize that endpoint by the solo prefix construction, and then follow the recorded quota suffix. The central-cut construction in Lemma 7.2, or the solo palindrome when the cut is too expensive, supplies the winning strategy. This proves both exact evaluation and construction without expanding the long affine middle one day at a time. ◻

This is an ordinary geometric and arithmetic proof. It uses the proved prefix reduction but has not been formalized as a complete Lean theorem.

An explicit onset for the scalar formula

Theorem 7.5 (Eventually only the solo endpoints matter). With the constants in (26), put M=2J+Γ+m(W+3).M_*=2J+\Gamma+m(W+3). For every odd nwn\ge w with M=(wn1)/2MM=(wn-1)/2\ge M_*, Tm(PwPn)={2τ1,E+MD0(τ1)D1(τ1)m,2τ,E+MD0(τ1)D1(τ1)>m. T_m(P_w\mathbin{\square}P_n)= \begin{cases} 2\tau-1,&E+M-D_0(\tau-1)-D_1(\tau-1)\le m,\\ 2\tau,&E+M-D_0(\tau-1)-D_1(\tau-1)>m. \end{cases} (30) Thus Proposition 6.4 evaluates the exact answer using O(b)O(b) scalar arithmetic stages; no joint-state optimization is needed.

Proof. The maximum solo deficit increases by at most mm per proper step, because each inverse is at most its argument. This concerns the maximum, not each fixed physical coordinate. At the first layer t0t_0 with both capacities at least JJ, their maximum is at most J+Γ+m1J+\Gamma+m-1. This layer precedes capture: a predecessor with smaller capacity below JJ has maximum at most J+Γ1J+\Gamma-1, and adding mm still leaves both inverse inputs below the full endpoint. Monotonicity and eventual capture ensure that t0t_0 exists. For 0sW+10\le s\le W+1 the maximum is at most J+Γ+m1+msMJJ+\Gamma+m-1+ms\le M-J, while the minimum remains at least JJ. Induction using the same proper-input bound excludes capture during these layers. There are therefore WW consecutive safe transitions.

The age argument above erases every mixed history present at safe entry. After WW transitions every retained mixed state has a pure ancestor within the safe interval. Its ancestry-primary is then the larger coordinate, greater than KK, and its ancestry-secondary is at most KK. This alignment is essential: Lemma 7.4 alone bounds only the numerical minimum.

The alignment persists through the final collar. Following an initial cohort across movement, a secondary deficit at most KK becomes at most K+mK+m, since this input is proper. If the new primary were at most KK, the total would be at most 2K+m<JB2K+m<J\le B, so the successor could not be exceptional. Thus an exceptional successor still has primary greater than KK; the numerical collar bound forces secondary at most KK again. A fresh mixed birth from a pure endpoint obeys the same argument, with secondary output at most mm. Pure states reset to solo endpoints, and persistence excludes revival of a discarded mixed history.

At the midpoint all exceptional states consequently share a primary ancestry by Lemma 7.3, and each has secondary at most KK. A pair of exceptional states leaves at least M2K>mM-2K>m rooms in the other color and cannot win centrally. If at least one state is nonexceptional, the two totals sum to at most A+B=D0+D1A+B=D_0+D_1; their central cost is at least E+MD0D1E+M-D_0-D_1. The two opposite solo endpoints attain precisely this latter cost. Lemma 7.2 now gives (30). ◻

The threshold is deliberately generous. Theorem 7.1 still gives an exact bounded calculation below it. Neither this theorem nor the ancestry lemma asserts serial optimality from arbitrary partial states. The all-length results at minimum budget and at mb2+1m\ge b^2+1 (Theorems 21.1 and 8.1) leave only intermediate budgets b+2mb2b+2\le m\le b^2 for the unrestricted scalar conjecture. The constants are nondecreasing in mm, and M(b,b2)=O(b5)M_*(b,b^2)=O(b^5). Hence any counterexample at a fixed width must have n=O(b4)n=O(b^4); this is a finite obstruction bound, not a claim that those remaining cases satisfy the scalar criterion.

Minimum total probes in the unbounded corner model

The next lemma isolates a second scalar reduction valid at every feasible budget. Its conclusion concerns the number of probes, not a fixed horizon in the full finite rectangle. For k>0k>0 define L0(k)=k+min{R(k),b},L1(k)=k+min{Q(k),b+1},Lp(0)=0.L_0(k)=k+\min\{R(k),b\},\qquad L_1(k)=k+\min\{Q(k),b+1\},\qquad L_p(0)=0. Their inverses are the bottom maps h0,h1h_0,h_1 above. Each is nondecreasing and 11-Lipschitz on the nonnegative integers, vanishes at zero, and has image all nonnegative integers.

Proposition 7.6 (Exact corner ammunition recurrence). Let μp(k)\mu_p(k) be the least total quota in an alternating growth sequence v=hp(v+r)v'=h_p(v+r), 0rm0\le r\le m, starting from zero in either phase and ending at least kk in color pp. The horizon is unrestricted. Then μp(0)=0\mu_p(0)=0, μp(k)k\mu_p(k)-k is nondecreasing, exact targets are attainable, and μp(k)=min{m,Lp(k)}+μ1p((Lp(k)m)+). \mu_p(k)=\min\{m,L_p(k)\} +\mu_{1-p}\bigl(\left(L_p(k)-m\right)_+\bigr). (31) Every two positive recursive calls strictly decrease their argument. The minimum growth time is μp(k)/m\left\lceil\mu_p(k)/m\right\rceil. At any prescribed horizon tt, the target is feasible exactly when μp(k)mt\mu_p(k)\le mt; its minimum ammunition then remains μp(k)\mu_p(k). The initial zero phase is free here. With a fixed initial phase, the horizon and final phase must have the corresponding cyclic compatibility. For inspection-before-movement clearing with profiles LpL_p, the minimum total quota is Fp(k)={k,km,m+μp(km),k>m,Fp(k)=m+F1p(Lp(km))(k>m).F_p(k)= \begin{cases}k,&k\le m,\\m+\mu_p(k-m),&k>m,\end{cases} \qquad F_p(k)=m+F_{1-p}(L_p(k-m))\quad(k>m). Thus greedy full quotas minimize total probes in this unbounded model.

Proof. Feasibility follows since h0(z+m)z+1h_0(z+m)\ge z+1 and h1(z+m)zh_1(z+m)\ge z. In a fixed growth schedule, deleting one probe changes the final output by at most one, by monotonicity and the Lipschitz bound. Deleting probes from an optimal schedule until its output first hits <k\ell<k removes at least kk-\ell probes. The remaining cost is at least μp()\mu_p(\ell), proving monotone excess; the same deletion argument gives optimal schedules with exact output.

Put z=Lp(k)z=L_p(k), the least input with hp(z)kh_p(z)\ge k. A last-step predecessor must be at least v0=(zm)+v_0=\left(z-m\right)_+. For v0vzv_0\le v\le z, monotone excess gives μ1p(v)+zvμ1p(v0)+min{m,z}.\mu_{1-p}(v)+z-v\ge\mu_{1-p}(v_0)+\min\{m,z\}. For vzv\ge z the same bound follows from monotonicity of the excess. Attain v0v_0 optimally and use quota min(m,z)\min(m,z); since hp(z)=kh_p(z)=k, equality is attained. This proves (31). Its predecessor is strictly smaller than kk in color zero and at most kk in color one, so two calls strictly descend.

Every nonterminal positive call contributes mm and the terminal one contributes an integer from one to mm. Reading backward gives one possibly partial first quota followed by full quotas, in exactly μp(k)/m\left\lceil\mu_p(k)/m\right\rceil steps. A tt-step schedule spends at most mtmt, proving the horizon lower bound. When tt is larger, prepend zero steps: all maps fix zero, and choosing the initial phase to end in pp aligns the optimal block correctly. For a fixed initial phase this requires the stated compatibility. Padding at the end of a positive block is not used. In particular, Dpbottom(t)=max{k:μp(k)mt}.D_p^{\mathrm{bottom}}(t)=\max\{k:\mu_p(k)\le mt\}.

Finally the inverse threshold identity, applied backward through the nonterminal moves of a clearing schedule, gives Fp(k)=min0rmin(m,k)(r+μp(kr)).F_p(k)=\min_{0\le r\le\min(m,k)} \bigl(r+\mu_p(k-r)\bigr). Monotone excess makes the largest allowed first quota optimal, giving the displayed formula. A full first quota followed by the optimal continuation gives the equivalent clearing recurrence. ◻

Remark 7.7 (Cyclic growth controls). The proof requires no special root identities. Let the phases form any nonempty finite cycle, let m1m\ge1, and let each hp:NNh_p:\mathbb{N}\to\mathbb{N} be nondecreasing and onto. These assumptions imply hp(0)=0h_p(0)=0 and increments in {0,1}\{0,1\}. With least-input inverse LpL_p, a target (p,k)(p,k) is feasible exactly when the reverse threshold orbit (p,k)(p1,(Lp(k)m)+)(p,k)\longmapsto(p-1,\left(L_p(k)-m\right)_+) reaches zero. Necessity follows by propagating required predecessors backward through any actual schedule; sufficiency assigns the least predecessor and quota min(m,Lp(k))\min(m,L_p(k)) at each reverse step. For feasible targets the same deletion and last-step proof gives (31), with phase subtraction taken cyclically, and the same exact cost and horizon conclusions. Intermediate reverse targets may increase; termination, rather than per-step decrease, is the essential condition. The bottom root maps supply a simple terminating instance. With a fixed initial phase aa, the prescribed-horizon assertion requires a+t=pa+t=p in the phase cycle.

This proposition omits the reflected end branches by definition. It does not by itself justify allocating full quotas serially in the two-cohort rectangle problem. The following conditional exchange states precisely where it does apply to the finite board.

Lemma 7.8 (Suffix exchange beyond the primary lower corner). Consider a legal history up to t<τt<\tau, with a pure solo endpoint for an initial cohort AA at time iti\le t. Suppose that every subsequent inverse input of AA is at least H=b2+1H=b^2+1. Its final deficit pair is componentwise dominated by a history of the same length consisting of full quotas on AA, one possibly shared quota, then full quotas on the opposite initial cohort BB. Empty and pure-block degenerations are allowed.

Proof. On proper inputs zHz\ge H, the lower root in IpI_p has reached its cap and the reflected root is nonincreasing. Hence Ip(z)zI_p(z)-z is nondecreasing, so Ip(v)Ip(u)vu(vuH).I_p(v)-I_p(u)\ge v-u\qquad(v\ge u\ge H). Before τ\tau, the two input deficits sum to at most MM. Thus every old BB input is at most MHM-H, where the finite inverse agrees with the bottom map. Let r=tir=t-i, let kk be the final BB deficit, and let pp be its final physical color. The cases r=0r=0 and k=0k=0 are immediate. Otherwise write μ=μp(k)\mu=\mu_p(k) and let QμQ\ge\mu be the old total quota on BB. Pack the exact minimum-ammunition block as late as possible in the same rr steps: zeros, one partial quota, then full quotas. Its cumulative quota at step ss is (μm(rs))+\left(\mu-m(r-s)\right)_+. The old cumulative quota is at least (Qm(rs))+\left(Q-m(r-s)\right)_+, and hence at least the new one.

Assign the complementary quota to AA. If Δs0\Delta_s\ge0 is its cumulative new-minus-old quota, induction gives new-minus-old primary deficit at least Δs\Delta_s: the next input difference is at least Δs+1\Delta_{s+1}, and the displayed expansion preserves this inequality. Both histories are legal from the full board, so coordinatewise solo domination and t<τt<\tau keep every new input proper independently of the induction.

The packed BB block has nondecreasing inputs, because after its first partial quota it uses mb+1m\ge b+1 at every step. Its final input is Lp(k)L_p(k), no greater than the old final input and hence at most MHM-H. Every new BB input therefore remains in the bottom range, and the finite-board output is exactly kk. Beginning padding preserves the initial cohort: total length and final physical color are fixed. Thus AA improves and BB is unchanged. Before the packed block the new history simply extends the original pure solo trajectory, giving the asserted two-block form. ◻

The lower-corner hypothesis is essential to this proof. No analogous exchange, or unrestricted scalar midpoint criterion, is asserted for histories entering that corner. The generic concentration, ancestry and midpoint implications have a Lean development with their inverse and secondary-bound hypotheses explicit; the physical corner-clock and safe-interval instantiations here and the conditional exchange remain ordinary proofs.

Explicit formulas at large budgets on every odd rectangle

The exact recurrence of Corollary 5.4 admits a closed solution in a uniform budget range, with no restriction on the length. Let w=2b+13,nw odd,N=wn=2h+1,B=b2.w=2b+1\ge3,\qquad n\ge w\text{ odd},\qquad N=wn=2h+1,\qquad B=b^2. The majority and minority classes have sizes K0=h+1K_0=h+1 and K1=hK_1=h. All neighborhood profiles and prefixes below are those of Theorem 5.1.

Define L0(0)=L1(0)=0L_0(0)=L_1(0)=0 and, for k>0k>0, L0(k)=k+min{R(k),b},L1(k)=k+min{Q(k),b+1}. L_0(k)=k+\min\{R(k),b\},\qquad L_1(k)=k+\min\{Q(k),b+1\}. (32) These are the corner profiles before the far boundary clips a neighborhood. In particular gz(k)Lz(k)g_z(k)\le L_z(k). For r>0r>0 put J(r)={L1(r/2),r even,L0((r+1)/2),r odd,δ(r)={L0(r/2+1)L1(r/2),r even,L1((r+1)/2)L0((r+1)/2),r odd.\begin{aligned} J(r)&= \begin{cases} L_1(r/2),&r\text{ even},\\ L_0((r+1)/2),&r\text{ odd}, \end{cases}\\ \delta(r)&= \begin{cases} L_0(r/2+1)-L_1(r/2),&r\text{ even},\\ L_1((r+1)/2)-L_0((r+1)/2),&r\text{ odd}. \end{cases} \end{aligned}(33, 34) Set J(0)=δ(0)=0J(0)=\delta(0)=0. The two corner profiles interlace, so δ(r){0,1}\delta(r)\in\{0,1\}. These explicit square-root functions describe the small set left by the first sweep and the inspection cost for starting the second sweep on the same day.

Theorem 8.1 (All odd rectangles above a quadratic budget). Suppose mb2+1m\ge b^2+1. If mNm\ge N, then Tm(PwPn)=1T_m(P_w\mathbin{\square}P_n)=1; if hm<Nh\le m<N, then Tm(PwPn)=2T_m(P_w\mathbin{\square}P_n)=2. For m<hm<h, write D=2mw,Nw1=qD+r,0r<D.D=2m-w,\qquad N-w-1=qD+r,\qquad 0\le r<D. Then Tm(PwPn)={2q,r=0,2q+1,r>0 and 2J(r)+δ(r)m,2q+2,r>0 and 2J(r)+δ(r)>m. T_m(P_w\mathbin{\square}P_n)= \begin{cases} 2q,&r=0,\\ 2q+1,&r>0\text{ and }2J(r)+\delta(r)\le m,\\ 2q+2,&r>0\text{ and }2J(r)+\delta(r)>m. \end{cases} (35) The constructions use two prefix sweeps, with at most one shared day. The lower bound applies to arbitrary inspection schedules.

Corollary 8.2 (A formula using only integer division). For m2b2+1m\ge2b^2+1 and m<hm<h, put cm=mw1+1{m=2b2+1}c_m=m-w-1+\mathbf{1}_{\{m=2b^2+1\}}. With the same q,rq,r, Tm(PwPn)={2q,r=0,2q+1,1rcm,2q+2,r>cm.T_m(P_w\mathbin{\square}P_n)= \begin{cases} 2q,&r=0,\\ 2q+1,&1\le r\le c_m,\\ 2q+2,&r>c_m. \end{cases}

An inspection potential and a solved partial-state recurrence

Write ρz(k)=Lz(k)k\rho_z(k)=L_z(k)-k, with ρz(0)=0\rho_z(0)=0. For k>0k>0, 0L0(k+1)L1(k)1,0L1(k)L0(k)1.0\le L_0(k+1)-L_1(k)\le1,\qquad 0\le L_1(k)-L_0(k)\le1. Both LzL_z and their surpluses ρz\rho_z are nondecreasing. Thus JJ is nondecreasing, J(r+2)J(r)+1J(r+2)\ge J(r)+1, and J(1)=2J(1)=2. Throughout the proof we assume mB+1m\ge B+1. Then D>0D>0 and J(D)=mJ(D)=m.

Assign a nonempty parity-zz count kk the rank u=2k+zu=2k+z. Define F(u)={u/2,u/2m,am+J(s),uw1=aD+s,0s<D,u/2>m. F(u)= \begin{cases} \left\lfloor u/2\right\rfloor,&\left\lfloor u/2\right\rfloor\le m,\\ am+J(s),&u-w-1=aD+s,\quad0\le s<D, \quad\left\lfloor u/2\right\rfloor>m. \end{cases} (36) In particular F(0)=F(1)=0F(0)=F(1)=0. Empty supports always have potential zero. The function measures a lower bound on the total number of inspections still required against one cohort.

Lemma 8.3 (Interior inequality and its equality cases). The function FF is nondecreasing, F(u)u/2F(u)\ge\left\lfloor u/2\right\rfloor, and F(u+2)F(u)+1F(u+2)\ge F(u)+1. For 0pm0\le p\le m, F(2k+z)p+F(2Lz((kp)+)+1z). F(2k+z)\le p+F\bigl(2L_z(\left(k-p\right)_+)+1-z\bigr). (37) Put j(u)=(uw2)+/Dj(u)=\left\lfloor\left(u-w-2\right)_+/D\right\rfloor. Every noncapture equality in (37) lowers jj by exactly one. A capture has source quotient zero.

Proof. For j1j\ge1, use the positive-remainder convention u=w+1+jD+su=w+1+jD+s, 1sD1\le s\le D. Then F(u)=jm+J(s)=u+jw2ϵ(s),0ϵ(s)=s+w+12J(s)b1.F(u)=jm+J(s)=\left\lfloor\frac{u+jw}{2}\right\rfloor-\epsilon(s),\qquad 0\le\epsilon(s)=\left\lfloor\frac{s+w+1}{2}\right\rfloor-J(s)\le b-1. At j=0j=0, F(u)=u/2F(u)=\left\lfloor u/2\right\rfloor, without a correction. These formulas prove the stated monotonicity properties, including the period boundaries. A capturable source has potential kk. Every nonempty survivor has Lz(kp)>kpL_z(k-p)>k-p, so a noncapture transition from kmk\le m is strict.

Suppose k>mk>m and put s=kp>0s=k-p>0. On the plateau of LzL_z, the next rank is v=u2p+wv=u-2p+w. If pbp\le b, then vu+1v\ge u+1: monotonicity makes the inequality strict for p>0p>0, while p=0p=0 is strict because vu+2v\ge u+2. If p>bp>b, the quotient cannot increase and decreases by at most one. When it stays unchanged, the floor term, after including the pp inspections, increases by at least bb; the correction can save at most b1b-1. When the quotient falls once, its positive remainders obey t=s+2(mp)t=s+2(m-p), with s,ts,t now denoting those remainders. Hence J(t)J(s)mpJ(t)-J(s)\ge m-p, as required. A target of quotient zero has its actual cardinality as potential, at least the corresponding J(t)J(t).

Off the plateau, the survivor size is at most b(b1)b(b-1) in phase one or (b1)2(b-1)^2 in phase zero. Its next count is at most B<mB<m. Since m>Bm>B, the noncapturable source has quotient exactly one. Write a=km>0a=k-m>0 and e=mpe=m-p, so the survivor size is a+ea+e. Substitution gives F(2k+z)=m+Lz(a)F(2k+z)=m+L_z(a), and Lz(a+e)Lz(a)eL_z(a+e)-L_z(a)\ge e proves the inequality. This step goes from quotient one to zero. Finally a capture source has kpmk\le p\le m, hence quotient zero. ◻

Lemma 8.4 (Full-budget capacity). Using the unbounded profiles LzL_z, the largest starting count in phase zz that clears in t1t\ge1 consecutive mm-inspection days is Az(t)=tD+w+1z2.A_z(t)=\left\lfloor\frac{tD+w+1-z}{2}\right\rfloor. In particular an actual finite-board prefix of rank at most tD+w+1tD+w+1 clears in tt such days.

Proof. All queried capacities are at least mB+1m\ge B+1, beyond the last nonplateau output. The inverse of LzL_z there is subtraction by b+zb+z. Thus Az(1)=mA_z(1)=m and Az(t+1)=m+A1z(t)(b+z)A_z(t+1)=m+A_{1-z}(t)-(b+z). The displayed formula solves these two affine recurrences. Finite-board neighborhoods are no larger, and compatible prefixes realize every step. ◻

A finite correction for the far corner

For a count kk in phase zz, let d=Kzkd=K_z-k be its deficit from a full cohort. For a noncapture step with pp useful inspections, write d=K1zgz(kp)d'=K_{1-z}-g_z(k-p). The profiles imply dd+p. d'\le d+p. (38) For majority survivors this uses g0(s)s1g_0(s)\ge s-1; for nonempty minority survivors it uses the strict Hall bound g1(s)s+1g_1(s)\ge s+1. The inequality need not hold at capture, which will be treated separately. If gz(s)Lz(s)g_z(s)\ne L_z(s), the survivor deficit x=Kzs=d+px=K_z-s=d+p is at most BB. Define the finite constant C=minz{0,1}0xB[x+F(2gz(Kzx)+1z)] C=\min_{\substack{z\in\{0,1\}\\0\le x\le B}} \left[x+F\bigl(2g_z(K_z-x)+1-z\bigr)\right] (39) and the monotone potential Φz(k)=min{F(2k+z),(CKz+k)+},Φz(0)=0. \Phi_z(k)=\min\{F(2k+z),\left(C-K_z+k\right)_+\},\qquad \Phi_z(0)=0. (40) All sets in (39) are nonempty because nwn\ge w. The x=0x=0 cases give CF(N),F(N+1)C\le F(N),F(N+1).

Lemma 8.5 (Boundary envelope). For every exact-profile transition, Φz(k)p+Φ1z(gz((kp)+)).\Phi_z(k)\le p+\Phi_{1-z}(g_z(\left(k-p\right)_+)). Consequently Tm(PwPn)2C/mT_m(P_w\mathbin{\square}P_n)\ge\left\lceil 2C/m\right\rceil.

Proof. For a noncapture step, (38) gives the inequality against the target’s linear branch. If the far corner does not clip, Lemma 8.3 gives the inequality against its FF branch. Otherwise x=d+pBx=d+p\le B, and the defining minimum gives Cdp+F(next rank)C-d\le p+F(\text{next rank}). Thus the source is at most pp plus each target branch. At capture, kpmk\le p\le m and Φz(k)F(2k+z)=kp\Phi_z(k)\le F(2k+z)=k\le p. Both initial potentials equal CC and both terminal potentials are zero. Summing over the two cohorts gives the bound. Monotonicity of Φ\Phi and the isoperimetric lower bounds give the same comparison for arbitrary physical supports; no special shape of an uncompressed belief is assumed. ◻

Lemma 8.6 (Corner correction). For mB+1m\ge B+1 and m<hm<h, F(N)1CF(N).F(N)-1\le C\le F(N). For mB+bm\ge B+b, the stronger equality C=F(N)C=F(N) holds.

Proof. For x>0x>0, the two full-cohort departures in (39) have next ranks NdE(x),dE(x)=2(xR(x));NdO(x),dO(x)=2(xQ(x))+1.N-d_E(x),\quad d_E(x)=2(x-R(x));\qquad N-d_O(x),\quad d_O(x)=2(x-Q(x))+1. For xBx\le B, the high-end term in the finite profile indeed gives these expressions. A negative gain, possible at x=1x=1 in the minority case, is harmless by monotonicity. Every nonnegative gain is at most 2B2b<D2B-2b<D, so at most one quotient boundary is crossed.

Without a quotient crossing, the potential drop is at most xx. One can use the strict inequalities proved below in (43) when the target remainder is positive. If that remainder is zero, direct substitution gives J(dE(x))xJ(d_E(x))\le x and J(dO(x))xJ(d_O(x))\le x instead.

It remains to bound a crossing. Put a=R(x)a=R(x) for an EE departure, a=Q(x)a=Q(x) for an OO departure, and d=bad=b-a. Let Δ\Delta be F(N)F(N) minus the departure cost. The following table writes its periodic endpoint expression; using the actual cardinality branch of FF can only decrease Δ\Delta. Here the source remainder is 2k2k or 2k+12k+1.

Case Target argument \ell cc Δ\Delta
EE, even mbx+a+km-b-x+a+k ρ1(k)\rho_1(k) d+cρ0()d+c-\rho_0(\ell)
EE, odd mbx+a+km-b-x+a+k ρ0(k+1)\rho_0(k+1) d+1+cρ1()d+1+c-\rho_1(\ell)
OO, even mbx+a+k1m-b-x+a+k-1 ρ1(k)\rho_1(k) d+1+cρ1()d+1+c-\rho_1(\ell)
OO, odd mbx+a+km-b-x+a+k ρ0(k+1)\rho_0(k+1) d+1+cρ0()d+1+c-\rho_0(\ell)

All target arguments are positive. Suppose first that c>0c>0. If Δ2\Delta\ge2, its bound on the target surplus is below that surplus’s plateau, so the defining square or consecutive-product inequality applies without clipping. Substitute xa2x\le a^2 for EE and xa(a1)x\le a(a-1) for OO, together with k(c1)(c2)+1k\ge(c-1)(c-2)+1 in an even-source row and k(c1)2k\ge(c-1)^2 in an odd-source row. Write v=2d(ca)v=2d(c-a) and I=1{a=b+1}I=\mathbf{1}_{\{a=b+1\}}. Rearrangement gives the bounds in the middle column below. Assuming only Δ1\Delta\ge1 increases the allowed target root by one and gives the last column.

Case Upper bound on mBm-B if Δ2\Delta\ge2 Upper bound if Δ1\Delta\ge1
EE, even v3dc+1v-3d-c+1 vd+c2v-d+c-2
EE, odd v2dc+1v-2d-c+1 v+c1v+c-1
OO, even vdbbIv-d-b-bI v+d+2cb2bIv+d+2c-b-2-bI
OO, odd vbbIv-b-bI v+2d+2cb1bIv+2d+2c-b-1-bI

The indicator comes from xBx\le B, which improves xa(a1)x\le a(a-1) by bb when a=b+1a=b+1.

For EE we have d0d\ge0 and cabc\le a\le b, with c2c\ge2 in the even row. The middle-column bounds are nonpositive; the last-column bounds are at most b2b-2 and b1b-1. For OO with aba\le b, the same conclusions hold, with last-column bounds at most b2b-2 and b3b-3; the odd row has ca1c\le a-1. For a=b+1a=b+1, the middle-column bounds become 32c3-2c and 22c2-2c, and the last-column bounds both become 1-1. Thus Δ2\Delta\ge2 contradicts mB+1m\ge B+1, while Δ1\Delta\ge1 contradicts mB+bm\ge B+b.

If c=0c=0, only even-source rows occur, with k=0k=0. The assumption Δ2\Delta\ge2 forces d3d\ge3 and gives, respectively, mB2ad3d+4m-B\le-2ad-3d+4 and mB2addb+3m-B\le-2ad-d-b+3, both nonpositive. The assumption Δ1\Delta\ge1 forces d2d\ge2 and gives mB2add+1m-B\le-2ad-d+1 and mB2ad+db+1m-B\le-2ad+d-b+1, both below bb. This completes both lower bounds on CC. The x=0x=0 majority departure always supplies the upper bound CF(N)C\le F(N). ◻

The attaining sweeps

The upper construction works throughout mB+1m\ge B+1. Suppose m<hm<h. Start with the minority cohort. Every noncapture full-budget shot decreases its rank by at least DD. If r=0r=0, its rank is qD+w+1qD+w+1, so Lemma 8.4 clears it in qq days. Here qq is odd, since Nw1N-w-1 and DD are odd. The other untouched cohort is therefore also minority when its qq-day sweep starts.

If r>0r>0, after q1q-1 full shots the first rank is at most 2m+r+12m+r+1. Its next shot leaves at most J(r)J(r) rooms: the last survivor has phase one and size at most r/2r/2 for even rr, or phase zero and size at most (r+1)/2(r+1)/2 for odd rr. Clear those rooms on day q+1q+1.

On the same day, the other cohort is minority for even rr and majority for odd rr. To put its next rank at most qD+w+1qD+w+1, create a deficit of r/2+1r/2+1 majority rooms in the even case, or (r+1)/2(r+1)/2 minority rooms in the odd case. Inspecting the neighbors of a terminal corner prefix achieves this at costs, respectively, L0(r/2+1)=J(r)+δ(r),L1((r+1)/2)=J(r)+δ(r).L_0(r/2+1)=J(r)+\delta(r),\qquad L_1((r+1)/2)=J(r)+\delta(r). These neighborhoods are terminal prefixes too; the remaining initial prefix is a compatible next belief. The next qq full shots suffice by Lemma 8.4. Thus a shared day works precisely at the stated sufficient budget 2J(r)+δ(r)m2J(r)+\delta(r)\le m. Otherwise either full phase has rank at most (q+1)D+w+1(q+1)D+w+1, because r+1Dr+1\le D, and two (q+1)(q+1)-day sweeps give the other upper bound. Early capture during a sweep only reduces its actual inspection costs.

For mNm\ge N one inspection of the entire board suffices. For hm<Nh\le m<N, inspect the minority class on day one; after movement the other cohort occupies at most the hh minority rooms and clears on day two. One day is impossible when m<Nm<N.

The equality case and the missing shared-day inspection

For mB+bm\ge B+b, Lemmas 8.5 and 8.6 give the lower bound 2F(N)/m\left\lceil 2F(N)/m\right\rceil. It matches the construction except when 2J(r)=m,δ(r)=1. 2J(r)=m,\qquad\delta(r)=1. (41) We now rule out 2q+12q+1 days in this case. Assume first b2b\ge2. Then m>Bm>B, r2r\ge2, r<Dr<D, and C=qm+m/2C=qm+m/2. Moreover F(N+1)=C+1,Ch=(q1)w+mr22. F(N+1)=C+1,\qquad C-h=\frac{(q-1)w+m-r}{2}\ge2. (42) For the latter inequality, mr4m-r\ge4 for even rr and mr3m-r\ge3 for odd rr. Every linear branch of Φ\Phi is consequently positive on nonempty supports; its zero cutoff cannot introduce a false equality.

We first record the strict inequalities used when a full-cohort corner departure leaves the same positive quotient. For x>0x>0, put a=R(x)a=R(x) in the first two rows and a=Q(x)a=Q(x) in the last two. For positive displayed arguments and xBx\le B, x+L1(kx+a)>L1(k),E, r=2k,x+L0(kx+a)>L0(k),E, r=2k1,x+L0(kx+a)>L1(k),O, r=2k,x+L1(kx+a1)>L0(k),O, r=2k1.\begin{aligned} x+L_1(k-x+a)&>L_1(k),& &E,\ r=2k,\nonumber\\ x+L_0(k-x+a)&>L_0(k),& &E,\ r=2k-1,\nonumber\\ x+L_0(k-x+a)&>L_1(k),& &O,\ r=2k,\\ x+L_1(k-x+a-1)&>L_0(k),& &O,\ r=2k-1.\nonumber \end{aligned}(43) Here EE and OO indicate the phase of the full cohort, while the source potential is qm+J(r)qm+J(r) in both cases.

To verify these inequalities, write cc for the source surplus. In the first row, the cost difference is a+ρ1(target)ca+\rho_1(\text{target})-c. It is positive if ac1a\ge c-1. Otherwise the bounds k(c1)(c2)+1k\ge(c-1)(c-2)+1 and xa2x\le a^2 place the target above (ca)(ca1)(c-a)(c-a-1): their difference is at least 2c(a1)2a2+3>02c(a-1)-2a^2+3>0. Its surplus is therefore at least ca+1c-a+1. For the second row, only a<ca<c needs checking; the target exceeds (ca)2(c-a)^2 by at least 2c(a1)2a2+a+2>02c(a-1)-2a^2+a+2>0. For the third row, use a2a\ge2, xa(a1)x\le a(a-1), and k(c1)(c2)+1k\ge(c-1)(c-2)+1; when a<ca<c, the target exceeds (ca)2(c-a)^2 by at least (2a3)c2a2+2a+3>0(2a-3)c-2a^2+2a+3>0. For the last row, its cost difference is a1+ρ1(target)ca-1+\rho_1(\text{target})-c. When a<ca<c, the target exceeds (ca+1)(ca)(c-a+1)(c-a) by at least (2a3)c2a2+3a+1>0(2a-3)c-2a^2+3a+1>0. The required surpluses are all at most their plateau caps. The remaining cases follow from the minimum positive surpluses one and two. This proves (43).

Suppose now that a strategy captured in 2q+12q+1 days. Its available inspections total 2C2C, so every step must be tight in the envelope inequality and every day must use all mm useful inspections. A positive full departure has d<pd'<p. A proper nonempty source has d<d+pd'<d+p on every noncapture step: its majority survivors have surplus at least zero, and its minority survivors have surplus at least two. Together with (42), these facts make a target linear branch strictly inefficient. Every tight target after departure therefore uses FF, and its potential remains below CC.

A positive full departure lowers jj exactly once. For pBp\le B its rank gain is less than DD, and (43) excludes no drop. For p>Bp>B there is no corner clipping: a majority departure is strict because its initial FF value is C+1C+1, while a tight minority departure has one drop by Lemma 8.3.

Consider a later clipped step, with proper-source deficit dd and x=d+pBx=d+p\le B. Its output equals that of a full-cohort xx-inspection departure. Its source quotient is either qq or q1q-1, since D2B1D\ge2B-1 and r2r\ge2. If both source and target quotients equal qq, the strict corner inequalities give p+F(target)>CdΦ(source)p+F(\text{target})>C-d\ge\Phi(\text{source}). If the source quotient is q1q-1, then F(source)<Cd. F(\text{source})<C-d. (44) For completeness, when r=2sr=2s put α=ρ1(s)\alpha=\rho_1(s), so m/2=s+αm/2=s+\alpha; when r=2s1r=2s-1 put α=ρ0(s)\alpha=\rho_0(s), so again m/2=s+αm/2=s+\alpha. Substitution in FF bounds CdF(source)C-d-F(\text{source}) below by α1,α,α,α\alpha-1,\alpha,\alpha,\alpha for EE/even, OO/even, EE/odd, OO/odd, respectively. All are positive. At q=1q=1 the source quotient is zero and only even rr occurs; its cardinality potential gives exactly α1\alpha-1 and α\alpha. Thus (44) includes this endpoint. The full-corner lower bound gives x+F(target)Cx+F(\text{target})\ge C, making this proper transition strict too.

Consequently every tight clipped step goes from qq to q1q-1. Every other tight noncapture step has a single quotient drop by Lemma 8.3, and capture starts at quotient zero. Each cohort therefore has exactly q+1q+1 consecutive active days, from its first positive allocation through capture. Two such intervals covering the 2q+12q+1-day horizon start on days 00 and qq and overlap once. The first day spends all mm on its only active cohort, which must be minority: a full-majority mm-inspection departure is unclipped and strict. The first cohort spends qmqm before the shared day and therefore needs exactly Cqm=m/2C-qm=m/2 inspections on that final day.

For even r=2sr=2s, the other cohort is minority on the shared day. Its necessary quotient drop requires at least s+1s+1 majority rooms to be absent from the next belief. All neighbors of those absent rooms must be inspected, requiring at least g0(s+1)=L0(s+1)=J(r)+δ(r)=m/2+1g_0(s+1)=L_0(s+1)=J(r)+\delta(r)=m/2+1 inspections. For odd r=2s1r=2s-1, the other cohort is majority and the same argument uses ss absent minority rooms and g1(s)=L1(s)=m/2+1g_1(s)=L_1(s)=m/2+1. These profiles equal LzL_z: the complementary deficits of the absent sets are at least m>Bm>B, using q1q\ge1 and the parity of qq (for odd rr, qq is even and at least two). Thus the shared day needs more than mm inspections, a contradiction.

For b=1b=1, the case m=2m=2 has D=1D=1 and r=0r=0, and follows directly from C=F(N)C=F(N) and the solo construction. At m3m\ge3 the same equality argument applies; a critical remainder has m4m\ge4, r=m31r=m-3\ge1, and the clipped proper-source cases are immediate since B=1B=1: only a majority survivor of deficit one can clip, and its neighborhood is the full minority class, of potential CC. Such a return to full is impossible after a tight departure. This proves the formula for every mB+bm\ge B+b.

The full range mB+1m\ge B+1: a one-unit slack argument

It remains to add B+1m<B+bB+1\le m<B+b. For b=1b=1 this interval is empty. For b=2b=2 its only budget is m=5m=5: then q=n2q=n-2, r=4r=4, and J(4)=4J(4)=4. The corner-correction lemma gives C5q+3C\ge5q+3, so the initial potential 2C10q+62C\ge10q+6 exceeds the 10q+510q+5 inspections available in 2q+12q+1 days. The two sweeps above attain 2q+22q+2 days. This proves that endpoint directly, without using a separate five-row classification. Henceforth assume b3b\ge3. The minimum square size and D2B3D\le2B-3 give q2q\ge2. Put η=F(N)C{0,1}\eta=F(N)-C\in\{0,1\}. At r=0r=0, the c=0c=0 positive-discount bounds in the proof of Lemma 8.6 are nonpositive, so η=0\eta=0 and the lower time is 2q2q.

A positive corner discount necessarily has δ(r)=0\delta(r)=0. To see this, suppose δ(r)=1\delta(r)=1. In an even-remainder row of the corner table, c=ρ1(k)=ρ0(k+1)c=\rho_1(k)=\rho_0(k+1), so k(c1)2k\ge(c-1)^2, improving the earlier lower bound by c2c-2. In an odd-remainder row, ρ1(k+1)=c+1\rho_1(k+1)=c+1, so kc(c1)k\ge c(c-1), an improvement by c1c-1. The four upper bounds on mBm-B for a positive discount become vd,v,v+ca,v+2d+cb,v=2d(ca).v-d,\qquad v,\qquad v+c-a,\qquad v+2d+c-b, \quad v=2d(c-a). The first three are nonpositive since d0d\ge0 and cac\le a. The last is at most d1-d-1, since ca1c\le a-1. The exceptional last minority band a=b+1a=b+1 already has upper bound 1-1 before this improvement. Thus a discount contradicts m>Bm>B when δ=1\delta=1.

For r>0r>0, Lemma 8.6 gives Cqm+1C\ge qm+1. The lower time is at least 2q+12q+1, so only a proposed upper of 2q+22q+2 needs attention. Its unresolved cases are precisely η2J(r)mδ(r)A001B110C120.\begin{array}{c|ccc} &\eta&2J(r)-m&\delta(r)\\\hline A&0&0&1\\ B&1&1&0\\ C&1&2&0. \end{array} We exclude 2q+12q+1 days in all three cases.

Exact counters and tight proper tails.

By Corollary 5.4, it suffices to study exact profile counters. More explicitly, retain any alleged physical strategy’s useful allocations and evolve the minimum-profile counters, capping allocations if the smaller counter has already been reached. Monotonicity keeps these counters below the actual cardinalities, and compatible prefixes attain them with no greater daily budget. They therefore capture by the alleged deadline; pad with zero allocations if capture occurs early. All following equalities use these exact gzg_z updates.

The nonnegative slack of one cohort step is p+Φ(next)Φ(current)p+\Phi(\text{next})-\Phi(\text{current}). Add each day’s unused budget. Over a (2q+1)(2q+1)-day successful schedule the total is (2q+1)m2C(2q+1)m-2C, which is 0,1,00,1,0 in cases A,B,CA,B,C, respectively. In AA and BB, Ch=(q1)w+m+(2Jm)2ηr2>1.C-h=\frac{(q-1)w+m+(2J-m)-2\eta-r}{2}>1. Indeed mr3m-r\ge3, q2q\ge2, and w7w\ge7 suffice. Every nonempty linear branch CdC-d is thus positive and strictly exceeds the support size.

Every tight noncapture step from a proper nonempty support is positive, remains proper, and lowers jj by one. Here are the adjustments needed to extend the preceding argument to the present budgets. A linear target is still strict because d<d+pd'<d+p. An unclipped tight step has one quotient drop by Lemma 8.3. A return to full is strict because its potential CC exceeds that of the source.

For a positive clipped step, d+pBd+p\le B, so dB1d\le B-1. Its source quotient is qq or q1q-1, because D+r>2B2D+r>2B-2. For b4b\ge4, in case AA the even and odd bounds are, respectively, D+r3B4bD+r\ge3B-4b and D+r3B4b+1D+r\ge3B-4b+1; case BB improves them by one. They all exceed 2B22B-2. For b=3b=3, direct substitution into JJ gives J(4)=4J(4)=4, J(5)=5J(5)=5, J(6)=J(7)=6J(6)=J(7)=6, J(8)=7J(8)=7, and δ(5)=δ(7)=1\delta(5)=\delta(7)=1, δ(6)=0\delta(6)=0. Hence the possible critical residues are exactly mrD+rA10518B11621C10619.\begin{array}{c|ccc} &m&r&D+r\\\hline A&10&5&18\\ B&11&6&21\\ C&10&6&19. \end{array} In particular the rows A,BA,B needed here both exceed 2B2=162B-2=16. This strict inequality also handles the positive-remainder convention at zero. The target quotient is qq or q1q-1 since every full-corner gain is less than DD.

If both source and target have quotient qq, the full departure with x=d+px=d+p inspections costs strictly more than F(N)F(N) in AA, by (43), or at least F(N)>CF(N)>C in BB. Subtracting dd rules out equality. If the source quotient is q1q-1, write r=2sr=2s, α=ρ1(s)\alpha=\rho_1(s), or r=2s1r=2s-1, α=ρ0(s)\alpha=\rho_0(s). Substitution gives lower bounds CdF(source)αη1,αη,αη,αηC-d-F(\text{source})\ge \alpha-\eta-1,\quad\alpha-\eta,\quad \alpha-\eta,\quad\alpha-\eta in the order EE/even, OO/even, EE/odd, OO/odd. They are positive: case AA needs only α2\alpha\ge2 in even parity and α1\alpha\ge1 in odd parity. In BB, J=(m+1)/26J=(m+1)/2\ge6 forces even α3\alpha\ge3 and odd α2\alpha\ge2. There is no cardinality exception because q2q\ge2. The full-corner lower bound again rules out equality. Only a transition from qq to q1q-1 remains.

A zero allocation from a proper support is strict directly. A minority neighborhood adds at least two rooms. A majority neighborhood adds at least one, except at deficit one when it returns to the full minority class. Thus FF increases strictly in the former cases, and the full potential CC is strictly larger in the latter. The linear branch also increases, since d<dd'<d. Finally, tight capture begins at quotient zero: its potential can equal the support size only in the cardinality branch. A proper tight tail consequently lasts exactly j+1j+1 consecutive days.

Case AA: the phase obstruction persists.

Every step and day is tight. The full-departure argument using (43) is unchanged, so each cohort has q+1q+1 consecutive active days. They overlap once, the first cohort is minority, and it requires J=m/2J=m/2 inspections on the shared day. The fresh cohort requires J+δ=m/2+1J+\delta=m/2+1 by the omitted-set argument above. The small-set profiles are uncut: their complementary deficits are (qD+w)/2(qD+w)/2 for even rr, when qq is odd and at least three, and at least (qD+w1)/2(qD+w-1)/2 for odd rr, when qq is even and at least two. Both exceed BB. Hence the shared day exceeds the budget.

Discounted cases: the first day uses the slack.

A tight positive full departure in BB or CC uses the FF target branch, has pBp\le B, and crosses a quotient boundary. The linear branch is strict by d<pd'<p; an uncut departure costs at least F(N)>CF(N)>C. The crossing conditions imply E departureO departurer evenpJ+1pJr oddpJpJ+1.\begin{array}{c|cc} &E\text{ departure}&O\text{ departure}\\\hline r\text{ even}&p\ge J+1&p\ge J\\ r\text{ odd}&p\ge J&p\ge J+1. \end{array} For even r=2sr=2s, an EE crossing has pR(p)s+1p-R(p)\ge s+1 with R(p)Q(s)R(p)\ge Q(s); an OO crossing has pQ(p)sp-Q(p)\ge s with Q(p)Q(s)Q(p)\ge Q(s). For odd r=2s1r=2s-1, use R(s)R(p)R(s)\le R(p) in the majority case and R(s)Q(p)1R(s)\le Q(p)-1 in the minority case. These prove the displayed bounds, including the surplus caps since pBp\le B.

The first day’s total slack is at least one. Unused budget already contributes one; allocating all mm to one cohort costs at least one slack because m>Bm>B and C<F(N)C<F(N). If all mm are divided between two positive tight departures, their minima sum to at least 2J+1>m2J+1>m, impossible. Case CC, which has zero total slack, is excluded.

In case BB, day one consumes exactly the single available unit. Every later day uses all mm inspections and every later step is tight. If both outputs of day one are proper, their quotients are at most qq: a proper output of a full departure has rank at most NN. Both tails then finish by day q+2<2q+1q+2<2q+1, leaving an entirely unused later day, a contradiction.

If exactly one output is proper, the other remains full. Its probes and any unused budget contribute their entire amount to slack, and so total at most one. The proper allocation is therefore pm1Bp\ge m-1\ge B. Define its gain here as NN minus the target rank (the initial majority rank is N+1N+1). This gain lies between D3D-3 and DD: the majority gain is 2B2b2B-2b at p=Bp=B and 2p2b22p-2b-2 at p>Bp>B; the minority gain is 2p2b12p-2b-1. The opposite corner is on its plateau since nwn\ge w and pm<B+bp\le m<B+b. Here rm3<D3r\le m-3<D-3 and r2r\ge2, so this output has quotient q1q-1. Both outputs cannot remain full, since that would cost slack m>1m>1.

The proper cohort has exactly qq consecutive tight days left; a fresh tight departure of the other begins q+1q+1 consecutive days. They cover the remaining 2q2q days and overlap once, since no later day’s budget may be unused. Immediately after day one the proper potential is Cm+1C-m+1. Before the overlap it receives another q1q-1 full allocations, so its capture requires Cqm+1=JC-qm+1=J inspections. The fresh tight departure requires at least JJ too. But 2J=m+12J=m+1, again exceeding the budget. This excludes BB and proves Theorem 8.1 for every mB+1m\ge B+1.

Removing the root functions

For Corollary 8.2, the function H(r)=2J(r)+δ(r)H(r)=2J(r)+\delta(r) is strictly increasing for r1r\ge1: its increments alternate between positive increments of L0L_0 and L1L_1. If m=2B+1m=2B+1 and b2b\ge2, put k=b(b1)k=b(b-1). Then H(2k)=L1(k)+L0(k+1)=m,H(2k+1)=L0(k+1)+L1(k+1)=m+2.H(2k)=L_1(k)+L_0(k+1)=m,\qquad H(2k+1)=L_0(k+1)+L_1(k+1)=m+2. The last admissible remainder is therefore 2k=mw2k=m-w. If m>2B+1m>2B+1, substitution at r=mw1r=m-w-1 and r+1=mwr+1=m-w puts the relevant arguments on the plateaus. The only endpoint is m=2B+2m=2B+2, where L1(Bb)=BL_1(B-b)=B; there H(mw1)=m1H(m-w-1)=m-1 and H(mw)=m+1H(m-w)=m+1. Otherwise H(mw1)=mH(m-w-1)=m and H(mw)>mH(m-w)>m. For b=1b=1, the cutoffs at m=3,4m=3,4 are zero and follow directly from H(1)=5H(1)=5; the other cases use the same plateau calculation.

Exact profiles on every even-area rectangle

Let G=PwPnG=P_w\mathbin{\square}P_n, where 2wn2\le w\le n and wnwn is even, and put b=w/2b=\left\lfloor w/2\right\rfloor and h=wn/2h=wn/2. Reflection in an even-length coordinate interchanges the checkerboard classes, so their profiles agree. Write ρ(d)=min{s0:ds(s+1)}\rho(d)=\min\{s\ge0:d\le s(s+1)\}.

Theorem 9.1 (Even-area neighborhood profile). For every 0kh0\le k\le h, g(k)=k+min{k,b,ρ(hk)}.g(k)=k+\min\{\left\lceil\sqrt{k}\right\rceil,b,\rho(h-k)\}. Equivalently, every one-color set of surplus s=N(S)S<bs=|N(S)|-|S|<b satisfies Ss2orhSs(s+1). |S|\le s^2\quad\hbox{or}\quad h-|S|\le s(s+1). (45) The minimum is attained for each cardinality and each color. These minimizers are not asserted to form a compatible dynamic order.

Matching contraction and a common component

Choose an even side length ee and let oo be the other side. Use physical coordinates (x,y)(x,y) with 0x<e0\le x<e, 0y<o0\le y<o. Match rows 2i,2i+12i,2i+1 in every column. Identify each color-pp vertex with (i,y)(i,y) by x=2i+((py)mod2)x=2i+((p-y)\bmod2). A physical edge followed by the inverse matching gives a directed graph DpD_p on an (e/2)×o(e/2)\times o array. It has loops, bidirectional horizontal edges, and vertical rungs directed down in one column parity and up in the other. The two choices of pp transpose the directed graph.

For the image RR of SS, put B=NDp+(R)RB=N^+_{D_p}(R)\setminus R. Then B=s0|B|=s\ge0, and RR is outgoing-closed in DpBD_p-B. If s<bs<b, at most ss columns contain BB. Since o2b2s+2o\ge2b\ge2s+2, two consecutive columns avoid BB. They form a strongly connected ladder: its two rung directions allow travel both ways between rows. Every row avoiding BB meets this ladder and is a full bidirectional path. Thus all such rows lie in a single strongly connected component CC, and at least one exists because e/2b>se/2\ge b>s. An outgoing-closed RR either contains CC or avoids it.

A sharp area bound outside the component

Suppose UB=U\cap B=\varnothing, N+(U)UBN^+(U)\setminus U\subseteq B, and every row avoiding BB is empty in UU. We prove Us2|U|\le s^2. Choose an empty row rr avoiding BB. Above it, let PP be the column parity with downward rungs and put αi=UiP,βi=UiP,ti=BiP,wi=Bi.\alpha_i=|U_i\cap P|,\quad \beta_i=|U_i\setminus P|, \quad t_i=|B_i\cap P|,\quad w_i=|B_i|. Rung closure gives αiαi+1+ti+1\alpha_i\le\alpha_{i+1}+t_{i+1} and hence αii<j<rtj\alpha_i\le\sum_{i<j<r}t_j. Horizontal matching gives βiαi+ti\beta_i\le\alpha_i+t_i. For even oo use a perfect matching of the horizontal path. For odd o=2q+1o=2q+1, every proper subset of the majority column parity matches into its neighbors, as does every subset of the minority. The sole possible exception is the full majority. That would force qαi+tiij<rtjsq\le\alpha_i+t_i\le\sum_{i\le j<r}t_j\le s, contrary to qb>sq\ge b>s. Thus in all cases each occupied row satisfies Uiwi+2i<j<rwj. |U_i|\le w_i+2\sum_{i<j<r}w_j. (46)

Let W=i<rwiW=\sum_{i<r}w_i and let aa be the number of occupied rows above rr. Every occupied row contains a boundary vertex, so aWa\le W. In the sum of (46), a boundary vertex in row jj has coefficient twice the number of earlier occupied rows, plus one if its own row is occupied. Reserve one vertex in each occupied row. Their coefficients are 1,3,,2a11,3,\ldots,2a-1, summing to a2a^2; every remaining vertex has coefficient at most 2a2a. The total is therefore at most a2+2a(Wa)W2a^2+2a(W-a)\le W^2.

Below rr, reverse row order and use upward rungs. If WW' counts the boundary there, this gives area at most (W)2(W')^2. Since W+W=sW+W'=s, we obtain UW2+(W)2s2|U|\le W^2+(W')^2\le s^2. The argument includes b=1,s=0b=1,s=0.

If RR avoids CC, apply this bound to RR. Otherwise set U=V(Dp)(RB)U=V(D_p)\setminus(R\cup B). It avoids every boundary-free row and is outgoing-closed outside BB in the transposed graph: an edge from UU to RR there would be an edge from RR to UU originally. The same area bound gives hR=U+ss(s+1)h-|R|=|U|+s\le s(s+1). This proves (45) and the profile lower bound for every physical support.

Attaining the three bounds

For the plateau bound, return to coordinates with ww transverse rows and nn longitudinal columns. Take an ideal of the predecessor relation (x,y)(x±1,y1)(x,y)\succ(x\pm1,y-1) on one checkerboard class. Its row cutoffs axa_x have the required row parity and satisfy ax+1ax=1|a_{x+1}-a_x|=1; virtual cutoffs 2,1-2,-1 represent empty rows. The neighborhood cutoff in row xx is at most ax+1a_x+1. Write sx=(px)mod2s_x=(p-x)\bmod2 for its source parity. The rowwise cardinality change is (axax+2sx1)/2(a'_x-a_x+2s_x-1)/2. For even ww, the parity correction sums to zero; for odd ww, choose p=0p=0, when it sums to 1-1. In both cases the total surplus is at most b=w/2b=\left\lfloor w/2\right\rfloor. Reflection in an even-length coordinate supplies the other color. Every size kk occurs: take an initial segment of any linear extension of this finite predecessor order.

If s=k<bs=\left\lceil\sqrt{k}\right\rceil<b, the even-color quadrant prefix of size kk, ordered by increasing coordinate sum and then decreasing transverse coordinate, has exactly k+sk+s neighbors. It lies within coordinates 0,,2s20,\ldots,2s-2, with neighborhood within 0,,2s10,\ldots,2s-1, so both fit inside GG. This attains the small-corner bound; k=0k=0 is immediate.

For the other end put d=hkd=h-k and s=ρ(d)<bs=\rho(d)<b. Then x=dsx=d-s satisfies 0xs20\le x\le s^2. The small-corner construction provides an opposite-color set XX of size xx with at most x+s=dx+s=d neighbors. Choose kk vertices outside N(X)N(X) in the desired color. Their neighborhood avoids XX, so has size at most hx=k+sh-x=k+s. Reflection in an even-length coordinate supplies either color in these constructions. Each branch that improves on bb is thus attained, proving the theorem.

Together with Theorem 5.1, this settles the static neighborhood profiles for all nondegenerate rectangles. The scalar profile alone need not determine optimal time: on 6×66\times6 with five inspections its full-budget solo recurrence permits 18,15,13,11,9,6,2,018,15,13,11,9,6,2,0. Combining two six-step preparations with a central inspection would give thirteen days if those prescribed sizes were physically attainable. The exact physical optimum is fourteen, as independently certified in the research archive. This is an obstruction to dynamic attainment, not to the profile theorem.

Corner restrictions and memory on an even-width half-strip

Static minimizers need not be compatible with an earlier belief. Here we quantify one source of incompatibility without imposing a shape on that belief. Work in the whole half-strip Hb={(x,y):0x<2b, y0},b1,H_b=\{(x,y):0\le x<2b,\ y\ge0\},\qquad b\ge1, with square-grid adjacency. For color zero put c=(0,0)c=(0,0) and c=(2b1,0)c'=(2b-1,0). These are the favorable bottom corners of the current and next colors. Reflection supplies the other color. A restriction on a source set does not delete vertices from the graph: every neighborhood below is taken in HbH_b. Write R(k)=k,Q(k)=min{s1:ks(s1)},Ch(s)=max{s(s1)/2,s(sh)}.R(k)=\left\lceil\sqrt{k}\right\rceil,\qquad Q(k)=\min\{s\ge1:k\le s(s-1)\},\qquad C_h(s)=\max\{s(s-1)/2,s(s-h)\}. The last function is the punctured-quadrant capacity of Theorem 4.1.

Theorem 10.1 (Exact conditional corner profiles). For every k>0k>0, the least neighborhood size of a kk-room color-zero set subject to each indicated condition is kk plus the following surplus: condition on Sminimum surplusnonemin{R(k),b}cSmin{Q(k),b+1}cN(S)min{Q(k),b}cN(S){R(k),k<b2,b+1,kb2.\begin{array}{c|c} \text{condition on }S&\text{minimum surplus}\\ \hline \text{none}&\min\{R(k),b\}\\ c\notin S&\min\{Q(k),b+1\}\\ c'\in N(S)&\min\{Q(k),b\}\\ c'\notin N(S)& \begin{cases}R(k),&k<b^2,\\b+1,&k\ge b^2.\end{cases} \end{array} For the joint condition cSc\notin S, cN(S)c'\notin N(S), the exact capacity at surplus at most ss is, when b2b\ge2, Γb(s)={C2(s),0sb,max{b(b+1)/2,b22},s=b+1,,sb+2. \Gamma_b(s)= \begin{cases} C_2(s),&0\le s\le b,\\ \max\{b(b+1)/2,b^2-2\},&s=b+1,\\ \infty,&s\ge b+2. \end{cases} (47) Thus its minimum surplus is min{s:kΓb(s)}\min\{s:k\le\Gamma_b(s)\}. For b=1b=1 the joint minimum is instead two for every k>0k>0. Every asserted minimum is attained at every cardinality.

Matching rows and the marginal restrictions

Use the matching contraction of Section 9: the source room represented by (i,y)(i,y) has physical coordinate x=2i+(ymod2)x=2i+(y\bmod2). The contracted graph has horizontal edges in both directions, upward rungs at even yy, and downward rungs at odd yy. If B=ND+(S)SB=N_D^+(S)\setminus S, then B=N(S)S=:s|B|=|N(S)|-|S|=:s. A matched row avoiding BB is horizontally closed in a ray and finite, hence empty in SS. Its two empty physical rows separate the support into parts with disjoint neighborhoods. Each part has its full neighborhood unchanged when viewed as a quadrant; the empty row supplies its transverse neighbor layer. Surpluses therefore add. Such a row always exists if s<bs<b.

The two unrestricted quadrant capacities are C0(u)=u2C_0(u)=u^2 and C1(u)=u(u1)C_1(u)=u(u-1), so their sum at total surplus ss is at most s2s^2. If cc is omitted, the capacities become C2C_2 and C1C_1, both at most u(u1)u(u-1); their sum is at most s(s1)s(s-1). If cc' belongs to the neighborhood, the odd-quadrant part is nonempty and consumes surplus r2r\ge2. Even allowing the other part its square capacity gives S(sr)2+r(r1)s(s1).|S|\le(s-r)^2+r(r-1)\le s(s-1). These prove the subcritical lower bounds in the first three rows.

For the omitted-current bound at s=bs=b, only the absence of a boundary-free row remains. Every matched row then has exactly one boundary vertex. Its occupied set is empty or an initial interval of length cic_i, because any other finite subset of a ray has two horizontal boundary vertices. Here c0=0c_0=0. Upward even rungs give ci+1ci+2c_{i+1}\le c_i+2, including when ci=0c_i=0, and consequently Si=0b12i=b(b1).|S|\le\sum_{i=0}^{b-1}2i=b(b-1). Thus omission of cc requires surplus at least b+1b+1 beyond this size.

For later use, omission of the outgoing corner has the sharper critical bound cN(S), s=bSb21. c'\notin N(S),\ s=b\quad\Longrightarrow\quad |S|\le b^2-1. (48) With a boundary-free row the two capacities are C0C_0 and C3C_3, whose sum is at most b2b^2. Equality forces all surplus into the unrestricted even quadrant and the full square extremizer there. Indeed, equality in the full-layer proof of Theorem 4.1 forces every occupied diagonal to be full and consecutive. That square reaches transverse coordinate 2b22b-2, whereas a component before an empty matched row reaches at most 2b32b-3. Equality is impossible. Without a boundary-free row, all occupied rows are prefixes, the last is empty, and downward odd rungs give ci2(bi)1c_i\le2(b-i)-1 for i<b1i<b-1. Their sum is b21b^2-1. This proves (48) and the fourth lower bound in the theorem.

We record the constructions together. Finite downward pyramids, meaning ideals under (x,y)(x±1,y1)(x,y)\succ(x\pm1,y-1), exist at every size and have surplus at most bb: their neighborhood cutoffs are at most their source cutoffs plus one. Small even-quadrant prefixes give surplus R(k)R(k); odd-quadrant prefixes at the opposite corner give surplus Q(k)Q(k) and touch cc'. Fill a partial diagonal toward smaller transverse coordinate. Then every even prefix of size k<b2k<b^2 avoids the two neighbors of cc', attaining the fourth row below its threshold.

The following elementary bounds supply all larger constructions. If (v,t)(v,t) is missing from a pyramid of source color zero, its cutoffs obey axt2+xva_x\le t-2+|x-v|, and its size is at most x(t+xv(xmod2))/2\sum_x(t+|x-v|-(x\bmod2))/2. In particular, omission of (1,1)(1,1) bounds the size by b(b1)+1b(b-1)+1, and omission of (2b2,2)(2b-2,2) bounds it by b2+1b^2+1. The sharper bottom-root threshold in Lemma 12.2 is b(b1)b(b-1). For k>b(b1)k>b(b-1), take a pyramid of size k+1k+1 and remove cc. The forced room (1,1)(1,1) covers both neighbors of cc, so this has surplus at most b+1b+1. A pyramid of size k>b(b1)k>b(b-1) also contains (2b2,0)(2b-2,0) and hence touches cc', proving the remaining attainment with outgoing corner present. For kb2k\ge b^2, take a pyramid of size k+2k+2 and remove the two neighbors (2b2,0),(2b1,1)(2b-2,0),(2b-1,1) of cc'. The forced room (2b2,2)(2b-2,2) and its predecessors cover every other neighbor of these rooms. Exactly cc' disappears from the neighborhood, so the resulting surplus is at most b+1b+1. This completes all marginal profiles, including b=1b=1.

Both omissions, including the critical extra unit

Suppose first b2b\ge2. The joint condition forbids exactly the three source rooms (0,0),(2b2,0),(2b1,1).(0,0),\qquad (2b-2,0),\qquad(2b-1,1). A boundary-free row splits their capacities into C2C_2 on the left and C3C_3 on the reflected right. Convexity, their zero values at zero, and C3C2C_3\le C_2 give total capacity at most C2(s)C_2(s). If s=bs=b and there is no such row, the preceding prefix argument has both endpoint rows empty and gives cimin{2i,2(bi)1}(1ib2),Sb(b1)/21C2(b).c_i\le\min\{2i,2(b-i)-1\}\quad(1\le i\le b-2), \qquad |S|\le b(b-1)/2-1\le C_2(b). This proves the first line of (47).

Now let s=b+1s=b+1. If both neighbors of cc already belong to N(S)N(S), adding cc leaves the neighborhood unchanged and still omits cc'. Equation (48) then gives S+1b21|S|+1\le b^2-1, or Sb22|S|\le b^2-2. Assume henceforth that this origin-addition argument is unavailable.

If there is a boundary-free row and the right part is nonempty, its surplus is at least two. For b3b\ge3, convexity bounds the total by max{C3(b+1), C2(b1)+C3(2)}b22.\max\{C_3(b+1),\ C_2(b-1)+C_3(2)\}\le b^2-2. If only the left part is nonempty, its sole larger possibility is C2(b+1)=b21C_2(b+1)=b^2-1. Equality in the punctured-quadrant proof forces full diagonals 2,4,,2b22,4,\ldots,2b-2, which cannot fit before an empty matched row. Diagonal compression toward the smaller transverse coordinate preserves that width restriction, so equality is impossible even for an uncompressed source. For b=2b=2 the direct quadrant bound is already C2(3)=3C_2(3)=3, as required.

It remains to consider s=b+1s=b+1 with no boundary-free row. Exactly one row has two boundary vertices; all other occupied rows are prefixes. First suppose both endpoint rows are empty. Write αi,βi\alpha_i,\beta_i for the numbers of even and odd occupied columns and ti,uit_i,u_i for the respective boundary counts. Rung inclusion gives αij<itj,βij>iuj,\alpha_i\le\sum_{j<i}t_j,\qquad \beta_i\le\sum_{j>i}u_j, and therefore Sj((b1j)tj+juj)(b+1)(b1)(b2)=b2b+1.|S|\le\sum_j\bigl((b-1-j)t_j+j u_j\bigr) \le(b+1)(b-1)-(b-2)=b^2-b+1. For the second inequality reserve one boundary vertex on each internal row, where its coefficient is at most b2b-2; every other coefficient is at most b1b-1. This is at most b22b^2-2 for b3b\ge3, and is three when b=2b=2. No interval assumption on the exceptional internal row was used.

If an endpoint row is occupied, it must be the exceptional row. Its source is a single interval avoiding column zero, since two components away from zero would require more than two horizontal boundary vertices. There are two endpoint cases.

  • At the first row, an interval starting at one contains the physical room (1,1)(1,1) and permits origin addition. In the remaining case its first column is at least two. The next row must be empty: otherwise its prefix sends an even rung to column zero in the first row, creating a third boundary vertex. At most one odd interval room can feed that empty next row, so the interval has length at most three. The other prefixes grow by at most two per row, giving total at most (b2)(b3)+3(b-2)(b-3)+3.

  • At the last row, the interval starts at least at two because both columns zero and one are forbidden. The earlier prefixes satisfy ci2ic_i\le2i. If the preceding prefix has length c>0c>0, its sole boundary is at cc; the interval’s even coordinates are at most cc, and its length is at most cc. The total is at most (b2)(b1)+2(b2)=b2b2(b-2)(b-1)+2(b-2)=b^2-b-2. If that preceding row is empty, at most one even interval room can feed it. The interval has length at most three, and the earlier prefixes contribute at most (b3)(b2)(b-3)(b-2).

Each bound is at most b22b^2-2 for b3b\ge3; the endpoint cases for b=2b=2 give at most three. Together these exhaust the extra-unit cases and prove the finite upper capacity in (47).

For sharpness at sbs\le b, both the proper-ramp and full-layer constructions for C2(s)C_2(s) avoid all three forbidden rooms. The full layers end at diagonal 2s42s-4; the ramp is filled toward small transverse coordinate. Their partial terminal layers give every intermediate size. For b3b\ge3, fill the even diagonals 2,4,,2b22,4,\ldots,2b-2 and delete (2b2,0)(2b-2,0). This has b22b^2-2 rooms and surplus b+1b+1. Every smaller size at this surplus bound comes from an even-quadrant prefix of size k+1k+1, filled toward smaller transverse coordinate, with its origin deleted. For b=2b=2 the ramp {(0,2),(0,4),(1,3)}\{(0,2),(0,4),(1,3)\} and its initial subprefixes give sizes up to three.

For every larger kk, take a downward pyramid of size k+3k+3 and remove all three forbidden rooms. Its size forces (1,1)(1,1) and (2b2,2)(2b-2,2) by the two omission bounds above; their predecessors ensure that all three rooms to be removed are present. Their other neighbors remain covered, so only cc' disappears from the neighborhood. The surplus is at most b+2b+2. This proves every-size attainment, not just unboundedness along a subsequence. When b=1b=1, the two bottom forbidden rooms coincide; the joint restriction is exactly the outgoing-absent restriction already proved, with minimum surplus two. This finishes the theorem.

Localization gives more than availability bits

Corollary 10.2 (Triangular localization and propagation delay). Let SS be a nonempty color-zero set, with surplus s<bs<b. If S>s(s1)|S|>s(s-1), then SS is connected under the relation of sharing a neighbor, contains cc, and x+y2s2((x,y)S),cNj(S)(j<2(bs)+1).x+y\le2s-2\quad((x,y)\in S),\qquad c'\notin N^j(S)\quad\bigl(j<2(b-s)+1\bigr). If cSc\notin S and S>C2(s)|S|>C_2(s), then SS is connected under the same relation, cN(S)c'\in N(S), and (2b1x)+y2s3((x,y)S),cNj(S)(j<2(bs)+2).(2b-1-x)+y\le2s-3\quad((x,y)\in S),\qquad c\notin N^j(S)\quad\bigl(j<2(b-s)+2\bigr). Both exclusions remain valid after arbitrary intervening inspections. Here jj counts movements from the survivor SS.

Proof. Sharing-neighbor components have disjoint neighborhoods, so their sizes and surpluses add. A nonempty component omitting cc has surplus at least two and capacity u(u1)u(u-1) at surplus u<bu<b. For the first claim, if no component contains cc, the total capacity is at most s(s1)s(s-1). If one contains cc with surplus a1a\ge1 and has companions of total surplus d2d\ge2, its total capacity is at most a2+d(d1)(a+d)(a+d1)a^2+d(d-1)\le(a+d)(a+d-1). Both are contradictions. Thus SS is one component containing cc.

For the second claim, every component has surplus at least two. Two or more components have total capacity at most (s2)(s3)+2s(s2)C2(s),s4;(s-2)(s-3)+2\le s(s-2)\le C_2(s),\qquad s\ge4; this follows by merging all but one component and maximizing the convex two-part pronic sum at an endpoint. For s<4s<4 two components are impossible. Thus SS is connected; the joint profile then forces cN(S)c'\in N(S).

A boundary-free matched row exists in both cases. Connectedness confines the whole support to the corresponding corner quadrant, with its actual neighborhood unchanged. In the first case its occupied even diagonals are 0,2,,2L20,2,\ldots,2L-2: a sharing-neighbor edge changes the coordinate sum by zero or two, so there is no gap. Diagonal compression preserves which diagonals are occupied. The layer inequalities in Theorem 4.1 charge at least one surplus unit per occupied diagonal; hence LsL\le s. This bounds the original support, without claiming it is compressed. In the reflected odd quadrant of the second case, cN(S)c'\in N(S) forces the first diagonal to be one. The occupied diagonals are 1,3,,2L11,3,\ldots,2L-1, and the output origin supplies one more surplus unit, so L+1sL+1\le s.

The bottom corners have distance 2b12b-1. Subtracting the respective triangle radii gives the two stated distances. Every later belief is a subset of the corresponding free neighborhood iterate, proving the inspection-independent exclusions. Full square and pronic triangles attain these distances, so the strict inequalities on jj are intentional. ◻

The sharp localization examples for b=4,s=3b=4,s=3. Filled rooms are SS; open rooms are N(S)N(S). Crosses mark the excluded opposite corner. Its shortest arrival times are three and four movements.

These statements concern arbitrary supports, but are not a sufficiency theorem for corner-availability bits. For example, on width fourteen a 30-room set omitting its current favorable corner and having surplus six must be the opposite odd triangle on diagonals 1,3,5,7,91,3,5,7,9. Indeed the separating-row capacities force all surplus into that quadrant; equality in its full-layer bound forces each raw diagonal to be full. Its 36-room neighborhood cannot reach the other bottom corner on the following movement. Remembering only current corner presence loses this distance information even though each individual conditional profile is sharp. No full-board capture time is being asserted by this example.

Finally, on a finite rectangle the half-strip profile applies to a source that avoids the far longitudinal row, so its neighborhood agrees with the half-strip neighborhood. That guard must be checked at every use of a profile inequality. Once localization has been established, the propagation exclusions also hold on the finite board, whose free neighborhoods can only be smaller.

Corner geometry and stronger lower bounds

The following argument retains the geometric information lost by a size-only profile, then proves which necessary models can be concentrated into one cohort. A model path need not be physically attainable. Its numerical evaluation therefore supplies a lower bound until a construction matches it.

A corner-count bound on every even-area rectangle

The preceding size profile can lose the corner information needed to chain two inspection steps. The following necessary bound retains both current and outgoing corner counts, without restricting the shape of the support. Let G=PwPnG=P_w\mathbin{\square}P_n, where 2wn2\le w\le n and wnwn is even, and put b=w/2b=\left\lfloor w/2\right\rfloor and h=wn/2h=wn/2. Each color contains exactly two board corners. For a one-color support SS, write a=S,s=N(S)S,i=SKp,j=N(S)K1p,a=|S|,\qquad s=|N(S)|-|S|,\qquad i=|S\cap\mathcal K_p|,\qquad j=|N(S)\cap\mathcal K_{1-p}|, where Kp\mathcal K_p consists of the two corners of color pp. Neighborhoods are always taken in the entire finite board.

For 0i,j20\le i,j\le2, define Φi,j(s)={,s<i+2j,i+2j2+(si2j+2)(si2j+1),si+2j, j>0,i1+(si+1)2,si, j=0<i,max{s(s1)/2,s(s2)},s0, i=j=0. \Phi_{i,j}(s)= \begin{cases} -\infty,&s<i+2j,\\ i+2j-2+(s-i-2j+2)(s-i-2j+1),&s\ge i+2j,\ j>0,\\ i-1+(s-i+1)^2,&s\ge i,\ j=0<i,\\ \max\{s(s-1)/2,s(s-2)\},&s\ge0,\ i=j=0. \end{cases} (49) Put Ψi,j(s)=max0d2iΦ2j,d(s2+i+d). \Psi_{i,j}(s)=\max_{0\le d\le2-i} \Phi_{2-j,d}(s-2+i+d). (50) This maximum has at most three candidates, with d{0,1,2}d\in\{0,1,2\}; both functions therefore use a fixed number of numerical operations.

Theorem 11.1 (Finite-board corner-count dichotomy). For every physical support SS with 0s<b0\le s<b, aΦi,j(s)orhasΨi,j(s). a\le\Phi_{i,j}(s) \qquad\text{or}\qquad h-a-s\le\Psi_{i,j}(s). (51) No compression or compatibility assumption is required. The statement includes both parities of the shorter side and the empty and full supports.

Proof. Choose an even side ee, and let oo be the other side. Use the directed matching contraction in Section 9, with e/2e/2 matched rows, oo columns, contracted support RR, and outside boundary BB of size ss. Since e/2b>se/2\ge b>s, some matched row avoids BB. Since o2b2s+2o\ge2b\ge2s+2, two consecutive columns avoid BB. Those two columns form a strongly connected ladder. Every undeleted matched row and every adjacent pair of undeleted columns therefore lie in one strongly connected component CC of DBD-B. The outgoing-closed set RR contains all of CC or none of it.

First suppose RR avoids CC. Select an undeleted matched row and two consecutive undeleted columns. They contain neither RR nor BB. Physically they supply two consecutive empty transverse rows and two consecutive empty longitudinal columns. Cutting there splits SS into four corner pieces with disjoint neighborhoods. Each neighborhood is unchanged when its piece is viewed in the whole quadrant based at its board corner: the empty separators keep it away from the two opposite physical board edges. Thus the four sizes and surpluses add.

At each source-colored corner present in SS, the even quadrant piece has surplus at least one and capacity C0(u)=u2C_0(u)=u^2. At an omitted source-colored corner its capacity is C2(u)C_2(u). At each opposite-colored corner present in N(S)N(S), the odd quadrant piece has surplus at least two and capacity C1(u)=u(u1)C_1(u)=u(u-1). If that outgoing corner is absent, both odd neighbors of its origin are forbidden, giving capacity C3(u)C_3(u). These are precisely the punctured-quadrant bounds of Theorem 4.1.

The ii required even pieces and jj required odd pieces consume surplus at least i+2ji+2j. All four capacities are nondecreasing and discretely convex. Subject to their minimum surpluses, the sum is maximized by putting all remaining surplus into one piece: for two variable pieces, convexity moves the maximum to an endpoint of their allocation interval; repeat until one variable remains. Write z=si2jz=s-i-2j. Above its minimum, a required even piece gains z2+2zz^2+2z, and a required odd piece gains z2+3zz^2+3z. An optional piece gains at most C2(z)z2C_2(z)\le z^2, with C3(z)C2(z)C_3(z)\le C_2(z). Thus a required odd piece receives the excess when j>0j>0, a required even piece when j=0<ij=0<i, and an omitted-even-origin piece when i=j=0i=j=0. This gives exactly (49) and proves the first branch.

Otherwise put U=V1pN(S)U=V_{1-p}\setminus N(S), so U=has,N(U)VpS.|U|=h-a-s,\qquad N(U)\subseteq V_p\setminus S. In the transposed matching contraction, UU is outgoing-closed outside BB and avoids CC. The same four-quadrant argument applies. Its current corner count is 2j2-j. Write d=N(U)Kpd=|N(U)\cap\mathcal K_p| and t=N(U)Ut=|N(U)|-|U|; then 0d2i0\le d\le2-i and 0ts0\le t\le s. The complement slack has size (VpS)N(U)=st.|(V_p\setminus S)\setminus N(U)|=s-t. It contains the 2id2-i-d corners belonging to neither SS nor N(U)N(U). Consequently ts2+i+dt\le s-2+i+d. The first-branch argument and monotonicity now give hasΦ2j,d(t)Φ2j,d(s2+i+d)Ψi,j(s),h-a-s\le\Phi_{2-j,d}(t) \le\Phi_{2-j,d}(s-2+i+d) \le\Psi_{i,j}(s), proving the second branch. The corner charge in the middle inequality is essential; merely using tst\le s would discard relevant information. ◻

Corollary 11.2 (A uniform necessary inspection rule). Suppose a one-color belief AA has size KK and contains cc of its physical-color corners. After pp useful inspections, let the next belief have size KK' and corner count jj. Set a=Kpa=K-p and s=Kas=K'-a. If s<bs<b, then (51) holds for some i{0,1,2}i\in\{0,1,2\} satisfying ici+pi\le c\le i+p.

Proof. The survivor SAS\subseteq A has aa rooms and ii current-colored corners; removing pp rooms can remove at most pp corners. Apply the theorem. ◻

For example, on 8×88\times8 a 2525-room belief with one current-colored corner cannot become a 2323-room belief after five inspections. The size-only profile forces the survivor size to be 2020 and surplus three. Its source-corner count is at most one. For i=1i=1, the three dual capacities, indexed by j=0,1,2j=0,1,2, are 2,4,62,4,6, whereas has=9h-a-s=9; for i=0i=0 they are no larger. The small branch also fails. Thus the corner bound excludes this transition even though the static size profile permits it. For surplus sbs\ge b, retain the size-only profile; this section makes no claim that the corner relaxation is sharp there or that its allowed transitions are jointly attainable.

The critical corner bound on odd-width rectangles

When the shorter side is odd and the longer side is even, the preceding corner dichotomy extends to the critical surplus with one explicit exception. Let w=2b+13w=2b+1\ge3, n=2wn=2\ell\ge w, and h=wh=w\ell. Use the corner counts i,ji,j and capacities Φ,Ψ\Phi,\Psi from Section 11.1.

Theorem 11.3 (Critical corner dichotomy). Every physical one-color support of size aa and surplus bb satisfies aΦi,j(b)orhabΨi,j(b)or(i,j)=(2,0).a\le\Phi_{i,j}(b) \quad\text{or}\quad h-a-b\le\Psi_{i,j}(b) \quad\text{or}\quad (i,j)=(2,0). Together with Theorem 11.1, this is a uniform necessary corner bound at every surplus at most bb. No assertion of attainability or dynamic compatibility is made.

Proof. Reflect to physical color zero and match longitudinal room pairs. The contracted graph has bidirectional transverse edges, downward edges on U={0,2,,2b}U=\{0,2,\ldots,2b\}, and upward edges on V={1,3,,2b1}V=\{1,3,\ldots,2b-1\}. Let RR be the contracted support and HH its outside boundary, with H=b|H|=b. Since >b\ell>b, a horizontal row avoids HH.

If two adjacent columns also avoid HH, the proof of Theorem 11.1 applies without change: the two separators lie in one strongly connected component, which RR either contains or avoids. Accordingly RR or its transposed complement splits into four physical corner quadrants. Their whole neighborhoods agree with the finite-board neighborhoods. Additive capacities and the same missing-corner slack give the first or second displayed alternative. That argument needs the two separators, not the strict surplus bound.

Otherwise the marked columns form a vertex cover of a path on 2b+12b+1 positions using at most bb columns. They are exactly VV, with one mark (v,cv)(v,c_v) each. Every UU fiber is a prefix of length tut_u, and horizontal closure gives, for adjacent uvuv, RvRu,RuRv{cv}.R_v\subseteq R_u,\qquad R_u\setminus R_v\subseteq\{c_v\}. Thus neighboring UU lengths differ by at most one. For consecutive UU columns u,uu,u' surrounding vv, one also has Rvmin{tu,tu},Rvmin{tu,tu}+1.|R_v|\le\min\{t_u,t_{u'}\},\qquad \ell-|R_v|\le\min\{\ell-t_u,\ell-t_{u'}\}+1. These inequalities do not assume that RvR_v is a prefix.

An outgoing corner is present exactly when its endpoint UU fiber is full, because the neighborhood adds no UU vertices. A full UU fiber forces every UU fiber to be nonempty: its length drops by at most one across each of bb intervening positions, and >b\ell>b. Consequently j>0j>0 implies i=2i=2. There are five remaining possibilities. If (i,j)=(0,0)(i,j)=(0,0), both endpoint UU fibers are empty, so t2qmin{q,bq}t_{2q}\le\min\{q,b-q\}; the first VV bound sums to ab(b1)/2Φ0,0(b)a\le b(b-1)/2\le\Phi_{0,0}(b). If (i,j)=(1,0)(i,j)=(1,0), the one-sided distance bound instead gives ab2=Φ1,0(b)a\le b^2=\Phi_{1,0}(b). The pair (2,0)(2,0) is precisely the stated exception. If (i,j)=(2,1)(i,j)=(2,1), one endpoint UU fiber is full; applying the second VV bound to its deficiencies gives hab(b+1)h-a\le b(b+1), hence habb2=Ψ2,1(b)h-a-b\le b^2=\Psi_{2,1}(b). Finally, for (i,j)=(2,2)(i,j)=(2,2) both endpoint deficiencies vanish, giving hab(b+1)/2,habb(b1)/2Φ0,0(b)=Ψ2,2(b).h-a\le b(b+1)/2,\qquad h-a-b\le b(b-1)/2\le\Phi_{0,0}(b)=\Psi_{2,2}(b). These alternatives exhaust the cases and prove the theorem. ◻

Corollary 11.4 (Rigidity at the pronic capacity). Suppose b2b\ge2. A survivor SS with S=b(b1),N(S)S=b,|S|=b(b-1),\qquad |N(S)|-|S|=b, and no corner of its own color is the full odd triangle based at one opposite-colored board corner: its relative diagonals are 1,3,,2b31,3,\ldots,2b-3. Consequently N(S)N(S) contains exactly that one opposite-colored corner, and N2(S)N^2(S) contains neither original-colored corner. The latter omission persists after any intervening inspections.

Proof. Take radius t=bt=b in Theorem 11.12. Since the shorter side is odd, its outgoing allowance is κ=0\kappa=0. ◻

Corollary 11.5 (Critical orientation down to the pronic threshold). Put B=b(b+1)B=b(b+1) and C=b(b1)C=b(b-1). If a survivor SS has surplus bb and C<S<hBC<|S|<h-B, it contains at least one own-colored corner, while N(S)N(S) contains neither opposite-colored corner. Two successive survivors in this interval cannot both have surplus bb. Moreover, after such a survivor, every next survivor AA of size ab2a\le b^2 satisfies N(A)a+min{Q(a),b+1},Q(a)=min{q1:aq(q1)}(a>0),Q(0)=0.|N(A)|\ge a+\min\{Q(a),b+1\},\qquad Q(a)=\min\{q\ge1:a\le q(q-1)\}\quad(a>0),\quad Q(0)=0.

Proof. Every Ψi,j(b)b2\Psi_{i,j}(b)\le b^2, so the upper size restriction excludes the dual branch of Theorem 11.3. If i=0i=0 or j>0j>0, then Φi,j(b)C\Phi_{i,j}(b)\le C, excluding its small branch. Its exceptional pair (2,0)(2,0) already has the required corners. The next survivor omits both of its own corners, so the reflected conclusion proves incompatibility.

For its small-corner bound, suppose ab2a\le b^2 and its surplus is sbs\le b. The critical exception is unavailable since its current corner count is zero. Also hashb2b>b2Ψ0,j(s)h-a-s\ge h-b^2-b>b^2\ge\Psi_{0,j}(s), so the dual branch is excluded. The first branch gives aΦ0,j(s)s(s1)a\le\Phi_{0,j}(s)\le s(s-1), using the subcritical theorem when s<bs<b. Therefore either sb+1s\ge b+1 or sQ(a)s\ge Q(a), as required. ◻

Corollary 11.6 (The dual critical corner restriction). If N(S)S=b|N(S)|-|S|=b and b2<S<hb2b^2<|S|<h-b^2, then SS contains both corners of its own color and N(S)N(S) contains at most one opposite-colored corner.

Proof. The small branch of Theorem 11.3 is impossible since every Φi,j(b)b2<S\Phi_{i,j}(b)\le b^2<|S|. Its exceptional pair (2,0)(2,0) already has the asserted corners. Otherwise the complementary size is hSb>b(b1)h-|S|-b>b(b-1). Every Ψi,j(b)\Psi_{i,j}(b) with i<2i<2 or j=2j=2 is at most b(b1)b(b-1), so the dual branch forces i=2i=2 and j1j\le1. ◻

The critical corner bound on even-width rectangles

The critical surplus has two possible spanning orientations. The even one occurs on every even-width rectangle; the odd one occurs additionally on a rectangle whose sides differ by one. These are necessary exceptions, not a sufficiency assertion about the corresponding profiles.

Theorem 11.7 (Critical corner bound for even widths). Let w=2b2w=2b\ge2, n2bn\ge2b, and h=bnh=bn. A physical one-color support of size aa, surplus bb, and corner counts i,ji,j satisfies aΦi,j(b)orhabΨi,j(b)a\le\Phi_{i,j}(b) \quad\text{or}\quad h-a-b\le\Psi_{i,j}(b) unless (i,j)=(1,1)(i,j)=(1,1), or n=2b+1n=2b+1 and (i,j)=(2,0)(i,j)=(2,0).

Proof. Match adjacent rooms across the 2b2b side. The contraction has bb rows, nn columns, horizontal bidirectional edges, and alternating downward and upward rungs. Reflect to make even columns downward. Write RR for the contracted support and BB for its outside boundary, with B=b|B|=b. Then RR is disjoint from BB and outgoing-closed in DBD-B.

An unmarked adjacent pair. Two adjacent columns avoiding BB form a strongly connected ladder; no unmarked matched row is needed for this assertion. If RR avoids this ladder, the two empty physical columns split its support into two pieces whose neighborhoods are disjoint and unchanged in the whole half-strips of width 2b2b based at the board’s two ends. If both pieces are nonempty, each surplus is less than bb. Each piece then splits across an empty matched row into two quadrants, and the capacity allocation in Theorem 11.1 gives Φ\Phi. If only one is nonempty, Theorem 10.1 bounds its critical capacity by C2(b)C_2(b), b(b1)b(b-1), or b21b^2-1 for corner bits (0,0)(0,0), (0,1)(0,1), or (1,0)(1,0), respectively. These fit Φ\Phi; the remaining pair (1,1)(1,1) is the stated exception.

If RR contains the ladder, use U=V1pN(S)U=V_{1-p}\setminus N(S) in the transposed contraction. Its surplus tt is at most bb. The same first-branch argument applies to UU, except possibly at its critical pair (1,1)(1,1). Its outgoing count dd satisfies tb2+i+dt\le b-2+i+d by the missing-corner slack, giving Ψ\Psi as before. If t=bt=b and UU has pair (1,1)(1,1), zero slack forces i=j=1i=j=1 for SS. This proves the theorem whenever an adjacent pair is unmarked, and hence for n2b+2n\ge2b+2.

The near-square n=2b+1n=2b+1. If no adjacent pair is unmarked, the bb marked columns are exactly the odd columns, each with one mark. Clean even fibers are prefixes of lengths t0,,tb{0,,b}t_0,\ldots,t_b\in\{0,\ldots,b\}. For a marked fiber RvR_v between clean fibers q,q+1q,q+1, horizontal closure gives tq+1tq1,Rvmin(tq,tq+1),bRvmin(btq,btq+1)+1. |t_{q+1}-t_q|\le1,\qquad |R_v|\le\min(t_q,t_{q+1}),\qquad b-|R_v|\le\min(b-t_q,b-t_{q+1})+1. (52) Current corners correspond to nonempty endpoint clean fibers, and outgoing corners to full ones. The distance sums in the proof of Theorem 11.3 give the same bounds here: i=j=0i=j=0 gives ab(b1)/2Φ0,0(b)a\le b(b-1)/2\le\Phi_{0,0}(b); (i,j)=(1,0)(i,j)=(1,0) gives ab2=Φ1,0(b)a\le b^2=\Phi_{1,0}(b); (i,j)=(2,1)(i,j)=(2,1) gives habb2=Ψ2,1(b)h-a-b\le b^2=\Psi_{2,1}(b); and i=j=2i=j=2 gives habb(b1)/2Ψ2,2(b)h-a-b\le b(b-1)/2\le\Psi_{2,2}(b). The pair (2,0)(2,0) is allowed. The only extra possibility at matched height bb is one full endpoint and one empty endpoint, giving (1,1)(1,1). Thus this case also follows.

The square n=2bn=2b. Again assume that no adjacent pair is unmarked. The bb unmarked columns form a maximum independent set of the 2b2b-vertex path. They are 0,2,,22;2+1,2+3,,2b1(0b). 0,2,\ldots,2\ell-2;\quad 2\ell+1,2\ell+3,\ldots,2b-1 \qquad(0\le\ell\le b). (53) Indeed bb nonadjacent positions need span at least 2b22b-2, leaving one unit of slack, at an end or at one interior gap. Every marked column has exactly one boundary vertex. Clean even fibers are prefixes and clean odd fibers suffixes; the bounds (52) apply across each single marked column.

For the pure pattern =b\ell=b, write t0,,tb1t_0,\ldots,t_{b-1} for its prefix lengths. The final odd column is marked and has just one clean neighbor. Its fiber is contained in that neighbor and differs by at most one boundary vertex. In particular tb1>0t_{b-1}>0: otherwise the final column has no source neighbor and cannot contain an actual boundary mark. Its bottom outgoing corner is consequently always present. The left current corner is present exactly when t0>0t_0>0, the left outgoing corner exactly when t0=bt_0=b. The right current corner requires tb1=bt_{b-1}=b, which forces t01t_0\ge1.

If i=0i=0, then t0=0t_0=0 and j=1j=1. Summing tqqt_q\le q and the marked bounds gives ab(b1)=Φ0,1(b)a\le b(b-1)=\Phi_{0,1}(b). The pair (1,1)(1,1) is allowed. For (1,2)(1,2) or (2,1)(2,1), a clean endpoint is full. The deficiencies are bounded by their distances from that endpoint; the marked deficiencies have one extra unit each. Their sum is at most b2b^2, so habb(b1)=Ψ1,2(b)Ψ2,1(b)h-a-b\le b(b-1)=\Psi_{1,2}(b)\le\Psi_{2,1}(b). For i=j=2i=j=2, both endpoints are full and dq=btqmin(q,b1q)d_q=b-t_q\le\min(q,b-1-q). Hence habqdq+q=0b2min(dq,dq+1)(b1)(b2)/2C2(b)=Ψ2,2(b).h-a-b\le \sum_q d_q+\sum_{q=0}^{b-2}\min(d_q,d_{q+1}) \le (b-1)(b-2)/2\le C_2(b)=\Psi_{2,2}(b). This includes b=1b=1; reflection handles =0\ell=0.

It remains to handle 1b11\le\ell\le b-1 in (53). Put d=bd=b-\ell. There are \ell clean prefixes on the left and dd clean suffixes on the right. Let the two central clean fibers be P=[0,L1]P=[0,L-1] and Q=[bR,b1]Q=[b-R,b-1]. Between them are two marked fibers A,ZA,Z, with respective marks α,β\alpha,\beta. Horizontal closure gives AP,PA{α},ZQ,QZ{β},AZ{β},ZA{α}.A\subseteq P,\quad P\setminus A\subseteq\{\alpha\},\quad Z\subseteq Q,\quad Q\setminus Z\subseteq\{\beta\},\quad A\setminus Z\subseteq\{\beta\},\quad Z\setminus A\subseteq\{\alpha\}. Thus PQ{α,β}P\mathbin\triangle Q\subseteq\{\alpha,\beta\}, and L+R2orL+R2b2. L+R\le2\quad\text{or}\quad L+R\ge2b-2. (54) The unit slopes from the center and the marked-size bounds give a2L+2dR+(1)2+(d1)2. a\le2\ell L+2dR+(\ell-1)^2+(d-1)^2. (55) For example, the clean left fibers contribute at most L+(1)/2\ell L+\ell(\ell-1)/2, their internal marked fibers at most (1)L+(1)(2)/2(\ell-1)L+(\ell-1)(\ell-2)/2, and the central marked fiber at most LL. The right calculation is identical.

First suppose L+R2L+R\le2. Equation (55) is at most b2b^2. If an outgoing corner is present, an endpoint clean fiber is full. On the left this requires bL+1b\le L+\ell-1 and hence d=1,L=2,R=0d=1,L=2,R=0; the other endpoint is empty. This is the allowed pair (1,1)(1,1), and reflection handles the right side. Therefore assume j=0j=0. For i=0i=0, bound each half from its empty outer endpoint instead: a(1)+d(d1)(b1)(b2)C2(b).a\le\ell(\ell-1)+d(d-1)\le(b-1)(b-2)\le C_2(b). For i=1i=1, the bound ab2a\le b^2 suffices. For i=2i=2 the required bound is (b1)2+1(b-1)^2+1. If L+R1L+R\le1, it follows from (55). If (L,R)=(2,0)(L,R)=(2,0), the nonempty right endpoint requires d2d\ge2, and the same equation is at most b22(d1)(+1)(b1)2+1b^2-2(d-1)(\ell+1)\le(b-1)^2+1; reflect for (0,2)(0,2). If L=R=1L=R=1 and b3b\ge3, both central marked fibers are empty. Indeed P={0}P=\{0\} and Q={b1}Q=\{b-1\}; the horizontal relations permit either both marked fibers empty or both singletons. The latter forces α=b1,β=0\alpha=b-1,\beta=0, but the upward rung out of A={0}A=\{0\} then requires 1=α1=\alpha, contradicting b3b\ge3. Removing the two central estimates gives a2+d2(b1)2+1a\le\ell^2+d^2\le(b-1)^2+1. For the sole endpoint b=2b=2, =d=L=R=1\ell=d=L=R=1, empty central fibers give a=2=Φ2,0(2)a=2=\Phi_{2,0}(2); two singletons give a=4a=4 and hab=2=Ψ2,0(2)h-a-b=2=\Psi_{2,0}(2).

Finally consider the other branch of (54), after disposing of the first: L+R>2L+R>2 and L+R2b2L+R\ge2b-2. For U=V1pN(S)U=V_{1-p}\setminus N(S) in the transpose, the clean central lengths after reflection are bL,bRb-L,b-R, totaling at most two. It is closed outside BB, so the area estimate alone gives Ub2|U|\le b^2. If its true surplus t<bt<b, its complementary branch in Theorem 11.1 is impossible because hUtb2b+1>(b1)2Ψi,j(t).h-|U|-t\ge b^2-b+1>(b-1)^2\ge\Psi_{i',j'}(t). Its small branch and the missing-corner slack give the desired Ψ\Psi bound for SS. If t=bt=b, its true boundary equals BB, and the preceding small-center proof applies to UU. A small branch gives Ψ\Psi for SS; its exception (1,1)(1,1) transfers to the same pair by zero slack. The only small-center case that instead used a complementary branch had b=2b=2 and central total two. It cannot occur here, since b=2,L+R>2b=2,L+R>2 makes the complement’s central total strictly less than two. There is therefore no circular appeal to the square theorem. This finishes every pattern. ◻

Corollary 11.8 (A symmetric critical corner rule). On every nondegenerate even-area rectangle put b=min(w,n)/2b=\left\lfloor\min(w,n)/2\right\rfloor. The Φ/Ψ\Phi/\Psi dichotomy holds at surplus bb except possibly for (i,j)=(1,1)(i,j)=(1,1) when a side equals 2b2b, or (i,j)=(2,0)(i,j)=(2,0) when a side equals 2b+12b+1.

Proof. Combine Theorems 11.3 and 11.7. The two exceptional conditions may both apply only to the near-square 2b×(2b+1)2b\times(2b+1). ◻

Retaining the corners of an erosion

Let an even-area rectangle have 4wn4\le w\le n, and put b=w/2b=\left\lfloor w/2\right\rfloor, h=wn/2h=wn/2. For a one-color support AA, let c(A)c(A) count its own-colored board corners and let e(A)e(A) count the opposite-colored corners whose two neighbors both belong to AA. Thus e(A)e(A) is the corner count of E(A)={v:N(v)A}E(A)=\{v:N(v)\subseteq A\} in the opposite color. Keeping this second count distinguishes reaching a corner from retaining both of its neighbors. It yields necessary rules for arbitrary physical beliefs.

Lemma 11.9 (One forbidden neighbor of a quadrant origin). For odd-colored supports in the whole nonnegative quadrant with one specified neighbor of the origin forbidden, the maximum cardinality at neighborhood surplus at most ss is H(0)=0,H(s)=max{s(s1)/2, s(s3)+1}(s1).H(0)=0,\qquad H(s)=\max\{s(s-1)/2,\ s(s-3)+1\}\quad(s\ge1). This asserts attainment of the maximum, not every intervening cardinality.

Proof. Compress each odd diagonal toward the permitted neighbor. This preserves the prohibition and cardinality and cannot increase the neighborhood. Use the occupied-layer notation of the punctured-quadrant proof, with surplus δ\delta, LL occupied diagonals, and ftf_t full diagonals among the first tt. The same layer bound is ajtδL+t1+fta_{j_t}\le\delta-L+t-1+f_t. If the first diagonal is empty, C3(δ)H(δ)C_3(\delta)\le H(\delta) applies. If it has one room and no diagonal is full, the no-full-layer bound is δ(δ1)/2\delta(\delta-1)/2. Otherwise the first full diagonal has occupied rank u2u\ge2 and length at least 2u2u, while the layer bound gives length at most δL+u\delta-L+u. Hence Lδ2L\le\delta-2. For t2t\ge2 use ftt1f_t\le t-1 and retain the first layer’s exact size one: A1+t=2L(δL+2t2)=1+δ(L1)1+δ(δ3).|A|\le1+\sum_{t=2}^{L}(\delta-L+2t-2) =1+\delta(L-1)\le1+\delta(\delta-3). Monotonicity of HH permits δs\delta\le s. Proper initial diagonal counts 1,2,,s11,2,\ldots,s-1 attain the first branch. For s5s\ge5, a full odd triangle of surplus s1s-1, with the forbidden origin neighbor deleted, retains its neighborhood and has size (s1)(s2)1=s(s3)+1(s-1)(s-2)-1=s(s-3)+1. The empty endpoints are immediate. ◻

For 0i20\le i\le2 and 0uj20\le u\le j\le2, put z=si2jz=s-i-2j and define Pi,u,j(s)={,z<0,i+j+u+z2+3z,z0, u>0,i+j+z2+2z,z0, u=0<i,j1+H(z+2),z0, i=u=0<j,C2(s),s0, i=u=j=0. \mathcal P_{i,u,j}(s)= \begin{cases} -\infty,&z<0,\\ i+j+u+z^2+3z,&z\ge0,\ u>0,\\ i+j+z^2+2z,&z\ge0,\ u=0<i,\\ j-1+H(z+2),&z\ge0,\ i=u=0<j,\\ C_2(s),&s\ge0,\ i=u=j=0. \end{cases} (56) It uses a fixed number of numerical operations and satisfies Pi,u,j(s)Φi,j(s)s2\mathcal P_{i,u,j}(s)\le\Phi_{i,j}(s)\le s^2 whenever finite.

Theorem 11.10 (Erosion-corner dichotomy). Let SS be one-colored, B=N(S)B=N(S), and set q=S,i=c(S),u=e(S),t=B,j=c(B),v=e(B),s=tq.q=|S|,\quad i=c(S),\quad u=e(S),\qquad t=|B|,\quad j=c(B),\quad v=e(B),\quad s=t-q. Then uju\le j, ivi\le v, and, for 0s<b0\le s<b, qPi,u,j(s)orhtΦ2j,2v(s+iv). q\le\mathcal P_{i,u,j}(s) \quad\text{or}\quad h-t\le\Phi_{2-j,2-v}(s+i-v). (57) For odd w=2b+1w=2b+1 and even nwn\ge w, this also holds at s=bs=b unless (i,j)=(2,0)(i,j)=(2,0); that exception necessarily has u=0,v=2u=0,v=2. The refined critical assertion here does not include even ww.

Proof. The two feature inequalities follow directly from the definition of a neighborhood. In the small side of the matching separation proof of Theorem 11.1, the ii required even-origin pieces consume surplus one and area one each. Of the jj touched odd origins, uu have both neighbors present and juj-u have exactly one. They consume surplus two each, with respective initial areas two and one. The remaining surplus is zz. Discrete convexity concentrates it in one piece. The gains for a required two-neighbor odd piece, a required even piece, and a required one-neighbor odd piece are respectively z2+3z,z2+2z,H(z+2)1=max{z(z+3)/2,z2+z2}.z^2+3z,\qquad z^2+2z,\qquad H(z+2)-1=\max\{z(z+3)/2,z^2+z-2\}. The third gain lies between C2(z)C_2(z) and z2+2zz^2+2z; an optional piece gains at most C2(z)C_2(z). This proves the four branches of (56).

On the other side, put U=V1pBU=V_{1-p}\setminus B. The identity E(B)=VpN(U)E(B)=V_p\setminus N(U) gives the exact counts c(U)=2jc(U)=2-j, c(N(U))=2vc(N(U))=2-v. If σ=N(U)U\sigma=|N(U)|-|U|, the slack (VpS)N(U)(V_p\setminus S)\setminus N(U) has size sσs-\sigma and contains viv-i corners. Thus σs+iv\sigma\le s+i-v. The same common matching component and separators put UU on the small side. Applying its Φ\Phi capacity proves the second alternative.

At critical odd width, the separator case is unchanged. In the alternating-column case of the critical corner proof, the possible corner pairs are (0,0),(1,0),(2,0),(2,1),(2,2)(0,0),(1,0),(2,0),(2,1),(2,2). In the first two, u=0u=0 and the refined small capacity equals the old one. The middle pair is the stated exception. In the last two, v=2v=2 and the fixed dual capacity Φ2j,0(b)\Phi_{2-j,0}(b) equals the previous Ψ2,j(b)\Psi_{2,j}(b), so the same deficiency bound applies. ◻

Proposition 11.11 (Corner closure and retention). In the preceding notation, put δ=vi\delta=v-i and σ=sδ\sigma=s-\delta. Then σ0\sigma\ge0. Whenever σ\sigma is in the theorem’s proved range, its stronger closed form is q+δPv,u,j(σ)orhtΦ2j,2v(σ),q+\delta\le\mathcal P_{v,u,j}(\sigma) \quad\text{or}\quad h-t\le\Phi_{2-j,2-v}(\sigma), with the same critical exception σ=b,(v,j)=(2,0)\sigma=b,(v,j)=(2,0) on odd width. This applies even when the original surplus ss exceeds bb.

Every physical transition from a belief with features (a,c,e)(a,c,e) can be realized, at no larger inspection cost pp, with survivor features (q,i,u)(q,i,u) satisfying q=ap,ic,ue,(ci)+(eu)p,imax{0,c+v2}.q=a-p,\quad i\le c,\quad u\le e,\quad (c-i)+(e-u)\le p,\quad i\ge\max\{0,c+v-2\}. Every physical feature (a,c,e)(a,c,e) satisfies c+2eah4+c+ec+2e\le a\le h-4+c+e.

Proof. Adjoin to SS its viv-i missing own-colored corners in E(B)E(B). Their neighbors are already in BB, so the neighborhood stays BB. They are disjoint from the opposite-corner neighbor pairs, so uu is unchanged. The augmented support has features (q+δ,v,u)(q+\delta,v,u) and surplus σ0\sigma\ge0 by the board’s perfect matching. Apply the theorem. These adjoined corners are used only in the inequality and need not belong to the previous belief.

For retention, replace an actual survivor by AE(B)A\cap E(B). It contains the original survivor, has neighborhood exactly BB, and costs no more inspections. Its own corners are the intersection of two subsets of a two-element set of sizes c,vc,v, giving the lower bound on ii. The two own corners and the two opposite-corner neighbor pairs are pairwise disjoint when both sides are at least four. Removing an own corner and destroying an eroded corner therefore require distinct inspected rooms, proving the combined deletion charge. The same disjointness proves the feature lower bound and forces at least (2c)+(2e)(2-c)+(2-e) missing rooms, proving the upper bound. Since retention may reduce cost, all costs pkp\le k must be allowed in a necessary model. ◻

Equality at the pronic corner capacity

The corner bounds give a uniform history restriction at every radius where the odd-corner capacity is attained. The critical even-square endpoint must retain the corners reached across both sides.

Theorem 11.12 (Pronic rigidity on every even-area rectangle). Let 4wn4\le w\le n, wnwn be even, b=w/2b=\left\lfloor w/2\right\rfloor, and h=wn/2h=wn/2. If 2rb2\le r\le b and a one-color support SS satisfies S=r(r1),N(S)S=r,c(S)=0,|S|=r(r-1),\qquad |N(S)|-|S|=r,\qquad c(S)=0, then it is exactly a full odd triangle based at an opposite-colored board corner, with relative diagonals 1,3,,2r31,3,\ldots,2r-3. In particular, N(S)N(S) has features (r2,1,0)(r^2,1,0) in the notation of Section 11.4. Its second neighborhood contains exactly κ\kappa corners of the original color, where κ={0,r<b or w is odd,1,r=b, w is even, n>w,2,r=b, w=n is even. \kappa= \begin{cases} 0,&r<b\text{ or }w\text{ is odd},\\ 1,&r=b,\ w\text{ is even},\ n>w,\\ 2,&r=b,\ w=n\text{ is even}. \end{cases} (58) Consequently the next belief after any inspections of N(S)N(S) has at most κ\kappa such corners.

Proof. Apply the subcritical or critical corner dichotomy. Its critical exceptions have current-corner count one or two, so neither applies. The complementary side has size hr2r2h-r^2\ge r^2, whereas every finite Ψ0,j(r)\Psi_{0,j}(r) is strictly less than r2r^2. Thus the small branch holds. Its capacities for j=0,2j=0,2 are strictly below r(r1)r(r-1), so j=1j=1 and equality holds in Φ0,1(r)=r(r1)\Phi_{0,1}(r)=r(r-1).

When the proof uses quadrant separation, equality in its convex surplus allocation puts all surplus into the required odd-origin component. Equality in the diagonal-layer capacity bound makes every initial odd diagonal full. Compression preserved every diagonal’s cardinality, so the original support itself is that full triangle.

At a critical endpoint, the proofs of Theorems 11.3 and 11.7 supply the other possible decompositions. The odd-width and near-square alternating cases with no current corner have no outgoing corner and therefore cannot give j=1j=1. In the even square’s pure alternating case, equality forces successive clean-fiber lengths 0,1,,b10,1,\ldots,b-1 and equality in every intermediate and final fiber bound; these are exactly the same triangle. The mixed square case with no current corner has no outgoing corner and is again excluded.

In a single critical whole-half-strip piece, a boundary-free matched row reduces to the quadrant case. If no such row exists, each matched row has one outside-boundary vertex and its occupied set is an initial interval of length cic_i. The omitted current corner gives c0=0c_0=0; alternating rungs give ci+1ci+2c_{i+1}\le c_i+2. Equality in i=0b1cii=0b12i=b(b1)\sum_{i=0}^{b-1}c_i\le\sum_{i=0}^{b-1}2i=b(b-1) forces ci=2ic_i=2i for every ii. In physical coordinates x=2i+(ymod2)x=2i+(y\bmod2) these intervals are the odd triangle based at (2b1,0)(2b-1,0). This verifies the half-strip equality case directly.

The first neighborhood has relative even diagonals through 2r22r-2, so its size is r2r^2 and its own corner count is one. At any other board corner reached by the second neighborhood, exactly one of its neighbors lies in that first neighborhood; therefore e(N(S))=0e(N(S))=0. The second neighborhood has radius 2r12r-1. Among original-colored corners it can reach precisely those across an even board side of length at most 2r2r. This gives (58). Inspections only decrease the following neighborhood. ◻

Corollary 11.13 (Dual pronic restriction). Under the same board and radius assumptions, suppose S=hr2,N(S)S=r,c(N(S))=2.|S|=h-r^2,\qquad |N(S)|-|S|=r,\qquad c(N(S))=2. Then c(S)=e(N(S))=1c(S)=e(N(S))=1 and e(S)=2κe(S)=2-\kappa.

Proof. Let U=V1pN(S)U=V_{1-p}\setminus N(S). It has size r(r1)r(r-1), no own corner, and surplus at most rr. The unconditional size profile forces surplus at least rr: its square term is rr, the width cap is at least rr, and the complementary pronic term is at least rr since hr(r1)r(r+1)h-r(r-1)\ge r(r+1). Hence its surplus is exactly rr and N(U)=VpSN(U)=V_p\setminus S. The theorem makes UU a full odd triangle. Its neighborhood contains one corner, so SS contains the other one. An opposite-colored corner has both neighbors in SS exactly when it is absent from N2(U)N^2(U), giving e(S)=2κe(S)=2-\kappa. Finally E(N(S))=VpN(U)=SE(N(S))=V_p\setminus N(U)=S, so e(N(S))=1e(N(S))=1. ◻

These are physical restrictions on every strategy. They may be imposed as a one-step memory and a dual transition condition in a necessary model. Their validity does not assert that the remaining model paths are physically attainable. In particular, the zero-corner continuation valid on odd widths cannot be imposed at the critical even-square radius.

Localization throughout the pronic band

Exact equality is not needed to recover a support’s corner location. Throughout this section let w=2b+15w=2b+1\ge5, let nwn\ge w be even, and put h=wn/2,C=b(b1),D=C2(b)=max{b(b1)/2,b(b2)}.h=wn/2,\qquad C=b(b-1),\qquad D=C_2(b)=\max\{b(b-1)/2,b(b-2)\}. Write c(A)c(A) for the number of own-colored board corners in AA. Write e(A)e(A) for the number of opposite-colored corners whose two neighbors both belong to AA.

Theorem 11.14 (Localization above the omitted-corner capacity). Let UU be a one-color support with c(U)=0c(U)=0 and D<UC,N(U)Ub.D<|U|\le C,\qquad |N(U)|-|U|\le b. Its surplus is exactly bb, and it is connected under the relation of sharing a neighbor. There is exactly one board corner oN(U)o\in N(U), and every uUu\in U has Manhattan distance at most 2b32b-3 from oo.

Proof. Consider any nonempty sharing-neighbor component UiU_i and its surplus sibs_i\le b. Theorems 11.1 and 11.3 apply with current-corner count zero. Their critical exception is unavailable, and the large branch is excluded by hUisihb2>b2Ψ0,j(si).h-|U_i|-s_i\ge h-b^2>b^2\ge\Psi_{0,j}(s_i). Hence Uisi(si1)|U_i|\le s_i(s_i-1) and si2s_i\ge2. Components have disjoint neighborhoods, so their sizes and surpluses add. For b4b\ge4, two or more components have total size at most (b2)(b3)+2D,(b-2)(b-3)+2\le D, by convex allocation of their surplus; for b<4b<4, two components already cost too much surplus. Thus UU is connected. Surplus at most b1b-1 would give U(b1)(b2)D|U|\le(b-1)(b-2)\le D, so its surplus is bb. The bounds Φ0,0(b)=D\Phi_{0,0}(b)=D and Φ0,2(b)D\Phi_{0,2}(b)\le D then force exactly one outgoing corner oo.

The critical separator proof supplies an actual corner quadrant here. Indeed the longitudinal matching has more than bb rows, so a row avoids the boundary. If no adjacent columns avoid it, the alternating case with current-corner count zero has outgoing-corner count zero, contrary to the preceding conclusion. Otherwise the two separators split the source or its transposed complement into quadrants; the complement case was excluded by the large-branch inequality above. Their neighborhoods agree with the whole-quadrant neighborhoods. Connectedness therefore puts all of UU in the quadrant based at oo.

No compression is needed to bound its radius. Touching oo makes diagonal 11 occupied. A sharing-neighbor step changes the diagonal index by zero or two, so its occupied diagonals are 1,3,,2L11,3,\ldots,2L-1 without gaps. The upper shadow of each occupied diagonal has at least one more room than that diagonal’s support: for a nonempty finite integer set XX, X(X+1)X+1|X\cup(X+1)|\ge|X|+1. These upper shadows are disjoint, and the output origin supplies one additional room. Consequently N(U)U+L+1,Lb1,|N(U)|\ge|U|+L+1, \qquad L\le b-1, which gives the stated radius. ◻

Corollary 11.15 (Dual feature rule throughout the pronic band). Let SS be a one-color survivor, put B=N(S)B=N(S), and suppose c(B)=2,D<hBC,BSb.c(B)=2,\qquad D<h-|B|\le C,\qquad |B|-|S|\le b. Then BS=b,c(S)=1,e(S)=2,e(B)=1.|B|-|S|=b,\qquad c(S)=1,\qquad e(S)=2,\qquad e(B)=1.

Proof. Put U=VoppBU=V_{\mathrm{opp}}\setminus B. Its own corners are absent, and N(U)VsrcSN(U)\subseteq V_{\mathrm{src}}\setminus S, so its surplus is at most BSb|B|-|S|\le b. The localization theorem makes that surplus exactly bb. Equality of sizes follows throughout, giving N(U)=VsrcSN(U)=V_{\mathrm{src}}\setminus S and BS=b|B|-|S|=b. The unique corner of N(U)N(U) gives c(S)=1c(S)=1. Also N2(U)N^2(U) lies within radius 2b12b-1 of its localization corner, whereas every opposite-colored corner has distance at least n12b+1n-1\ge2b+1. Thus both such corners have all their neighbors in SS, giving e(S)=2e(S)=2. Finally E(B)=VsrcN(U)=SE(B)=V_{\mathrm{src}}\setminus N(U)=S, so e(B)=c(S)=1e(B)=c(S)=1. ◻

Corollary 11.16 (No consecutive transitions into the pronic band). For a physical inspection transition AA=N(AI)A\longmapsto A'=N(A\setminus I), put p=IAp=|I\cap A| and s=AA+ps=|A'|-|A|+p. Consider the condition c(A)=2,D<hAC,sb. c(A')=2,\qquad D<h-|A'|\le C,\qquad s\le b. (59) Two consecutive transitions cannot both satisfy (59), regardless of their inspection budgets.

Proof. The first transition has e(A)=1e(A')=1 by Corollary 11.15. Every next survivor SAS'\subseteq A' therefore has e(S)1e(S')\le1, whereas another transition satisfying (59) would require e(S)=2e(S')=2. ◻

The existing erosion-corner feature thus records this restriction without an additional history bit. No assertion that the features characterize arbitrary reachable beliefs is needed.

Two individually possible cleared regions on an 11×1211\times12 board, of sizes 17 and 18, each with surplus five. The gray region is the neighborhood of the proposed second region. At zero complement slack, every first-region room would have to lie there; the circled room prevents this. The localization proof applies to arbitrary supports in the stated band, not only the prefixes drawn here.

A near-square rigidity and a boundary-history obstruction

The corner capacities contain geometric information beyond their numerical values. Close to the square capacity, a support cannot spread across distant diagonals.

Theorem 11.17 (Near-square localization). Let UU be a finite even-color support in the nonnegative quadrant, with N(U)Us|N(U)|-|U|\le s, where s1s\ge1. If U>s(s1),|U|>s(s-1), then U{(x,y):x+y{0,2,,2s2}}.U\subseteq\{(x,y):x+y\in\{0,2,\ldots,2s-2\}\}. In particular, UU lies inside the s2s^2-room triangle based at the origin.

Proof. Apply the diagonal compression used in the proof of Theorem 4.1, which preserves the number of rooms on each diagonal. Use its notation aj,δj,La_j,\delta_j,L, with compressed surplus δs\delta\le s. The branch with no full diagonal has at most s(s1)/2s(s-1)/2 rooms and is excluded. In the other branch, that proof gives LδL\le\delta and ULδ|U|\le L\delta. Hence U>s(s1)|U|>s(s-1) forces L=δ=sL=\delta=s. Each occupied diagonal contributes at least one to the surplus, so δj=1\delta_j=1 there and every other contribution, including δ1\delta_{-1}, is zero.

There can be no initial or internal gap before an occupied diagonal j1j\ge1. Such a gap would give 0=δj1ajϵj0=\delta_{j-1}\ge a_j-\epsilon_j, forcing the nonempty diagonal to be full of size one, whereas its length is 2j+1>12j+1>1. Thus the occupied diagonals are exactly 0,,s10,\ldots,s-1. Their cardinalities were unchanged by compression, so the same localization holds for the original support. ◻

If a support is in the small branch of the finite-board quadrant decomposition, the same threshold forces it into one genuine corner quadrant. Indeed, if at least two nonempty pieces have positive integer surpluses summing to at most ss, their capacities are at most (s1)2+1s(s1)(s2).(s-1)^2+1\le s(s-1)\qquad(s\ge2). The case s=1s=1 cannot have two nonempty pieces. A surviving single quadrant must be based at an occupied corner of the support’s color: the other corner and omission profiles have capacity at most s(s1)s(s-1). After a reflection, Theorem 11.17 applies.

Proposition 11.18 (A physical boundary-history barrier). On the 24×2424\times24 board with daily budget 1313, a solo history starting from an entire color class has at least 177177 possible rooms after 2828 unsuccessful inspection-and-move steps. Consequently its guaranteed solo capture time is at least 103103 days.

Proof. The finite necessary corner model admits no state smaller than 176176 at that time, and its only 176176-room feature has one occupied corner. Suppose a physical history reached such a belief AA, and set U=VpAU=V_p\setminus A. Thus U=112|U|=112 and UU has one corner of its color. Reversing the first 2828 inspections gives a 2828-day capture strategy from N(U)N(U): an avoiding path there, preceded by its edge from UU, would reverse to an original avoiding path ending in UU.

A checked lower potential on the same necessary model assigns at least 2929 days to every feature of size at least 124124. Hence N(U)123|N(U)|\le123. The unconditional profile gives the reverse inequality, so N(U)=123|N(U)|=123 and the surplus is 1111. In the finite corner dichotomy, the large branch is impossible: its complementary size is 165165, exceeding each relevant dual capacity. The small branch also forces zero outgoing corners. Since 112>1110112>11\cdot10, the preceding localization places UU in a single genuine corner triangle of size 121121.

Reflect this corner to the origin and apply the simultaneous square diagonal strategy compression CC. The triangle is fixed, so C(U)C(U) still lies in it and has size 112112. Moreover N(C(U))C(N(U))N(C(U))\subseteq C(N(U)). The unconditional profile and cardinality preservation give both sets size 123123, hence equality. There are exactly eight fixed pyramid supports obtained by deleting nine rooms from the 121121-room triangle. Their neighborhoods all have size 123123. An independent finite certificate excludes capture in 2828 days from each such neighborhood.

For completeness, the certificate uses 146146 failed states for the anchored prefix and one additional failed initial state for each of the other seven neighborhoods. An independent verifier enumerates every full-quota survivor by local-maximum deletion, computes literal board neighborhoods, and checks either a decreasing-time certificate edge or a separately checked lower-potential inequality. Thus it covers all pyramid strategies. The fixed-state clause of Theorem 3.2 makes this an unrestricted lower bound from each of these initial pyramids. Strategy comparison gives T13(N(U))T13(C(N(U)))=T13(N(C(U)))29,T_{13}(N(U))\ge T_{13}(C(N(U))) =T_{13}(N(C(U)))\ge29, contradicting the reversed 2828-day strategy.

Finally, recomputing the necessary solo model with this physical time-2828 barrier removes every 102102-day path; its minimum becomes 103103. This last finite calculation retains every allowed target, not merely a path attaining the successive minimum cardinalities. ◻

The physical restriction in this proposition cannot automatically be imposed on the synthetic merger of two cohorts. The following finite equality check supplies the required additional bridge.

Corollary 11.19 (The remaining 24×2424\times24 bracket). For the full board, 206T13(24,24)207.206\le T_{13}(24,24)\le207.

Proof. The established subcritical-model merger maps a pair of cohort features (a,c),(b,d)(a,c),(b,d) to (a+b288,max(0,c+d2))(a+b-288,\max(0,c+d-2)) while the merged size exceeds the budget. Its shortest solo path from (288,2)(288,2) to (176,1)(176,1) has length 2828. Consequently, any joint history attaining merged feature (176,1)(176,1) at that time maps to a shortest path: at stage tt, its merged feature has forward distance tt and backward distance 28t28-t.

A finite equality certificate enumerates every component-feature pair over these shortest-path layers and every allowed combined-quota transition. Its unique terminal pair is ((176,1),(288,2)).((176,1),(288,2)). Thus equality forces one cohort still to be full and the other to have the physical belief excluded by Proposition 11.18. This conclusion uses the final pair, and does not assume that the full cohort was never inspected earlier. Therefore every physical merged history also obeys the time-2828 restriction.

An independent verifier rebuilds the weighted relations from separate budget-indexed bitset relations and expands component transitions. It checks 380358380\,358 weighted edges and 6629566\,295 equality-graph transitions. The resulting time-filtered subcritical solo model has clock 103103 and minimum remaining size 99 after 102102 steps. The guarded merger therefore shows that every full-board history of 102102 unsuccessful steps leaves at least 288+9=297288+9=297 possible rooms. For a purported 205205-day strategy, apply this to its first 102102 inspections and to its final 102102 inspections in reverse order. Their central possible sets intersect in at least 2297576=182\cdot297-576=18 rooms, exceeding the central budget 1313. This proves the lower bound 206206.

For the upper bound, the independently replayed 104104-day solo construction ends with a two-room final inspection. Use its first 103103 inspections, then the union of that final inspection with its horizontal reflection, then the reversed horizontal reflections of the first 103103 inspections. The central day uses four inspections, and every other day uses at most 1313. Literal full-board replay verifies capture by day 207207. ◻

Concentration in the necessary corner model

The corner-count inequality also admits a concentration principle. This reduces a lower-bound calculation to one cohort; it does not assert that the model’s paths are physically attainable. We first prove the principle for the base model below, then prove its closure under critical-surplus filters and one geometric memory rule. The additional restrictions are not inferred automatically from the base merger theorem.

A feature (a,c)(a,c) satisfies c{0,1,2}c\in\{0,1,2\} and cah2+cc\le a\le h-2+c. A cost-pp transition, 0pk0\le p\le k, chooses a valid survivor feature (q,i)(q,i) with q=ap,max{0,cp}ic,q=a-p,\qquad \max\{0,c-p\}\le i\le c, and a valid target (t,j)(t,j). For q=0q=0 require (t,j)=(0,0)(t,j)=(0,0). Otherwise put s=tq0s=t-q\ge0, require the size profile of Theorem 9.1, and, when s<bs<b, require qΦi,j(s)orhqsΨi,j(s).q\le\Phi_{i,j}(s) \quad\text{or}\quad h-q-s\le\Psi_{i,j}(s). At sbs\ge b impose no further corner condition. Every physical transition is included by Corollary 11.2. Joint transitions allocate a total of at most kk inspections to two features.

Theorem 11.20 (Merger before a solo clearing day). Let b1b\ge1, h2b2h\ge2b^2, and 1k<h1\le k<h. Define M((a,c),(a,c))=(a+ah,(c+c2)+).\mathcal M\bigl((a,c),(a',c')\bigr) =\bigl(a+a'-h,\left(c+c'-2\right)_+\bigr). If the merged source has size greater than kk, every joint model transition induces a solo model transition from the merged source to the exact merged target, using the same total inspection cost.

Proof. We first record the needed capacity algebra. Write A=2iA=2-i, B=2jB=2-j. Expanding the at most three candidates in (50) gives Ψi,j(s)=\Psi_{i,j}(s)=-\infty for s<A+Bs<A+B. For z=sAB0z=s-A-B\ge0 it gives Ψi,j(s)={z2+2z+B,B>0,z2+z,B=0<A,C2(z),A=B=0. \Psi_{i,j}(s)= \begin{cases} z^2+2z+B,&B>0,\\ z^2+z,&B=0<A,\\ C_2(z),&A=B=0. \end{cases} (60) For j<2j<2, the d=0d=0 candidate dominates: writing v=s+i+j3v=s+i+j-3, its differences from the d=1,2d=1,2 candidates are v1,3v5v-1,3v-5, and feasibility of the latter gives vd+1v\ge d+1. For j=2,i<2j=2,i<2, the d=1d=1 candidate dominates whenever feasible; at the initial argument the d=0d=0 value is zero and agrees with (60). The case i=j=2i=j=2 has only d=0d=0. In particular every finite Ψi,j(s)\Psi_{i,j}(s) is at most s2s^2.

The dual capacities are superadditive under the merger of corner counts: Ψi1,j1(s1)+Ψi2,j2(s2)Ψ(i1+i22)+,(j1+j22)+(s1+s2) \Psi_{i_1,j_1}(s_1)+\Psi_{i_2,j_2}(s_2) \le\Psi_{\left(i_1+i_2-2\right)_+,\left(j_1+j_2-2\right)_+}(s_1+s_2) (61) whenever both left terms are finite. Indeed the merged missing counts are A=min{2,A1+A2}A=\min\{2,A_1+A_2\} and B=min{2,B1+B2}B=\min\{2,B_1+B_2\}. Put δ=A1+A2A+B1+B2B0\delta=A_1+A_2-A+B_1+B_2-B\ge0. The new variable is z=z1+z2+δz=z_1+z_2+\delta. If B>0B>0, bound each source term by zl2+2zl+Blz_l^2+2z_l+B_l. The difference from the target is at least 2z1z2+2δ(z1+z2)+δ2+2δ(B1+B2B)0.2z_1z_2+2\delta(z_1+z_2)+\delta^2+2\delta-(B_1+B_2-B)\ge0. If B=0<AB=0<A, use the source bounds zl2+zlz_l^2+z_l instead. If A=B=0A=B=0, all four missing counts vanish and convexity of C2C_2, with C2(0)=0C_2(0)=0, gives its superadditivity. This proves (61).

Two deletion inequalities handle the other combination: Φ(i1)+,j(s+1)Φi,j(s)1,Φi,(j1)+(s+1)Φi,j(s). \Phi_{\left(i-1\right)_+,j}(s+1)\ge\Phi_{i,j}(s)-1,\qquad \Phi_{i,\left(j-1\right)_+}(s+1)\ge\Phi_{i,j}(s). (62) For positive jj, deleting a current corner increases the pronic quadratic. At j=0,i=2j=0,i=2 compare (s+1)2(s+1)^2 with 1+(s1)21+(s-1)^2; at j=0,i=1j=0,i=1 use C2(s+1)s21C_2(s+1)\ge s^2-1. For the second inequality, j=2j=2 gives a larger pronic quadratic; j=1,i>0j=1,i>0 gives a larger square; and j=1,i=0j=1,i=0 uses C2(s+1)s21s(s1)C_2(s+1)\ge s^2-1\ge s(s-1). A zero index uses monotonicity. These comparisons also preserve the domains of the capacities.

Let the chosen survivors be (ql,il)(q_l,i_l), the targets (tl,jl)(t_l,j_l), and the costs plp_l. Put Q=q1+q2h>0,T=t1+t2h,sl=tlql,s=s1+s2,Q=q_1+q_2-h>0,\quad T=t_1+t_2-h,\quad s_l=t_l-q_l,\quad s=s_1+s_2, I=(i1+i22)+,J=(j1+j22)+.I=\left(i_1+i_2-2\right)_+,\qquad J=\left(j_1+j_2-2\right)_+. If s<bs<b, both component profiles are subject to the corner inequality. They cannot both use its small branch: that would give q1+q2s12+s22s2<b2<hq_1+q_2\le s_1^2+s_2^2\le s^2<b^2<h. If both use its complementary branch, their complement sizes add and (61) gives the complementary merged branch. If one is small, call its counts i,ji,j and surplus uu. Let the other omit AA current corners and BB outgoing corners, have surplus vv, and leave complement size d=hthigh0d=h-t_{\rm high}\ge0. Equation (60) gives vA+Bv\ge A+B. Applying (62) AA and BB times gives Φ(iA)+,(jB)+(u+v)Φi,j(u)A.\Phi_{\left(i-A\right)_+,\left(j-B\right)_+}(u+v)\ge\Phi_{i,j}(u)-A. But Q=qsmall(v+d)Q=q_{\rm small}-(v+d) and v+dAv+d\ge A. The small merged branch follows. Either branch implies the unconditional size profile. For sbs\ge b, that profile is automatic.

It remains to check feature validity. If the merged source is (m,c)(m,c), then m>k1m>k\ge1 gives m2cm\ge2\ge c, and adding the source upper bounds gives mh2+cm\le h-2+c. The only invalid raw survivor possibility is Q=1,I=2Q=1,I=2; choose I=min{Q,I}I^*=\min\{Q,I\}. The inspection inequalities survive because both II and Q=mp1p2Q=m-p_1-p_2 are at least cp1p2c-p_1-p_2, and IcI\le c. All survivor upper bounds also hold. In the subcritical complementary/ complementary case, Qhss2b2+b2,Q\ge h-s-s^2\ge b^2+b\ge2, so no clipping occurs. In the mixed case Φ1,J(s)Φ2,J(s)\Phi_{1,J}(s)\ge\Phi_{2,J}(s) preserves the proved small bound: for J=0J=0 compare s2s^2 with 1+(s1)21+(s-1)^2, and for J>0J>0 use the pronic formula. At sbs\ge b the profile does not depend on II.

The target upper bound follows by adding the two original upper bounds. Its lower bound could fail only at T=1,J=2T=1,J=2. Then Q=1,s=0Q=1,s=0; both nonempty original survivors have zero surplus, so the size profile forces q1=q2=hq_1=q_2=h, contradicting Q=1Q=1. Thus (T,J)(T,J) is valid. The chosen survivor (Q,I)(Q,I^*) and target (T,J)(T,J) constitute the required solo transition of cost p1+p2p_1+p_2. ◻

Corollary 11.21 (Closure under critical filters). The merger theorem remains valid if an additional condition is imposed at surplus bb, provided that it retains every profile satisfying the Φ/Ψ\Phi/\Psi alternative. Keep the base rule at surplus greater than bb.

Proof. Only total surplus bb is new. If both component surpluses are below bb, the same capacity algebra applies. The two small branches are impossible since their survivor sizes sum to at most b2<hb^2<h. In the two complementary branches, Qhbb2b2b2Q\ge h-b-b^2\ge b^2-b\ge2 when b2b\ge2, so clipping is still unnecessary. When b=1b=1, two subcritical surpluses cannot sum to bb. Mixed-case clipping preserves Φ\Phi as in the theorem. The merged profile is therefore retained by the assumed filter.

If one component has surplus bb, the other has surplus zero. Its survivor is nonempty and the size profile forces it to be full. Its source and target are consequently full and its cost is zero. The merger is the identity on the critical component, which already obeys the filter. ◻

Corollary 11.22 (Closure under the odd-triangle memory rule). On w=2b+1w=2b+1, with even nwn\ge w and b2b\ge2, equip the necessary model with the following flag, initially zero. A transition sets its new flag to one exactly when its chosen survivor and target satisfy q=b(b1),i=0,s=b,(t,j)=(b2,1).q=b(b-1),\quad i=0,\quad s=b,\quad (t,j)=(b^2,1). Every other transition resets the flag to zero. A flagged source permits only targets with zero corners. Every physical history satisfies this rule, and the precapture merger remains valid for the augmented model.

Proof. Physical necessity is Corollary 11.4. Define the merged history’s flag from its own preceding action. We show that a newly flagged merged state comes from a flagged component with the other component full. Its total surplus is bb. If both component surpluses are below bb, the mixed case would give Qqsmall(b1)2<b(b1),Q\le q_{\rm small}\le(b-1)^2<b(b-1), whereas the two complementary branches would give hb2Ψ0,1(b)(b2)2<b2hb2.h-b^2\le\Psi_{0,1}(b)\le(b-2)^2<b^2\le h-b^2. Both are impossible; the two small branches were already excluded. Thus one component has surplus bb and the other is a zero-cost full-to-full action. The merger is the identity on the first, so it receives the same flag.

If the current merged flag is one, its flagged component has next corner count zero. The merged next count is therefore (0+jother2)+=0\left(0+j_{\rm other}-2\right)_+=0, satisfying the flag restriction. When the merged action does not trigger, its own flag resets to zero; no assertion that it equals the disjunction of the component flags is needed. Induction proves the claimed history merger. ◻

Corollary 11.23 (A one-cohort lower clock). Let τ^\widehat\tau be the finite minimum solo capture time in this necessary model (including either preceding augmentation), starting from (h,2)(h,2), and let ftf_t be its minimum reachable belief size after tt inspections and moves. For every t<τ^t<\widehat\tau, the minimum joint model total size is exactly h+fth+f_t. Consequently every physical strategy satisfies Tk(w,n)2τ^1,Tk(w,n)2τ^if 2fτ^1>k.T_k(w,n)\ge2\widehat\tau-1, \qquad T_k(w,n)\ge2\widehat\tau \quad\text{if }2f_{\widehat\tau-1}>k.

Proof. Merge the full joint start into (h,2)(h,2). Inductively, if a merged source had size at most kk before the last required transition, the solo path already constructed could clear on the next day, before τ^\widehat\tau. Hence Theorem 11.20 applies at every step up to time t<τ^t<\widehat\tau. It gives joint size at least h+fth+f_t. Equality is attained in the model by following a minimizing solo path while leaving the other cohort full.

Put L=τ^1L=\widehat\tau-1. A supposed 2L2L-day physical capture has a forward belief after LL inspections and moves of size greater than hh. Read its final LL inspections backward: after the first L1L-1 moves the reverse belief has at least h+fL1>h+kh+f_{L-1}>h+k rooms, and its last inspection leaves more than hh. The two sets occupy the same cut and intersect, giving an avoiding walk. Thus at least 2τ^12\widehat\tau-1 days are needed. For a (2L+1)(2L+1)-day search, the two beliefs at the central day each have at least h+fLh+f_L rooms. Their intersection has at least 2fL2f_L rooms, which must all be inspected centrally. This proves the second bound. ◻

The clock is an exact evaluator inside the necessary model. Neither the merger theorem nor the lower-clock corollary asserts physical attainment of its solo paths or a fixed-size formula for its numerical value.

Concentration with eroded-corner information

The enriched inequalities still admit a one-cohort lower calculation. One deliberate relaxation makes the merger closed: for positive states we retain the upper feature bound but omit the lower cardinality bound. This only adds states to a necessary model. The theorem concerns odd-width, even-length rectangles, where the enriched critical profile has been proved; it does not assert physical attainment of model paths.

Let b2b\ge2, h2b2h\ge2b^2, and 1k<h1\le k<h. A feature (a,c,e)(a,c,e) satisfies c,e{0,1,2},0ah4+c+e,a=0c=e=0.c,e\in\{0,1,2\},\qquad 0\le a\le h-4+c+e, \qquad a=0\Longrightarrow c=e=0. We omit c+2eac+2e\le a when a>0a>0, and omit its survivor counterpart. The full feature is still necessarily (h,2,2)(h,2,2). A cost-pp action, 0pmin{k,a}0\le p\le\min\{k,a\}, chooses q=apq=a-p. If q=0q=0, its target is empty. Otherwise choose a survivor (q,i,u)(q,i,u) obeying the retained feature bound and ic,ue,(ci)+(eu)p,i\le c,\quad u\le e,\quad(c-i)+(e-u)\le p, and a target (t,j,v)(t,j,v) obeying the feature bound, with tqt\ge q, uju\le j, ivi\le v. Require the size profile and the maximal-retention condition i(c+v2)+i\ge\left(c+v-2\right)_+. Writing s=tq,δ=vi,x=q+δ,σ=sδ,s=t-q,\quad\delta=v-i,\quad x=q+\delta,\quad\sigma=s-\delta, require σ0\sigma\ge0. Whenever σb\sigma\le b, require xPv,u,j(σ)orhtΦ2j,2v(σ)orσ=b,(v,j)=(2,0). x\le\mathcal P_{v,u,j}(\sigma) \quad\text{or}\quad h-t\le\Phi_{2-j,2-v}(\sigma) \quad\text{or}\quad \sigma=b, (v,j)=(2,0). (63) Here P\mathcal P is (56). The reduced surplus controls this filter even when s>bs>b. Theorem 11.10 and Proposition 11.11 include every physical trajectory on w=2b+1w=2b+1, even nwn\ge w, h=wn/2h=wn/2, after the harmless maximal-retention normalization.

Lemma 11.24 (Capacity comparisons for erosion merging). For finite inputs one has Φmin(2,a+a),min(2,d+d)(s+t)Φa,d(s)+Φa,d(t),P(i1)+,u,j(s+1)Pi,u,j(s)1,Pi,(u1)+,j(s+1)Pi,u,j(s)1.\begin{aligned} \Phi_{\min(2,a+a'),\min(2,d+d')}(s+t) &\ge\Phi_{a,d}(s)+\Phi_{a',d'}(t), \\ \mathcal P_{\left(i-1\right)_+,u,j}(s+1) &\ge\mathcal P_{i,u,j}(s)-1, \\ \mathcal P_{i,\left(u-1\right)_+,j}(s+1) &\ge\mathcal P_{i,u,j}(s)-1. \end{aligned}(64, 65, 66) For j>0j>0 and i>0i>0, respectively, the stronger comparisons are Pi,0,j1(s+1)Φi,j(s),Pi1,0,j(s+2)Φi,j(s).\begin{aligned} \mathcal P_{i,0,j-1}(s+1)&\ge\Phi_{i,j}(s), \\ \mathcal P_{i-1,0,j}(s+2)&\ge\Phi_{i,j}(s). \end{aligned}(67, 68) Consequently, if A,B,C{0,1,2}A,B,C\in\{0,1,2\}, CAC\ge A, and ΦA,B(t)max{0,B+Ct}\Phi_{A,B}(t)\ge\max\{0,B+C-t\}, then P(vB)+,(uC)+,(jA)+(s+t)Pv,u,j(s)max{t,B+C} \mathcal P_{\left(v-B\right)_+,\left(u-C\right)_+,\left(j-A\right)_+}(s+t) \ge\mathcal P_{v,u,j}(s)-\max\{t,B+C\} (69) whenever its right side is positive.

Proof. For (64), combine the two quadrant allocations in the proof of Theorem 11.1, temporarily allowing more than two required pieces of each type. Convexity combines the optional pieces. Truncating a required count greater than two frees one or two surplus units to another required piece of the same type; its convex gain covers the removed area. The resulting capacity is the left side.

The remaining comparisons follow from the branches of P\mathcal P and the one-neighbor capacity HH of Lemma 11.9. For (65), the only possible loss is i=1,j=u=0i=1,j=u=0, where C2(s+1)s21C_2(s+1)\ge s^2-1. The other branches increase; when i=1,u=0,j>0i=1,u=0,j>0, put z=s12jz=s-1-2j and use H(z+4)(z+4)(z+1)+1H(z+4)\ge(z+4)(z+1)+1. For (66), the only possible loss is i=0,u=1i=0,u=1, where H(z+3)(z+3)z+1H(z+3)\ge(z+3)z+1 loses at most one area unit; the other branches increase. Zero indices use monotonicity. For (67), j=1,i=0j=1,i=0 uses C2(s+1)s21s(s1)C_2(s+1)\ge s^2-1\ge s(s-1), and j=2,i=0j=2,i=0 uses H(s+1)s2s1s25s+8H(s+1)\ge s^2-s-1\ge s^2-5s+8 for s4s\ge4. When i>0i>0, the new even-piece quadratic dominates the old Φ\Phi. For (68), i=1,j=0i=1,j=0 uses C2(s+2)s(s+2)C_2(s+2)\ge s(s+2); at i=1,j>0i=1,j>0 use H(z+5)(z+5)(z+2)+1H(z+5)\ge(z+5)(z+2)+1; at i=2i=2 the new even-piece quadratic again dominates. These substitutions also preserve the capacity domains.

To prove (69), first suppose A>0A>0. Apply (67) AA times, resetting uu to zero, and (65) BB times. A zero outgoing index uses monotonicity. This needs A+BA+B surplus and loses at most BB; feasibility gives tA+2Bt\ge A+2B. Monotonicity in uu permits the desired possibly positive final count instead of zero. If A=0A=0 and tB+Ct\ge B+C, use (65) BB times and (66) CC times. If A=0A=0 and t<B+Ct<B+C, feasibility and Φ0,0(0)=Φ0,0(1)=0\Phi_{0,0}(0)=\Phi_{0,0}(1)=0 leave only B=1,C=2,t=2B=1,C=2,t=2. For v=0v=0, two pair deletions lose at most two; for v>0v>0, (68) applies. Both suffice for the permitted loss three. ◻

Theorem 11.25 (Enriched precapture merger). Define M((a,c,e),(a,c,e))=(a+ah,(c+c2)+,(e+e2)+).\mathcal M\bigl((a,c,e),(a',c',e')\bigr) =\bigl(a+a'-h,\left(c+c'-2\right)_+,\left(e+e'-2\right)_+\bigr). When the merged source has size greater than kk, every joint transition of total cost at most kk in the stated model induces a solo transition to its exact merged target, at the exact same cost.

Proof. For component survivors (ql,il,ul)(q_l,i_l,u_l) and targets (tl,jl,vl)(t_l,j_l,v_l), put Q=q1+q2h>0,T=t1+t2h,I=(i1+i22)+,U=(u1+u22)+,Q=q_1+q_2-h>0,\quad T=t_1+t_2-h,\quad I=\left(i_1+i_2-2\right)_+,\quad U=\left(u_1+u_2-2\right)_+, J=(j1+j22)+,V=(v1+v22)+.J=\left(j_1+j_2-2\right)_+,\quad V=\left(v_1+v_2-2\right)_+. Write δl=vlil\delta_l=v_l-i_l, xl=ql+δlx_l=q_l+\delta_l, σl=tlqlδl\sigma_l=t_l-q_l-\delta_l. The merged closure has δ=VIδ1+δ2\delta=V-I\le\delta_1+\delta_2. With η=δ1+δ2δ0\eta=\delta_1+\delta_2-\delta\ge0, its closed size and surplus are Q+δ=x1+x2hη,σ=σ1+σ2+η. Q+\delta=x_1+x_2-h-\eta, \qquad \sigma=\sigma_1+\sigma_2+\eta. (70) If σ>b\sigma>b, the profile is automatic. Otherwise both component filters apply. If one uses the critical exception, say σ1=b\sigma_1=b, then σ2=η=0\sigma_2=\eta=0. At zero reduced surplus the positive closed support cannot use the small branch; its high branch forces (t2,j2,v2)=(h,2,2)(t_2,j_2,v_2)=(h,2,2) and x2=hx_2=h. Thus the merged closed profile is exactly the critical one, with V=2,J=0V=2,J=0. No claim that this component’s original source is full is needed here.

Otherwise both use capacity branches. They cannot both be small because q1+q2x1+x2σ12+σ22b2<hq_1+q_2\le x_1+x_2\le\sigma_1^2+\sigma_2^2\le b^2<h. If both are high, their target-hole sizes add, and (64) with surplus monotonicity in η\eta gives the high merged branch. If one is small, put A=2jHA=2-j_H, B=2vHB=2-v_H, C=2uHC=2-u_H, t=σHt=\sigma_H, and d=htHd=h-t_H for the high component. Then CAC\ge A, dΦA,B(t)d\le\Phi_{A,B}(t), and its survivor upper bound gives t+d=hxHB+Ct+d=h-x_H\ge B+C. The merged closed size is xL(t+d)ηx_L-(t+d)-\eta. Apply (69) and then surplus monotonicity in η\eta to get the low merged branch. Either branch implies the old size profile since both capacities are at most the square of their surplus.

It remains to check the features and inspection charge. Adding the retained upper bounds proves each merged upper bound, because min(c1+c2,2)+min(e1+e2,2)4\min(c_1+c_2,2)+\min(e_1+e_2,2)\le4. The merged source, survivor, and target are positive, so no empty-state or lower cardinality issue arises. Monotonicity gives UJU\le J, IVI\le V. The positive-part map is one-Lipschitz, so the losses of the merged current and eroded counts sum to at most the four component losses, hence at most p1+p2p_1+p_2. Finally component maximality gives I(c1+c2+v1+v26)+((c1+c22)++V2)+.I\ge\left(c_1+c_2+v_1+v_2-6\right)_+ \ge\left(\left(c_1+c_2-2\right)_++V-2\right)_+. This is exactly merged maximality. The raw survivor (Q,I,U)(Q,I,U) therefore supplies the required transition at the exact total cost. ◻

Corollary 11.26 (Uniform pronic restrictions preserve merging). On the stated odd-width, even-length boards, the merger remains valid with all the following restrictions, for every 2rb2\le r\le b:

  • A survivor q=r(r1)q=r(r-1), i=0i=0, s=rs=r has target (r2,1,0)(r^2,1,0). Flag that target; on the next step the current-corner count must be zero, then reset the flag unless a new trigger occurs.

  • If q=hr2q=h-r^2, s=rs=r, and j=2j=2, require (i,u,v)=(1,2,1)(i,u,v)=(1,2,1).

These are necessary physical rules by Theorem 11.12.

Proof. A merged primal trigger has original total surplus rr. If both component surpluses were positive, they would each be below rr. A small component would give QxL(r1)2<r(r1)Q\le x_L\le(r-1)^2<r(r-1). With two high components, the merged hole size hr2r2h-r^2\ge r^2 is bounded by Φ2J,2V(rV)\Phi_{2-J,2-V}(r-V), since I=0I=0. For V>0V>0 this is at most (r1)2(r-1)^2, and for V=0V=0 its second index is two, again giving a value strictly less than r2r^2. Both are impossible. Consequently one component has original surplus zero. Its survivor, source, and target are all full, with cost zero. Merging is the identity on the other component, which has exactly the same trigger and flag.

For a merged dual event, J=2J=2 forces j1=j2=2j_1=j_2=2. A small component cannot supply the required near-full total. With two positive high surpluses, the two hole sizes sum to at most s1(s11)+s2(s21)=r(r1)2s1s2<r(r1)s_1(s_1-1)+s_2(s_2-1)=r(r-1)-2s_1s_2<r(r-1), contradicting the required value. Again a full-to-full component makes the merger the identity on the constrained component.

For flags, use the merged history’s own trigger, maintaining that a flagged merged state has one flagged component and the other full. The formation proof establishes this invariant. Its next merged current count is at most the flagged component’s count, hence zero. Reset on nontriggering actions; a disjunction of component flags is not assumed. ◻

Corollary 11.27 (The near-pronic band restriction preserves merging). Put C=b(b1)C=b(b-1) and D=C2(b)D=C_2(b). The merger remains valid when every transition with j=2j=2, D<htCD<h-t\le C, and original surplus sbs\le b is required to satisfy s=bs=b and (i,u,v)=(1,2,1)(i,u,v)=(1,2,1). This necessary physical rule is Corollary 11.15. It already forbids consecutive band transitions through ueu\le e; no additional memory flag is needed.

Proof. A merged event has J=2J=2, hence j1=j2=2j_1=j_2=2, and its component hole sizes sum to a number in (D,C](D,C]. Each is therefore at most CC. A small component would have xlPvl,ul,jl(σl)σl(σl1)x_l\le\mathcal P_{v_l,u_l,j_l}(\sigma_l) \le\sigma_l(\sigma_l-1), hence tlσl2b2t_l\le\sigma_l^2\le b^2. Its holes would be at least hb2b2>Ch-b^2\ge b^2>C, impossible. The critical exception has outgoing count zero, so both components must use their high branches. Consequently dlΦ0,2vl(σl)sl(sl1).d_l\le\Phi_{0,2-v_l}(\sigma_l)\le s_l(s_l-1). If both original surpluses are positive, their sum at most bb gives d1+d2s1(s11)+s2(s21)(b1)(b2)D,d_1+d_2\le s_1(s_1-1)+s_2(s_2-1) \le(b-1)(b-2)\le D, contradicting the event. Thus one component is original-full-to-full at cost zero. The merger is the identity on the constrained component, including its surplus and all three survivor/target features. ◻

The induction and reversed-walk argument of Corollary 11.23 now apply to this enriched model, including all pronic radii and the static near-pronic band restriction. If its finite solo clearing time is τ^\widehat\tau and its smallest reachable size after tt moves is ftf_t, the minimum joint total before solo clearing is h+fth+f_t, and Tk(w,n)2τ^1,Tk(w,n)2τ^if 2fτ^1>k.T_k(w,n)\ge2\widehat\tau-1, \qquad T_k(w,n)\ge2\widehat\tau \quad\text{if }2f_{\widehat\tau-1}>k. This is an exact lower-model evaluator. Physical attainment and a fixed-size numerical evaluation of its clock remain separate questions.

Finite applications and a remaining gap

The geometric theorems apply uniformly, but the following numerical applications evaluate finite necessary models separately. Their matching upper bounds are inspection sequences replayed on the actual board. These distinctions matter: neither a necessary-model path nor an unmatched construction is an optimal physical strategy.

Theorem 11.28 (Certified finite capture times). The following values hold: T5(8,8)=40,T7(12,12)=72,T4(7,8)=68,T5(9,10)=96,T_5(8,8)=40,\qquad T_7(12,12)=72,\qquad T_4(7,8)=68,\qquad T_5(9,10)=96, T6(11,12)=128,T6(11,14)=172.T_6(11,12)=128,\qquad T_6(11,14)=172. For each equality, the accompanying artifact specifies a legal inspection sequence attaining the stated time.

Proof. For the two even squares, enumerate the size–corner model of Section 11.8, retaining every target allowed by the subcritical corner inequalities and every allocation of at most kk inspections. Joint reachability first reaches a total of at most kk after 3939 and 7171 unsuccessful days, respectively. The next inspection gives the lower bounds 4040 and 7272. The retained transitions include every physical strategy by Theorem 11.1. No square-compression assumption is needed for these lower certificates.

For 7×87\times8 and 9×109\times10, use the erosion-corner model with full reduced-surplus closure, maximal retention, and the critical pronic restrictions. Independent integer potentials on the joint state space give lower bounds 6868 and 9696: they vanish at capture and decrease by at most one on every permitted joint transition. The verifier checked 476281164476\,281\,164 and 43538277264\,353\,827\,726 transition inequalities, respectively. These two lower certificates do not require the merger theorem.

For the two eleven-row boards, use instead the relaxed model of Theorem 11.25, including all pronic radii and Corollary 11.27. In particular, the two positive lower feature bounds omitted in that theorem are also omitted in the finite evaluator. Its pairs (τ^,fτ^1)(\widehat\tau,f_{\widehat\tau-1}) are (64,4)(64,4) and (86,4)(86,4). As 24>62\cdot4>6, the concentration and reversed-cut argument gives lower bounds 128128 and 172172, not merely 127127 and 171171. The forward-distance certificates check every edge from a reachable state and the minimum residual size before clearing.

The upper certificates supply a 2020-day solo sequence on 8×88\times8, a 3636-day solo sequence on 12×1212\times12, and full-board sequences of lengths 68,96,128,17268,96,128,172 on the four odd-width boards. Clearing the two cohorts successively in the first two cases gives 4040 and 7272 days. The recorded rooms are checked against the daily budget and the exact recursion At+1=N(AtSt)A_{t+1}=N(A_t\setminus S_t), starting from the appropriate full color class or full board and ending with no survivor. Thus the physical upper bounds match the lower certificates. ◻

The precise reproducibility records are as follows. Paths are relative to the research artifact; historical phrases such as “proof-pending” in an early receipt record the status at its generation, while the geometric premises are proved in the preceding sections.

  • The even-square lower evaluator is ; its receipts are and . The upper records are , replayed by , and , replayed by .

  • The 7×87\times8 and 9×109\times10 joint lower records are in , with evaluator and independent joint-potential checker .

  • The two eleven-row lower records are in , generated by . The receipt records the source hash and the deliberate feature relaxation; it uses the static band-dual rule, with no band-memory bit.

  • All four odd-width upper sequences and their full-board replays are in , generated by .

For comparison, the present full-board bounds on the larger square are 206T13(24,24)207. 206\le T_{13}(24,24)\le207. (71) Corollary 11.19 proves the lower bound using the near-square physical obstruction and a separately verified time-sensitive joint equality certificate. Its reproducibility records are and . The latter verifier is . The upper bound is the literal 207207-day full-board replay in , from . Its underlying solo sequence takes 104104 days; reflection across the central capture inspection saves one day from simple concatenation. The underlying solo interval remains 103103 to 104104. The lower bound in (71) uses the additional joint equality argument; it is not inferred merely by doubling the physical solo lower.

These are ordinary geometric proofs combined with checked finite integer calculations and physical inspection replays. They have not been formalized in Lean. They establish the displayed individual values and bounds, rather than a new all-width classification or a uniform fixed-size numerical formula.

Uniform time bounds and exact large-budget searches on even widths

Continue with G=P2bPnG=P_{2b}\mathbin{\square}P_n, n2bn\ge2b, and h=bnh=bn. The preceding static profile gives an all-budget lower bound without assuming that its minimizing sets can be chained.

Lemma 12.1 (A scalar lower bound with a central-day test). More generally, let gg be the symmetric profile of any even-area rectangle, with hh vertices in each color. Starting with c0=hc_0=h, define ct+1=g((ctm)+),τ=min{t:ct=0}.c_{t+1}=g(\left(c_t-m\right)_+),\qquad \tau=\min\{t:c_t=0\}. If τ\tau is finite, then Tm2τ1T_m\ge2\tau-1, and Tm2τT_m\ge2\tau when 2cτ1>m2c_{\tau-1}>m.

Proof. The inverse profile is I(z)=hg(hz)=zmin{ρ(z),b,R(hz)},0zh.I(z)=h-g(h-z) =z-\min\{\rho(z),b,R(h-z)\},\qquad0\le z\le h. Its subtracted term is subadditive. If a cap or decreasing reflected branch minimizes either summand, that branch bounds the value at the sum. Otherwise use subadditivity of ρ\rho, following from ur(r+1)u\le r(r+1), vs(s+1)v\le s(s+1) and u+v(r+s)(r+s+1)u+v\le(r+s)(r+s+1). Thus I(x)+I(y)I(x+y)I(x)+I(y)\le I(x+y) when x+yhx+y\le h.

Put Dt=hctD_t=h-c_t. Then Dt+1=I(min{h,Dt+m})D_{t+1}=I(\min\{h,D_t+m\}). For t<τt<\tau, the total physical deficit of both cohorts after tt inspections and moves is at most DtD_t. Indeed, useful allocations of total at most mm give next deficit at most I(d0+p)+I(d1+q)I(Dt+m)I(d_0+p)+I(d_1+q)\le I(D_t+m) whenever t+1<τt+1<\tau. Here Dt+m<hD_t+m<h follows from Dt+1<hD_{t+1}<h and I(h)=hI(h)=h. This proves the invariant inductively from zero.

The case τ=1\tau=1 is immediate. Otherwise, for a purported 2τ22\tau-2-day capture, set L=τ1L=\tau-1. After the first LL inspections and moves the belief has more than hh vertices. Reversing the last LL inspections, using L1L-1 moves and then a final inspection, also leaves more than hh vertices: its deficit is at most DL1+m<hD_{L-1}+m<h. The two sets occupy the same day and intersect, giving an avoiding walk. Thus Tm2τ1T_m\ge2\tau-1.

At the central day of a (2τ1)(2\tau-1)-day search, the forward and backward beliefs each have deficit at most Dτ1D_{\tau-1}. Their intersection has at least 2h2Dτ1=2cτ12h-2D_{\tau-1}=2c_{\tau-1} vertices, all of which must be inspected centrally. This proves the second bound. ◻

A common enlargement and erosion lemma

The following construction supplies the physical upper strategies in both parity cases. It also permits a nonpyramidal terminal survivor. Let QQ be a finite connected bipartite graph with at least two vertices, with bipartition map χ:V(Q){0,1}\chi:V(Q)\to\{0,1\}. In QPnQ\mathbin{\square}P_n, a downward pyramid is a one-color set closed under every valid predecessor (u,y1)(u,y-1) of (v,y)(v,y), where uvE(Q)uv\in E(Q) and y>0y>0. Write cl(R)\operatorname{cl}(R) for the least such set containing RR. These are ideals of a finite poset, since every predecessor lowers yy. Put HQ=maxvV(Q)uV(Q)distQ(v,u)/2.H_Q=\max_{v\in V(Q)}\sum_{u\in V(Q)} \left\lceil\operatorname{dist}_Q(v,u)/2\right\rceil. The sharper, phase-dependent threshold needed for erosion is BQ,p=maxv:χ(v)=puV(Q)distQ(v,u)/2.B_{Q,p}=\max_{v:\chi(v)=p}\sum_{u\in V(Q)} \left\lfloor\operatorname{dist}_Q(v,u)/2\right\rfloor.

Lemma 12.2 (Prescribed envelopes with arbitrary terminal supports). Let RR be any set in physical color pp, and let kk satisfy cl(R)ZpkVp,Zp={(v,0):χ(v)=p},|\operatorname{cl}(R)\cup Z_p|\le k\le |V_p|, \qquad Z_p=\{(v,0):\chi(v)=p\}, where VpV_p is the full physical color class in the cylinder. In particular, admission holds if cl(R)k|\operatorname{cl}(R)|\le k and k>BQ,pk>B_{Q,p}, or if RR is already a pyramid and k=R+mVpk=|R|+m\le|V_p| with mZpm\ge|Z_p|. There are pyramids ARA\supseteq R of color pp and EE of color 1p1-p such that A=k,E=kχ1(p),N(E)A.|A|=k,\qquad |E|=k-|\chi^{-1}(p)|, \qquad N(E)\subseteq A. Consequently, after a movement from any survivor contained in EE, the designated inspections ARA\setminus R leave an actual survivor contained in RR, using exactly kRk-|R| designated inspections.

Proof. Two predecessor moves show that every fiber of a pyramid is a spacing-two prefix. Put sv=(pχ(v))mod2s_v=(p-\chi(v))\bmod2. If its fiber size is kvk_v, the virtual last height av=sv2+2kva_v=s_v-2+2k_v satisfies auav=1|a_u-a_v|=1 on every QQ-edge; empty fibers have heights 2-2 or 1-1. If fiber vv is empty, distance along QQ gives kusv+dist(v,u)su2={dist(v,u)/2,sv=0,dist(v,u)/2,sv=1.k_u\le\frac{s_v+\operatorname{dist}(v,u)-s_u}{2} =\begin{cases} \left\lfloor\operatorname{dist}(v,u)/2\right\rfloor,&s_v=0,\\ \left\lceil\operatorname{dist}(v,u)/2\right\rceil,&s_v=1. \end{cases} Thus a pyramid with any empty fiber has at most HQH_Q rooms. If an empty fiber has sv=0s_v=0, its sharper bound is BQ,pB_{Q,p}. These are exactly the fibers whose bottom room contributes to erosion.

Every bottom root is a minimal poset element, so cl(R)Zp\operatorname{cl}(R)\cup Z_p is an ideal. Extend it to exactly kk elements by repeatedly adding a minimal element of its complement; fix a linear extension to make this choice deterministic. Call it AA. For the first sufficient admission condition, an arbitrary kk-element ideal containing cl(R)\operatorname{cl}(R) already contains every root by the preceding distance bound. For the second, adjoining all roots adds at most Zpm|Z_p|\le m elements. Define the opposite-color cutoffs by ev=max{av1,(1sv)2}.e_v=\max\{a_v-1,(1-s_v)-2\}. Both vectors inside the maximum are edgewise 11-Lipschitz with the required parity; their maximum has the same properties. Opposite parity on an edge makes its height difference exactly one. The cutoffs obey both physical boundaries and therefore define a pyramid EE. Its exact cardinality loss is the number of occupied fibers with sv=0s_v=0. All these fibers are occupied by the chosen roots, giving loss χ1(p)|\chi^{-1}(p)|. The other term in the maximum represents an empty fiber and contributes no actual room. Every neighbor of an actual room of EE has height at most the appropriate cutoff of AA, proving N(E)AN(E)\subseteq A even at the physical ends. Movement therefore enters AA, and inspecting ARA\setminus R leaves only rooms of RR. ◻

The all-fiber threshold HQH_Q is sharp across the two colors when ndiam(Q)n\ge\operatorname{diam}(Q): at a maximizing vertex vv, choose sv=1s_v=1 and heights au=dist(v,u)1a_u=\operatorname{dist}(v,u)-1. Bipartiteness makes adjacent distances differ by one, giving a valid pyramid of size HQH_Q with an empty fiber. For a path of order aa, HPa=a2/4.H_{P_a}=\left\lfloor a^2/4\right\rfloor. Indeed the distance sum is maximized at an endpoint, by the nondecreasing increments of j=1tj/2\sum_{j=1}^t\left\lceil j/2\right\rceil. The root threshold BQ,pB_{Q,p} is separately sharp when nmax{1,diam(Q)}n\ge\max\{1,\operatorname{diam}(Q)\}: at a maximizing vertex vv of color pp, the cutoffs au=dist(v,u)2a_u=\operatorname{dist}(v,u)-2 give a pyramid of size BQ,pB_{Q,p} with an empty bottom root. For paths the sharper thresholds are BP2b,0=BP2b,1=b(b1),BP2b+1,0=b2,BP2b+1,1=b(b1),B_{P_{2b},0}=B_{P_{2b},1}=b(b-1),\qquad B_{P_{2b+1},0}=b^2,\quad B_{P_{2b+1},1}=b(b-1), where color zero contains the endpoints of the odd path. Indeed, at vertex vv of a path indexed from zero, the floor-distance sum is v2/4+(a1v)2/4\left\lfloor v^2/4\right\rfloor+\left\lfloor(a-1-v)^2/4\right\rfloor; convexity maximizes it at an extreme vertex of the required parity. Taking k=R+mk=|R|+m gives the usual backward step whenever m>BQ,pm>B_{Q,p} and the requested envelope fits; the additional admission condition for a nonpyramidal RR is exactly cl(R)Rm|\operatorname{cl}(R)|-|R|\le m. For a pyramidal RR, deliberately adjoining the roots instead gives the same backward step whenever mZpm\ge|Z_p|. The quadratic threshold is therefore unnecessary for this chosen upper construction; its role in the large-budget lower-bound argument is separate.

An all-budget upper bound and its exact range

Theorem 12.3 (Every even width: construction and large-budget equality). Let b+1m<hb+1\le m<h, and write D=mb,hb=qD+r,0r<D.D=m-b,\qquad h-b=qD+r,\quad0\le r<D. Set J(0)=0J(0)=0 and J(r)=r+min{r,b}J(r)=r+\min\{\left\lceil\sqrt r\right\rceil,b\} for r>0r>0. Then Tm(G){2q,r=0,2q+1,r>0 and 2J(r)m,2q+2,otherwise.T_m(G)\le \begin{cases} 2q,&r=0,\\ 2q+1,&r>0\text{ and }2J(r)\le m,\\ 2q+2,&\text{otherwise}. \end{cases} Equality holds whenever m>b(b1)m>b(b-1). At smaller budgets this theorem alone supplies an explicit upper bound. The boundary budget m=b(b1)m=b(b-1) is classified separately in Theorem 31.4, whose construction may improve the displayed bound. For hm<2hh\le m<2h the answer is two days, and for m2hm\ge2h it is one. The constructions are physical searches; the lower bounds permit arbitrary interleaving and arbitrary support shapes.

An optimal seven-day search on 6×96\times9 with ten daily inspections, constructed backwards from the final survivor envelope. Every displayed possible-position set and inspection has been replayed on the physical room graph.

Lower bound. Assume in this part that m>b(b1)m>b(b-1). Because m>b(b1)m>b(b-1), the reflected term in the full-budget scalar recurrence is saturated. Thus ct+1=L((ctm)+)c_{t+1}=L(\left(c_t-m\right)_+), where L(0)=0L(0)=0 and L(k)=k+min{R(k),b}L(k)=k+\min\{R(k),b\} for k>0k>0. Now D(b1)2D\ge(b-1)^2. When D>(b1)2D>(b-1)^2 or r>0r>0, successive plateau steps give ct=htD(0tq1),cq=J(r).c_t=h-tD\quad(0\le t\le q-1),\qquad c_q=J(r). If r=0r=0, then τ=q\tau=q and cq1=mc_{q-1}=m. If r>0r>0, then 0<J(r)<m0<J(r)<m, so τ=q+1\tau=q+1. The only new endpoint is D=(b1)2D=(b-1)^2, r=0r=0, b2b\ge2. Here q2q\ge2, and the penultimate plateau step has survivor D=(b1)2D=(b-1)^2, whose surplus is b1b-1. Consequently cq1=m1c_{q-1}=m-1 and τ=q\tau=q. Since m3m\ge3, one still has 2cq1>m2c_{q-1}>m, giving the same answer 2q2q. For b=1b=1, D1>(b1)2D\ge1>(b-1)^2 already covers every feasible budget. Lemma 12.1 gives precisely the claimed lower bounds. Its argument also covers the two extreme budget ranges. ◻

Physical upper construction. Apply Lemma 12.2 with Q=P2bQ=P_{2b}. Deliberately include its bb bottom roots at each enlargement. Since mb+1m\ge b+1, this is always admitted, and erosion loses exactly bb rooms in either color. The prescribed-size enlargement and physical neighborhood inclusion are supplied by that common lemma.

Choose a terminal pyramid RR of size rr with N(R)J(r)|N(R)|\le J(r). The small-corner construction, ordered toward the longitudinal near edge as above, supplies it when r<b\left\lceil\sqrt r\right\rceil<b, and the plateau bound supplies it otherwise. Reflection in the even short axis permits either physical color. Enlarge RR by mm vertices and apply the clipped erosion. This constructs a preceding survivor of size r+Dr+D, whose neighborhood lies inside that enlarged envelope. Repeat q1q-1 times, and enlarge by mm once more. This first envelope has size r+(q1)D+m=hr+(q-1)D+m=h, so is the full color class. Every enlargement fits and adds enough rooms to include all roots, giving the required erosion loss even if some other fibers are empty.

Read the construction forward. On each day inspect the difference between its envelope and prescribed survivor, using exactly mm designated rooms. The actual belief stays inside the next envelope. After qq days its survivor lies in RR and its next belief has at most J(r)J(r) rooms. When r=0r=0, this is a qq-day solo capture; otherwise one more day suffices.

For r>0r>0 and 2J(r)m2J(r)\le m, join one such qq-day preparation and the time reversal of another on opposite cohorts. Inspect both final neighborhood envelopes on the central day. Their colors are opposite and their total size is at most 2J(r)2J(r), giving 2q+12q+1 days. Otherwise concatenate two (q+1)(q+1)-day solo searches. For r=0r=0 concatenate two qq-day searches. Reflection lets each half choose its required physical color independently. Finally, when mhm\ge h, two inspections of one fixed physical color capture both initial cohorts; inspecting the entire board gives one day when m2hm\ge2h. ◻

Exact symbolic transitions between physical fronts

The next results evaluate transitions between prescribed fronts, rather than assuming that every optimal intermediate support has this form. They include exact one-day costs at the physical ends and arbitrary prescribed daily quotas in the interior. A later application eliminates the translation coordinate from the finite-interface graph.

Let QQ be connected and bipartite, with A2A\ge2 vertices and bipartition map χ\chi. For a downward pyramid of physical color pp in QPnQ\mathbin{\square}P_n, write sv=(pχ(v))mod2s_v=(p-\chi(v))\bmod2. Its virtual last occupied heights satisfy av=sv2+2kv,auav=1(uvE(Q)),a_v=s_v-2+2k_v,\qquad |a_u-a_v|=1\quad(uv\in E(Q)), where kvk_v is the fiber cardinality. The values 2,1-2,-1 denote empty fibers. This is the height representation established in Lemma 12.2. All the results have reflected versions for upward pyramids.

Proposition 13.1 (Maximal erosion and exact one-day costs). Let BB be a downward pyramid of color pp, with heights bvb_v. Its maximal graph erosion in the opposite color, E(B)={xV1p:N({x})B},E(B)=\{x\in V_{1-p}:N(\{x\})\subseteq B\}, is a pyramid with heights ev=max{bv1,(1sv)2}+21{Tv}, e_v=\max\{b_v-1,(1-s_v)-2\}+2\mathbf{1}_{\{T_v\}}, (72) where TvT_v means that n11sv(mod2)n-1\equiv1-s_v\pmod2, bv=n2b_v=n-2, and bu=n1b_u=n-1 for every neighbor uu of vv in QQ.

For any downward pyramid PP of the opposite color, with heights ava_v, the minimum useful inspections forcing the next belief to be contained in BB are exactly PE(B)=12v(avev)+. |P\setminus E(B)|=\frac12\sum_v\left(a_v-e_v\right)_+. (73) The exact next belief BB is attainable if and only if N(PE(B))=BN(P\cap E(B))=B; when it is, the same cost is minimal. These minima allow arbitrary competing survivors.

Proof. A candidate room below the top has an upward longitudinal neighbor, so its height is at most bv1b_v-1. The transverse inequalities add nothing: adjacent cutoffs are bv1b_v-1 or bv+1b_v+1. The lower maximum in (72) represents an empty opposite-color fiber when no room is admissible. At the top, the upward neighbor is absent. That one additional room is admissible exactly under TvT_v, by its downward and transverse neighbors. This also handles n=1n=1, when the condition reduces to the transverse neighbor test.

The bottom correction raises a local minimum 3-3 to 1-1, with neighboring new cutoffs 2-2. A top correction raises a local minimum n3n-3 to n1n-1, with neighboring new cutoffs n2n-2. Thus edge differences remain one, proving that the erosion is a pyramid. Its intersection with PP has cutoffs min(av,ev)\min(a_v,e_v).

A survivor has neighborhood contained in BB exactly when it is contained in E(B)E(B). The largest admissible survivor is therefore PE(B)P\cap E(B), proving the minimum cost. If any survivor has neighborhood exactly BB, its inclusion in this largest survivor forces BN(PE(B))BB\subseteq N(P\cap E(B))\subseteq B. The converse is immediate. ◻

Lemma 13.2 (Exact height descent with a quota word). Let a,za,z be integer height configurations on QQ, each with edge differences one and checkerboard vertex parities. Fix t0t\ge0 and nonnegative integer quotas p1,,ptp_1,\ldots,p_t. In the virtual height model, a day consists of at most pjp_j legal local-maximum lowerings by two, followed by adding one to every height. The endpoint zz is reachable from aa in exactly tt days if and only if zvav+t(mod2),zvav+tfor every v,F:=vavvzv+At2j=1tpj. \begin{gathered} z_v\equiv a_v+t\pmod2,\qquad z_v\le a_v+t\quad\hbox{for every }v,\\ F:=\frac{\sum_v a_v-\sum_v z_v+At}{2} \le\sum_{j=1}^t p_j. \end{gathered} (74) Exactly FF lowerings suffice. The same criterion holds with movement before each day’s lowerings.

Proof. Each lowering reduces the height sum by two, while movement raises each coordinate by one. This proves necessity, including the componentwise and parity conditions.

Put c=zt1c=z-t\mathbf1. It has the same vertexwise parities as aa and satisfies cac\le a. From any current xcx\ne c, choose a vertex vv of maximum current height among those with xv>cvx_v>c_v. A higher neighbor uu would also be above its target: otherwise cu=xu=xv+1c_u=x_u=x_v+1 and cvxv2c_v\le x_v-2, contradicting the target edge condition. Such a neighbor contradicts maximality, so all neighbors are one lower. Lowering xvx_v by two is legal and preserves xcx\ge c. Repeated descent reaches cc in exactly FF steps.

Choose integers 0qjpj0\le q_j\le p_j summing to FF and divide this word into successive pieces of lengths qjq_j. Uniform additions commute with the local-maximum test. Inserting one addition per piece, before or after it, gives endpoint c+t1=zc+t\mathbf1=z. The case t=0t=0 forces a=za=z and uses the empty word. ◻

The following physical lower bound is what permits comparison with arbitrary, possibly nonpyramidal competitors. Suppose QQ has a Hamiltonian path, indexed 0,,A10,\ldots,A-1, and take its parity as χ\chi. All color indices in the following formulas are read modulo two. Put CA=(A2)2/4,γp=χ1(1p).C_A=\left\lfloor(A-2)^2/4\right\rfloor,\qquad \gamma_p=|\chi^{-1}(1-p)|. For any finite color-pp support SS in QPQ\mathbin{\square}P_\infty, N(S)S,S>CA  N(S)S+γp. |N(S)|\ge|S|,\qquad |S|>C_A\ \Longrightarrow\ |N(S)|\ge|S|+\gamma_p. (75) Indeed, deleting the extra transverse edges leaves the spanning rectangle. Put the finite support in a sufficiently long auxiliary rectangle so that its neighborhood is unchanged and the far profile branch cannot lower the cap. For A=2bA=2b, the proved profile becomes k+min(k,b)k+\min(\left\lceil\sqrt k\right\rceil,b), whose plateau begins at k>(b1)2k>(b-1)^2. For A=2b+1A=2b+1, choose the auxiliary length odd. Its two profiles are k+min(R(k),b)k+\min(R(k),b) and k+min(Q(k),b+1)k+\min(Q(k),b+1), with their common plateau beginning at k>b(b1)k>b(b-1). These are exactly the stated CAC_A and γp\gamma_p. Their small branches also prove nonnegative expansion.

Theorem 13.3 (Unrestricted physical transitions in a guarded interior). Let QQ be bipartite with a Hamiltonian path and A2A\ge2. Let P,ZP,Z be downward pyramids in QPnQ\mathbin{\square}P_n, with heights a,za,z. Fix t1t\ge1, quotas p1,,ptp_1,\ldots,p_t, and P:=jpjP_*:=\sum_jp_j. Assume tminvav,tminvzv,maxvav, maxvzvn1t,PP>CA. \begin{gathered} t\le\min_v a_v,\quad t\le\min_v z_v,\qquad \max_v a_v,\ \max_v z_v\le n-1-t,\\ |P|-P_*>C_A. \end{gathered} (76) An actual tt-day block with these daily quotas and exact endpoint ZZ exists, without restrictions on intermediate supports, if and only if (74) holds. Whenever it exists, there is such a block with every survivor and belief a downward pyramid. Both longitudinal parities and arbitrary partial initial pyramids are included.

Proof. Free evolution from PP has heights a+ja+j for 0jt0\le j\le t under the height margins. Every competitor is contained in this free belief, so the endpoint inclusion and parity conditions are necessary. Before each movement no survivor meets the far longitudinal row; hence its neighborhood agrees with that in the half-strip.

Nonnegative expansion in (75) bounds every survivor below by PP>CA|P|-P_*>C_A. If the initial color is pp, its jjth expansion is therefore at least γp+j1\gamma_{p+j-1}. For svp=(pχ(v))mod2s^p_v=(p-\chi(v))\bmod2, j=1tγp+j1=At+vsvpvsvp+t2,PZ=vavvzvvsvp+vsvp+t2.\sum_{j=1}^t\gamma_{p+j-1} =\frac{At+\sum_v s^p_v-\sum_v s^{p+t}_v}{2},\qquad |P|-|Z|=\frac{\sum_v a_v-\sum_v z_v-\sum_v s^p_v+\sum_v s^{p+t}_v}{2}. Summing the useful inspections and canceling these parity terms gives FPF\le P_*. This lower bound did not constrain the intermediate shapes.

For sufficiency use the descent in Lemma 13.2. Its unshifted heights stay between zt1z-t\mathbf1 and aa. The margins keep every surviving fiber nonempty and, before a movement, its height at most n2n-2. Its actual neighborhood consequently has cutoffs exactly one higher. Each lowering removes one actual top room; successive lowerings of the same fiber remove distinct rooms. Thus the virtual construction is an exact physical block with the prescribed daily quotas. ◻

The cardinality guard is only a lower-bound hypothesis. The construction itself extends to arbitrarily long durations with fixed physical margins. Write r=diam(Q)r=\operatorname{diam}(Q) and μ(x)=A1vxv\mu(x)=A^{-1}\sum_vx_v.

Proposition 13.4 (Balanced inspections in fixed physical margins). Let QQ be connected and bipartite with A2A\ge2, and suppose the criterion (74) holds for a constant quota mm and t1t\ge1. If r+2μ(a),μ(z)nr3, r+2\le\mu(a),\mu(z)\le n-r-3, (77) there is an exact physical pyramid block from aa to zz using at most mm inspections each day, regardless of its duration.

Proof. Use the legal descent word, with piece lengths qj=jF/t(j1)F/tm.q_j=\left\lfloor jF/t\right\rfloor-\left\lfloor(j-1)F/t\right\rfloor\le m. The completed-day mean is μ(a)+j2AjF/t=(1j/t)μ(a)+(j/t)μ(z)+2A{jF/t}.\mu(a)+j-\frac2A\left\lfloor jF/t\right\rfloor =(1-j/t)\mu(a)+(j/t)\mu(z)+\frac2A\{jF/t\}. Here braces denote the fractional part. It lies between the smaller endpoint mean and the larger plus 2/A2/A. The survivor immediately before a movement is one lower. Each partial inspection step lies coordinatewise between that day’s source and survivor, and every height configuration has range at most rr. All partial heights therefore lie in [min(μ(a),μ(z))r1,max(μ(a),μ(z))+r+2/A].[\min(\mu(a),\mu(z))-r-1,\quad \max(\mu(a),\mu(z))+r+2/A]. The margin keeps them in the nonempty, unclipped physical range. Neighborhoods are exactly the global additions, completing the proof. ◻

For m>A/2m>A/2, define D=2mAD=2m-A. Between prescribed height endpoints, the least virtual duration is the smallest nonnegative integer t0t_0 of the required color parity satisfying t0max{0, maxv(zvav),vavvzvD}. t_0\ge\max\left\{0,\ \max_v(z_v-a_v),\quad \left\lceil\frac{\sum_v a_v-\sum_v z_v}{D}\right\rceil\right\}. (78) Thus two maxima, an integer ceiling, and a parity adjustment give its cost. Under (77) the corresponding block is physical. An unrestricted lower bound for a long connection requires control of possible boundary excursions; it does not follow by applying (76) with a large mt0mt_0. The finite ports below handle those excursions explicitly.

Constructive transport without boundary margins

Lemma 13.5 (Upper transport without boundary margins). Let QQ be a connected bipartite transverse graph, and consider QPnQ\square P_n. Let ava_v and bvb_v be integer cutoff vectors of physical phases pp and p+tp+t, respectively, with adjacent heights differing by one. A belief is contained in the envelope aa when every possible room (v,y)(v,y) satisfies yavy\le a_v. If Ft(a,b):=12vV(Q)(avbv+t)+kt,F_t(a,b):=\frac12\sum_{v\in V(Q)}(a_v-b_v+t)_+\le kt, there is a directly prescribed tt-day strategy, with at most kk inspections per day, whose final belief is contained in the envelope bb. There is no requirement that either envelope lie away from a board boundary.

Proof. Put cv=min(av,bvt)c_v=\min(a_v,b_v-t). The two arguments have the same parity; their minimum is edgewise 11-Lipschitz, so adjacent values differ by one. Starting from aa, repeatedly lower by two a highest vertex still above cc, with a fixed tie order. Every neighbor is one lower: a higher neighbor at target would violate the target’s Lipschitz condition, and a higher neighbor above target would contradict the choice. The resulting legal flip word has exactly Ft(a,b)F_t(a,b) letters and ends at cc.

Partition the word into tt consecutive groups of at most kk letters. On each day inspect the old top room of every flip in that day’s group when that room lies inside the board; distinct flips name distinct rooms. Then increase every virtual height by one. This dominates physical movement, both longitudinally and transversely, even when a virtual height lies below or above the board. Uniform additions commute with legal height flips. The final virtual envelope is c+t=min(a+t,b)bc+t=\min(a+t,b)\le b, proving the containment. When t=0t=0, the hypothesis says aba\le b and no inspection is needed. ◻

Corollary 13.6 (A bottom-boundary credit). Suppose a,ba,b are canonical physical pyramid cutoffs and t1t\ge1. Let z(B)z(B) be the number of empty target fibers whose bottom cell has the target physical color. The same containment conclusion holds under the weaker sufficient condition Ft(a,b)kt+z(B).F_t(a,b)\le kt+z(B).

Proof. In the preceding legal flip word, a flip at unshifted old height HtH\le-t lies below the physical board on every day 0,,t10,\ldots,t-1. There is exactly one such flip in each empty target bottom-root fiber: there bv=2b_v=-2, the target cv=t2c_v=-t-2, and the canonical initial height is at least t-t. An empty nonroot target fiber has bv=1b_v=-1 and its last flip is at height 1t1-t; nonempty target fibers end higher still. Thus exactly z(B)z(B) letters are guaranteed free. Partition the other letters into tt groups of at most kk, retaining all free letters in their original order. Actual visible inspections never exceed the charged count. The virtual endpoint remains min(a+t,b)b\min(a+t,b)\le b. ◻

Corollary 13.7 (A linear-rate change of corner). Let the board have even width w=2rw=2r. Let AA and BB be weightlex prefixes based at the two bottom corners, with AB|A|\ge |B|, and let their physical phases differ by tw1t\ge w-1. If AB(kr)t+z(B),|A|-|B|\le (k-r)t+z(B), there is a directly prescribed tt-day strategy from AA into BB. In particular, the simpler condition AB(kr)t|A|-|B|\le(k-r)t suffices.

Proof. Let a,ba,b be the canonical cutoffs. Reflect BB horizontally. If tt is odd, the reflected prefix has the same phase as AA and is contained in AA. Thus bxaw1xax+w1b_x\le a_{w-1-x}\le a_x+w-1. If tt is even, the reflected prefix has the opposite phase. Since the board has a perfect matching, N(A)AB|N(A)|\ge|A|\ge|B|; the neighborhood of a weightlex prefix is a prefix in the same corner order. Consequently the reflected BB lies in N(A)N(A), and bxaw1x+1ax+wb_x\le a_{w-1-x}+1\le a_x+w. Since ww is even and tw1t\ge w-1, we have bxaxtb_x-a_x\le t in both cases. The canonical cutoff sums give Ft(a,b)=AB+rt.F_t(a,b)=|A|-|B|+rt. The preceding bottom-boundary credit therefore proves the claim. ◻

Corollary 13.8 (A size-only sufficient transport criterion). On an even-width board w=2rw=2r, let A,BA,B have canonical pyramid cutoffs and phases compatible with t1t\ge1, and write D=ABD=|A|-|B|. If D+rtr(w1),D(kr)t+z(B),D+rt\ge r(w-1),\qquad D\le(k-r)t+z(B), there is a directly prescribed tt-day strategy from AA into BB.

Proof. The difference δx=bxax\delta_x=b_x-a_x is 22-Lipschitz and has sum 2D-2D. If its maximum is MM, summing the bounds δxM2xx0\delta_x\ge M-2|x-x_0| gives 2DwMw(w1)-2D\ge wM-w(w-1), whence Mw1D/rtM\le w-1-D/r\le t. Thus Ft(a,b)=D+rtF_t(a,b)=D+rt, and the bottom-boundary credit applies. ◻

Odd widths and even lengths: construction and large-budget equality

The remaining parity of rectangular boards requires remembering the orientation of an efficient boundary. The resulting formula has the same corner cost as the odd-board formula, but no middle-day parity penalty. Throughout this section let w=2b+13,n=2w,h=wn/2,B=b(b+1).w=2b+1\ge3,\qquad n=2\ell\ge w,\qquad h=wn/2,\qquad B=b(b+1). Use L0,L1,J,FL_0,L_1,J,F from (32), (33), and (36), with the present b,mb,m.

Theorem 14.1 (Odd width and even length: an all-budget construction). Suppose b+1m<hb+1\le m<h, and write D=2mw,2hw1=qD+r,0r<D.D=2m-w,\qquad 2h-w-1=qD+r,\qquad 0\le r<D. Then Tm(PwPn){2q,r=0,2q+1,r>0 and 2J(r)m,2q+2,r>0 and 2J(r)>m. T_m(P_w\mathbin{\square}P_n)\le \begin{cases} 2q,&r=0,\\ 2q+1,&r>0\text{ and }2J(r)\le m,\\ 2q+2,&r>0\text{ and }2J(r)>m. \end{cases} (79) Equality holds for mb(b+1)+1m\ge b(b+1)+1. The proof of the construction uses every feasible budget; the lower-bound proof below retains this separate quadratic hypothesis. For hm<2hh\le m<2h the answer is two days, and for m2hm\ge2h it is one. The upper bounds are explicit physical searches. The lower bounds allow arbitrary inspection locations and arbitrary interleaving of the cohorts.

A sharp orientation constraint

Call a survivor critical when its surplus is bb, and strictly middle when its cardinality ss satisfies b2<s<hB.b^2<s<h-B. Match longitudinal rooms (x,2j)(x,2j) and (x,2j+1)(x,2j+1), and identify a color-pp room with (x,j)(x,j) by y=2j+((px)mod2)y=2j+((p-x)\bmod2). The matching-contracted graph has bidirectional edges in xx and longitudinal edges pointing toward j=0j=0 on even xx, toward j=1j=\ell-1 on odd xx, when p=0p=0; phase one reverses the directions. Put U={0,2,,2b}U=\{0,2,\ldots,2b\} and V={1,3,,2b1}V=\{1,3,\ldots,2b-1\}.

Lemma 14.2 (Critical orientation and a corner consequence). A phase-zero strictly middle critical survivor consists of prefixes of lengths txt_x with 1tu1(uU),tvtutv+1(uv an edge).1\le t_u\le\ell-1\quad(u\in U),\qquad t_v\le t_u\le t_v+1\quad(uv\text{ an edge}). Phase one gives reflected suffixes. Two successive strictly middle survivors cannot both be critical. After a strictly middle critical survivor, any next survivor of size sb2s\le b^2 has at least L1(s)L_1(s) neighbors.

More generally, a survivor of size hxh-x, xBx\le B, and surplus aba\le b can precede a strictly middle critical survivor only if xa2x\le a^2.

Proof. Let HH be the outside directed boundary, of size bb. If two adjacent xx-columns avoid HH, they form a strongly connected ladder, and all horizontal rows avoiding HH belong to one common component. The anchored-area argument of (46) still bounds a set outside that component by b2b^2. At this equality threshold the only new issue is a horizontal matching exception: an occupied row could contain the entire majority parity UU. In that case every one of the bb minority columns has a selected or boundary vertex. Following each minority column toward an empty boundary-free anchor forces a boundary vertex in that same column. All bb boundary vertices would therefore mark exactly VV, contradicting the assumed adjacent unmarked pair. The exception is excluded. The original weighted row sum now gives area at most b2b^2; applied to the transposed complement it gives deficiency at most b2+bb^2+b. Both contradict the strict-middle inequalities.

Thus no adjacent columns are unmarked. With only bb marked columns on a path of 2b+12b+1 positions, they must be exactly VV, with one boundary vertex (v,cv)(v,c_v) on each. In phase zero every UU fiber is a prefix, and directed closure gives RvRu,RuRv{cv}(uv an edge).R_v\subseteq R_u,\qquad R_u\setminus R_v\subseteq\{c_v\} \quad(uv\text{ an edge}). If fiber 2jU2j\in U were empty, summing the neighboring length bounds would give Rj2+(bj)2b2|R|\le j^2+(b-j)^2\le b^2. Applying the same argument to the transposed complement shows that a full UU fiber forces deficiency at most BB. Thus every UU fiber is nonempty and nonfull. A VV fiber cannot contain a point above cvc_v: its forward chain would reach the missing far endpoint without another boundary vertex. Hence it too is a prefix, with the asserted adjacent lengths.

Its neighborhood leaves the UU fibers unchanged, so misses their far endpoints. An opposite-phase strictly middle critical suffix contains all those endpoints, proving incompatibility. Physically the next belief omits an entire longitudinal endpoint row. Its next survivor lies in the minority class of the odd rectangle obtained by removing that row. Theorem 5.1 gives L1(s)L_1(s) for sb2s\le b^2; its opposite-corner term cannot improve the bound.

For the final assertion set A=N(R)A=\overline{N(R)}. Then A=xa|A|=x-a and N(A)RN(A)\subseteq\overline R, so its surplus is at most aa. If the next survivor is strictly middle critical, it contains the favored endpoint row, and AA omits it. In the smaller odd rectangle the minority capacity is hb12Bh-b-1\ge2B, whereas ABa|A|\le B-a. Its reflected profile term is at least b+1b+1. Thus surplus at most aba\le b forces Aa(a1)|A|\le a(a-1), or xa2x\le a^2. ◻

The physical construction

Use the root-selected form of Lemma 12.2 with Q=P2b+1Q=P_{2b+1}. A physical-color-pp envelope AA containing all its b+1pb+1-p bottom roots erodes to an opposite-phase pyramid EE with N(E)A,E=A(b+1p). N(E)\subseteq A,\qquad |E|=|A|-(b+1-p). (80)

Choose a phase-pp terminal survivor RR of rank 2R+p=r+12|R|+p=r+1: use (R,p)=(r/2,1)(|R|,p)=(r/2,1) for even rr, and ((r+1)/2,0)((r+1)/2,0) for odd rr. Quadrant prefixes and the pyramid plateau bound provide such an RR with N(R)J(r)|N(R)|\le J(r). For r=0r=0 use the empty phase-one survivor.

Enlarge RR by mm vertices inside the finite predecessor ideal, including all phase roots, then apply (80). This backward step raises its rank by exactly DD; the root choice is admitted since mb+1m\ge b+1. After q1q-1 steps the first survivor has rank r+1+(q1)D=2h2mr+1+(q-1)D=2h-2m and phase zero, since qq and rr have the same parity. One last enlargement by mm gives the full color class. Reading the nested envelopes forwards gives qq inspection days ending, after movement, in at most J(r)mJ(r)\le m rooms. All requested cardinalities are at most hh, since the backward ranks increase to 2h2m2h-2m.

Reflection in the even longitudinal side lets either initial physical cohort use this favorable relative phase independently. A forward qq-day half-search and a reversed half-search meet on one middle day; their endpoint envelopes have opposite colors and total size at most 2J(r)2J(r). Inspect their union when 2J(r)m2J(r)\le m. Otherwise concatenate two (q+1)(q+1)-day solo searches. For r=0r=0, two qq-day searches suffice. Walk reversal justifies the backward half even when its terminal set is only a containing envelope. This proves all upper bounds in (79).

A corner potential with at most one lost inspection

Throughout the lower-bound argument that follows, assume m>B=b(b+1)m>B=b(b+1). Put N=2hN=2h and retain the function FF of (36). Define C=min0xB{x+F(2(hx+ρ(x)))}. C=\min_{0\le x\le B}\{x+F(2(h-x+\rho(x)))\}. (81) The following arithmetic records precisely how much the far corner can improve the potential.

Lemma 14.3 (Corner estimates). One has F(N)1CF(N)F(N)-1\le C\le F(N), with equality C=F(N)C=F(N) if r=0r=0. For 0ab0\le a\le b, 0xa(a+1)0\le x\le a(a+1), and U{N,N1}U\in\{N,N-1\}, xa2  x+F(U2(xa))F(U),x+F(U2(xa)+1)F(U).\begin{aligned} x\le a^2&\ \Longrightarrow\ x+F(U-2(x-a))\ge F(U), \\ x+F(U-2(x-a)+1)&\ge F(U). \end{aligned}(82, 83) In particular CF(N1)C\ge F(N-1).

Proof. Cases with xax\le a, or a source in the cardinality branch, follow directly from monotonicity and F(v)v/2F(v)\ge\left\lfloor v/2\right\rfloor. Otherwise put t=xa>0t=x-a>0, d=bad=b-a. Since 2t2b2<D2t\le2b^2<D, a target crosses at most one period boundary. If it enters the final cardinality branch, replacing its actual value by the periodic expression only lowers it, as in Lemma 8.3. Write ρp(v)=Lp(v)v\rho_p(v)=L_p(v)-v, with ρp(0)=0\rho_p(0)=0.

Without a crossing, an even remainder 2k2k in the uncorrected cost has possible discount ρ1(k)ρ1(kt)a\rho_1(k)-\rho_1(k-t)-a. If kt>0k-t>0, square/pronic subadditivity makes this nonpositive. If k=tk=t, it is at most one since Q(t)a+1Q(t)\le a+1; when xa2x\le a^2, the stronger ta(a1)t\le a(a-1) makes it nonpositive. An odd remainder gives ρ0(k+1)ρ0(kt+1)a0\rho_0(k+1)-\rho_0(k-t+1)-a\le0 by square-root subadditivity. For the corrected cost, put v=kt+1>0v=k-t+1>0. The two discounts are ρ1(k)a1ρ0(v),ρ0(k+1)aρ1(v),\rho_1(k)-a-1-\rho_0(v),\qquad \rho_0(k+1)-a-\rho_1(v), both nonpositive: use kR(v)2+a21k\le R(v)^2+a^2-1 and k+1Q(v)(Q(v)1)+a2k+1\le Q(v)(Q(v)-1)+a^2, respectively. If a root is clipped, either the same estimate applies or the cap makes the claim immediate.

At a crossing set λ=mb+kx+ab2a2+k+1.\lambda=m-b+k-x+a\ge b^2-a^2+k+1. For even remainder 2k>02k>0 put c=ρ1(k)a+1c=\rho_1(k)\le a+1; for odd remainder 2k+12k+1 put c=ρ0(k+1)ac=\rho_0(k+1)\le a. The uncorrected discounts are respectively d+cρ0(λ)d+c-\rho_0(\lambda) and d+1+cρ1(λ)d+1+c-\rho_1(\lambda). They are at most one, because λ(d+c2)22d(ac+2)+c>0,λ(d+c1)(d+c2)2d(ac)+3d+c>0.\begin{aligned} \lambda-(d+c-2)^2&\ge2d(a-c+2)+c>0,\\ \lambda-(d+c-1)(d+c-2)&\ge2d(a-c)+3d+c>0. \end{aligned} These follow from k(c1)(c2)+1k\ge(c-1)(c-2)+1 and k(c1)2k\ge(c-1)^2, respectively. When k=0k=0 in the even case, λ>d2\lambda>d^2 instead makes the discount negative; this also proves C=F(N)C=F(N) for remainder zero.

Under xa2x\le a^2, the lower bound on λ\lambda gains aa, and the stronger estimates are λ(d+c1)22d(ac+1)+ac+3>0,λ(d+c)(d+c1)2d(ac)+d+ac+2>0.\begin{aligned} \lambda-(d+c-1)^2&\ge2d(a-c+1)+a-c+3>0,\\ \lambda-(d+c)(d+c-1)&\ge2d(a-c)+d+a-c+2>0. \end{aligned} Here cac\le a in both rows. They prove (82). For the corrected target the discounts are d+cρ1(λ)d+c-\rho_1(\lambda) and d+cρ0(λ+1)d+c-\rho_0(\lambda+1), controlled by λ(d+c1)(d+c2)2d(ac)+3d+2>0,λ+1(d+c1)22d(ac+1)+2>0.\begin{aligned} \lambda-(d+c-1)(d+c-2)&\ge2d(a-c)+3d+2>0,\\ \lambda+1-(d+c-1)^2&\ge2d(a-c+1)+2>0. \end{aligned} The required root thresholds do not exceed their caps b+1b+1 and bb. Again k=0k=0 in the even case follows directly from λ>d(d1)\lambda>d(d-1). A corrected target exactly at a period boundary uses J(D)=mJ(D)=m, equal to the next period’s zero remainder. This proves (83). Finally apply it at U=N1U=N-1, with a=ρ(x)a=\rho(x), to obtain CF(N1)C\ge F(N-1); x=0x=0 gives CF(N)C\le F(N). ◻

Initially mark both cohorts zero. Subsequently mark a belief by z=1z=1 exactly when its preceding survivor was strictly middle critical. Give a belief of size kk potential Φz(k)=min{F(2k+z),max(0,Ch+k)},Φz(0)=0.\Phi_z(k)=\min\{F(2k+z),\max(0,C-h+k)\},\qquad\Phi_z(0)=0. Every physical transition lowers this potential by at most its useful inspection allocation. For a survivor below hBh-B, this follows from Lemma 8.3 and Lemma 14.2: a critical middle move has marks 010\to1, a larger surplus dominates the alternating rank step, and a small survivor uses L0L_0 or L1L_1 according to the source mark. The small target counts are at most b2+b+1mb^2+b+1\le m, so their two ranks have the same cardinality potential. Sources of size at most mm are handled directly by matching. For a co-small survivor with deficiency xx, the definition of CC handles the target’s FF branch. Matching makes deficits grow by at most the useful allocation, handling the linear branch. Thus Tm2C/m. T_m\ge\left\lceil 2C/m\right\rceil. (84)

Since F(N)=qm+J(r)F(N)=qm+J(r), the corner estimates match the upper bound except possibly when r>0,J(r)=m/2+1,C=F(N)1. r>0,\qquad J(r)=\left\lfloor m/2\right\rfloor+1,\qquad C=F(N)-1. (85)

Separating the two corners on longer boards

Suppose h>m+2b2+b. h>m+2b^2+b. (86) It suffices to settle (85). Now mark a belief if its preceding survivor was either strictly middle critical, or co-small with deficiency xx, surplus aba\le b, and x>a2x>a^2. Use the common-cap potential Ψz(k)=min{F(N),F(2k+z)},Ψz(0)=0.\Psi_z(k)=\min\{F(N),F(2k+z)\},\qquad\Psi_z(0)=0. The new mark also forbids a critical next middle move by Lemma 14.2. For a co-small target, the corner estimates give x+F(target rank)F(N):x+F(\text{target rank})\ge F(N): use (82) when xa2x\le a^2 and (83) otherwise. Surplus greater than bb already gives the interior rank inequality.

For a source deficiency dd, monotonicity by two rank units gives d+F(N2d)F(N)d+F(N-2d)\le F(N). A marked source has d1d\ge1, and (85) together with CF(N1)C\ge F(N-1) gives d+F(N2d+1)F(N1)+1F(N).d+F(N-2d+1)\le F(N-1)+1\le F(N). Since the allocation is xdx-d, these estimates prove the potential inequality for every co-small target, including the common cap. For a small target, the old mark uses the conditional L1L_1 bound. A new co-small mark has source size at least hBh-B, so (86) prevents it from reaching size at most b2b^2 in one day. All other steps are the interior cases already checked. Both initial potentials are F(N)F(N), proving Tm2F(N)/m=2q+2T_m\ge\left\lceil 2F(N)/m\right\rceil=2q+2 in the sole possible gap.

Every q4q\ge4 satisfies (86), since h4m3b1,hm2b2bb2b+2>0.h\ge4m-3b-1,\qquad h-m-2b^2-b\ge b^2-b+2>0. Also q1q\ge1 because h>mh>m. For q=1q=1, write r=2s1r=2s-1; then h=m+sh=m+s and F(N)=h+min(R(s),b)F(N)=h+\min(R(s),b). A corner departure with t=xaa2t=x-a\le a^2 costs h+ah+a when tst\ge s, and h+a+min(R(st),b)h+a+\min(R(s-t),b) otherwise. Square-root subadditivity makes both at least F(N)F(N), so C=F(N)C=F(N) and there is no gap. For q=3q=3 in (85), write r=2k+1r=2k+1 and c=min(R(k+1),b)c=\min(R(k+1),b). Then k+c=m/2k+c=\left\lfloor m/2\right\rfloor, so kb(b1)/2k\ge b(b-1)/2, while h=3m2b+kh=3m-2b+k. Hence hm2b2bkb+2(b23b+4)/2>0.h-m-2b^2-b\ge k-b+2\ge(b^2-3b+4)/2>0. Only q=2q=2 still requires an argument.

A two-day bound closes the short-board case

Let q=2q=2, r=2k>0r=2k>0, and c=min(Q(k),b+1)c=\min(Q(k),b+1). Thus h=2mb+kh=2m-b+k and J(r)=k+cJ(r)=k+c. We claim that after any two inspections and their following moves the total deficit of the two cohorts is at most D=hkc. D_*=h-k-c. (87) Use the symmetric inverse profile I(z)=zmin{ρ(z),b,R(hz)},0zh,I(z)=z-\min\{\rho(z),b,R(h-z)\},\qquad0\le z\le h, whose superadditivity was proved in Lemma 12.1. Since hm=mb+k>b2h-m=m-b+k>b^2, the first-day reflected term exceeds bb. Unless all mm useful first-day inspections go to one cohort and its survivor has surplus exactly bb, the first-day total deficit is at most mb1m-b-1. Indeed a nontrivial split would otherwise have positive costs a,aa,a' with a+aba+a'\le b, forcing ma(a+1)+a(a+1)Bm\le a(a+1)+a'(a'+1)\le B, a contradiction. Higher actual surplus only strengthens this conclusion.

In these cases superadditivity bounds the second-day total deficit by I(Z)I(Z), where Z=2mb1<hZ=2m-b-1<h. As Z>BZ>B and hZ=k+1h-Z=k+1, I(Z)=Zmin(b,R(k+1))hkc,I(Z)=Z-\min(b,R(k+1))\le h-k-c, using 1+min(b,R(k+1))c1+\min(b,R(k+1))\ge c.

In the exceptional pure first day, the survivor of size hmh-m is strictly middle critical. The active next belief has m+km+k rooms, and its mate is full. Allocate mum-u to the active cohort and uu to its mate on day two, leaving active survivor size s=k+us=k+u. If s<hBs<h-B, Lemma 14.2 gives at least L1(s)L_1(s) neighbors, both in the small and middle ranges. The mate’s deficit is at most uu, so their total deficit is at most hL1(k+u)+uhkch-L_1(k+u)+u\le h-k-c. If shBs\ge h-B, then u2mbB>mbb2+1u\ge2m-b-B>m-b\ge b^2+1, and the inverse profile gives I(u)=ubI(u)=u-b. The active survivor is nonempty and proper; the exact static profile therefore gives at least s+1s+1 neighbors. The total deficit is at most hkb1hkch-k-b-1\le h-k-c. This proves (87). Unused quotas may be filled monotonically, so the argument includes all schedules with budget at most mm.

Finally, a five-day capture would have two forward days, one middle inspection, and two reversed days. By (87), the two possible-position sets at the middle inspection intersect in at least 2h2D=2J(r)2h-2D_*=2J(r) cells. Every cell in this intersection supports an avoiding walk on each side; their concatenation must be intercepted by the middle inspection. If 2J(r)>m2J(r)>m, this is impossible, giving the required sixth day. All remaining cases already match (84). The one- and two-day regimes follow by inspecting whole color classes. This completes Theorem 14.1.

Paths: matching geometry and a probe-count potential

We prove the path formula stated in (1). The geometric lower proof applies to arbitrary possible-position sets. An interval description is used only for the explicit strategy attaining the bound.

An optimal four-day search of eight rooms with two daily probes. The rows show every position still possible before that day’s inspection.

Neighborhood inequalities

Number the vertices 0,,n10,\ldots,n-1. Each set below is contained in one color class. If nn is even, the edges (0,1),(2,3),(0,1),(2,3),\ldots give a perfect matching and therefore N(R)R|N(R)|\ge |R|. We need the following information about equality.

Lemma 15.1. On an even path, if 0<R<n/20<|R|<n/2 and N(R)=R|N(R)|=|R|, then N(R)N(R) contains neither endpoint. Every nonempty set containing neither endpoint has strictly more neighbors than vertices. On an odd path with larger class EE and smaller class OO, N(R)min{R,O}(RE),N(R)R+1(RO).|N(R)|\ge\min\{|R|,|O|\}\quad(R\subseteq E),\qquad |N(R)|\ge |R|+1\quad(\varnothing\ne R\subseteq O).

Proof. Let MM send each vertex of an even path to its matching partner. Equality implies N(R)=M(R)N(R)=M(R). If RR consists of even vertices and contains 2i>02i>0, its neighbor 2i12i-1 forces 2i2R2i-2\in R. Thus equality makes RR an initial segment of the even vertices. Similarly an odd equality set is a final segment of the odd vertices. These statements prove both assertions about endpoints: a proper initial even segment has an odd neighborhood missing the far endpoint, and a proper final odd segment has an even neighborhood missing the other endpoint. Conversely, a nonempty equality set must itself contain an endpoint.

When nn is odd, for every even vertex gg there is a matching covering all vertices except gg: match consecutive vertices separately to its left and right. If RER\subsetneq E, choose gRg\notin R to inject RR into N(R)N(R). For R=ER=E its neighborhood is OO. Finally, for nonempty ROR\subseteq O, the matching exposing vertex 00 injects RR into N(R)N(R), and equality is impossible: the least occupied odd vertex has a left neighbor that would force a smaller occupied odd vertex, or the unmatched vertex 00. Thus there is at least one extra neighbor. ◻

Track separately the targets that started in the two colors. Their current colors are opposite each day, so their allocations p,qp,q always satisfy p+qmp+q\le m. Write bb for a cohort’s size before inspection. On an even path retain a bit zz: it is one just after a nonempty proper zero-growth neighborhood, and zero otherwise. Such a set is endpointless by the lemma. A surviving subset of it therefore expands strictly. The rank u=2b+zu=2b+z, with rank zero for the empty set, is at most nn and each physical step dominates FC(u,p)={0,u/2p,min{C,u2p+c},u/2>p, F_C(u,p)=\begin{cases} 0,&\left\lfloor u/2\right\rfloor\le p,\\ \min\{C,u-2p+c\},&\left\lfloor u/2\right\rfloor>p, \end{cases} (88) with C=n,c=1C=n,c=1. Indeed, a zero-growth step raises the bit from zero to one; a step following bit one gains a vertex and may discard the bit. Both changes give at least one unit after subtracting 2p2p.

For odd nn, assign rank 2b2b in EE, rank 2b+12b+1 in nonempty OO, and zero to the empty set. The same comparison holds with c=1c=1 and alternating new caps n+1n+1 in EE and nn in OO. Initially the ranks are n+1,nn+1,n. Replacing both caps and initial ranks by nn gives a valid lower comparison, since FCF_C is nondecreasing in CC and uu.

A general potential for the counting argument

Lemma 15.2 (Affine-rank potential). Let 0c<2m0\le c<2m, D=2mcD=2m-c, and uCu\le C. Define J(u)=max{uc2,0}D,Φ(u)=u+cJ(u)2.J(u)=\left\lfloor\frac{\max\{u-c-2,0\}}D\right\rfloor,\qquad \Phi(u)=\left\lfloor\frac{u+cJ(u)}2\right\rfloor. For 0pm0\le p\le m, the constant-cap transition (88) satisfies Φ(u)p+Φ(FC(u,p))\Phi(u)\le p+\Phi(F_C(u,p)). Consequently two such ranks sharing budget mm need at least (Φ(u0)+Φ(v0))/m\left\lceil(\Phi(u_0)+\Phi(v_0))/m\right\rceil rounds to become zero.

Proof. Both JJ and Φ\Phi are nondecreasing. If capture occurs, then u2p+12m+1u\le2p+1\le2m+1, whence J(u)=0J(u)=0 and Φ(u)p\Phi(u)\le p. If 2pc2p\le c and capture does not occur, the next rank is at least uu, because uCu\le C. Otherwise put v=u2p+cv=u-2p+c. It is positive and at most uCu\le C, so the cap does not act. Since 2pcD2p-c\le D, J(u)J(v)+1J(u)\le J(v)+1. Therefore u+cJ(u)v+2p+cJ(v).u+cJ(u)\le v+2p+cJ(v). Divide by two and take floors. Summing the resulting inequalities over both ranks and all rounds proves the last assertion. ◻

For paths c=1c=1. Suppose n>m2n>m\ge2, put D=2m1D=2m-1, and use positive remainder coordinates n=qD+r+2,1rD.n=qD+r+2,\qquad 1\le r\le D. Here n3n\ge3 and q0q\ge0. Direct substitution gives Φ(n)=qm+(r+2)/2.\Phi(n)=qm+\left\lfloor(r+2)/2\right\rfloor. The resulting lower bound is 2q+12q+1 when rm2r\le m-2, or when r=m1r=m-1 and mm is even; otherwise it is 2q+22q+2. For even nn this is the required answer. For odd nn it misses just the case mm even and r=m1r=m-1, which we now settle.

The equality obstruction on odd paths

Here n=q(2m1)+m+1n=q(2m-1)+m+1 with m,qm,q even. Assume a strategy succeeds in T=2q+1T=2q+1 days. Use the exact alternating-cap comparison counters. For each counter, select its first zero and its last full state before that zero. If this interval starts at time aa, has length LL, and uses PP probes, all intermediate transitions are unsaturated. Telescoping the affine transitions, including the final capture inequality, gives C(a)+L2P+2,PLm.C(a)+L\le2P+2,\qquad P\le Lm. Since C(a)nC(a)\ge n, these imply Lq+1L\ge q+1 and PA:=qm+m/2P\ge A:=qm+m/2. The two cohorts together have only Tm=2ATm=2A probes, so equality holds for both. In particular L=q+1L=q+1 and C(a)=nC(a)=n: both intervals start when their cohort is in the smaller color class.

Their starting times have opposite parity and are at most qq. The odd one, aa, satisfies 1aq11\le a\le q-1 because qq is even. If the even starting time is zero, both intervals lie in the first 2q2q days; otherwise both lie in the last 2q2q days. Their total probe count 2A=(2q+1)m2A=(2q+1)m exceeds the 2qm2qm available in either window. This contradiction proves that one extra day is necessary. The argument permits overlapping active intervals and arbitrary wasted inspections outside them.

For m=1m=1, the same potential has D=1D=1 and Φ(n)=n2\Phi(n)=n-2 for n3n\ge3, giving 2n42n-4 days. On P2P_2 one probe cannot inspect both initial possibilities, and two consecutive inspections of one endpoint suffice. A single room is inspected directly.

An explicit strategy attaining the bound

For this construction number rooms 1,,n1,\ldots,n. Put A(r)={r,r2,r4,}{1,,n}.A(r)=\{r,r-2,r-4,\ldots\}\cap\{1,\ldots,n\}. For 1r<n1\le r<n, N(A(r))=A(r+1)N(A(r))=A(r+1). Inspecting the bb largest vertices of A(r)A(r) leaves A(r2b)A(r-2b); if nonempty, movement changes the frontier to r2b+1r-2b+1. Reflection in the middle of the path gives the same rule in the opposite direction.

Assume n3n\ge3 and n>mn>m. Set d=2m1d=2m-1 and e=n2d,ρ=n2(e1)d,c=ρ/2+1,=mc.e=\left\lceil\frac{n-2}{d}\right\rceil,\qquad \rho=n-2-(e-1)d,\qquad c=\left\lfloor\rho/2\right\rfloor+1,\qquad \ell=m-c. Thus 1ρd1\le\rho\le d. Start with the cohort occupying A(n1)A(n-1) and inspect its largest mm possible rooms each day. Its frontier before day tt is n1(t1)dn-1-(t-1)d, so it finishes on day ee, using only cc inspections that day. If >0\ell>0, assign the remaining \ell inspections to the other cohort immediately; if =0\ell=0, start that cohort on day e+1e+1.

Before its first inspection the second cohort is a whole color class. For odd nn, use the same orientation. Its frontier is nn on an odd starting day and n1n-1 on an even starting day. For even nn, choose the orientation whose frontier is n1n-1: reflect when the starting day is odd. If its first batch has size bb, the surviving frontier is R02b+1R_0-2b+1. Continue with batches of mm until capture. A nonempty frontier A(R)A(R) with R2R\ge2 requires (R1)/d\left\lceil(R-1)/d\right\rceil such days; a singleton is inspected once.

For completeness the arithmetic determining the joining day is as follows. If =0\ell=0 the total is 2e2e. If >0\ell>0, the totals are 2e2+2ρ+2d(n odd),2e2+ρ+2cd(n even).2e-2+\left\lceil\frac{2\rho+2}{d}\right\rceil\quad(n\text{ odd}),\qquad 2e-2+\left\lceil\frac{\rho+2c}{d}\right\rceil\quad(n\text{ even}). They equal 2e12e-1 exactly when ρm2\rho\le m-2, or when ρ=m1\rho=m-1 and n,mn,m are both even; otherwise they equal 2e2e. Comparing with (2n4)/d\left\lceil(2n-4)/d\right\rceil proves (1). For m=1m=1 it gives 2n42n-4. If nmn\le m, inspect every vertex on the first day. This completes both the construction and the arbitrary- strategy lower bound.

Two rows: an exact pair of counters

A two-row rectangle P2PnP_2\mathbin{\square}P_n is also called a ladder: the two horizontal paths are joined by one vertical edge in each column. Its graph terminology does not impose any restriction on the searcher’s movements between inspections.

For a cohort of fixed initial color, at any one time exactly one room per column has the right color. Identify its possible rooms with their column set B{1,,n}B\subseteq\{1,\ldots,n\}. A vertical move keeps the column, and a horizontal move changes it by one. Consequently the next column set after inspections is the closed path neighborhood NPn[BS]=(BS)NPn(BS).N_{P_n}[B\setminus S]=(B\setminus S)\cup N_{P_n}(B\setminus S). Every nonempty proper column set gains at least one column. An initial or final interval attains the bound and stays an interval. Therefore the exact one-cohort size transition with pp probes is F(b,p)={0,pb,min{n,bp+1},p<b.F(b,p)=\begin{cases}0,&p\ge b,\\ \min\{n,b-p+1\},&p<b. \end{cases} The two counters start at (n,n)(n,n) and share the budget mm. This is an exact lower and upper model: the inequality holds for arbitrary supports, and two boundary intervals attain every chosen sequence of allocations.

Theorem 16.1. For n2n\ge2 the minimum-time function is (2), with value \infty for m1m\le1 and value one for m2nm\ge2n.

Proof. For 2m<2n2\le m<2n, put N=n1N=n-1 and M=m1M=m-1. Assign a counter of size bb the weight w(b)=max{b1,0}w(b)=\max\{b-1,0\}. With a positive allocation pp, its weight drops by at most p1p-1; with no allocation its weight cannot drop. Thus the combined daily drop is at most MM, and T2N/MT\ge\left\lceil 2N/M\right\rceil.

Suppose 2N=TM2N=TM. Equality in this bound requires every day to allocate all mm probes to exactly one cohort and to reduce its weight by exactly MM. Each initial weight NN must consequently be divisible by MM. If 2N2N is divisible by MM but NN is not, one extra day is necessary. This is exactly the exceptional condition that MM is even and NM/2(modM)N\equiv M/2\pmod M.

To attain the answer, write N=qM+sN=qM+s, 0s<M0\le s<M. If s=0s=0, clear the first interval in qq full days and the second in qq more. Suppose s>0s>0. After qq full days on the first interval its size is s+1s+1. On the next day finish it with s+1s+1 probes and assign the remaining MsM-s to the other, still full, interval. Its next size is b=n(Ms)+1=(q1)M+2s+2.b=n-(M-s)+1=(q-1)M+2s+2. It then needs (b1)/M\left\lceil(b-1)/M\right\rceil days. The total is 2q+2s+1M,2q+\left\lceil\frac{2s+1}{M}\right\rceil, which is the claimed ceiling plus precisely the equality correction. The second interval always survives the shared day. If q=0q=0, then s=n1s=n-1 and its allocation is Ms=mn<nM-s=m-n<n, because m<2nm<2n. If q1q\ge1, then Mn1M\le n-1 and Ms<nM-s<n as well. Thus b2b\ge2 in both cases, and the displayed solo-day formula counts at least one remaining day. The algebra also holds for q=0q=0, by the integer translation rule for ceilings.

For one probe, an uninspected cohort remains full. Inspecting one room of a full color class also leaves the other color class full after movement, since every room on a ladder with n2n\ge2 has at least two neighbors. Hence capture is impossible. The one-day assertion is immediate from the number of initial rooms. For n=1n=1 the graph is P2P_2 and the path result applies. ◻

Three rows: a historical rank and the exact time

We prove the three-row classification in (3), including optimal inspection schedules. Put G=P3PnG=P_3\mathbin{\square}P_n. The length n=1n=1 is a three-vertex path. Henceforth n2n\ge2; a four-cycle contained in GG precludes capture with one inspection per day. Indeed, a target may stay on that cycle, where a nonempty parity cohort always has two possible vertices after movement. The constructions below show that two inspections suffice.

Even lengths: the efficient survivor sets

Let n=2sn=2s and h=3sh=3s, so both parity classes have hh vertices. In coordinates (column,row)(\text{column},\text{row}), label one parity by ai=(2i,0),bi=(2i,2),ci=(2i+1,1)(0i<s).a_i=(2i,0),\qquad b_i=(2i,2),\qquad c_i=(2i+1,1) \quad(0\le i<s). Match these vertices respectively to (2i+1,0),(2i+1,2),(2i,1)(2i+1,0),(2i+1,2),(2i,1) in the other parity. Contracting an edge followed by the inverse matching map gives a directed graph DD on the labelled parity. Besides loops, its arcs are aicibi,aiai1,bibi1,cici+1,a_i\leftrightarrow c_i\leftrightarrow b_i,\qquad a_i\to a_{i-1},\quad b_i\to b_{i-1},\quad c_i\to c_{i+1}, with out-of-range subscripts omitted. Consequently, for every survivor set RR in this parity, NG(R)R=ND+(R)R. |N_G(R)|-|R|=|N_D^+(R)\setminus R|. (89) Each triple is strongly connected; its middle chain moves right and its outer chains move left. Thus DD is strongly connected, and every nonempty proper parity set has surplus at least one.

Lemma 17.1. If RR is nonempty, Rh2|R|\le h-2, and N(R)=R+1|N(R)|=|R|+1, then R={ai,bi,ci:0i<j}U,U{aj,bj},0j<s.R=\{a_i,b_i,c_i:0\le i<j\}\cup U, \qquad U\subseteq\{a_j,b_j\},\quad 0\le j<s. For the opposite parity the analogous sets start at the other end. Moreover, if RN(R)R'\subseteq N(R) is nonempty, also has surplus one, and Rh2|R'|\le h-2, then R=h2|R|=h-2 and R=1|R'|=1.

Proof. By (89), the outside boundary is a single vertex vv, and RR is closed under outgoing arcs of DvD-v. Deleting an outer vertex leaves a strongly connected graph: the other outer chain still moves left, the middle chain moves right, and all remaining outer vertices connect to their middle vertices. A nonempty closed set would then have all h1h-1 remaining vertices, contrary to the hypothesis.

Deleting cjc_j leaves the prefix triples, the two singletons aj,bja_j,b_j, and the suffix triples as strongly connected components, omitting empty components. Arcs go from the suffix to each singleton and from each singleton to the prefix. A nonempty outgoing-closed set of size at most h2h-2 is therefore precisely the stated prefix with some of the two singletons. Reflection in the long coordinate exchanges the physical parities and gives the opposite description.

Every nonempty classified set contains an outer corner at its starting end, and a set of size at least two contains both outer corners there. The neighborhood of RR contains no outer corner at the opposite end unless j=s1j=s-1. In that case the size bound permits at most one of aj,bja_j,b_j. Containing an opposite corner therefore forces R=h2|R|=h-2 and supplies exactly one such corner. Hence RR' must be a singleton. ◻

A rank valid for arbitrary supports

We first assume m<h2m<h-2. Track the two initial-parity cohorts separately. For a physical support AA, set z=1z=1 if the preceding survivor set was nonempty, had surplus one, and had size at most h2h-2; otherwise set z=0z=0. In particular full and empty supports have label zero. Define ρ(A)=2A+z\rho(A)=2|A|+z for nonempty AA, and ρ()=0\rho(\varnothing)=0. This label records history and imposes no shape restriction on AA.

For a numerical rank 0u2h0\le u\le2h and an allocation pp, put Fh(u,p)={0,u/2p,min{2h,u2p+3},u/2>p. F_h(u,p)= \begin{cases} 0,&\left\lfloor u/2\right\rfloor\le p,\\ \min\{2h,u-2p+3\},&\left\lfloor u/2\right\rfloor>p. \end{cases} (90) It is nondecreasing in uu and nonincreasing in pp.

Lemma 17.2. If pm<h2p\le m<h-2 useful probes leave RAR\subseteq A, then ρ(N(R))Fh(ρ(A),p)\rho(N(R))\ge F_h(\rho(A),p).

Proof. Write r=R=Apr=|R|=|A|-p. Empty survivors are immediate. If r=hr=h or r=h1r=h-1, the neighborhood is full: every opposite-parity vertex has degree at least two. Thus its rank is the cap 2h2h.

Suppose 1rh21\le r\le h-2. If the surplus is one, the next label is one. The old label cannot be one: Lemma 17.1 would require a support of size h1h-1 to be reduced to one vertex, using h2h-2 probes. Hence the new rank is 2(r+1)+1=ρ(A)2p+32(r+1)+1=\rho(A)-2p+3. If the surplus is at least two, the new rank is at least 2r+4ρ(A)2p+32r+4\ge\rho(A)-2p+3, since the old label is at most one. Capping can only weaken these inequalities. ◻

Starting from (2h,2h)(2h,2h), compare any actual schedule to the two-counter process (u,v)(Fh(u,p),Fh(v,mp)),0pm.(u,v)\longmapsto\bigl(F_h(u,p),F_h(v,m-p)\bigr),\qquad 0\le p\le m. Its terminal inspection condition is u/2+v/2m\left\lfloor u/2\right\rfloor+\left\lfloor v/2\right\rfloor\le m. Use the actual two useful allocations; assign unused budget arbitrarily. Monotonicity and Lemma 17.2 keep the abstract ranks below the actual ranks throughout, so the numerical process captures no later than the actual schedule.

Conversely this process is physically realizable. Order each parity by increasing coordinate sum, breaking ties by increasing column. The two orders are E:;(0,0),((2i2,2),(2i1,1),(2i,0))i=1s1,(2s2,2),(2s1,1),O:;(0,1),(1,0),((2i1,2),(2i,1),(2i+1,0))i=1s1,(2s1,2).\begin{aligned} E:;&(0,0),\quad ((2i-2,2),(2i-1,1),(2i,0))_{i=1}^{s-1},\quad(2s-2,2),(2s-1,1),\\ O:;&(0,1),(1,0),\quad ((2i-1,2),(2i,1),(2i+1,0))_{i=1}^{s-1},\quad(2s-1,2). \end{aligned} Empty repeated blocks are omitted. Reading the neighbors of successive vertices in these lists gives, for every k>0k>0, N(Ek)=Omin(h,k+1),N(Ok)=Emin(h,k+2).N(E_k)=O_{\min(h,k+1)},\qquad N(O_k)=E_{\min(h,k+2)}. Here Ek,OkE_k,O_k denote prefixes of size kk; empty prefixes have empty neighborhood. Deleting a suffix of pp vertices and moving therefore realizes (90), with phases z=0,1z=0,1 respectively. A full cohort may choose either reflected orientation freely; reflection in the long coordinate exchanges physical parities. The two cohorts choose these orientations independently. Proper cohorts retain their orientation until they fill a parity class again or disappear. Thus the numerical process gives the exact time for m<h2m<h-2.

The even case: one critical budget and a specialization

At m=2m=2 and n4n\ge4, put V(u)=(u4)+V(u)=\left(u-4\right)_+. Directly from (90), allocating zero or one probe cannot lower VV, and allocating two lowers it by at most one, including capture. The shared two-probe budget therefore lowers the sum of the two potentials by at most one per day. Its initial value is 2(2h4)=6n82(2h-4)=6n-8, proving T26n8T_2\ge6n-8. A full two-probe solo sweep decreases its rank by one until the final rank is at most five, then captures; its duration is 2h42h-4. Two independently oriented sweeps attain 6n86n-8. For n=2n=2, the same value is four by the two-row theorem (2).

For every m3m\ge3 and even n4n\ge4, specialize Theorem 14.1 to b=1b=1. Its numerator is 3n43n-4, its denominator is D=2m3D=2m-3, and its corner cost is J(r)=r/2+2J(r)=\left\lfloor r/2\right\rfloor+2 for r>0r>0. Since 3n4=qD+r3n-4=qD+r is even, rq(mod2)r\equiv q\pmod2, so 2J(r)=r+4(qmod2).2J(r)=r+4-(q\bmod2). This is exactly the even-length condition in (3). The same theorem includes all boundary budgets and the one- and two-day cases; n=2n=2 is already covered by the two-row theorem.

The preceding numerical model also retains a useful interval bound. For m<h2m<h-2, put W=2h4W=2h-4 and D=2m3D=2m-3. In a cohort’s interval from its last full state before first capture to that capture, let \ell be the number of days and PP its total inspections. No intermediate step saturates; the 1\ell-1 nonterminal moves each add three rank units. The final capture inequality and PmP\le m\ell give PW+32,DW. P\ge\left\lceil\frac{W+3\ell}{2}\right\rceil,\qquad \ell D\ge W. (91) These two cohort intervals may overlap arbitrarily, and their inspection totals still sum to at most the whole schedule’s budget.

Odd lengths as a specialization of the general theorem

For odd n3n\ge3, Theorem 8.1 applies with b=1b=1 at every feasible budget m2m\ge2. For a positive argument, its corner functions are L0(k)=k+1L_0(k)=k+1 and L1(k)=k+2L_1(k)=k+2. Consequently J(r)=r/2+2,δ(r)=rmod2,2J(r)+δ(r)=r+4(r>0).J(r)=\left\lfloor r/2\right\rfloor+2,\qquad \delta(r)=r\bmod2,\qquad 2J(r)+\delta(r)=r+4\quad(r>0). Since Nw1=3n4N-w-1=3n-4, its quotient, remainder, and shared-day condition are exactly the odd-length branch of (3). The same theorem gives the one- and two-day thresholds. Its lower bound applies to arbitrary strategies, and its two sweeps give the attaining schedules. Thus no separate odd-length rank or equality argument is required. Together with the even-length proof and the already treated degenerate boards, this completes every three-row parameter case.

Four rows as a uniform-theorem corollary

For G=P4PnG=P_4\mathbin{\square}P_n, n4n\ge4, the improved root threshold makes every feasible budget a case of Theorem 12.3. No separate productive-inspection argument is needed.

Corollary 18.1 (Every four-row budget). Formula (4) holds, with physical attaining strategies and lower bounds against arbitrary searches. In particular T3(G)=4n4,T4(G)=2n2.T_3(G)=4n-4,\qquad T_4(G)=2n-2.

Proof. Put b=2b=2, h=2nh=2n. The uniform budget threshold is max{3,2(21)+1}=3\max\{3,2(2-1)+1\}=3. Its division is h2=q(m2)+rh-2=q(m-2)+r. Since J(1)=2J(1)=2 and J(r)=r+2J(r)=r+2 for r2r\ge2, the central-day condition is automatic for r=1r=1 and otherwise is m2r+4m\ge2r+4. This gives (4), including its extreme budgets. For m=3,4m=3,4 the remainder is zero, giving the two displayed specializations. The rectangular feasibility threshold excludes m2m\le2. Smaller lengths reduce by exchanging coordinates to the path, two-row, or three-row cases. ◻

Five rows

Five rows admit a complete minimum-time classification at every budget. The two parities of the long side require different lower arguments.

Theorem 19.1 (Five rows, three inspections). For every n5n\ge5, T3(P5Pn)=10n20. T_3(P_5\mathbin{\square}P_n)=10n-20. (92) The odd-length proof uses the profiles of Theorem 5.1. The even-length proof uses an exhaustive finite symbolic certificate for arbitrary supports. Both arithmetic potential inequalities are verified in Lean; the complete five-row geometric argument is not presently formalized.

Odd lengths: exact profiles and a parity potential

Suppose n5n\ge5 is odd, and put h=(5n1)/212h=(5n-1)/2\ge12. The even physical parity has h+1h+1 vertices and the odd physical parity has hh. Denote these parities by z=0,1z=0,1, respectively. Specializing Theorem 5.1 to short-side parameter b=2b=2 gives g0(0)=g1(0)=0g_0(0)=g_1(0)=0 and g0(k)={h,hkh+1,k+1,k=1 or h3kh1,k+2,2kh4,g1(k)={h+1,k=h,k+2,1k2 or h2kh1,k+3,3kh3.\begin{aligned} g_0(k)&=\begin{cases} h,&h\le k\le h+1,\\ k+1,&k=1\text{ or }h-3\le k\le h-1,\\ k+2,&2\le k\le h-4, \end{cases} \\ g_1(k)&=\begin{cases} h+1,&k=h,\\ k+2,&1\le k\le2\text{ or }h-2\le k\le h-1,\\ k+3,&3\le k\le h-3. \end{cases} \end{aligned}(93, 94) For example, the complementary corner term in the majority profile is at most one exactly when h+1k4h+1-k\le4. The minority corner term Q(k)Q(k) is at most two exactly when k2k\le2, and Q(0)=1Q(0)=1 handles its full set.

Define Wh(b,z)={0,b=0,1,1b2,b2,3b5,min{2b+z8, b+h+z10},b6. W_h(b,z)=\begin{cases} 0,&b=0,\\ 1,&1\le b\le2,\\ b-2,&3\le b\le5,\\ \min\{2b+z-8,\ b+h+z-10\},&b\ge6. \end{cases} (95) A reachable nonempty support has at least three vertices in parity zero and at least two in parity one: these are the minimum degrees of vertices in the opposite parities. Thus its size satisfies b=0or3zbh+1z. b=0\quad\hbox{or}\quad 3-z\le b\le h+1-z. (96)

Lemma 19.2 (Odd-length potential inequality). For h12h\ge12, z{0,1}z\in\{0,1\}, a size satisfying (96), and 0p30\le p\le3, Wh(b,z)Wh(gz((bp)+),1z)+1{p2}. W_h(b,z)\le W_h\bigl(g_z(\left(b-p\right)_+),1-z\bigr) +\mathbf{1}_{\{p\ge 2\}}. (97) For fixed h,zh,z, the function Wh(b,z)W_h(b,z) is nondecreasing in bb.

Proof. Substitute (93)(95), split source and target sizes at 0,2,50,2,5, select the smaller affine expression for sizes above five, and split the survivor size at the displayed profile endpoints. Every resulting branch is a linear integer inequality under h12h\ge12, p3p\le3, and (96). This complete case split, including truncated subtraction, is checked by potential_step and value_monotone in FiveRowOddRankArithmetic.lean. These proofs use Lean’s ordinary kernel-checked integer-arithmetic tactic and have no admitted cases. ◻

Take pp to be the number of useful probes actually meeting one cohort. Its survivor support has size bpb-p, and its actual next support has at least gz(bp)g_z(b-p) vertices. Monotonicity makes (97) valid for this actual transition. The cohorts occupy disjoint parities each day. Their useful allocations sum to at most three, so at most one receives two or more inspections. The sum of their potentials decreases by at most one per day. Initially Wh(h+1,0)=Wh(h,1)=2h9;W_h(h+1,0)=W_h(h,1)=2h-9; at capture both vanish. Thus every strategy takes at least 4h18=10n204h-18=10n-20 days.

For an attaining strategy, sweep the initially minority cohort first. Use the compatible diagonal prefixes of Theorem 5.1; each day delete its last three vertices, or all of it if fewer remain. The first two transitions are (h,1)(h,0)(h2,1).(h,1)\longrightarrow(h,0)\longrightarrow(h-2,1). For every minority size 6bh26\le b\le h-2, two rounds give (b,1)(b,0)(b1,1).(b,1)\longrightarrow(b,0)\longrightarrow(b-1,1). After h7h-7 such pairs the support has size five in the minority parity. The final three transitions are (5,1)(4,0)(2,1)0.(5,1)\longrightarrow(4,0)\longrightarrow(2,1)\longrightarrow0. The solo duration is 2+2(h7)+3=2h92+2(h-7)+3=2h-9, which is odd. The untouched cohort stays the full alternating parity, and is consequently minority when its own sweep begins. Repeat the same sweep, for a total of 4h184h-18 days. For n=5n=5, each solo sweep takes fifteen days.

Even lengths: a finite symbolic boundary classification

Suppose n=2q6n=2q\ge6, and put h=5qh=5q. Match horizontal pairs of columns. In row yy and matched column jj, the physical parity-zero vertex is (2j+(ymod2),y)(2j+(y\bmod2),y). Use the matching to identify the opposite parity with the same 5×q5\times q array. The resulting directed adjacency has a loop at every vertex, bidirectional vertical edges, leftward horizontal edges on rows 0,2,40,2,4, and rightward edges on rows 1,31,3. The other physical parity reverses the horizontal arrows. For a support RR, write σ(R)=N(R)R\sigma(R)=|N(R)|-|R|. The matching identifies this surplus with its directed outside-boundary size. The directed graph is strongly connected: vertical travel reaches a row of either horizontal orientation. Thus a nonempty proper support has positive surplus.

Represent a column by a subset B{0,1,2,3,4}B\subseteq\{0,1,2,3,4\}, and let V(B)V(B) be its vertical neighbors. For successive column masks A,B,CA,B,C, define c(A,B,C)=B(V(B)(A{1,3})(C{0,2,4})). c(A,B,C)=\left|\overline B\cap \bigl(V(B)\cup(A\cap\{1,3\})\cup(C\cap\{0,2,4\})\bigr)\right|. (98) The complement is within the five rows. With zero sentinel columns, the surplus of a word B1BqB_1\cdots B_q is exactly j=1qc(Bj1,Bj,Bj+1).\sum_{j=1}^q c(B_{j-1},B_j,B_{j+1}).

For a bound s2s\le2, use states (A,B,e)(A,B,e), 0es0\le e\le s. Every (0,B,0)(0,B,0) is initial. For each of the 32 choices of CC, retain (A,B,e)(B,C,e+c(A,B,C))(A,B,e)\longrightarrow(B,C,e+c(A,B,C)) if the new weight is at most ss. A state is terminal for boundary exactly ss when e+c(A,B,0)=se+c(A,B,0)=s. Explore every reachable state. Remove only self-loops, verifying that each repeats an empty or full column at zero additional weight. The remaining graph is acyclic. Its complete enumeration gives

boundary one boundary two
Reduced terminal paths 59 1057
Maximum reduced word length 5 8

At bound two the reduced reachable graph has 1124 states and 3874 edges. These counts follow from the stated finite rule; they are not a cutoff on physical grid length.

Every accepted word reduces to one of these terminal paths by deleting loop repetitions. Conversely, arbitrary nonnegative repetitions at the recorded positions preserve its boundary. A reduced word with kk present and aa absent cells therefore represents counts k+5uk+5u and a+5va+5v, where u,v0u,v\ge0 count allowed full and empty repetitions. A parameter is zero if its loop type is absent. Repetition preserves whether each row is a prefix.

Lemma 19.3 (Five-row small-boundary geometry). For q3q\ge3, in the directed orientation just specified:

  1. A surplus-one support has size 11, h2h-2, or h1h-1.

  2. A surplus-two support of size 3kh53\le k\le h-5 has left-prefix rows.

  3. A surplus-two support with prefix rows and an empty row has at most five vertices.

  4. A surplus-two prefix support of size four, five, or six has no neighbor in the last column.

Finite symbolic verification. Enumerate every terminal path in the specified finite graph, recording every removed-loop position. For a reduced word let k,ak,a be its present and absent counts, and let F,EF,E indicate a full or empty repetition position. Discard only words shorter than three columns with no repetition positions. Every remaining word satisfies these checks:

  1. At boundary one, either k=1k=1 and FF is false, or a{1,2}a\in\{1,2\} and EE is false.

  2. At boundary two, FF implies k10k\ge10. If (k3 or F)(k\ge3\text{ or }F) and (a5 or E)(a\ge5\text{ or }E), all rows are prefixes.

  3. At boundary two, prefix rows and an empty row imply that FF is false and k5k\le5.

  4. At boundary two, prefix rows and 4k64\le k\le6 imply that FF is false and BqV(Bq)(Bq1{1,3})=.B_q\cup V(B_q)\cup(B_{q-1}\cap\{1,3\})=\varnothing.

These checks cover 59 and 1057 reduced words, respectively. They are implemented directly from (98) in five_row_boundary_automaton.py; the full words and repetition positions are included in the accompanying certificate. No interval assumption is made about arbitrary supports.

The first three conclusions persist for all repetition counts by kk+5uk\mapsto k+5u and aa+5va\mapsto a+5v. In the fourth size range, no full repetition is possible. Empty repetitions occur after the nonempty part of a prefix support, and cannot create a neighbor in the new last column. This proves the assertions for every q3q\ge3. ◻

Lemma 19.4 (Incompatible efficient transitions). Suppose σ(R)=2\sigma(R)=2, 4k=Rh54\le k=|R|\le h-5, and RN(R)R'\subseteq N(R) belongs to the opposite physical parity. If k1Rk+2,Rh5,k-1\le |R'|\le k+2,\qquad |R'|\le h-5, then σ(R)2\sigma(R')\ne2.

Proof. If both surpluses were two, the preceding lemma would give left-prefix rows for RR and right-prefix rows for RR', since the second parity reverses horizontal arrows. The neighborhood of a left-prefix support also has left-prefix rows. Its size is k+2h3k+2\le h-3, so some row misses its last cell. The corresponding right-prefix row of RR' must be empty. Part 3 gives R5|R'|\le5, hence k6k\le6. Part 4 now says N(R)N(R) misses the entire last column, forcing every right-prefix row of RR' to be empty, a contradiction. ◻

The even-length historical potential and attaining sweeps

Mark a current cohort by z=1z=1 exactly when its immediately preceding survivor support had surplus two and size in [4,h5][4,h-5]; otherwise use z=0z=0. A marked support has 6bh36\le b\le h-3. Every nonempty reachable support has size at least two. Define Vh(b,z)={0,b=0,1,1b2,b2,3b5,min{2b+z8, b+h10},b6. V_h(b,z)=\begin{cases} 0,&b=0,\\ 1,&1\le b\le2,\\ b-2,&3\le b\le5,\\ \min\{2b+z-8,\ b+h-10\},&b\ge6. \end{cases} (99) Here zz records history, unlike the physical-parity variable in (95).

For p3p\le3 useful inspections put r=bpr=b-p, and denote the next state by (b,z)(b',z'). These alternatives exhaust every physical transition:

  1. r=0r=0, giving (b,z)=(0,0)(b',z')=(0,0);

  2. r=hr=h, necessarily b=h,p=0b=h,p=0, giving (h,0)(h,0);

  3. σ=1\sigma=1, giving r{1,h2,h1}r\in\{1,h-2,h-1\} and (b,z)=(r+1,0)(b',z')=(r+1,0);

  4. σ=2\sigma=2, giving b=r+2b'=r+2 and z=1{4rh5}z'=\mathbf{1}_{\{4\le r\le h-5\}}; if z=1z=1 and 3rh53\le r\le h-5, this is forbidden by Lemma 19.4;

  5. σ3\sigma\ge3, giving br+3b'\ge r+3 and z=0z'=0.

In the forbidden case, the previous survivor size is k=b2k=b-2 and r=k+2pr=k+2-p, so k1rk+2k-1\le r\le k+2 follows from 0p30\le p\le3.

Substitution into (99) gives Vh(b,z)Vh(b,z)+1{p2}. V_h(b,z)\le V_h(b',z')+\mathbf{1}_{\{p\ge 2\}}. (100) This is a finite split of linear integer inequalities under h15h\ge15, bhb\le h, b=0b=0 or b2b\ge2, and z=16bh3z=1\Rightarrow6\le b\le h-3. Its universal proof is FiveRowRankArithmetic.potential_step in the Lean artifact; the geometric alternatives remain the ordinary argument just given. The two-cohort potential decreases by at most one per day. Initially it is 2Vh(h,0)=4h20=10n202V_h(h,0)=4h-20=10n-20, proving the lower bound.

For the upper bound use ascending (x+y,x)(x+y,x) prefixes, choosing a fixed reflected orientation independently for each initial cohort. Their surpluses are as follows; these describe the stated orders, rather than claiming that they simultaneously minimize all even-length profiles:

Phase survivor sizes surplus
0 1,h2,h11,h-2,h-1 1
0 all other proper nonempty sizes 2
1 h1h-1 1
1 1,2,h4,h3,h21,2,h-4,h-3,h-2 2
1 3,,h53,\ldots,h-5 3

Empty and full supports have empty and full neighborhoods. Neighborhoods of prefixes are opposite-phase prefixes. To derive the tables, let L(d)L(d) be the length of diagonal x+y=dx+y=d, and set A(0)=0A(0)=0, A(d+1)=L(d)A(d)A(d+1)=L(d)-A(d). For a prefix with jj cells in its final diagonal, the surplus is A(d)+11{d4}1{max(0,d4)+j1=n1}.A(d)+1-\mathbf{1}_{\{d\ge 4\}} -\mathbf{1}_{\{\max(0,d-4)+j-1=n-1\}}. The diagonal lengths are 1,2,3,4,51,2,3,4,5, then five through diagonal n1n-1, then 4,3,2,14,3,2,1. The recurrence gives A(d)=d/2A(d)=\left\lceil d/2\right\rceil for d4d\le4, A(d)=2+(dmod2)A(d)=2+(d\bmod2) for 4dn14\le d\le n-1, and final values 2,2,1,12,2,1,1. Substitution gives the tables and the neighborhood-prefix assertion.

Starting in phase zero, three rounds give hh1h2h3h\to h-1\to h-2\to h-3. Then h8h-8 pairs of a stationary round and a one-cell decrease reach size five. The last three rounds are 54205\to4\to2\to0. The solo duration is 3+2(h8)+3=2h10.3+2(h-8)+3=2h-10. Reflection xn1xx\mapsto n-1-x swaps physical parities because nn is even, so each initial cohort can start its sweep in favorable phase zero. The untouched cohort remains full until its sweep begins. Two consecutive sweeps take 4h204h-20 days, completing Theorem 19.1.

Even lengths at every budget

The one-bit obstruction can be strengthened enough to resolve every budget on the even-length boards. We treat these first, then solve the odd-length recurrence explicitly.

Theorem 19.5 (Five rows, even length, every budget). Let n6n\ge6 be even and h=5n/2h=5n/2. Budgets one and two are impossible; T3=4h20T_3=4h-20; and T4=22h83. T_4=2\left\lceil\frac{2h-8}{3}\right\rceil. (101) For 5m<h5\le m<h, write 2h6=q(2m5)+r2h-6=q(2m-5)+r, 0r<2m50\le r<2m-5, and set J(0)=0,J(1)=2,J(2)=3,J(3)=J(4)=4,J(r)=r+52(r5).J(0)=0,\quad J(1)=2,\quad J(2)=3,\quad J(3)=J(4)=4, \qquad J(r)=\left\lceil\frac{r+5}{2}\right\rceil\quad(r\ge5). Then Tm={2q,r=0,2q+1,r>0 and 2J(r)m,2q+2,otherwise. T_m=\begin{cases} 2q,&r=0,\\ 2q+1,&r>0\text{ and }2J(r)\le m,\\ 2q+2,&\text{otherwise}. \end{cases} (102) Finally, Tm=2T_m=2 for hm<2hh\le m<2h, and Tm=1T_m=1 for m2hm\ge2h.

For m7m\ge7, this is already Theorem 14.1 with b=2b=2: its numerator is 2h62h-6, and its corner function is exactly the displayed JJ. We retain the stronger boundary relation below, then use it to settle the remaining budgets four, five, and six.

We first strengthen the geometry in Lemma 19.3. Call the two endpoints in the last matched column outward corners when considering the reversed directed orientation.

Lemma 19.6 (Endpoint compatibility). Suppose σ(R)=2\sigma(R)=2 and 3k=Rh53\le k=|R|\le h-5. If N(R)N(R) contains an outward corner, then kh6k\ge h-6. If RN(R)R'\subseteq N(R) has opposite physical parity, surplus two, and 3=Rh53\le\ell=|R'|\le h-5, then (k,){(h6,3),(h5,3),(h5,4)}. (k,\ell)\in\{(h-6,3),(h-5,3),(h-5,4)\}. (103)

Proof. Write n=2sn=2s. For k6k\ge6, the prefix and empty-row conclusions of Lemma 19.3 imply that every row of RR is a nonempty left prefix. Let its lengths be tit_i and set di=stid_i=s-t_i. The missing lengths in the rows of N(R)N(R) are exactly e0=min(d0,d1),e1=min(d0,(d11)+,d2),e2=min(d1,d2,d3),e3=min(d2,(d31)+,d4),e4=min(d3,d4).\begin{aligned} e_0&=\min(d_0,d_1),& e_1&=\min(d_0,\left(d_1-1\right)_+,d_2),& e_2&=\min(d_1,d_2,d_3),\\ e_3&=\min(d_2,\left(d_3-1\right)_+,d_4),& e_4&=\min(d_3,d_4). \end{aligned} The surplus identity is di=ei+2\sum d_i=\sum e_i+2. Splitting the minima gives these three elementary integer consequences: e0e4=0  di6,(e0=e1=e2=0) or (e2=e3=e4=0)  di5,e0=e2=e4=0  di2.\begin{aligned} e_0e_4=0&\ \Longrightarrow\ \sum d_i\le6,\\ (e_0=e_1=e_2=0)\text{ or }(e_2=e_3=e_4=0) &\ \Longrightarrow\ \sum d_i\le5,\\ e_0=e_2=e_4=0&\ \Longrightarrow\ \sum d_i\le2. \end{aligned} Their complete universal arithmetic proofs are the theorems endpoint, three_rows, and alternating_rows in FiveRowDeficitArithmetic.lean. The first proves the corner claim.

The rows of RR' are right prefixes. Every occupied row must therefore be full in N(R)N(R), that is, have ei=0e_i=0. Since N(R)h3|N(R)|\le h-3, some row is not full, so the empty-row conclusion implies 5\ell\le5. The surplus-two prefix row vectors of sizes three through five, up to vertical reflection, are 3(2,1,0,0,0), (1,1,1,0,0), (1,0,1,0,1)4(2,1,1,0,0), (1,1,1,0,1)5(2,1,1,0,1), (1,1,1,1,1).\begin{array}{c|l} 3&(2,1,0,0,0),\ (1,1,1,0,0),\ (1,0,1,0,1)\\ 4&(2,1,1,0,0),\ (1,1,1,0,1)\\ 5&(2,1,1,0,1),\ (1,1,1,1,1). \end{array} This finite list follows by substituting the row-neighborhood maxima for vectors with total at most five. For s6s\ge6 the far boundary cannot affect the check; direct substitution for s=3,4,5s=3,4,5 gives the same list. A size-three vector forces a zero endpoint deficit; a size-four vector forces three consecutive zeros at an end or the stronger alternating zeros; a size-five vector forces alternating zeros. The three inequalities above now give respectively kh6k\ge h-6, kh5k\ge h-5, and the contradiction kh2k\ge h-2.

For the source sizes 3k53\le k\le5, use the same finite list directly. Every neighborhood row has length at most two, hence misses the last column because s3s\ge3. It contains neither an outward corner nor a nonempty right prefix. This separate check is needed because the displayed deficit formula assumes that every source row is nonempty. ◻

For this all-budget argument, mark a cohort by z=1z=1 when its previous survivor had surplus two and size in [3,h5][3,h-5]. Thus z=1z=1 implies 5bh35\le b\le h-3, and the previous survivor size was b2b-2. Every physical transition, for pp useful inspections and a=bpa=b-p, belongs to the following relation:

  1. a=0a=0 gives (0,0)(0,0), and a=ha=h gives (h,0)(h,0);

  2. surplus at least three gives any (b,0)(b',0) with a+3bha+3\le b'\le h;

  3. surplus one gives (a+1,0)(a+1,0) for a{1,h2,h1}a\in\{1,h-2,h-1\}, with a=1a=1 forbidden when z=1z=1 and b<h4b<h-4;

  4. surplus two gives (a+2,1{3ah5})(a+2,\mathbf{1}_{\{3\le a\le h-5\}}); when z=1z=1 and 3ah53\le a\le h-5, the pair (b2,a)(b-2,a) must satisfy (103).

The last two restrictions are precisely Lemma 19.6. In particular, the large-surplus branch includes every possible target size, so this is a lower relaxation for arbitrary supports.

A boundary potential and the budgets five and six

For m5m\ge5, let FmF_m be the general potential (36) with b=2b=2. An explicit residue form is D=2m5,j(u)=(u7)+D,s(u)=((u7)+modD)+1,D=2m-5,\qquad j(u)=\left\lfloor\frac{\left(u-7\right)_+}D\right\rfloor,\qquad s(u)=(\left(u-7\right)_+\bmod D)+1, Fm(u)=u+5j(u)21{j(u)1, s(u){1,2,4}}. F_m(u)=\left\lfloor\frac{u+5j(u)}2\right\rfloor -\mathbf{1}_{\{j(u)\ge 1,\ s(u)\in\{1,2,4\}\}}. (104) The common interior lemma gives the following properties:

  1. FmF_m is nondecreasing and Fm(u+2)Fm(u)3F_m(u+2)-F_m(u)\le3;

  2. if u/2m\left\lfloor u/2\right\rfloor\le m, then Fm(u)=u/2F_m(u)=\left\lfloor u/2\right\rfloor;

  3. if pmp\le m and u/2>p\left\lfloor u/2\right\rfloor>p, then Fm(u)p+Fm(u2p+5)F_m(u)\le p+F_m(u-2p+5).

Indeed, Lemma 8.3 applies because mb2+1=5m\ge b^2+1=5. Writing u=2k+zu=2k+z, its target rank is at most u2p+5u-2p+5, since L0(s)s+2L_0(s)\le s+2 and L1(s)s+3L_1(s)\le s+3. Monotonicity gives property 3, while property 2 is the defining cardinality branch. The only additional assertion, the upper bound on a two-unit increment, follows from the displayed JJ values and J(D)=mJ(D)=m, including the first period and the wrap between periods.

For 5mh85\le m\le h-8, set C=min{Fm(2h), 2+Fm(2h2), 4+Fm(2h4)},Φ(b,z)=min{C,Fm(2b+z)}.C=\min\{F_m(2h),\ 2+F_m(2h-2),\ 4+F_m(2h-4)\}, \qquad \Phi(b,z)=\min\{C,F_m(2b+z)\}. Every permitted transition lowers Φ\Phi by at most its useful allocation pp. Here are all exceptional cases in that verification. A bulk surplus-two transition from z=0z=0 has target rank u2p+5u-2p+5; from z=1z=1 it would require ph7>mp\ge h-7>m by (103). Surplus at least three has target rank at least u2p+5u-2p+5. The three properties of FmF_m therefore handle these branches; a common cap preserves the inequality.

Capture follows from property 2. A surplus-one singleton is impossible from a marked state because it would require ph5p\ge h-5. From an unmarked state, bm+1b\le m+1; the only extra endpoint value is Fm(2m+2)=m+2F_m(2m+2)=m+2, paid by mm inspections and the target pair. For surplus two at survivor sizes one or two, states bmb\le m follow from cardinality. The four extra source values at (b,z)=(m+1,0),(m+1,1),(m+2,0),(m+2,1)(b,z)=(m+1,0),(m+1,1),(m+2,0),(m+2,1) are m+2,m+3,m+4,m+4m+2,m+3,m+4,m+4, respectively, and the target size is at most four.

Finally consider survivor sizes h4,,h1h-4,\ldots,h-1. Rank increases need only monotonicity. The sole proper-source rank decrease is unmarked h1h2h-1\to h-2 with three inspections, paid by property 1. The improvements from the full state to h1h-1 with two inspections and to h2h-2 with four inspections are exactly the last two terms defining CC. The full, zero-inspection transition is tautological. This exhausts the relation.

Both initial cohorts have potential CC and both final potentials vanish, so this boundary relation gives Tm2C/mT_m\ge\left\lceil 2C/m\right\rceil throughout 5mh85\le m\le h-8. Direct substitution in the quotient and remainder of (102) gives, for m6m\ge6, C=qm+J(r)1{r=2}.C=qm+J(r)-\mathbf{1}_{\{r=2\}}. Only m=5,6m=5,6 remain after the general theorem, and both satisfy mh8m\le h-8 because h15h\ge15. For m=5m=5, the physical value hh is divisible by five: q=n2q=n-2, r=4r=4, and C=5q+4C=5q+4, giving T52q+2=2n2T_5\ge2q+2=2n-2. For m=6m=6, the values of C6qC-6q for r=0,,6r=0,\ldots,6 are 0, 2, 2, 4, 4, 5, 6.0,\ 2,\ 2,\ 4,\ 4,\ 5,\ 6. The resulting lower bounds 2C/6\left\lceil 2C/6\right\rceil are 2q2q, 2q+12q+1 for r=1,2r=1,2, and 2q+22q+2 for r3r\ge3, as required.

The four-inspection lower bound

Define H(b,z)={b,b4,6,(b,z)=(5,0),4(2b+z)/38+31{(2b+z)mod3=2},otherwise,H(b,z)=\begin{cases} b,&b\le4,\\ 6,&(b,z)=(5,0),\\ 4\left\lfloor(2b+z)/3\right\rfloor-8+3\mathbf{1}_{\{(2b+z)\bmod 3=2\}},&\text{otherwise}, \end{cases} and A1=min{H(h1,0),3+H(h2,0)},C4=min{H(h,0),2+A1,4+H(h2,0)}.A_1=\min\{H(h-1,0),3+H(h-2,0)\},\qquad C_4=\min\{H(h,0),2+A_1,4+H(h-2,0)\}. Use potential C4C_4 at the full state, A1A_1 at the unmarked state h1h-1, and HH elsewhere. Allocating p4p\le4 lowers it by at most pp. This assertion is a finite residue split with the unbounded parameter h15h\ge15: the theorem potential_step in FiveRowFourProbeArithmetic.lean checks every branch of the physical relaxation above. In this budget range a marked source forbids all surplus-one transitions and all bulk surplus-two transitions; the endpoint restrictions prove these exclusions. The checker includes all larger targets in the surplus-at-least-three branch.

Writing h=3t,3t+1,3t+2h=3t,3t+1,3t+2 gives respectively (A1,C4)=(8t12,8t10),(8t9,8t8),(8t5,8t4).(A_1,C_4)=(8t-12,8t-10),\quad(8t-9,8t-8),\quad(8t-5,8t-4). For L=(2h8)/3L=\left\lceil(2h-8)/3\right\rceil, this means C4=4LC_4=4L except when h0(mod3)h\equiv0\pmod3, where C4=4L2C_4=4L-2. The total-ammunition inequality already proves T42LT_4\ge2L outside that residue.

In the exceptional residue, 2L12L-1 days would use exactly 2C42C_4 probes, so every cohort transition must be tight and every day must use four useful probes. From a full state, the only positive tight allocation is two inspections, producing size h1h-1. Thus the first day must split 2+22+2. From an unmarked state of size h1h-1, every tight allocation requires four inspections. Two such transitions cannot share day two. This proves T42LT_4\ge2L. The two local tightness assertions are universally checked by full_tight and penultimate_tight in FiveRowFourProbeEquality.lean.

Explicit attaining schedules for the remaining budgets

All budgets m7m\ge7, including the boundary cases, are covered by Theorem 14.1. The independent finite lower certificates at (h,m)=(15,8),(15,11),(20,14)(h,m)=(15,8),(15,11),(20,14) remain kernel checked in FiveRowHighBudgetArithmetic.lean.

For the matching upper bounds, use the previously displayed physical prefix tables. With four inspections, start each solo sweep in phase one. Its first round gives (h2,0)(h-2,0). At phase-zero size b9b\ge9, two rounds give (b2,1)(b-2,1) and (b3,0)(b-3,0). Repeat until size 7,8,67,8,6, for hh modulo three equal to 0,1,20,1,2, respectively. The final tails are 75307\to5\to3\to0, 86408\to6\to4\to0, and 6406\to4\to0. The solo duration is LL, so two independently oriented sweeps attain 2L2L.

For m=5,6m=5,6, full allocations decrease the bulk rank by D=2m5D=2m-5. If r=0r=0, each solo sweep lasts qq rounds. If r>0r>0, after qq full allocations its remaining size is J(r)J(r); substitution in the last two prefix transitions gives the special residues one, two, and four. At m=5m=5, only r=4r=4 occurs, so two separate sweeps suffice. At m=6m=6, a shared day is needed only for r=1,2r=1,2, where J(r)=2,3J(r)=2,3. The corresponding initial allocations to a suitably oriented fresh cohort decrease its rank by one and two, respectively. Its new rank is therefore at most qD+6qD+6, which clears within qq further full allocations by the same prefix table. Finish the first cohort and start the second with J(r)J(r) inspections each on that shared day. The remaining residues use two separate sweeps, attaining (102).

The impossibility at budgets below three follows from the 4×44\times4 subgrid obstruction. At budget at least hh, inspect one full parity then the other cohort’s full parity; one day is possible exactly at budget 2h2h. Together with Theorem 19.1, these facts complete the proof of Theorem 19.5. The geometry here is an ordinary proof with a finite symbolic certificate; the cited Lean modules verify its universal scalar consequences, not the complete physical five-row classification.

Odd lengths at every budget

Theorem 19.7 (Five rows, odd length, every budget). Let n5n\ge5 be odd and h=(5n1)/2h=(5n-1)/2. Budgets at most two are impossible, T3=10n20T_3=10n-20, and T4=25n93+21{3n},T5=2n2.T_4=2\left\lceil\frac{5n-9}{3}\right\rceil+2\mathbf{1}_{\{3\mid n\}},\qquad T_5=2n-2. For 5m<h5\le m<h, write 5n6=q(2m5)+r5n-6=q(2m-5)+r, 0r<2m50\le r<2m-5. Use the function JJ from Theorem 19.5, and put δ(r)=1{r{1,2,4} or (r5 and r odd)}.\delta(r)=\mathbf{1}_{\{r\in\{1,2,4\}\text{ or }(r\ge 5\text{ and }r\text{ odd})\}}. Then Tm={2q,r=0,2q+1,r>0 and 2J(r)+δ(r)m,2q+2,otherwise. T_m=\begin{cases} 2q,&r=0,\\ 2q+1,&r>0\text{ and }2J(r)+\delta(r)\le m,\\ 2q+2,&\text{otherwise}. \end{cases} (105) Finally, Tm=2T_m=2 for hm<2h+1h\le m<2h+1, and Tm=1T_m=1 for m2h+1m\ge2h+1.

All transitions below use the exact profiles (93)(94). An arbitrary physical search dominates the corresponding count search, and compatible prefixes attain it. Thus a lower proof may either use a nondecreasing potential directly on arbitrary supports, or rule out an equally fast prefix search. No serial-search assumption is needed.

Four inspections

Use the interior function H(b,z)H(b,z) from the four-inspection even-length proof. For h=3t,3t+1,3t+2h=3t,3t+1,3t+2, respectively, put C(h)=8t8,8t5,8t4C(h)=8t-8,8t-5,8t-4, and define Vh(b,z)={C(h)1,z=0, b=h,min{H(b,0),C(h)2},z=0, b=h1,min{C(h),H(b,z)},otherwise.V_h(b,z)=\begin{cases} C(h)-1,&z=0,\ b=h,\\ \min\{H(b,0),C(h)-2\},&z=0,\ b=h-1,\\ \min\{C(h),H(b,z)\},&\text{otherwise}. \end{cases} For h12h\ge12, b=0b=0 or 3zbh+1z3-z\le b\le h+1-z, and 0p40\le p\le4, Vh(b,z)p+Vh(gz((bp)+),1z). V_h(b,z)\le p+V_h(g_z(\left(b-p\right)_+),1-z). (106) Here is a finite reduction that verifies the assertion for unbounded hh. The identities C(h+3)=C(h)+8C(h+3)=C(h)+8 and H(b+3,z)=H(b,z)+8H(b+3,z)=H(b,z)+8 for b6b\ge6 give the same translation for both exceptional caps. Also gh+3,z(k+3)=gh,z(k)+3g_{h+3,z}(k+3)=g_{h,z}(k)+3 for k3k\ge3 in the domain. For h24,b13h\ge24,b\ge13, reduce both h,bh,b by three; survivors are at least six before reduction, and both sides of (106) decrease by eight. For b12b\le12, reduce only hh by three: target sizes are at most fifteen, no high-end clause is reached, and the caps are inactive since C(h3)48>H(b,z)C(h-3)\ge48>H(b',z') for b15b'\le15. Only 12h2312\le h\le23 remain. All states and all five allocations in this finite range are checked by RecurrenceBridgeOddFiveFour.finite_certificate in Lean. The translations are ordinary proofs, separate from this finite check.

The initial potential sum is 2C(h)2C(h), so summation gives T4C(h)/2T_4\ge\left\lceil C(h)/2\right\rceil. For attainment start the majority cohort. The first two rounds give (h+1,0)(h2,1)(h3,0)(h+1,0)\to(h-2,1)\to(h-3,0). From majority size b9b\ge9, two rounds give (b2,1)(b3,0)(b-2,1)\to(b-3,0). The final majority sizes 6,7,86,7,8 have tails 6406\to4\to0, 75307\to5\to3\to0, and 86408\to6\to4\to0. The solo durations are L=2t2,2t1,2t1L=2t-2,2t-1,2t-1, respectively. When LL is odd the second cohort starts in majority parity. When LL is even, its minority solo has the same duration: the first round reaches majority size h1h-1, followed by the same pairs and the size-eight tail. Thus 2L=C(h)/22L=\left\lceil C(h)/2\right\rceil days attain the formula.

Larger budgets as a specialization of the general theorem

For m5m\ge5, apply Theorem 8.1 with b=2b=2. Its parameter B=b2B=b^2 is four, so its full budget range applies. The two uncapped corner functions simplify to L0(k)={0,k=0,2,k=1,k+2,k2,L1(k)={0,k=0,k+2,1k2,k+3,k3.L_0(k)=\begin{cases}0,&k=0,\\2,&k=1,\\k+2,&k\ge2,\end{cases} \qquad L_1(k)=\begin{cases}0,&k=0,\\k+2,&1\le k\le2,\\k+3,&k\ge3.\end{cases} Substituting in (33) gives precisely the function JJ in Theorem 19.5. Substitution in (34) gives δ(r)=1{r{1,2,4} or (r5 and r odd)}.\delta(r)=\mathbf{1}_{\{r\in\{1,2,4\}\text{ or }(r\ge 5\text{ and }r\text{ odd})\}}. Finally Nw1=5n6N-w-1=5n-6. Thus the general theorem is exactly (105), including its one- and two-day thresholds and its explicit attaining schedules. At m=5m=5, the quotient and remainder are q=n2,r=4q=n-2,r=4, giving T5=2n2T_5=2n-2. The proof of the general theorem establishes this boundary case directly, so this specialization has no circular dependency.

The independent audits and direct room-coordinate constructions remain in the research archive. The finite Lean arithmetic bases do not amount to a complete physical Lean proof of the five-row theorem.

Seven rows with five inspections per day

The following low-budget family illustrates how a periodic potential and a short equality obstruction can solve the two-count recurrence explicitly. The proof is an ordinary argument with finite rational certificates; it is not presently a complete physical Lean theorem.

Theorem 20.1. For every odd n7n\ge7, T5(P7Pn)=27n163.T_5(P_7\mathbin{\square}P_n)=2\left\lceil\frac{7n-16}{3}\right\rceil.

Put H=(7n+1)/2H=(7n+1)/2, so the two checkerboard classes have sizes H,H1H,H-1. Theorem 5.1, with b=3b=3, supplies exact profiles g0,g1g_0,g_1 and compatible prefixes. Thus gp(0)=0g_p(0)=0, and g0(k)=k+min{R(k),3,R(Hk)1},g1(k)=k+min{Q(k),4,Q(H1k)}g_0(k)=k+\min\{R(k),3,R(H-k)-1\},\qquad g_1(k)=k+\min\{Q(k),4,Q(H-1-k)\} on the respective nonempty domains. We use the profiles for the lower bound on arbitrary supports and the compatible prefixes for construction.

Finite potentials and the exceptional residue.

Assign charges c0=(0,0,12,34,1,1),c1=(0,0,14,12,1,1).c_0=(0,0,\tfrac12,\tfrac34,1,1),\qquad c_1=(0,0,\tfrac14,\tfrac12,1,1). They satisfy c0(r)+c1(s)1c_0(r)+c_1(s)\le1 whenever r+s5r+s\le5. For each finite base below, define fp(k)f_p(k) as the least total charge of a path from (p,k)(p,k) to an empty state in the one-cohort graph (p,k)(1p,gp(max{kr,0})),edge charge cp(r),0r5.(p,k)\longrightarrow \bigl(1-p,g_p(\max\{k-r,0\})\bigr), \qquad\text{edge charge }c_p(r),\quad 0\le r\le5. All quantities are multiples of 1/41/4. The accompanying certificate computes these finite shortest-path distances exactly and verifies their monotonicity, zero terminal values, and every inequality fp(k)cp(r)+f1p(gp(max{kr,0})). f_p(k)\le c_p(r)+f_{1-p}\bigl(g_p(\max\{k-r,0\})\bigr). (107) The complete base data give the following initial sums V=f0(H)+f1(H1)V=f_0(H)+f_1(H-1) and attaining serial times UU: n7911131517192123V2263/24150119/26978175/297U223242506070788898\begin{array}{c|rrrrrrrrr} n&7&9&11&13&15&17&19&21&23\\\hline V&22&63/2&41&50&119/2&69&78&175/2&97\\ U&22&32&42&50&60&70&78&88&98 \end{array} There are 5,778 one-cohort inequalities in these nine certificates. Summing (107) across the current physical colors bounds the total potential loss by one per day. Monotonicity handles neighborhoods larger than the profile minimum. Hence T5VT_5\ge\left\lceil V\right\rceil.

For n=11,17,23n=11,17,23, this leaves one day. If capture occurred in V=U1V=U-1 days, every day would have to lose exactly one potential unit. In these three bases the only tight first allocation is three inspections in color zero and two in color one. Its minimum successor counts are (H1,H2)(H-1,H-2). The second-day losses from that state, for allocations r=0,,5r=0,\ldots,5 in color zero, are (34,14,12,0,0,14). \left(\tfrac34,-\tfrac14,\tfrac12,0,0,\tfrac14\right). (108) None is one, a contradiction. An actual first successor with larger counts cannot evade this calculation: if its first day is tight, its potential equals that of the minimum successor, while monotonicity makes its next potential at least as large. Filling unused quota is harmless. This proves all nine base lower bounds.

A periodic extension valid at every larger length.

Use the three base triples (n0,H0,c)=(19,67,33), (21,74,36), (23,81,39).(n_0,H_0,c)=(19,67,33),\ (21,74,36),\ (23,81,39). Their exact tables satisfy, for both colors, fp(k+3)=fp(k)+2,c10kc+10,gp(k)=k+3+p,c15kc+15.\begin{aligned} f_p(k+3)&=f_p(k)+2,&&c-10\le k\le c+10, \\ g_p(k)&=k+3+p,&&c-15\le k\le c+15.\nonumber \end{aligned}(109) For n=n0+6jn=n_0+6j, write Δ=21j\Delta=21j, so H=H0+ΔH=H_0+\Delta. Keep fpf_p unchanged through cc. On the inserted interval define f~p(c+3+r)=fp(c+r)+2,1r3,0<3+rΔ.\widetilde f_p(c+3\ell+r)=f_p(c+r)+2\ell, \qquad 1\le r\le3,\quad 0<3\ell+r\le\Delta. Above c+Δc+\Delta, put f~p(k)=fp(kΔ)+2Δ/3\widetilde f_p(k)=f_p(k-\Delta)+2\Delta/3. The period identity makes this a nondecreasing extension.

We check (107) by three exhaustive source ranges. For kc5k\le c-5, every output is at most c1c-1 and the distant upper corner has no effect; the old inequality is unchanged. For kc+Δ+5k\ge c+\Delta+5, subtract Δ\Delta from source and output. The lower corner is saturated, and both profile and potential translate exactly. In the remaining range c4kc+Δ+4c-4\le k\le c+\Delta+4, residuals are at least c9c-9 and outputs are at most c+Δ+8c+\Delta+8. All relevant profiles are on their plateau. Reduce the source modulo three to a representative in {c,c+1,c+2}\{c,c+1,c+2\}. The output changes by the same multiple of three, and both potentials change by the same multiple of two. The ten-place collar in (109) contains all needed old values, so this too is a verified base inequality. The explicit profile formulas justify the corner invariance and translation at every Δ\Delta.

The initial sum increases by 4Δ/3=28j4\Delta/3=28j. For the residue n5(mod6)n\equiv5\pmod6, the first two transitions remain in the translated upper part, so the tight first allocation and the loss table (108) are unchanged. The extra-day obstruction therefore persists. Since the stated formula also increases by 28j28j when nn increases by 6j6j, all lower bounds follow. The six smaller bases cover the lengths below these three starting points.

An attaining physical strategy.

Use the compatible prefixes from Theorem 5.1. Allocate five inspections to one cohort until it is captured, assigning any spare quota on its last day to the other cohort, and then finish that cohort. The base times in the table are direct evaluations of this strategy. At bases n0=19,21,23n_0=19,21,23, successful first colors are respectively 1,0,01,0,0. The two active middle visits, recorded as (count, current color), are n0first cohortsecond cohort19(34,1)(34,1)21(37,1)(38,1)23(41,1)(41,1)\begin{array}{c|cc} n_0&\text{first cohort}&\text{second cohort}\\\hline 19&(34,1)&(34,1)\\ 21&(37,1)&(38,1)\\ 23&(41,1)&(41,1) \end{array} All cuts exceed five. The companion is consequently globally full at the first visit and empty at the second; the finite certificates check these conditions directly.

On the common plateau, two consecutive five-inspection days reduce an active count by three and restore its color, from either starting color. Insert 2Δ/3=14j2\Delta/3=14j days at each visit to reduce the translated count from k+Δk+\Delta to kk. Before a visit, the profile trajectory translates by Δ\Delta; afterwards its lower part is unchanged. The active count decreases under five inspections, so the old segments stay on their respective sides. The inserted segment lies wholly in the plateau. Its even duration preserves the companion’s color and the original last-day spare allocation. Both insertions are therefore compatible physical prefix strategies. Their total added time is 28j28j, matching the lower bound and proving Theorem 20.1.

The finite certificates and their independent replay include the full rational base tables, all inequalities, the strict second-day losses, the collar identities, and actual coordinate-neighborhood replays of the nine base searches. The three-range proof and the physical insertion establish every larger length; the result does not rely on extrapolating the finite time table.

Minimum-budget searches on every odd width

At the minimum feasible budget, one width-dependent corner clock gives the exact time on every odd rectangle. The common-ancestry lemma removes the last central-day ambiguity uniformly, including widths for which many exceptional mixed states survive near the final corner.

Fix w=2b+1w=2b+1, m=b+1m=b+1, and set C=b(b1)C=b(b-1). Define the width-only recurrence A0=B0=0,At+1=Bt+mmin{q(Bt+m),b},Bt+1=At+mmin{R(At+m),b+1}.\begin{aligned} A_0=B_0&=0,\notag\\ A_{t+1}&=B_t+m-\min\{q(B_t+m),b\},\notag\\ B_{t+1}&=A_t+m-\min\{R(A_t+m),b+1\}. \end{aligned}(110) Here q(z)q(z) is the least nonnegative integer rr with zr(r+1)z\le r(r+1). Let LbL_b be the first time Bt=CB_t=C, with L1=0L_1=0.

Theorem 21.1. For every odd nw=2b+13n\ge w=2b+1\ge3, Tb+1(PwPn)=2wnCw,Cw=8b24b4Lb+4. T_{b+1}(P_w\mathbin{\square}P_n)=2wn-C_w, \qquad C_w=8b^2-4b-4L_b+4. (111) The budget b+1b+1 is the minimum feasible budget, and the recurrence (110) terminates independently of nn. Its clock can be evaluated in O(b)O(b) arithmetic stages using Proposition 6.4. This width-dependent recurrence does not meet the absolute O(1)O(1) numerical completion criterion when bb varies. The following finite list does give fixed numerical constants for its stated widths. In particular, w3579111315Cw8204484136208288.\begin{array}{c|rrrrrrr} w&3&5&7&9&11&13&15\\\hline C_w&8&20&44&84&136&208&288. \end{array}

Proof. The two scalar maps in (110) are at least z+1z+1 and zz, respectively; each two-step composition therefore increases its argument by at least one. The recurrence is monotone from zero. At input C1C-1 both maps equal CC, while at CC they equal C+1C+1 and CC. Before BB first reaches CC, AA cannot exceed CC: producing AC+1A\ge C+1 requires the preceding BCB\ge C. Thus the first arrival is (C1,C)(C-1,C) or (C,C)(C,C), followed by (C+1,C)(C+1,C) and (C+1,C+1)(C+1,C+1). For b=1b=1 this follows directly from (A0,B0)=(0,0)(A_0,B_0)=(0,0); expressions at C1C-1 are needed only for b2b\ge2. These observations also prove finite termination and exact arrival at CC rather than an overshoot.

This bottom history through time Lb+2L_b+2 is the physical solo history on every allowed rectangle. Its inverse inputs are at most b2+2b^2+2. A reflected branch can first improve ι0\iota_0 at input MCM-C, at least b2+3bb^2+3b, and the corresponding ι1\iota_1 threshold is farther away. The b=1b=1 endpoints satisfy the same exclusion directly. At time Lb+2L_b+2 both solo deficits are C+1C+1. Total concentration makes every mixed state low-total; Lemma 7.2 therefore replaces the retained frontier by the two pure endpoints exactly.

In the common affine interval the solo ties evolve as (s,s)(s+1,s)(s+1,s+1).(s,s)\longmapsto(s+1,s)\longmapsto(s+1,s+1). At the first step every mixed successor has total at most ss, by both inverse concentration inequalities. The second step is a solo tie and again has no exceptional states. Hence the retained frontier stays pure. Choose a=Mb21,t=Lb+2(aC).a_*=M-b^2-1,\qquad t_*=L_b+2(a_*-C). The inverse formulas give these affine transitions through the tie (a,a)(a_*,a_*). It lies after C+1C+1 since a(C+1)3b2>0a_*-(C+1)\ge3b-2>0. At time tt_* the two active solo belief sizes are b2+2b^2+2 and b2+1b^2+1.

For a canonical monochromatic belief of current color pp and size kk, greedy capture within TT days is equivalent to km+Dp(T1), k\le m+D_p(T-1), (112) where DD is the fresh inverse recursion from zero. Indeed, apply the integer inverse profile successively backward through the T1T-1 nonterminal moves, with the final inspection threshold mm. For the two displayed belief sizes the required fresh deficits are C+1C+1 in color zero and CC in color one. Their exact upper-tail solo durations are consequently Lb+2L_b+2 and Lb+1L_b+1. The full-board solo durations are consecutive, the faster being τ=t+Lb+1=wn4b2+2b+2Lb2.\tau=t_*+L_b+1=wn-4b^2+2b+2L_b-2.

It remains to exclude 2τ12\tau-1 days. At the last pure tie, every subsequent secondary ancestry starts from zero. The precentral upper tail lasts exactly LbL_b steps, so monotonicity bounds every secondary by the fresh solo deficits up to time LbL_b, hence by CC. Lemma 7.3 says all final exceptional pairs have the same primary ancestry. Any two such pairs leave at least M2C4b>b+1=mM-2C\ge4b>b+1=m rooms in their other color, so cannot win centrally. If either pair is nonexceptional, their combined total is at most D0+D1D_0+D_1 and they cannot improve on the solo endpoints. The slower solo needs τ+1\tau+1 days; its remaining count at time τ1\tau-1 therefore exceeds mm, or it could be captured on day τ\tau. Thus the solo central sum also exceeds mm. The exact midpoint theorem forces T=2τT=2\tau, proving (111).

Finally, the rectangular-grid feasibility theorem (Abramovskaya et al. 2016, Theorem 2) gives minimum budget b+1b+1. The clock also satisfies Lb=μ1(C)/(b+1)L_b=\left\lceil\mu_1(C)/(b+1)\right\rceil by Proposition 7.6. Equivalently, (112) identifies Lb+1L_b+1 with the solo clearing time of a minority prefix of size b2+1b^2+1 on the width-ww square. Proposition 6.4 evaluates this time in O(b)O(b) stages. Evaluating the width-only recurrence gives the seven displayed constants. ◻

The proof is uniform in the width. It does not assert serial optimality from arbitrary partial states. Its geometric and corner-clock arguments are ordinary proofs; the abstract inverse, persistence and ancestry implications have separate Lean verification with their hypotheses explicit.

The same expression as an upper bound at even lengths

Proposition 21.2 (All-length minimum-budget construction). For w=2b+13w=2b+1\ge3, even nwn\ge w, and k=b+1k=b+1, the constant CwC_w of Theorem 21.1 gives Tb+1(w,n)2wnCw.T_{b+1}(w,n)\le2wn-C_w. Together with that theorem, the construction is valid at every length. This upper bound can be strict: in width 2525, sharing the final inspection day improves it from 50n92450n-924 to the exact value 50n92550n-925 for every even n26n\ge26. Thus equality of the displayed expression throughout all even lengths and widths is false. The general exact minimum-budget classification remains open, and evaluating CwC_w in fixed size for arbitrary width remains a separate unresolved question.

Proof. Use coordinates 0x<n0\le x<n, 0y<w0\le y<w, and order each color by (x+y,x)(x+y,x), ascending. Write Ip(a)I_p(a) for its aa-room prefix and set h=wn/2h=wn/2. These particular prefixes have nested neighborhoods, with g0(a)=a+min{R(a),b,ρ(ha)},g1(a)=a+min{Q(a),b+1,R(ha)}g_0(a)=a+\min\{R(a),b,\rho(h-a)\},\qquad g_1(a)=a+\min\{Q(a),b+1,R(h-a)\} for a>0a>0, and gp(0)=0g_p(0)=0. Here R(a)=aR(a)=\left\lceil\sqrt a\right\rceil, ρ(a)\rho(a) is the least u0u\ge0 with au(u+1)a\le u(u+1), and Q(a)Q(a) the least u1u\ge1 with au(u1)a\le u(u-1), with Q(0)=0Q(0)=0. The two oriented profiles differ even though reflection makes the unrestricted physical profiles equal.

For completeness, let (d)\ell(d) be diagonal x+y=dx+y=d’s length and define J(0)=0J(0)=0, J(d+1)=(d)J(d)J(d+1)=\ell(d)-J(d). A prefix ending after jj rooms on diagonal dd has surplus J(d)+11{d2b}1{max(0,d2b)+j1=n1}.J(d)+1-\mathbf{1}_{\{d\ge 2b\}} -\mathbf{1}_{\{\max(0,d-2b)+j-1=n-1\}}. Following the two forward neighbors of the terminal interval proves neighborhood nesting. The diagonal lengths increase, plateau, and decrease; the recursion gives J(d)=d/2,0d2b,J(d)=b+(dmod2),2bdn1,J(n+u)=bu/2,0u2b.\begin{array}{ll} J(d)=\left\lceil d/2\right\rceil,&0\le d\le2b,\\ J(d)=b+(d\bmod2),&2b\le d\le n-1,\\ J(n+u)=b-\left\lfloor u/2\right\rfloor,&0\le u\le2b. \end{array} Substituting the terminal partial diagonal proves the two profiles, including the far-end correction. Their integer inverses satisfy ιp(z)=hgp(hz)\iota_p(z)=h-g_p(h-z).

Inspect the final min(k,a)\min(k,a) rooms of the current prefix each day. Its next size is gp((ak)+)g_p(\left(a-k\right)_+). Until capture, the deficit hah-a therefore follows the alternating inverse maps ιp(z+k)\iota_p(z+k). Put C=b(b1)C=b(b-1), B=b(b+1)B=b(b+1), and a=hB1a_*=h-B-1. Through the tie (a,a)(a_*,a_*), every inverse input is at most a+k=hb2a_*+k=h-b^2, so the competing far-corner terms are inactive. The width-clock argument already proved above gives this tie at t=Lb+2(aC)=Lb+2h4b22.t_*=L_b+2(a_*-C)=L_b+2h-4b^2-2. Here aC+1a_*\ge C+1, since h(2b+1)(b+1)h\ge(2b+1)(b+1). Both initial phases now have prefix size B+1B+1, in opposite current colors.

Throughout the remaining search, sizes are at most B+1B+1 and the far corner stays inactive, since h(B+1)b2+2bh-(B+1)\ge b^2+2b. The same inverse-clock equivalence used in (112) says that a prefix of size B+1B+1 clears in s+1s+1 days when its fresh inverse clock reaches B+1k=b2B+1-k=b^2 at time ss. The first entry reaches this at Lb+2b1L_b+2b-1, so choose the initial phase whose tail lasts Lb+2bL_b+2b days. Its full solo duration is τ=t+Lb+2b=wn4b2+2b+2Lb2.\tau=t_*+L_b+2b=wn-4b^2+2b+2L_b-2. The inspection list followed by its reversal captures both initial colors in 2τ2\tau days: an avoiding walk in the second half, reversed, would contradict the first half’s solo guarantee. This is a physical construction and uses no assumed optimality of the oriented prefixes. ◻

Certificate and affine-insertion tools

Reusable lower certificates and affine insertion

The following certificate method has a broader purpose than the numerical corollaries above: its insertion lemmas also apply to other compatible profile families; independent applications are retained in the companion.

Set w=2b+1w=2b+1, m=b+1m=b+1, D=m+1D=m+1, and let the two color classes have sizes HH and H1H-1. Use the profiles g0,g1g_0,g_1 from Theorem 5.1. Choose nonnegative rational numbers cp(r)c_p(r), for p{0,1}p\in\{0,1\} and 0rm0\le r\le m, with c0(r)+c1(mr)1. c_0(r)+c_1(m-r)\le1. (113) Suppose nonnegative functions FpF_p, with Fp(0)=0F_p(0)=0, satisfy Fp(k)F1p(gp((kr)+))cp(r)(0kHp, 0rm). F_p(k)-F_{1-p}\bigl(g_p(\left(k-r\right)_+)\bigr)\le c_p(r) \quad(0\le k\le H-p,\ 0\le r\le m). (114) Here (x)+=max(x,0)\left(x\right)_+=\max(x,0), as elsewhere in the search recurrences.

At a current state (u,v)(u,v) the sum F0(u)+F1(v)F_0(u)+F_1(v) decreases by at most one per day, by (113). It suffices to consider strategies using the full quota whenever more than mm possibilities remain: additional suffix inspections preserve the prefix normal form and cannot hurt. On the final day one can pad the two quotas to sum to mm, with the positive-part convention making both survivors empty. Consequently TmF0(H)+F1(H1). T_m\ge\left\lceil F_0(H)+F_1(H-1)\right\rceil. (115) The functions are indexed by current color, so this argument includes arbitrary interleaving of the two initial cohorts.

For each finite certificate below, Fp(k)F_p(k) is computed as the shortest total charge of a path from (p,k)(p,k) to an empty cohort, where a quota rr costs cp(r)c_p(r) and sends the cohort to (1p,gp((kr)+))(1-p,g_p(\left(k-r\right)_+)). Multiplying by the common denominator gives a finite graph with nonnegative integer edge weights. After computing the functions, the verifier checks every inequality (113)(114) directly with exact fractions.

Inserting an arbitrarily long affine interval

Lemma 22.1 (Affine insertion). Let A=b(b+1)A=b(b+1). Suppose a certificate at majority size HH has an integer cut cc such that cA+2D,HcA+2D+2,Fp(k)=2k+αp(c2Dkc+2D, p{0,1}).\begin{aligned} c&\ge A+2D,& H-c&\ge A+2D+2,\\ F_p(k)&=2k+\alpha_p &&(c-2D\le k\le c+2D,\ p\in\{0,1\}). \end{aligned}(116, 117) For every integer Δ0\Delta\ge0, replace HH by H+ΔH+\Delta in the profile formulas and define Fp(k)={Fp(k),kc,Fp(c)+2(kc),ckc+Δ,Fp(kΔ)+2Δ,kc+Δ. F'_p(k)= \begin{cases} F_p(k),&k\le c,\\ F_p(c)+2(k-c),&c\le k\le c+\Delta,\\ F_p(k-\Delta)+2\Delta,&k\ge c+\Delta. \end{cases} (118) Then FpF'_p satisfies the same charge inequalities. The initial lower bound (115) increases by exactly 4Δ4\Delta.

Proof. The pieces of (118) agree at their endpoints. For either the base or enlarged profiles, every successor j=gp((kr)+)j=g_p(\left(k-r\right)_+) satisfies jkD. |j-k|\le D. (119) For a nonempty survivor, its surplus lies between 1-1 and b+1b+1, and rmr\le m. For an empty survivor, kmk\le m and j=0j=0.

If k<cDk<c-D, the enlarged profile agrees with the base profile at q=(kr)+q=\left(k-r\right)_+. Indeed, the far-corner terms in both profile formulas exceed their plateau caps by (116). The successor is unchanged and is less than cc by (119). Both potentials are unchanged, so the base inequality applies.

If k>c+Δ+Dk>c+\Delta+D, write k0=kΔk_0=k-\Delta and q0=k0rq_0=k_0-r. Since q0>c+Dm=c+1q_0>c+D-m=c+1, the low-corner terms have reached their plateau caps. The profile formulas therefore give gp(q0+Δ)=gp(q0)+Δ.g'_p(q_0+\Delta)=g_p(q_0)+\Delta. Writing j0j_0 for the base successor of k0k_0, we have j=j0+Δj=j_0+\Delta and j0>cj_0>c. Both potentials gain 2Δ2\Delta, which cancels in their difference.

Finally suppose cDkc+Δ+Dc-D\le k\le c+\Delta+D. The survivor q=krq=k-r is positive, with qcDmA+1,H+ΔqHcDA+D+2.q\ge c-D-m\ge A+1, \qquad H+\Delta-q\ge H-c-D\ge A+D+2. Both profiles are therefore on their affine plateaus: j=kr+δpj=k-r+\delta_p, where δ0=b\delta_0=b and δ1=b+1\delta_1=b+1. By (119), both kk and jj lie in [c2D,c+Δ+2D][c-2D,c+\Delta+2D]. Throughout that interval the corresponding potentials are 2k+αp2k+\alpha_p and 2j+α1p2j+\alpha_{1-p}. Their difference is 2r2δp+αpα1p.2r-2\delta_p+\alpha_p-\alpha_{1-p}. This is exactly the base potential difference at source k=ck=c with the same current color and quota rr. Its survivor and successor lie in the same affine profile and potential collar, so the verified base inequality bounds the expression by cp(r)c_p(r).

These three cases exhaust the enlarged state space. At each full color class (118) adds 2Δ2\Delta to the potential, giving the stated increase of 4Δ4\Delta in the integer lower bound. ◻

The matching upper construction has the same insertion property. A serial strategy directs the full budget to one initial cohort until it can be eliminated, uses any unused quota on that finishing day on the other cohort, and then directs the full budget to the other.

Lemma 22.2 (Insertion in a serial strategy). Under (116), suppose a base serial strategy visits count cc in each active cohort before an inspection. An enlarged rectangle with majority size H+ΔH+\Delta has a strategy taking exactly 4Δ4\Delta more days.

Proof. Under a full-budget inspection an active cohort’s size never increases, because every neighborhood surplus is at most mm. The certified visit to cc is therefore reached from above, and the subsequent base trajectory stays at or below cc. Above the cut, the enlarged active trajectory is the translation by Δ\Delta of the base trajectory, by the high profile translation identity in the preceding proof. The uninspected cohort remains its full current color class. When the first active cohort reaches c+Δc+\Delta, insert 2Δ2\Delta full-budget days. Throughout this inserted interval the profile plateaus give g0(km)=k1,g1(km)=k.g_0(k-m)=k-1,\qquad g_1(k-m)=k. Every two days reduce its size by one and restore its current color. The inserted block therefore ends at cc with the phase of the base schedule unchanged. Follow the base trajectory below the cut.

The first cohort’s finishing-day unused quota is unchanged. The second cohort consequently begins its active phase at the translated base state. This state is above the cut: it lies within m+1m+1 of a full color class, whereas (116) places cc farther from that edge. Follow its translated trajectory until c+Δc+\Delta, insert another 2Δ2\Delta full-budget days, and then finish along the unchanged lower trajectory. Both inserted blocks have even length, so the later phases of the schedule agree with those in the base strategy. ◻

The two insertion proofs also apply to any other compatible profile family with color-class sizes H,H1H,H-1 and a fixed budget mm, provided that a corner radius AA has the following properties: every surplus is between 1-1 and mm; the central profiles are k+m1k+m-1 and k+mk+m; the low profiles are unchanged when the remaining tail exceeds AA; and the high profiles translate when the source count exceeds AA. These are exactly the properties used in the displacement, collar, and trajectory arguments. In that formulation one sets D=m+1D=m+1 and uses the same margin and affine-collar conditions. This observation will also give an exact three-dimensional family below.

The original exact-rational certificates for widths three through fifteen remain in the companion artifact. Their verifier is src/odd_minimum_budget_all_lengths.py; its receipt is research/odd-minimum-budget-all-lengths.json. They check every charge inequality, base potential, affine collar and attaining serial sweep; no numerical linear-programming output is trusted by the verifier. Those separate width calculations are now consequences of Theorem 21.1, so their charge tables are not needed for its proof. The generic certificate and insertion statements above retain their full conditional scope.

Eventual affine periods on odd rectangles

This is the rectangle specialization of the previously proved corner-profile and interval-insertion argument. Its canonical proof is shared with the parked all-odd-box application. An affine plateau alone would not justify changing the rectangle’s length.

Let Q=PWQ=P_W be an odd path with W3W\ge3 vertices. Put S=W1,Z=W(S+1)=W2,β=(W1)/2.S=W-1,\qquad Z=W(S+1)=W^2, \qquad \beta=(W-1)/2. Consider QPnQ\mathbin{\square}P_n with odd longitudinal length nn. The one-point cross-section gives paths, already classified separately. For nS+3n\ge S+3, the compatible order of Theorem 5.1 applies. Equivalently, put the short coordinate first and use decreasing lexicographic order within a fixed weight layer. Write H=(Wn+1)/2H=(Wn+1)/2 for its majority class size and gpng_p^n for its exact color-pp profile.

Two finite tables describe both ends

For vQpv\in Q_p, let rp(v)r_p(v) be the rank of (v,0)(v,0) in the parity order of the infinite prism Q×{0,1,}Q\times\{0,1,\ldots\}. Every such point has weight at most SS, so every preceding point has longitudinal coordinate at most SS. Its rank is therefore independent of nn for nS+1n\ge S+1 and can be computed in the single finite slab QPS+1Q\mathbin{\square}P_{S+1}. At most Z=W(S+1)Z=W(S+1) vertices have weight at most SS, so rp(v)Zr_p(v)\le Z.

Index the path vertices by 0,,W10,\ldots,W-1. Its transverse prefix cost is aQ(v)=1a_Q(v)=1 for v<W1v<W-1 and aQ(W1)=0a_Q(W-1)=0. Define Up(k)=vQprp(v)kaQ(v),Bp(k)={vQp:rp(v)k}.U_p(k)=\sum_{\substack{v\in Q_p\\r_p(v)\le k}}a_Q(v), \qquad B_p(k)=\bigl|\{v\in Q_p:r_p(v)\le k\}\bigr|. Both tables are constant for kZk\ge Z.

Lemma 23.1 (Stable corner decomposition). For nS+3n\ge S+3 and k>0k>0, gpn(k)=k+1{p=1}+Up(k)Qp+Bp(Hpk),gpn(0)=0. g_p^n(k)=k+\mathbf{1}_{\{p=1\}}+U_p(k)-|Q_p|+B_p(H-p-k), \qquad g_p^n(0)=0. (120) In particular, every surplus is at most β+p\beta+p, and k>Z,Hpk>Zgpn(k)=k+β+p. k>Z,\quad H-p-k>Z \quad\Longrightarrow\quad g_p^n(k)=k+\beta+p. (121)

Proof. The rectangle prefix-layer calculation in (22) assigns excess contribution aQ(v)a_Q(v) on the bottom slice, zero on an interior slice, and 1-1 on the top slice. This includes the origin: its excess contribution is the transverse origin cost. The prefix-layer identity therefore counts the selected bottom weights through Up(k)U_p(k) and subtracts the number of selected top vertices.

Coordinate complement preserves parity and reverses both weight and lexicographic order. It carries the top slice to the bottom slice. Thus selected top vertices correspond to bottom vertices outside the prefix of size HpkH-p-k, and their number is QpBp(Hpk)|Q_p|-B_p(H-p-k). This proves (120). The empty prefix is separate because the extra origin-neighbor term requires a nonempty odd prefix.

The transverse full-class cost identity gives Up()=Q1p1{p=1}U_p(\infty)=|Q_{1-p}|-\mathbf{1}_{\{p=1\}} and Bp()=QpB_p(\infty)=|Q_p|. Nonnegativity of aQa_Q gives the asserted upper bound on surplus. Stabilizing both tables gives (121). ◻

The decomposition gives the stronger identities needed to change length. For two valid majority sizes HH and H+δH+\delta, with both longitudinal lengths at least S+3S+3, we have Hpk>ZgpH+δ(k)=gpH(k),k>ZgpH+δ(k+δ)=gpH(k)+δ.\begin{aligned} H-p-k>Z&\quad\Longrightarrow\quad g_p^{H+\delta}(k)=g_p^H(k), \\ k>Z&\quad\Longrightarrow\quad g_p^{H+\delta}(k+\delta)=g_p^H(k)+\delta. \end{aligned}(122, 123) In the first identity the tail table is full; in the second the bottom weight table is full and the tail argument is unchanged. The first also holds at k=0k=0, since both profiles are zero there. Superscripts now indicate majority size rather than longitudinal length.

An odd rectangle has a spanning path whose two endpoints lie in its majority color: traverse successive rows alternately forward and backward. On that odd path a proper majority kk-set has at least kk neighbors, by omitting an unselected majority vertex and matching selected vertices toward it from both sides. A nonempty minority kk-set has at least k+1k+1 neighbors, by its consecutive blocks in the spacing-two path order. The rectangle contains these path edges, so g0(k)k (k<H),g1(k)k+1 (k>0),g0(H)=H1. g_0(k)\ge k\ (k<H),\qquad g_1(k)\ge k+1\ (k>0),\qquad g_0(H)=H-1. (124)

Corollary 23.2 (Eventual feasibility threshold). If H2Z+3H\ge2Z+3, then h(QPn)=(W+1)/2h(Q\mathbin{\square}P_n)=(W+1)/2.

Proof. The size condition implies n>S+3n>S+3. The majority surplus is at most β\beta and attains β\beta at k=Z+1k=Z+1 by (121). Apply the rectangular-grid feasibility theorem (Abramovskaya et al. 2016, Theorem 2). ◻

The same budget threshold holds for every nWn\ge W on rectangles by the rectangle feasibility theorem. The conservative hypothesis here is kept for the shared insertion argument.

The period and an explicit threshold

Fix a feasible eventual budget mβ+1m\ge\beta+1 and set d=2mW>0,g=gcd(W,d),Δ=lcm(W,d)=Wd/g.d=2m-W>0,\qquad g=\gcd(W,d),\qquad \Delta=\operatorname{lcm}(W,d)=Wd/g. For the explicit threshold define J=m+1,A=Z+1,R=Δ+2J,B=8Z+6d+2,L=Z+m+1,E=B+4L(B+1),H=R+2A+4J+2+2E(R+2J+1).\begin{aligned} J&=m+1,& A&=Z+1,& R&=\Delta+2J,\notag\\ B&=8Z+6d+2,& L&=Z+m+1,& \mathcal{E}&=B+4L(B+1),\notag\\ H_*&=R+2A+4J+2+2\mathcal{E}(R+2J+1). \end{aligned}(125)

Theorem 23.3 (Eventual affine period under the preceding profile hypotheses). For every odd nn with (Wn+1)/2H(Wn+1)/2\ge H_*, Tm(QPn+2d/g)=Tm(QPn)+4W/g. T_m(Q\mathbin{\square}P_{n+2d/g}) =T_m(Q\mathbin{\square}P_n)+4W/g. (126) At the eventual minimum budget m=(W+1)/2m=(W+1)/2, increasing a sufficiently large odd length by two increases the optimal time by exactly 4W4W.

The threshold is not intended to be sharp. The proof uses the profile bounds, plateau and stable translations just proved, together with connectedness.

A potential with a bounded total deficit

For nS+3n\ge S+3, write H=(Wn+1)/2H=(Wn+1)/2 and M=H1M=H-1. Define K=2Z+2m+1,Γ=(2H4Z2m5)+,Fp(k)=min{Γ,(2k+pK)+}.K=2Z+2m+1,\qquad \Gamma=\left(2H-4Z-2m-5\right)_+,\qquad F_p(k)=\min\{\Gamma,\left(2k+p-K\right)_+\}.

Lemma 23.4 (Uniform potential and time bounds). For 0rm0\le r\le m, Fp(k)F1p(gp((kr)+))(2rW)+. F_p(k)-F_{1-p}\bigl(g_p(\left(k-r\right)_+)\bigr) \le\left(2r-W\right)_+. (127) Consequently 2Γ/dTm(QPn)4(Mm)+/d+2. \left\lceil 2\Gamma/d\right\rceil\le T_m(Q\mathbin{\square}P_n) \le4\left\lceil\left(M-m\right)_+/d\right\rceil+2. (128)

Proof. The potential inequality is trivial if Γ=0\Gamma=0. Otherwise let q=(kr)+q=\left(k-r\right)_+ and j=gp(q)j=g_p(q). If qZq\le Z, then kZ+mk\le Z+m and 2k+pK02k+p-K\le0, so the current potential is zero. If qHZ1q\ge H-Z-1, then jq1HZ2j\ge q-1\ge H-Z-2, and 2j+(1p)K2H2Z4K=Γ.2j+(1-p)-K\ge2H-2Z-4-K=\Gamma. The successor potential is therefore Γ\Gamma. In the remaining region both profiles are on their plateaus, so j=kr+β+pj=k-r+\beta+p. The difference of the unclipped affine expressions is 2rW2r-W. Common monotone, 11-Lipschitz clipping proves (127).

For two quota shares r,mrr,m-r, the right sides sum to at most d=2mWd=2m-W. Both full color classes have potential Γ\Gamma, giving the lower bound by summing daily decreases. For the upper bound, start with the minority cohort of size MM. Each pair of full-budget days reduces an uncleared cohort by at least dd. Thus 2(Mm)+/d+12\left\lceil\left(M-m\right)_+/d\right\rceil+1 days suffice. Pad early clearing to this fixed odd phase length. The other initial cohort remains its full current color class and, after the odd phase, is also in the minority color with size MM. Repeat the phase to obtain the upper bound. ◻

For a rectangle Q=PwQ=P_w, w=2b+1w=2b+1, the explicit profiles of Theorem 5.1 permit the sharper corner radius Z=b2Z=b^2 in the preceding argument. At minimum budget, strengthen its potential slightly as follows, for every odd nwn\ge w. Take K=2b2+2b+2K=2b^2+2b+2 and Γ=(2H4b22b6)+\Gamma=\left(2H-4b^2-2b-6\right)_+. In the low region the current potential is zero for r<mr<m and at most one for r=mr=m; the high-region and plateau arguments are unchanged. This gives the useful uniform estimate max{0,2wn2w2+2w10}T(w+1)/2(PwPn)2wn2w2. \max\{0,\,2wn-2w^2+2w-10\} \le T_{(w+1)/2}(P_w\mathbin{\square}P_n) \le2wn-2w-2. (129) Thus its leading term is 2wn2wn for every fixed odd width, independently of whether a sharper correction has been determined.

Return to the preceding cylinder family, with Z=W(S+1)Z=W(S+1) and the potential of Lemma 23.4. Assume HHH\ge H_*, so Γ>0\Gamma>0 and M>mM>m. Fix an optimal prefix strategy, using padded full quotas as in Section 2. Let Φt\Phi_t be the sum of its two current-color potentials and put ηt=d(ΦtΦt+1)0.\eta_t=d-(\Phi_t-\Phi_{t+1})\ge0. These are integers, and the upper bound in (128) gives tηt=dTm2Γ8Z+6d+2=B. \sum_t\eta_t=dT_m-2\Gamma\le8Z+6d+2=B. (130) Here d(Mm)/dMm+d1d\left\lceil(M-m)/d\right\rceil\le M-m+d-1 accounts for the rounding. Call a day efficient if ηt=0\eta_t=0, and bad otherwise. There are at most BB bad days.

An efficient day gives all mm inspections to one cohort. Indeed, if both positive-part losses in (127) are positive, their sum is dW<dd-W<d. If only one is positive but neither share is mm, it is at most d2d-2. Thus on an efficient day the active cohort loses exactly dd potential and the inactive cohort’s potential remains exactly constant.

From flat potentials to empty or full cohorts

Zero inspections strictly increase every intermediate potential: 0<Fp(k)<ΓF1p(gp(k))>Fp(k). 0<F_p(k)<\Gamma \quad\Longrightarrow\quad F_{1-p}(g_p(k))>F_p(k). (131) For a proper majority prefix, g0(k)kg_0(k)\ge k, so its unclipped expression increases by at least one after the color reversal. A full majority prefix has potential Γ\Gamma and is excluded. For a nonempty minority prefix, g1(k)k+1g_1(k)\ge k+1, giving the same conclusion. Clipping preserves strict growth while the old value is below Γ\Gamma.

After an active cohort loses dd on an efficient day, its potential is strictly below Γ\Gamma. If it is still positive, (131) forces it to stay active on the next efficient day. A switch is possible only when its potential reaches zero. It cannot become active again in the same efficient run, since zero cannot lose dd and its inactive value must stay constant. Hence each consecutive efficient run has at most two focused blocks, and there are at most 2(B+1)2(B+1) such blocks in total.

Call a day clean when all mm inspections target one cohort and the other cohort is actually empty or actually its full current color class. Flat potential alone is insufficient for this conclusion. We now bound the transient days needed to reach actual emptiness or fullness.

If a nonempty proper support XX lies in one color of a connected bipartite graph without isolated vertices, then XN2(X)X\subsetneq N^2(X). Inclusion follows by backtracking along an edge. Equality would make XX closed under two-step paths; connectivity makes the two-step graph connected within each color and would force XX to be full. Therefore an uninspected nonempty proper prefix grows by at least one every two days until it is full.

During an efficient focused block the inactive potential is constantly zero or Γ\Gamma. At zero, its count is at most Z+m=L1Z+m=L-1; if nonempty, it cannot remain in that range for more than 2L2L days. At Γ\Gamma, its count is at least HZ2H-Z-2, hence within LL of its full class; it becomes full within 2L2L days. Empty and full cohorts remain so under further uninspected moves. Each efficient block therefore contributes at most 2L2L nonclean days. Counting all bad days as well, the entire optimal search has at most E=B+4L(B+1) \mathcal{E}=B+4L(B+1) (132) nonclean days.

A protected band and its two individual cuts

Every one-day count change has absolute value at most J=m+1J=m+1: profile surplus is between 1-1 and β+1\beta+1, and each quota is at most mm. Record both source counts from each nonclean day. A count kk forbids integer cuts cc with k[cJ,c+R+J]k\in[c-J,c+R+J], at most R+2J+1R+2J+1 cuts. There are at most 2E2\mathcal{E} records. Restrict candidate cuts to A+2JcHRA2J2. A+2J\le c\le H-R-A-2J-2. (133) There are HR2A4J1H-R-2A-4J-1 candidates. By (125), this exceeds 2E(R+2J+1)2\mathcal{E}(R+2J+1). Choose a cut forbidden by no record.

No nonclean transition can touch the protected interval [c,c+R][c,c+R]. A cohort in that interval is therefore active on every day, receiving all mm inspections; an inactive clean cohort is empty or full, both outside the interval. Its count never increases. Nor can it cross the interval upwards: a nonclean transition cannot touch it, and a clean active transition does not increase. Both cohorts begin above and finish below the interval.

For each initial cohort ii, choose its first count xix_i at most c+Δ+Jc+\Delta+J. The previous count is larger, so the displacement bound gives c+Δ<xic+Δ+J. c+\Delta<x_i\le c+\Delta+J. (134) The entire protected interval is inside the profile plateaus, including all relevant survivors. A full-budget step there sends kk to km+β+pk-m+\beta+p, so every pair of days reduces its count by exactly dd and restores its color. The next τ=2Δ/d\tau=2\Delta/d days therefore take xix_i to xiΔ(c,c+J]x_i-\Delta\in(c,c+J]. This duration is even, and the trajectory stays in the protected band. Throughout the block its inactive companion remains empty or full. The two crossing blocks cannot overlap.

Define the individual endpoints i=xiΔ,ui=xi.\ell_i=x_i-\Delta,\qquad u_i=x_i. They need not agree for the two cohorts. This avoids an otherwise real residue problem: when d>1d>1, a trajectory may skip a prescribed count, and the two cohorts need not have matching residues. One common protected band supplies two legitimate individual cuts. Every visit to (i,ui)(\ell_i,u_i) belongs to the chosen crossing block, because active clean trajectories are nonincreasing and nonclean transitions cannot touch the larger band. Boundary stalls at the minimum budget are harmless; the even block duration preserves the needed phase.

Removing and enlarging the crossing blocks

Proof of Theorem 23.3. First contract the majority size from HH to HΔH-\Delta and delete both crossing blocks of length τ\tau. At each remaining state transform initial cohort ii by fi(k)={k,ki,kΔ,kui.f_i(k)= \begin{cases} k,&k\le\ell_i,\\ k-\Delta,&k\ge u_i. \end{cases} No retained state lies strictly between these cases. At the ends of a deleted block, uiu_i and i\ell_i both map to i\ell_i. Its inactive companion is empty or full at both ends; a full class maps to the contracted full class. Since τ\tau is even, the color labels also match. The two state paths therefore glue.

For a low retained source, its survivor is at most i\ell_i. The contracted far-distance satisfies (HΔ)i=HuiH(c+R)A+2J+2,(H-\Delta)-\ell_i=H-u_i \ge H-(c+R)\ge A+2J+2, so the low profile identity (122) applies. Its successor cannot enter the removed interval, by the protected-band argument. For a high retained source, the contracted survivor is at least im>cm>Z.\ell_i-m>c-m>Z. The stable upper profile identity (123) therefore gives gpH(q+Δ)=gpHΔ(q)+Δ.g_p^H(q+\Delta)=g_p^{H-\Delta}(q)+\Delta. These identities verify every retained transition. Quotas remain within the same budget, and unused quota may be wasted. The result is a physical prefix search on length n2Δ/Wn-2\Delta/W. Its majority size is at least HΔ2Z+6J+4H_*-\Delta\ge2Z+6J+4, so its length exceeds 4(S+1)4(S+1) and the longitudinal coordinate remains longest. Thus all stable profile identities still apply. The resulting search is completed in Tm(QPn)4Δ/dT_m(Q\mathbin{\square}P_n)-4\Delta/d days. Hence Tm(QPn2Δ/W)Tm(QPn)4Δ/d. T_m(Q\mathbin{\square}P_{n-2\Delta/W}) \le T_m(Q\mathbin{\square}P_n)-4\Delta/d. (135)

Conversely, start with an optimal search on any HHH\ge H_* and its protected blocks. Enlarge HH to H+ΔH+\Delta. Keep lower counts at or below i\ell_i unchanged and increase upper counts at or above uiu_i by Δ\Delta. Replace each block from uiu_i to i\ell_i by a clean block from ui+Δu_i+\Delta to i\ell_i, lasting 4Δ/d4\Delta/d days. The affine profiles realize this trajectory explicitly, with the inactive companion empty or the enlarged full class. The extra τ\tau days per block are even. The same low and high identities verify every other transition. Thus Tm(QPn+2Δ/W)Tm(QPn)+4Δ/d.T_m(Q\mathbin{\square}P_{n+2\Delta/W}) \le T_m(Q\mathbin{\square}P_n)+4\Delta/d. Apply (135) at H+ΔH+\Delta for the reverse inequality. Since Δ/W=d/g\Delta/W=d/g and Δ/d=W/g\Delta/d=W/g, this proves (126). ◻

Let n0n_0 be the least odd length at or beyond the threshold. For each of the d/gd/g odd residue classes modulo 2d/g2d/g, the exact two-count recurrence determines the optimum and an optimal strategy at one of n0,n0+2,,n0+2d/g2.n_0,n_0+2,\ldots,n_0+2d/g-2. The theorem then determines every later time in that class and constructs its optimal strategy by insertion. In particular, Tm(QPn)=2W2mWn+OQ,m(1).T_m(Q\mathbin{\square}P_n)=\frac{2W}{2m-W}\,n+O_{Q,m}(1). At the eventual minimum budget there is one offset C(Q)C(Q), with T(W+1)/2(QPn)=2WnC(Q)T_{(W+1)/2}(Q\mathbin{\square}P_n)=2Wn-C(Q) for every sufficiently large odd nn. The offset can depend on the transverse shape, not only on its number of rooms. For rectangular cross-sections Q=PwQ=P_w, the stronger bounds in (129) give 2w+2C(w)2w22w+102w+2\le C(w)\le2w^2-2w+10. The offset recurrence and its parameter-dependent finite initialization are not a fixed-size numerical expression. Their reduction remains part of the rectangle objective when Q=PwQ=P_w.

A height construction used by rectangle bounds

We retain this construction in its natural generality because its path-cross-section case supplies the upper bounds used in the rectangle interface proofs. Independent higher-dimensional applications are parked in the companion.

Theorem 24.1. If HH is any finite bipartite graph with A1A\ge1 vertices and n2n\ge2, then h(HPn)A/2+1.h(H\mathbin{\square}P_n)\le\left\lfloor A/2\right\rfloor+1. For m>A/2m>A/2, at most 2A(n+2)/(2mA)2\left\lceil A(n+2)/(2m-A)\right\rceil days suffice.

Proof. We first clear one initial-color cohort. Write the path coordinate as 0z<n0\le z<n. Bound the possible positions in each fiber by a cutoff ava_v, of the current required parity, such that auav=1|a_u-a_v|=1 whenever uvuv is an edge of HH. Initially take av=n1a_v=n-1 or n2n-2 according to its parity; this bounds the full cohort. Cutoffs may later be negative or exceed the board.

At a local maximum vv, lower ava_v by two. Record the room at the old height if it lies on the board. Every adjacent difference stays one. A sequence of mm such virtual operations records at most mm distinct rooms: repeated operations in a fiber use strictly decreasing heights. Inspect those rooms simultaneously. The survivors lie below the new cutoffs ava'_v. After movement their cutoffs are bounded by av+1a'_v+1: a path move increases height by at most one, and an HH-move arrives from uu with auav+1a'_u\le a'_v+1.

Choose the virtual operations in a fixed cyclic order. List first the initially higher color class of HH, then the other class, and repeat this AA-letter word. Every operation is at a local maximum; after a whole color class has been lowered, the other is higher. Adding one to all cutoffs after a day changes no comparison. Isolated vertices of HH cause no difficulty.

After tt days every vertex has been lowered at least mt/A\left\lfloor mt/A\right\rfloor times, so maxvav(t)n1+t2mt/A<n+1t(2mA)/A.\max_v a_v(t)\le n-1+t-2\left\lfloor mt/A\right\rfloor < n+1-t(2m-A)/A. The displayed number of days per cohort makes every cutoff negative. Since HPnH\mathbin{\square}P_n has no isolated vertices, an empty post-movement belief certifies capture during inspection. Repeat for the other initial cohort, starting with the full bound of its then-current parity. ◻

A growth bound used by rectangle interfaces

The exact offsets remain sensitive to geometry, but the leading term of the optimal time has a uniform answer across all side parities.

Theorem 25.1. Let HH be a finite bipartite graph with A2A\ge2 vertices and a Hamiltonian path. For each fixed integer m>A/2m>A/2, as nn\to\infty through either parity, Tm(HPn)=2An2mA+OA,m(1). T_m(H\mathbin{\square}P_n)=\frac{2An}{2m-A}+O_{A,m}(1). (136) The height strategy in Theorem 24.1 has a bounded additive excess over the optimal time. When AA is even, the following bounds hold explicitly for every n2n\ge2: 2(An/2A2m)+mA/2Tm(HPn)2A(n+2)2mA. \frac{2\left(An/2-A^2-m\right)_+}{m-A/2} \le T_m(H\mathbin{\square}P_n) \le 2\left\lceil\frac{A(n+2)}{2m-A}\right\rceil. (137) In particular the theorem applies to every Cartesian transverse box.

Lemma 25.2 (An interior expansion bound for even-width rectangles). On P2bPnP_{2b}\mathbin{\square}P_n, b1,n2b\ge1,n\ge2, put h=bnh=bn and K=2b2K=2b^2. Every one-color set RR with K<R<hKK<|R|<h-K satisfies N(R)R+b|N(R)|\ge|R|+b.

Proof. Match consecutive short-axis rows in pairs. Contract an edge followed by the inverse matching to obtain a directed b×nb\times n grid DD. It has loops, bidirectional horizontal edges, and vertical rungs directed one way in even columns and the other way in odd columns. The opposite physical color reverses all rung directions. In either case N(R)R=ND+(R)R.|N(R)|-|R|=|N_D^+(R)\setminus R|. Suppose the outside boundary B=ND+(R)RB=N_D^+(R)\setminus R has size s<bs<b. In DBD-B, at least one entire horizontal row is undeleted. Its vertices lie in a single strongly connected component CC.

Call a column bad if it contains a vertex of BB. Every adjacent pair of good columns is strongly connected: the horizontal edges go both ways, and the opposite rung directions let a walk go both ways between adjacent rows. The pair meets the undeleted row, hence belongs to CC. Only bad columns and isolated good columns can contain vertices outside CC. There are at most ss of the former and s+1s+1 of the latter, so V(D)Cb(2s+1)<2b2=K.|V(D)\setminus C|\le b(2s+1)<2b^2=K. This count includes deleted vertices and also covers the case with no adjacent good columns. The set RR is outgoing-closed in DBD-B. It therefore either avoids CC or contains CC entirely. In the first case RK|R|\le K; in the second hRKh-|R|\le K, proving the contrapositive. ◻

Proof of Theorem 25.1. First let A=2bA=2b and consider the spanning rectangle PAPnP_A\mathbin{\square}P_n. Put C=(h2Km)+C=\left(h-2K-m\right)_+, L=K+mL=K+m, and ψ(k)=min{C,(kL)+}.\psi(k)=\min\{C,\left(k-L\right)_+\}. If a cohort of size kk receives pmp\le m useful inspections, write r=kpr=k-p and k=N(R)k'=|N(R)| for its survivor size and actual next size. The matching gives krk'\ge r for every survivor set. If rKr\le K, the source potential is zero. If rhKr\ge h-K, the target potential is CC whenever C>0C>0, while C=0C=0 is trivial. In the remaining case Lemma 25.2 gives kkp+bk'\ge k-p+b. Since clipping is monotone and has Lipschitz constant one, all cases give ψ(k)ψ(k)max{0,pb}.\psi(k)-\psi(k')\le\max\{0,p-b\}. The two cohorts’ useful allocations sum to at most mm, so their combined potential decreases by at most mbm-b. Their initial sum is 2C2C and their final sum zero. Thus Tm2C/(mb)T_m\ge2C/(m-b) on the rectangle. The rectangle is a subgraph of HPnH\mathbin{\square}P_n, giving the same lower bound there. Theorem 24.1 gives the displayed upper bound, with the same coefficient of nn.

For odd A3A\ge3, take the largest odd n\ell\le n. The spanning rectangle PAPP_A\mathbin{\square}P_\ell has, by the fixed-budget odd-rectangle theorem, an eventual affine period with length increment 2(2mA)/gcd(A,2mA)2(2m-A)/\gcd(A,2m-A) and time increment 4A/gcd(A,2mA)4A/\gcd(A,2m-A). Its time is consequently 2A/(2mA)+OA,m(1)2A\ell/(2m-A)+O_{A,m}(1). Since n1n-\ell\le1, this gives the required lower bound on the whole cylinder. The same height upper bound completes the proof. ◻

The even-width expansion lemma and its potential proof will be used in the rectangle interface construction. General-cylinder applications are recorded in the companion.

Efficient fronts and eventual periods for rectangle proofs

This section retains the physical efficient-frontier and paired-column arguments used by the exact rectangle interface theorem. They are stated for Hamiltonian cross-sections because the proofs have that natural generality. The independent synthesis for every transverse Cartesian box is preserved in the parked companion. For the rectangle objective take Q=PwQ=P_w throughout. Effective periods and finite preprocessing remain intermediate results under the absolute O(1)O(1) numerical completion goal.

Theorem 26.1. Let QQ be a finite bipartite graph with a Hamiltonian path and 2b2b vertices, where b1b\ge1. Fix an integer m>bm>b, and put d=mbd=m-b. There is an effective positive integer NN such that, with the even period Δ=2d/gcd(b,d)\Delta=2d/\gcd(b,d), Tm(QPn+Δ)=Tm(QPn)+2bΔd,nN. T_m(Q\mathbin{\square}P_{n+\Delta}) =T_m(Q\mathbin{\square}P_n)+\frac{2b\Delta}{d},\qquad n\ge N. (138) The assertion holds for both parities of nn. Thus the optimal time is eventually affine on every residue class modulo Δ\Delta. The displayed period is valid but need not be the smallest; the effective threshold below is deliberately conservative.

Fix a Hamiltonian order on QQ and match consecutive vertices in that order. Each checkerboard class in the cylinder identifies with a b×nb\times n array of matched pairs. Write h=bnh=bn. As in Lemma 25.2, following an edge by the inverse matching gives a directed graph containing loops, bidirectional edges along every longitudinal row, and alternating vertical rungs between consecutive rows. Extra edges of QQ add directed edges inside columns. For a one-color support RR, its ordinary neighborhood, expressed using the opposite-color matching, is RBR\cup B, where BB is the directed outside boundary. In particular N(R)R=B|N(R)|-|R|=|B|.

Equality in the interior expansion bound

Lemma 26.2 (A finite family of minimum-surplus frontiers). Put K=4b2K=4b^2. Suppose a one-color set RR in QPnQ\mathbin{\square}P_n satisfies K<R<hK,N(R)=R+b.K<|R|<h-K,\qquad |N(R)|=|R|+b. In the matched array, its rows are either all prefixes or all suffixes: there are integers 1cin21\le c_i\le n-2, 0i<b0\le i<b, such that either Ri={0,,ci1}for every i,orRi={ci+1,,n1}for every i.R_i=\{0,\ldots,c_i-1\}\quad\hbox{for every }i, \qquad\hbox{or}\qquad R_i=\{c_i+1,\ldots,n-1\}\quad\hbox{for every }i. Adjacent cuts satisfy ci+1ci2|c_{i+1}-c_i|\le2. If their difference is two, the rung at the sole intermediate column points from outside RR into RR. The outside boundary consists exactly of the bb cut points. Additional edges of QQ may exclude some such patterns, but introduce no additional forms.

Proof. First use only the spanning Hamiltonian rectangle. Its boundary has size at most bb, and Lemma 25.2 shows that its size is at least bb. Hence its boundary BB has exactly bb points and also equals the boundary for the whole cylinder.

If one row misses BB, the strongly connected component argument in Lemma 25.2 still applies with bb deleted points. One component contains all but at most b(2b+1)Kb(2b+1)\le K vertices, including the deleted points in the exceptional count. The outgoing-closed set RR either contains or avoids that component, contrary to the two strict size bounds. Thus every row contains exactly one boundary point, say cic_i. Horizontal bidirectionality shows that a row of RR is empty, a prefix, a suffix, or the entire row except its boundary point.

For two adjacent rows, the difference of their row sets is a union of at most two integer intervals. At a column where a rung points from the first row to the second, such a difference can contain only the second row’s boundary point. It therefore has at most one point of that column parity. A union of at most two intervals with this property has at most four points. Applying this in both directions gives RiRi+14,Ri+1Ri4.|R_i\setminus R_{i+1}|\le4,\qquad |R_{i+1}\setminus R_i|\le4. An empty row would now imply R4b2|R|\le4b^2, by propagating the bound through all rows. A row full except at its boundary similarly implies hRb(1+4(b1))4b2h-|R|\le b(1+4(b-1))\le4b^2. Both are excluded.

Suppose an adjacent prefix and suffix have lengths uu and vv. Their two differences have sizes min(u,nv)\min(u,n-v) and min(v,nu)\min(v,n-u), both at most four. The hypotheses give n>8n>8. If either length exceeds four, both lengths are at least n4n-4; otherwise both are at most four. Propagation through all rows again makes either RR or its complement have size at most KK. Hence all rows have the same orientation, and their cuts are interior.

Every column strictly between two adjacent cuts has one rung endpoint inside RR and its other endpoint outside both RR and BB. Its rung must therefore point into RR. Alternating directions permit at most one such column, proving the cut bound and parity condition. Conversely, for the spanning rectangle these conditions give exactly the indicated boundary: horizontal edges reach every cut, and no rung reaches another outside point. Extra transverse edges impose only further restrictions on these same bounded-width patterns. ◻

The cuts have total range at most 2(b1)2(b-1); for subsequent spatial margins use the larger value v=2b+2v=2b+2. For a prefix survivor with cuts (ci)(c_i), the next matched belief consists of prefixes of lengths ci+1c_i+1. A following prefix survivor with cuts (ei)(e_i) is possible precisely when eici+1e_i\le c_i+1, and its useful inspection count is p=i=0b1(ci+1ei). p=\sum_{i=0}^{b-1}(c_i+1-e_i). (139) At p=mp=m its sum of cuts decreases by dd. The suffix case is reflected and its sum increases by dd. An orientation cannot change between two such bulk survivors: the next belief of a prefix survivor omits the last column in every row, whereas every nonempty suffix contains it.

Only boundedly many days can behave differently

Consider an optimal strategy on a sufficiently long cylinder, and set C=h2Km>d,ψ(k)=min{C,(kKm)+}.C=h-2K-m>d,\qquad \psi(k)=\min\{C,\left(k-K-m\right)_+\}. The argument proving Theorem 25.1, with the larger cutoff K=4b2K=4b^2, gives for a cohort receiving pp useful inspections and changing from count kk to kk', ψ(k)ψ(k)max{0,pb}. \psi(k)-\psi(k')\le\max\{0,p-b\}. (140) The two cohorts start with total potential 2C2C and end with zero. Their combined daily decrease is at most dd. The height upper bound Tm2b(n+2)/dT_m\le2\left\lceil b(n+2)/d\right\rceil consequently gives dTm2CB,B=4K+4m+2b2. dT_m-2C\le B, \qquad B=4K+4m+2b-2. (141) Indeed the integer ceiling bound gives dTm2b(n+2)+2d2dT_m\le2b(n+2)+2d-2.

Call a day efficient when its total potential loss is exactly dd. Every other day contributes at least one to the nonnegative integer slack in (141), so at most BB days are inefficient. Potential increases contribute additional slack and cause no exception. Equality forces all mm useful inspections to be assigned to one cohort, called the day’s owner: any nontrivial split makes the sum of the two positive-part bounds in (140) strictly less than dd.

On an efficient day the owner loses potential dd, while its untouched mate has constant potential. The owner’s source potential is positive, so its survivor count rr exceeds KK. Its target potential is below CC, so its next count, and therefore rr, is below hKh-K. The interior expansion bound gives raw count loss at most mb=dm-b=d. Clipping cannot increase a positive loss; equality forces exactly mm useful inspections, raw count loss dd, and survivor surplus exactly bb. Thus every efficient owner survivor has the form in Lemma 26.2.

An untouched cohort with potential strictly between zero and CC cannot have constant potential: its actual count lies in the interior range and its neighborhood grows. The mate of an efficient owner therefore has potential zero or CC. A consecutive run of efficient days has at most two owner blocks. Once a cohort has owned a day its potential is below CC; if ownership switches, that cohort can remain unchanged only at zero, from which it cannot subsequently lose another dd in the run. There are consequently at most 2(B+1)2(B+1) owner blocks.

The matching-contracted graph is strongly connected for n2n\ge2: neighboring pairs of columns allow movement in both rung directions, and rows are bidirectional. Every proper nonempty untouched support therefore grows by at least one room per day. Put L=K+m+1L=K+m+1. An untouched nonempty mate with zero potential cannot stay in that collar for LL days, while an untouched mate with potential CC has deficit at most KK and becomes full within KK days. Mark every inefficient day and the first LL days of every owner block as nonclean. Their total number is at most E=B+2L(B+1). E=B+2L(B+1). (142) On each remaining clean day the mate is globally full or empty. A maximal clean block has one owner, a fixed frontier orientation, and both its owner beliefs and survivors have bounded-width descriptions: its first belief is already the neighborhood of the preceding efficient survivor. By (139), its average cut moves at the constant speed d/bd/b toward clearance. Individual cuts need not move monotonically.

A physical interval protected from all exceptional behavior

At the start of every consecutive block of nonclean days, mark the preceding clean frontier’s bb cut columns, if there is one. Initially the board is full, so no cuts need be marked. Also mark every actual inspection column on every nonclean day, and the two board ends. There are at most b(E+1)+mE+2F,F=(b+m)(E+1)+2b(E+1)+mE+2\le F,\qquad F=(b+m)(E+1)+2 marked columns. Enlarge each mark by radius ρ=E+2b+m+2\rho=E+2b+m+2. Outside these intervals, each cohort is locally full or empty throughout every nonclean block. At its start, all cuts are far away. During its at most EE days there are no nearby inspections, and movement propagates information by at most one longitudinal column per day. An empty region thus stays empty in the protected interior. A full region stays full using the matching inside each column. This proves the assertion for all intermediate states as well as the endpoints, even if remote shots create arbitrary holes elsewhere.

For any prescribed WW, the inequality n>F(2ρ+1)+(F+1)(W+2v+4) n>F(2\rho+1)+(F+1)(W+2v+4) (143) provides an unmarked interval of length at least W+2v+4W+2v+4. Trim v+2v+2 columns from each end and call the retained interval JJ; it has length at least WW.

A clean block has its endpoint frontiers outside the untrimmed interval: the preceding nonclean block ends uniformly there, and the cuts preceding the following nonclean block were marked. Its average frontier moves strictly toward clearance, with cut range at most vv. Consequently it can change its owner’s status on JJ only from full to empty, through a single complete passage. If its endpoint statuses agree, trimming removes any partial excursion onto JJ. It cannot start empty and end full, since that would move the average across the interval in the wrong direction. Nonclean blocks preserve the local status. Since each cohort starts full on JJ and ends empty there, each has exactly one clean crossing. These crossings occur at disjoint times; during either one the other cohort is globally full or empty.

Connecting physical cutoff frontiers

A direct height descent connects any compatible endpoints once the duration exceeds a short bound. This supplies the replacement segments needed for the exact period, without enumerating frontier states.

Put A=2bA=2b and D=2mA=2dD=2m-A=2d. For a left frontier, let ava_v be the last occupied physical longitudinal coordinate in the fiber over vQv\in Q. The two cutoffs in transverse matched pair ii are ci1c_i-1 and ci2c_i-2, in the order required by parity. Its actual next neighborhood advances both by one. A transverse edge uvuv consequently forces auav+1a_u\le a_v+1, and reversing the edge gives the opposite inequality. Their parities differ, so auav=1on every edge uv of Q. |a_u-a_v|=1\qquad\hbox{on every edge }uv\hbox{ of }Q. (144) This includes every extra transverse edge. Inside the protected crossing, all fiber cutoffs are far from both longitudinal ends. Conversely, any such interior prefix configuration satisfying (144) has neighborhood cutoffs exactly av+1a_v+1: longitudinal movement supplies them and transverse edges supply nothing larger. Right frontiers use reflected coordinates.

Lemma 26.3 (Height endpoints). Let QQ be connected and bipartite, with A2A\ge2 vertices and diameter RR. Fix m>A/2m>A/2 and put D=2mAD=2m-A. Let a,ba,b be integer height configurations satisfying (144). If tAR/m,bvav+t(mod2)for every v,vavvbv=Dt,t\ge\left\lceil AR/m\right\rceil,\qquad b_v\equiv a_v+t\pmod2\quad\hbox{for every }v, \qquad \sum_v a_v-\sum_v b_v=Dt, then tt global additions of one, each followed by mm legal local maximum flips, take aa to bb. At completed days the mean height moves steadily between the endpoint means. All intermediate cutoffs, including partial inspection steps, lie in [μ(b)R, μ(a)+R+1],μ(x)=A1vxv.[\mu(b)-R,\ \mu(a)+R+1],\qquad \mu(x)=A^{-1}\sum_v x_v. Whenever this interval lies inside the cylinder’s interior, these operations are actual movements and mm useful inspections per day.

Proof. This is a corollary of the exact quota-word criterion in Lemma 13.2. Put c=bt1c=b-t\mathbf1. Its mean difference from aa is 2mt/A-2mt/A. Edgewise height differences bound the range of cac-a by 2R2R, so for every vertex cvav2mt/A+2R0.c_v-a_v\le-2mt/A+2R\le0. Thus ba+t1b\le a+t\mathbf1 and the number of required lowerings in that lemma is exactly mtmt. Its movement-first construction gives mm useful lowerings after each of the tt additions.

Every completed day lowers the mean by D/AD/A. A configuration has range at most RR, so its completed-day cutoffs lie between μ(b)R\mu(b)-R and μ(a)+R\mu(a)+R. Movement can raise the upper bound by one; subsequent lowerings descend coordinatewise to the next survivor. This proves the displayed movement-first margin, including partial inspection steps. Within a physical interior, all lowerings remove actual distinct rooms and the global additions are exact neighborhoods. ◻

Set g=gcd(A,D)g=\gcd(A,D), 0=2A/g\ell_0=2A/g, and Δ=2D/g\Delta=2D/g. These are even integers satisfying AΔ=D0A\Delta=D\ell_0. Suppose a clean survivor path from aa to bb has length tAR/m+0t\ge\left\lceil AR/m\right\rceil+\ell_0. After deleting Δ\Delta columns, a left crossing requires endpoints aΔ1,ba-\Delta\mathbf1,b. Their sum difference is D(t0)D(t-\ell_0) and their phase difference is t0t-\ell_0, since both shifts are even. Lemma 26.3 supplies a path of exactly that shorter length. For insertion use endpoints a+Δ1,ba+\Delta\mathbf1,b and duration t+0t+\ell_0. Reflection handles right frontiers. The mean and range bound controls each replacement inside the protected physical band, independently of the old path’s details.

For the present even-order case, 0=2bgcd(b,d),Δ=2dgcd(b,d),K0=2b(2b1)m. \ell_0=\frac{2b}{\gcd(b,d)},\qquad \Delta=\frac{2d}{\gcd(b,d)},\qquad K_0=\left\lceil\frac{2b(2b-1)}{m}\right\rceil. (145) Here are conservative explicit margins that guarantee such a path well inside the protected interval. Set U=K0+0+4,W=2(Δ+v+m+3)+d(U+4)b+2v+2m+10.\begin{aligned} U&=K_0+\ell_0+4,\nonumber\\ W&=2(\Delta+v+m+3) +\left\lceil\frac{d(U+4)}b\right\rceil+2v+2m+10. \end{aligned}(146) In a complete crossing, take the central segment after its average cut has entered JJ with margin Δ+v+m+3\Delta+v+m+3, and before it leaves at the opposite margin. Its average advances by d/bmd/b\le m per edge, so entry and exit overshoots lose at most 2m2m of spatial length. The remaining travel exceeds dU/bdU/b, providing more than UU edges. Every cut is within vv of the average, so the entire segment stays more than Δ\Delta from the ends of JJ. Its endpoint frontiers lie on opposite sides of a central interval of Δ\Delta columns. These margins also cover the entry and exit edges.

For definiteness, one may take N=4+2K+m+d+1b+F(2ρ+1)+(F+1)(W+2v+4)+Δ. N=4+\left\lceil\frac{2K+m+d+1}{b}\right\rceil +F(2\rho+1)+(F+1)(W+2v+4)+\Delta. (147) This ensures C>dC>d, the protected-gap condition, and the same conditions after contracting by Δ\Delta. All constants depend only on bb and mm.

Deleting and inserting the common interval

Start with an optimal strategy on a cylinder long enough for the preceding construction. Delete Δ\Delta consecutive columns from the center of JJ. Outside the two central crossing segments, map rooms and inspections by ordinary column deletion. No nonclean inspection is lost. Every nonclean state is uniformly full or empty near the join, so neighborhood formation commutes with the deletion there. Other clean frontiers are entirely on one side of the join, and their transitions are either left fixed or translated as a whole by the even displacement Δ\Delta.

Within each central crossing, replace its tt-edge path by the (t0)(t-\ell_0)-edge path in Lemma 26.3. For a prefix frontier the new initial cutoffs are Δ\Delta lower and the final cutoffs are the old ones, matching the natural column map at both endpoints. For a suffix frontier use the reflected construction. The mean of the replacement decreases steadily between the mapped endpoint means, and its range is at most 2b12b-1. The chosen margins therefore keep every intermediate cutoff inside the shorter board. Every new daily edge is an actual movement followed by at most mm inspections.

The mate is globally full or empty during this operation. Deleting an even number of days and columns preserves its phase and state. The two crossings are disjoint in time, so their edits do not interfere. An edge is one subsequent inspection day, hence exactly 0\ell_0 days have been removed in each crossing. All remaining inspections respect the original budget. We have proved Tm(QPnΔ)Tm(QPn)20. T_m(Q\mathbin{\square}P_{n-\Delta})\le T_m(Q\mathbin{\square}P_n)-2\ell_0. (148)

For the reverse inequality, prepare an optimal strategy on the shorter, still sufficiently long cylinder and insert Δ\Delta columns in its protected interval. Extend the locally full or empty regions across the inserted band and translate the far-side rooms. Within each crossing, use Lemma 26.3 to replace its tt days by t+0t+\ell_0 days. A prefix frontier starts shifted right by Δ\Delta and ends at the old final cutoff; reflect this for a suffix. The same local transition and margin arguments apply. The full or empty mate returns to its phase, and the total added time is 202\ell_0. Therefore Tm(QPn)Tm(QPnΔ)+20. T_m(Q\mathbin{\square}P_n)\le T_m(Q\mathbin{\square}P_{n-\Delta})+2\ell_0. (149) Combining (148) and (149), and using 20=2bΔ/d2\ell_0=2b\Delta/d, proves Theorem 26.1 for every nNn\ge N after renaming the shorter length nn. The even displacement preserves either longitudinal parity throughout.

Odd-order cross-sections: geometry in paired columns

When the cross-section has odd order, there is no transverse perfect matching. At even longitudinal lengths we instead match consecutive columns. This changes the smallest bulk expansion from a constant cost to two alternating costs. A single bit recording the previous expansion will recover constant progress.

Theorem 26.4. Let QQ be a finite bipartite graph with a Hamiltonian path and A=2b+13A=2b+1\ge3 vertices. Fix an integer mb+1m\ge b+1 and put D=2mAD=2m-A. Put g=gcd(A,D)g=\gcd(A,D) and Δ=2D/g\Delta=2D/g. There is an effective positive integer NN such that Tm(QPn+Δ)=Tm(QPn)+4A/gT_m(Q\mathbin{\square}P_{n+\Delta}) =T_m(Q\mathbin{\square}P_n)+4A/g for every even nNn\ge N.

Write n=2Ln=2L and let X,YX,Y be the bipartition of QQ, with X=b+1|X|=b+1 and Y=b|Y|=b. A Hamiltonian path ensures these color sizes. Match columns 2j2j and 2j+12j+1. Each cohort now identifies with an A×LA\times L array of vertices (v,j)(v,j), one for each vV(Q)v\in V(Q) and paired-column index jj. The contracted graph has loops, bidirectional QQ-edges within every layer, and opposite one-way longitudinal flows on the two QQ colors. Choose phase zero so that XX fibers flow left and YY fibers flow right; phase one reverses both flows. There is no dependence on jj. The ordinary neighborhood surplus is again the cardinality of the directed outside boundary. Throughout the paired-column argument put h=ALh=AL and K=A2K=A^2.

Lemma 26.5 (Minimum surplus in paired columns). Every survivor RR with K<R<hKK<|R|<h-K has surplus at least bb. If its surplus equals bb, then in phase zero all fibers are left prefixes. Across each QQ-edge xyxy, xX,yYx\in X,y\in Y, the XX prefix has the same length as the YY prefix or is one position longer. In phase one the reflected statement holds, with right suffixes. Every fiber has at least two occupied and two unoccupied positions. Two consecutive middle survivors in an actual strategy cannot both have surplus bb.

Proof. Let BB be the outside boundary, of size sbs\le b. If one XX fiber and one YY fiber both avoid BB, all completely undeleted QQ layers lie in one strongly connected component of the graph with BB deleted. Each layer is strongly connected, and the two untouched, oppositely directed fibers connect these layers in both longitudinal directions. At most ss layers contain a boundary point, so this component contains all but at most As<KAs<K vertices, counting the deleted layers among the exceptions. The outgoing-closed set RR either contains or avoids the component, contradicting its middle size. There is at least one undeleted layer: h>2A2h>2A^2 implies L>2A>bL>2A>b.

If s<bs<b, both colors have an untouched fiber, a contradiction. If s=bs=b, there is still an untouched XX fiber, so every YY fiber must contain a boundary point. Thus BB consists of exactly one point (y,cy)(y,c_y) on each YY fiber, and no points on XX fibers.

In phase zero, the boundary-free XX fibers flow left and are prefixes. Bidirectional QQ-edges give, for every edge xyxy, RyRx,RxRy{cy}.R_y\subseteq R_x,\qquad R_x\setminus R_y\subseteq\{c_y\}. Adjacent cardinalities differ by at most one. Connectivity bounds the global range of fiber sizes by A1A-1. Both the average size and average complement size exceed AA, so each fiber has at least two occupied and two unoccupied positions. If Rx={0,,k1}R_x=\{0,\ldots,k-1\}, the inclusions make RyR_y either that prefix or that prefix with its boundary point removed. Removing a point strictly below k1k-1 would leave k1k-1 occupied; its right-going edge would then make kk a second boundary point. Thus Ry={0,,cy1},k{cy,cy+1}.R_y=\{0,\ldots,c_y-1\},\qquad k\in\{c_y,c_y+1\}. This proves the prefix description. Reflection proves the phase-one statement.

The next belief of a phase-zero minimum-surplus frontier leaves its XX lengths unchanged and increases each YY length by one. It still omits position L1L-1 in every fiber. A phase-one minimum-surplus middle survivor would be a nonempty right suffix in every fiber, hence could not be contained in that belief. Reflection handles the other direction. ◻

Lemma 26.6 (The intervening frontier). Suppose RR is a phase-zero middle survivor of surplus bb, and a phase-one middle survivor SN(R)S\subseteq N(R) has surplus b+1b+1. Then all fibers of SS are left prefixes. Across each QQ-edge, its YY prefix has the same length as its XX prefix or is one position longer. The reflected assertion holds with both orientations reversed.

Proof. For any support with boundary BB, a QQ-edge gives SuSvBvS_u\setminus S_v\subseteq B_v. Following a simple QQ path shows that any two fiber cardinalities differ by at most B|B|: its target fibers are distinct, so their boundary counts sum to at most B|B|. At B=b+1|B|=b+1, an empty fiber would give SA(b+1)<A2|S|\le A(b+1)<A^2, contrary to the middle-size hypothesis. Every fiber is nonempty.

The containment SN(R)S\subseteq N(R) ensures that all fibers omit L1L-1. In phase one, each XX fiber flows right. If such a fiber had no boundary point, its nonempty set would be right-closed and would contain L1L-1. Hence each of the b+1b+1 XX fibers meets BB. They exhaust the boundary, leaving no boundary point on any YY fiber. The latter flow left and are prefixes. Applying the same bidirectional-edge and endpoint argument as in Lemma 26.5, with X,YX,Y exchanged, proves that the XX fibers are prefixes as well, with the stated length relation. Reflection gives the other orientation. ◻

Both frontier families have finitely many relative-length patterns. Their length range is at most A1A-1, and choosing the zero-or-one length differences along a spanning tree gives at most 2A12^{A-1} patterns for fixed phase and orientation. Extra edges impose consistency conditions on these patterns.

A history bit and the paired-cylinder period

For each cohort, define et=1e_t=1 precisely when its preceding day’s survivor was in the strict middle range and had surplus bb; otherwise set et=0e_t=0. Initially e0=0e_0=0. If its before-inspection count is ktk_t, use the raw rank 2kt+et2k_t+e_t. Let pp be its useful inspection count, so the current survivor has size r=ktpr=k_t-p, surplus ss, and next count kt+1=r+sk_{t+1}=r+s. The raw loss is (2kt+et)(2kt+1+et+1)=2p2s+etet+1. (2k_t+e_t)-(2k_{t+1}+e_{t+1}) =2p-2s+e_t-e_{t+1}. (150) For a middle survivor with s=bs=b, Lemma 26.5 gives (et,et+1)=(0,1)(e_t,e_{t+1})=(0,1), so the loss is 2pA2p-A. If sb+1s\ge b+1, the new bit is zero and the old bit at most one, again giving loss at most 2pA2p-A.

Set L0=2(K+m)+1,C=2h4K2m1>D,ψt=min{C,(2kt+etL0)+}.L_0=2(K+m)+1,\qquad C=2h-4K-2m-1>D, \qquad \psi_t=\min\{C,\left(2k_t+e_t-L_0\right)_+\}. A survivor of size at most KK gives source rank at most L0L_0, hence source potential zero. A survivor of size at least hKh-K gives next rank at least 2h2K=L0+C2h-2K=L_0+C, hence target potential CC, by the longitudinal matching. Clipping and (150) therefore give, in every case, ψtψt+1max{0,2pA}. \psi_t-\psi_{t+1}\le\max\{0,2p-A\}. (151) For the two useful allocations p+qmp+q\le m, the sum of these charges is at most DD, with equality only if all mm useful inspections belong to one cohort.

Both initial potentials equal CC. The height upper bound T2A(n+2)/DT\le2\left\lceil A(n+2)/D\right\rceil and its integer ceiling estimate imply DT2CB,B=8K+8m+2A.DT-2C\le B, \qquad B=8K+8m+2A. Thus at most BB days have total potential loss below DD. On every efficient day the owner has positive source potential and target potential below CC, which force its survivor into the strict middle range. Equality in the clipped loss then forces equality in (150). The only cases are (s,et,et+1)=(b,0,1)or(b+1,1,0). (s,e_t,e_{t+1})=(b,0,1)\quad\hbox{or}\quad(b+1,1,0). (152) The first survivor is a frontier by Lemma 26.5. In the second case the preceding survivor was a middle minimum-surplus frontier, so the actual containment in its neighborhood permits Lemma 26.6. Both efficient phases therefore have physical frontiers.

The paired contraction is strongly connected for L2L\ge2. An untouched proper nonempty cohort grows by at least one room each day, while its history bit can drop by at most one. Its raw rank therefore increases by at least one, so its potential cannot remain constant strictly between zero and CC. The owner-block argument in Section 26.2 applies unchanged. There are at most 2(B+1)2(B+1) owner blocks. The zero-potential collar has at most K+mK+m possible rooms and the full-potential collar has deficit at most KK. Marking the first L1=K+m+1L_1=K+m+1 days of every owner block, as well as every inefficient day, leaves at most E=B+2L1(B+1) E=B+2L_1(B+1) (153) nonclean days. On each clean block the mate is globally full or empty, with bit zero, and the owner’s surpluses alternate b,b+1b,b+1. The frontiers have a fixed orientation throughout this block: the bridge preserves orientation, and the next minimum-surplus phase has the same orientation as the preceding minimum-surplus phase.

There is a timing distinction when the graph vertices are survivors. At such a vertex write ee for the newly set bit, referring to that survivor itself. If consecutive survivor sizes are r,rr,r' and the first has surplus ss, then r=r+smr'=r+s-m. Their constant-drift rank is 2re2r-e, rather than the before-inspection rank 2k+e2k+e: (2re)(2re)=D (2r-e)-(2r'-e')=D (154) in both alternating cases (s,e,e)=(b,1,0)(s,e,e')=(b,1,0) and (b+1,0,1)(b+1,0,1). The ordinary average occupied length is nonincreasing and may be stationary for one round when m=b+1m=b+1. Its corrected version (2re)/(2A)(2r-e)/(2A) decreases by exactly D/(2A)D/(2A) per edge and differs from it by at most 1/(2A)1/(2A). Use the enlarged margin v=A+2v=A+2 to cover this correction, the fiber range, and the direct height replacements.

These frontiers are also physical height configurations. If lvl_v is the occupied paired-column length and σv{0,1}\sigma_v\in\{0,1\} its physical longitudinal parity, then av=2(lv1)+σv.a_v=2(l_v-1)+\sigma_v. In either phase, the boundary-free color has parity zero and its length equals its neighbor’s length or exceeds it by one. Hence auav=1|a_u-a_v|=1 across every QQ-edge. The bridge lemma ensures this on the intervening phase as well. For a left frontier the sum of the parity indicators is b+1eb+1-e, so the sum of physical heights differs from 2re2r-e by a constant. The drift in (154) is therefore the same physical height drift used in Lemma 26.3.

Apply that lemma with g=gcd(A,D)g=\gcd(A,D) and the conservative diameter bound A1A-1. We may use K0=A(A1)m,0=2A/g,δ=D/g,Δ=2δ. K_0=\left\lceil\frac{A(A-1)}m\right\rceil,\qquad \ell_0=2A/g,\qquad \delta=D/g,\qquad \Delta=2\delta. (155) A crossing of length at least K0+0K_0+\ell_0 can be replaced by one shorter by 0\ell_0 days, shifting the initial endpoint by δ\delta paired columns, or by one longer by 0\ell_0 with the opposite shift. The construction connects actual physical height endpoints, without an additional assumption about intermediate survivor shapes.

We spell out the changes to the protected-band argument to ensure that this is a physical reduction. Mark the paired-column index of every nonclean inspection and the initial frontier cuts of every nonclean block. Together with the ends there are at most F=(A+m)(E+1)+2F=(A+m)(E+1)+2 marks. A physical move crosses at most one pair boundary, so radius ρ=E+2A+m+2\rho=E+2A+m+2 shields all nonclean blocks. Local full preservation uses the longitudinal matching inside each pair; it requires no perfect matching in the odd-order graph QQ. Local empty preservation follows from finite propagation. Thus the argument of Section 26.3 applies in the paired coordinate. Choose a raw gap of length W+2v+4W+2v+4 and trim v+2v+2 at each end. The corrected mean, its nonzero speed, and the margin vv give one complete clean crossing per cohort through the retained band. Their mates are globally full or empty and the crossings are disjoint in time.

Explicit constants are obtained by putting U=K0+0+4,W=2(δ+v+m+3)+D(U+4)2A+2v+2m+10,L=4+4K+2m+1+D2A+F(2ρ+1)+(F+1)(W+2v+4)+δ,\begin{aligned} U&=K_0+\ell_0+4,\nonumber\\ W&=2(\delta+v+m+3) +\left\lceil\frac{D(U+4)}{2A}\right\rceil+2v+2m+10,\nonumber\\ L_*&=4+\left\lceil\frac{4K+2m+1+D}{2A}\right\rceil +F(2\rho+1)+(F+1)(W+2v+4)+\delta, \end{aligned}(156) and taking N=2LN=2L_*. The corrected mean moves by D/(2A)mD/(2A)\le m per edge, so the entry and exit overshoots cost at most 2m2m paired positions. The stated WW leaves at least UU edges in a central path, with its endpoints on opposite sides of a δ\delta-pair band and all intermediate cuts more than δ\delta from the outer edges. The threshold ensures C>DC>D, the raw gap, and the same conditions after contraction.

Delete that central band of δ\delta pairs and replace each central crossing by the walk shorter by 0\ell_0 supplied by Lemma 26.3. Start a left frontier shifted by δ-\delta pairs, equivalently Δ-\Delta physical columns; its new endpoint is exactly the old endpoint. Reflect this for a right frontier. Every new edge is a valid physical-height transition, and the constant mean drift and bounded range keep its filled-tail configuration interior. Outside the crossings, neighborhood formation commutes with the natural column map because the protected neighborhood is uniformly full or empty, including every nonclean intermediate state. No nonclean inspection is deleted. The mate’s full or empty state is preserved; the removed time is even, and paired-column translation preserves phase. As survivor edges count the following inspection, exactly 0\ell_0 days are removed per cohort. This proves Tm(QPnΔ)Tm(QPn)20.T_m(Q\mathbin{\square}P_{n-\Delta})\le T_m(Q\mathbin{\square}P_n)-2\ell_0. Starting instead from a sufficiently long shorter board, insert the same number of pairs and use the longer endpoint connection to add 0\ell_0 days to each crossing. The same filled-tail, endpoint, and mate arguments prove the reverse inequality, exactly as in Section 26.5. Since 20=2AΔ/D2\ell_0=2A\Delta/D, this proves Theorem 26.4 on every sufficiently long even cylinder, with the displayed effective threshold.

Exact finite interfaces for even-area cylinders

The efficient-frontier arguments yield more than an eventual formula. They identify an exact finite collection of local search problems. The symbolic height theorem then evaluates every connection through the interior directly, leaving a graph of bounded size. Arbitrary intermediate supports are retained inside the boundary problems; a daily pyramid normal form is not assumed.

Theorem 27.1 (An exact finite-interface representation). Let QQ be a fixed finite bipartite graph with a Hamiltonian path, with A2A\ge2 vertices, and fix an integer m>A/2m>A/2. For every positive nn such that AnAn is even, the following construction determines the exact value Tm(QPn)T_m(Q\mathbin{\square}P_n) and an optimal physical strategy.

After an effective finite preprocessing depending only on Q,mQ,m, the value is obtained using OQ,m(1)O_{Q,m}(1) integer arithmetic stages on OQ,m(log(n+1))O_{Q,m}(\log(n+1))-bit integers. Its final graph has boundedly many vertices depending only on Q,mQ,m. Every vertex has at most one proper cohort, which is a physical pyramid; its mate is full or empty. Boundary edges are actual search blocks of bounded duration, retaining arbitrary nonpyramidal behavior in bounded longitudinal slabs. Interior edges have the exact symbolic costs in (78) and admit physical pyramid realizations. The sufficient size threshold and all bounds are explicit below.

The calculation gives a compressed description of an optimal strategy. Expanding it into individual inspections additionally costs its output length. No small bound on the parameter-dependent preprocessing is asserted.

For rectangles this covers every even-area board with both sides at least two, at every feasible budget, by choosing the shorter path as QQ. The one-row case is already solved. Theorem 7.1 covers odd-area rectangles. These are uniform exact algorithms. The hidden dependence on Q,mQ,m, including finite preprocessing and shortest paths, means that they do not meet the absolute O(1)O(1) operation goal for Tk(a,b)T_k(a,b). The closed formulas in earlier sections remain useful explicit evaluations in their stated budget ranges.

This theorem is a geometric strengthening, rather than an asymptotic speed claim over an eventual-period formula with its entire finite prefix precomputed. It specifies the exact local transition problems and a physical strategy reconstruction. The finite preprocessing described here is a mathematical construction, not a claimed implemented generic compiler.

Put α=A/2\alpha=\left\lceil A/2\right\rceil and define K=A2,B=8A2+8m+2A,E=B+2(K+m+1)(B+1),L=E+1,q=(m+α)L,R=100(q+A2+L+A+1),n0=10R.\begin{aligned} K&=A^2,& B&=8A^2+8m+2A,\nonumber\\ E&=B+2(K+m+1)(B+1),& L&=E+1,\nonumber\\ q&=(m+\alpha)L,& R&=100(q+A^2+L+A+1),\qquad n_0=10R. \end{aligned}(157) These constants depend only on A,mA,m. We prove the result for nn0n\ge n_0. Every smaller admissible length is a finite exception, determined by the ordinary exact belief recurrence. The displayed threshold dominates the clipping guards in both parity cases of Section 26, and gives An/2>mLAn/2>mL.

Physical pyramids, including the end boundaries

Index QQ by a Hamiltonian order 0,,A10,\ldots,A-1, so its bipartition is the parity of this index. A downward pyramid is a one-color set PP such that (v,y)P,y>0,uvE(Q)(u,y1)P.(v,y)\in P,\quad y>0,\quad uv\in E(Q) \quad\Longrightarrow\quad (u,y-1)\in P. An upward pyramid is its longitudinal reflection. Empty and full color classes are allowed in either orientation. For current color pp, put sv=(pv)mod2s_v=(p-v)\bmod2. A downward pyramid has a spacing-two prefix in each fiber. If that prefix has kvk_v rooms, its virtual last height is av=sv2+2kv.a_v=s_v-2+2k_v. The predecessor condition is equivalent to 2avn1,avpv(mod2),auav=1(uvE(Q)). -2\le a_v\le n-1,\qquad a_v\equiv p-v\pmod2, \qquad |a_u-a_v|=1\quad(uv\in E(Q)). (158) The values 2,1-2,-1 handle empty fibers. Two predecessor moves give spacing-two closure, and the higher cutoff forces the required adjacent predecessor; this proves both directions, including the bottom row. Along the Hamiltonian path the heights form a ±1\pm1 walk, so their range is at most A1A-1 and there are at most (n+2)2A1(n+2)2^{A-1} downward pyramids of each color. Extra edges of QQ impose additional conditions on these walks.

Neighborhoods preserve this family at the physical ends. Indeed, let (v,y)N(P)(v,y)\in N(P), y>0y>0, and consider its predecessor (u,y1)(u,y-1). A witnessing neighbor (v,y1)P(v,y-1)\in P is already adjacent to that predecessor. A witness (v,y+1)P(v,y+1)\in P supplies (u,y)P(u,y)\in P. A transverse witness (z,y)P(z,y)\in P supplies (v,y1)P(v,y-1)\in P. In all cases the required predecessor belongs to N(P)N(P).

Writing tvt'_v for the largest coordinate below nn of parity 1sv1-s_v, the exact neighborhood cutoff is η(a)v=max(hv,{au:uvE(Q)}),hv={(1sv)2,kv=0,min(av+1,tv),kv>0.\eta(a)_v=\max\bigl(h_v,\{a_u:uv\in E(Q)\}\bigr), \qquad h_v=\begin{cases} (1-s_v)-2,&k_v=0,\\ \min(a_v+1,t'_v),&k_v>0. \end{cases} In particular η(a)vav+1\eta(a)_v\le a_v+1. The simpler formula av+1a_v+1 alone need not be exact in an empty bottom fiber. A perfect matching of the cylinder is supplied by transverse Hamiltonian pairs when AA is even, or by longitudinal column pairs when AA is odd and nn is even. Thus every support SS satisfies N(S)S|N(S)|\ge|S|. The two fiber parity sums differ by at most one, giving 0N(P)Pα,PNr(P)P+αr. 0\le |N(P)|-|P|\le\alpha, \qquad |P|\le |N^r(P)|\le |P|+\alpha r. (159) Every Nr(P)N^r(P) has the same pyramid orientation.

A pyramid with at most uu rooms lies within 2u+A+22u+A+2 columns of its filled end. Its complement in its color class is an oppositely oriented pyramid, so the same bound locates a deficit of at most uu near the unfilled end. Finally, Lemma 12.2 bounds a pyramid with an empty physical fiber by HQA2H_Q\le A^2 rooms. The height range also confines it to an end band of width at most AA.

Canonical checkpoints of bounded separation

Call a full-board belief canonical if at most one cohort is nonempty and nonfull, that proper cohort is a pyramid, and its mate is full or empty. Initial full/full and final empty/empty beliefs are canonical.

The clean-day arguments already proved in Section 26 give the following interface. For even A=2bA=2b, the potential loss is at most mbm-b per day; every efficient owner survivor has surplus bb and is a physical pyramid by Lemma 26.2 and (144). For odd A=2b+1A=2b+1 and even nn, the history-bit potential has daily bound 2mA2m-A. Its two efficient cases are exactly (152). Surplus bb gives a pyramid by Lemma 26.5; surplus b+1b+1 also gives a pyramid by the actual containment hypothesis in Lemma 26.6. Thus both efficient phases have the physical height condition (158) on every QQ-edge.

The BB in (157) dominates the slack bound in both cases. At most BB days are inefficient, and there are at most 2(B+1)2(B+1) efficient owner blocks. Mark their first K+m+1K+m+1 days and all inefficient days. There are at most EE marked days. The proved untouched-cohort growth argument makes the mate literally full or empty on every remaining clean day, rather than merely placing it in a flat potential collar. Its source is the neighborhood of a preceding efficient pyramid, so both its source and successor are canonical.

Partition an optimal physical strategy at the sources of its clean days, also including the initial and terminal states. Following the last successful inspection by the empty movement step does not add a day. Every resulting block has duration at most E+1=LE+1=L: except for its possible first clean day, all intervening days are marked. If there are no clean days, the whole strategy has duration at most EE.

Consequently some optimum is a path of physical blocks of length at most LL between canonical states. Conversely every such concatenation is an actual strategy. No history bit is needed in its state: the bit establishes the existence of checkpoints in an optimum, whereas edge legality is checked on the physical supports themselves.

Localizing a physical transition

Lemma 27.2 (Exact endpoint localization). Suppose an rr-day block, rLr\le L, takes a one-cohort pyramid P0P_0 to a pyramid P1P_1, possibly of the opposite orientation. Set P2=Nr(P0)P_2=N^r(P_0) and D=P2P1D=P_2\setminus P_1. Then P1P2P_1\subseteq P_2 and D(m+α)r|D|\le(m+\alpha)r. Removing every inspection whose longitudinal distance from DD exceeds rr preserves the final support exactly. Moreover DD lies in an interval of at most 2(m+α)r+2A2+4A+42(m+\alpha)r+2A^2+4A+4 longitudinal columns.

Proof. The matching gives P1P0mr|P_1|\ge|P_0|-mr, while (159) bounds P2|P_2|, proving the cardinality claim. Removing inspections enlarges the final support. Any newly surviving walk must finish in DD, since its endpoint is freely reachable but not in P1P_1. Every earlier point of its rr-step walk is within longitudinal distance rr of DD. All original inspections that could hit it were retained, a contradiction. The endpoint is therefore unchanged.

For equal orientations, compare the two included height vectors of P1P2P_1\subseteq P_2. Each fiber’s cutoff difference is twice its contribution to D|D|, and the individual height ranges are at most A1A-1. This confines DD to at most 2D+2A+22|D|+2A+2 columns.

Suppose P2P_2 is downward and P1P_1 upward. If every fiber of P1P_1 is nonempty, it contains the topmost room of its color in each fiber, forcing P2P_2 to be full. Its difference DD is then the downward complement of P1P_1, of size at most (m+α)r(m+\alpha)r. Otherwise P1A2|P_1|\le A^2, whence P2A2+(m+α)r|P_2|\le A^2+(m+\alpha)r; this downward pyramid lies in the corresponding bounded initial band. Reflection handles the other case. Empty and full sets may be assigned either orientation. The stated bound covers all cases. ◻

Apply the lemma separately to the two initial-color cohorts. Their current colors are disjoint on every day, so the retained inspections still respect the shared daily quota. The lemma concerns actual avoiding walks, with no condition on intermediate support shapes.

It also gives an effective finite test for an edge. If II is the difference band, all shots lie in its rr-enlargement; only endpoints in its 2r2r-enlargement can be affected. Every rr-step walk to such an endpoint remains in the 3r3r-enlargement. Enumerate the daily shot sets there, simulate from the restricted initial support in the largest band, and compare final membership on the middle band. Outside that checked band the uninspected baseline already agrees with P1P_1. First reject an endpoint unless P1Nr(P0)P_1\subseteq N^r(P_0), an exact cutoff comparison. This proves an exact physical edge test, including the presence as well as absence of endpoint rooms.

Only one longitudinal coordinate remains

If the same cohort is proper at both ends with the same orientation, its cardinality changes between mr-mr and αr\alpha r. Height ranges are at most A1A-1, and the parity-sum correction is at most one. The two cutoff positions consequently differ by at most 2(m+α)r+4A+6<R2(m+\alpha)r+4A+6<R. Away from the board ends the localized block depends only on relative height shapes, bounded displacement, color, and duration. Translation by two columns preserves its complete physical test.

Every other possibility is confined to end collars. A proper cohort becoming empty has initial size at most mrmr; one becoming full has initial deficit at most αr\alpha r. A full cohort becoming proper has final deficit at most mrmr, while an empty cohort cannot become proper. For an orientation change, the two cases in Lemma 27.2 show either that both endpoint deficits are at most (m+α)r(m+\alpha)r, or that both sizes are at most A2+(m+α)rA^2+(m+\alpha)r. All their cutoffs are therefore in bounded end collars. A full mate ending full needs no inspections by the same localization lemma; a full mate cannot become empty in rLr\le L days because An/2>mLAn/2>mL.

An interior state is encoded by its physical color, orientation, mate status, a relative height walk, and z=(a0p)/2.z=(a_0-p)/2. For upward pyramids use the physical cutoff of their downward complement, so both orientations use the same longitudinal coordinate. Filter the Hamiltonian height walks by the additional QQ-edge conditions. This gives OA(n)O_A(n) canonical states. The preceding bounds give finitely many interior edge types of bounded displacement and finitely many boundary edge types. Opposite-end gadgets are tested together with the shared daily quota; for n10Rn\ge10R their movement cones cannot communicate within LL days. Their only dependence on length is the checkerboard parity at the far end.

Let Cn\mathcal C_n contain these states and all physical edges of duration 1,,L1,\ldots,L. It has OQ,m(n)O_{Q,m}(n) edges. Its shortest-path value from full/full to empty/empty is exactly TmT_m: an optimum supplies a path by the checkpoint argument, and every graph path expands to an actual strategy. Nonpyramidal intermediate supports are kept inside the finite edge tests, rather than projected away.

Finite ports and exact symbolic interior costs

Use the common homogeneous counter interval Rz(n22R)/2.R\le z\le\left\lfloor(n-2-2R)/2\right\rfloor. The first RR and last RR levels are called ports. Keep every vertex outside this interval, every port vertex, and all original boundary edges between retained vertices. There are only boundedly many of them depending on Q,mQ,m. The strict displacement bound <R<R ensures that an edge crossing between the interior and a boundary family meets a port. Retain the original edges joining the two remote boundary families, with their shared-quota tests; their legality depends only on the longitudinal parity once nn0n\ge n_0.

The proper cohort, its orientation, and its full or empty mate cannot change on an interior stretch: all such changes were confined to end collars above. Call these fixed data its sector. Endpoint physical colors may differ, and give the required duration parity. For every ordered pair of ports in the same sector, add a direct edge of weight t0t_0 from (78), using the proper cohort’s height vectors. Reflect longitudinal coordinates for an upward sector. The same construction includes connections returning to the same end.

We verify both directions of this replacement. Every original interior edge has duration rLr\le L. The large collar in (157) implies the height margins in (76), and its initial proper support has more than CA+mrC_A+mr rooms. Indeed its cutoff position is at least 2RA2R-A from its filled end, while R>100(mL+A2+L+A)R>100(mL+A^2+L+A). Theorem 13.3 therefore bounds that edge against arbitrary intermediate supports by zvav+r,vavvzv+Ar2mr.z_v\le a_v+r,\qquad \sum_v a_v-\sum_v z_v+Ar\le2mr. If its mate is full at both ends, omitting every mate inspection preserves that endpoint; an empty mate remains empty. Thus assigning the proper cohort the entire budget gives the relevant comparison. Summing these inequalities along any interior path makes the height sums telescope and gives exactly the criterion in (78). Its duration is at least t0t_0. This lower bound applies the guarded theorem to each bounded edge, never to a long block with an unjustified Pmt>CA|P|-mt>C_A guard.

Conversely, port cutoffs are far enough from both physical ends that (77) holds. Proposition 13.4 realizes the direct edge in exactly t0t_0 days, allocating at most mm inspections to the proper cohort and none to its full or empty mate. For t0=0t_0=0 the endpoints coincide. The realized block need not stay in the auxiliary counter interval: it stays within the actual physical board, which is the condition needed for an upper strategy.

Take an optimal path in Cn\mathcal C_n and split it at visits to the retained boundary families. Every omitted stretch has port endpoints in one sector. Replacing it by the corresponding direct edge cannot increase its cost. Conversely, every edge of the new graph is an actual physical block, so every new graph path is a valid strategy. The new finite graph therefore has exactly the same optimal value TmT_m. This argument allows arbitrary reverse travel, repeated visits to the same boundary, opposite-end gadgets, and owner changes within the retained boundary graph; it assumes neither two pure sweeps nor monotone excursions.

Port heights are affine functions of nn, with the end parity fixed. Their edge weights require maxima, one integer ceiling, and one parity adjustment. One fixed-size shortest-path closure consequently evaluates all paths using OQ,m(1)O_{Q,m}(1) integer arithmetic stages after finite preprocessing. The finitely many smaller lengths n<n0n<n_0 remain in that preprocessing, rather than being discarded by an asymptotic claim. Integer bit lengths are OQ,m(log(n+1))O_{Q,m}(\log(n+1)).

Store a shortest path after removing cycles. It has boundedly many edges. Each boundary edge stores its finite local inspections. Each interior edge stores its endpoints, duration, the balanced quota rule in Proposition 13.4, and the legal height-descent rule. This gives a bounded-size description of an optimal physical strategy; expanding its individual inspections costs the output length. The construction does not claim that all parameter-dependent boundary tables have been implemented. Its strengthening is the exact symbolic elimination of the interior transition problems, preserving all physical boundary and shared-quota effects. This completes the proof of Theorem 27.1.

The inverse rectangle tradeoff at a fixed deadline

The preceding reductions retain geometric information about the current belief. A different choice of state removes every parity restriction: fix the number of inspection days, and retain the history of each column. The resulting matrix is independent of the longitudinal length. It gives an exact recurrence and an eventual formula for the inverse tradeoff.

For rectangles, define Kt(a,b)=min{k:Tk(a,b)t}K_t(a,b)=\min\{k:T_k(a,b)\le t\}. This is the inverse of the same constant-budget capture relation, so its rectangle consequences remain inside the main scope. For fixed a,ta,t, the theorem below with Q=PaQ=P_a gives Kt(a,n)=an/t+cnmodpK_t(a,n)=an/t+c_{n\bmod p} eventually, together with effective finite exceptions. The period, coefficients and exception table require parameter-dependent computation; this does not meet the absolute O(1)O(1) numerical goal when all three parameters vary. The proof uses daily cost vectors as a tool, not as a new varying-budget research objective.

Let QQ be any nonempty finite simple graph, put A=V(Q)A=|V(Q)|, and let bT(n)b_T(n) be the minimum daily budget guaranteeing capture within TT days on QPnQ\mathbin{\square}P_n, where n2n\ge2 and T1T\ge1.

Theorem 28.1. For fixed Q,TQ,T, there are effectively computable integers n0,p>0n_0,p>0 and rational constants c0,,cp1c_0,\ldots,c_{p-1} such that bT(n)=AnT+cnmodp(nn0).b_T(n)=\frac{An}{T}+c_{n\bmod p}\qquad(n\ge n_0). The period can be chosen divisible by T/gcd(A,T)T/\gcd(A,T). The finitely many remaining values, and a winning strategy at any specified length, are also effectively computable. No bipartiteness assumption on QQ is needed.

Here “effectively computable” asserts a terminating finite procedure, not a small uniform complexity bound. The state space below has 22A(T1)2^{2A(T-1)} states. In particular, this theorem does not supply a fixed matrix when the deadline itself grows with the box length.

Exact local certificates

The case T=1T=1 is b1(n)=Anb_1(n)=An. Assume T2T\ge2, and use the finite alphabet W=(2V(Q))T1\mathcal W=(2^{V(Q)})^{T-1}. A letter b=(b1,,bT1)b=(b_1,\ldots,b_{T-1}) records proposed survivor sets in one column. Put bT=b_T=\varnothing, and let 00 denote the all-empty letter. For a,b,cWa,b,c\in\mathcal W define w1(a,b,c)=Ab1,wt(a,b,c)=(NQ(bt1)at1ct1)bt(2tT).\begin{aligned} w_1(a,b,c)&=A-|b_1|,\\ w_t(a,b,c)&=\bigl|(N_Q(b_{t-1})\cup a_{t-1}\cup c_{t-1}) \setminus b_t\bigr|\quad(2\le t\le T). \nonumber \end{aligned}(160) A word b1bnb^1\cdots b^n, with boundary letters b0=bn+1=0b^0=b^{n+1}=0, has day-tt cost j=1nwt(bj1,bj,bj+1)\sum_{j=1}^n w_t(b^{j-1},b^j,b^{j+1}).

Lemma 28.2. A successful TT-day strategy with respective daily capacities m1,,mTm_1,\ldots,m_T exists if and only if such a word has day-tt cost at most mtm_t for every tt.

Proof. Let RtR_t be the union of the word’s day-tt column sets, with RT=R_T=\varnothing. Define nominal beliefs B1=V(QPn)B_1=V(Q\mathbin{\square}P_n) and Bt=N(Rt1)B_t=N(R_{t-1}) for t2t\ge2, and inspect St=BtRtS_t=B_t\setminus R_t. The product-neighborhood identity shows that St|S_t| is exactly the local cost sum in (160).

The actual belief UtU_t satisfies UtBtU_t\subseteq B_t inductively: its survivors are contained in RtR_t, so their neighborhood is contained in Bt+1B_{t+1}. On day TT, the empty survivor envelope makes ST=BTS_T=B_T cover every possibility. This argument intentionally does not require RtBtR_t\subseteq B_t; extra envelope vertices do not compromise soundness.

Conversely, take the actual survivors of a successful strategy, discard inspections outside the actual belief, and extend an earlier capture by empty inspections and survivors. Its column sections form a word whose costs are exactly the useful inspection counts. ◻

Use pairs (a,b)W2(a,b)\in\mathcal W^2 as matrix states. The transition (a,b)(b,c)(a,b)\to(b,c) has monomial weight t=1Txtwt(a,b,c)\prod_{t=1}^T x_t^{w_t(a,b,c)}. Let M(x)M(\mathbf x) be this matrix; let uu indicate states (0,b)(0,b) and vv indicate states (b,0)(b,0). There is exactly one nn-edge walk for each nn-column word, so Fn(x)=uTM(x)nvF_n(\mathbf x)=u^{\mathsf T}M(\mathbf x)^n v has a positive coefficient at xc\mathbf x^{\mathbf c} precisely when a certificate with exact cost vector c\mathbf c exists. Thus n0Fn(x)zn=uT(IzM(x))1v\sum_{n\ge0}F_n(\mathbf x)z^n =u^{\mathsf T}(I-zM(\mathbf x))^{-1}v is a rational formal series encoding the exact daily-budget tradeoff. All coefficients are nonnegative; multiplicities of envelopes do not affect the existential criterion.

For a direct algorithm, retain the accumulated cost vector and discard it if any coordinate exceeds the proposed budget mm. This uses at most O(nW3(m+1)T)O(n|\mathcal W|^3(m+1)^T) transitions. Since an optimum never needs m>Anm>An, searching budgets remains polynomial in nn for fixed Q,TQ,T. Backtracking recovers the word and the physical inspections in the lemma.

Why the optimum has an eventual formula

A subset of Nr\mathbb N^r is linear if it is a translate of a finitely generated additive monoid, and semilinear if it is a finite union of linear sets. Add a length coordinate one to each edge weight. The attainable vectors (n,c1,,cT)(n,c_1,\ldots,c_T) form an effectively semilinear set LL. To see this directly, eliminate the finite automaton’s states to obtain a regular expression. Its additive image is computed using union, Minkowski sum and additive closure, all of which preserve semilinearity. For the only less immediate operation, if S=i(bi+monoid(Pi))S=\bigcup_i(b_i+\operatorname{monoid}(P_i)), then S=I(iIbi+monoid({bi:iI}iIPi)).S^*=\bigcup_I\left(\sum_{i\in I}b_i+ \operatorname{monoid}\left(\{b_i:i\in I\}\cup \bigcup_{i\in I}P_i\right)\right). Here II ranges over subsets of component indices. Reserve one base for each used component; extra bases account for repeated occurrences, and all periods can be assigned to the reserved occurrence. The empty II supplies zero. This proves both containments and effectivity.

By the effective equivalence of semilinear and Presburger-definable sets (Ginsburg and Spanier 1966, Theorems 1.1 and 1.3), the relation E(n,m)n2 and c((n,c)L and ctm for all t)E(n,m)\quad\Longleftrightarrow\quad n\ge2\ \text{and}\ \exists\mathbf c\, ((n,\mathbf c)\in L\ \text{and}\ c_t\le m\ \text{for all }t) is effectively Presburger-definable. The same holds for E(n,m)(m=0 or ¬E(n,m1))E(n,m)\wedge(m=0\ \text{or}\ \neg E(n,m-1)), which is the graph of bTb_T. Convert that graph to a finite union of linear sets.

Every infinite linear component of a function’s graph lies on a rational affine line. Indeed, a nonzero period cannot have zero first coordinate. For two periods (ai,di),(aj,dj)(a_i,d_i),(a_j,d_j) with positive first coordinates, using them aja_j and aia_i times gives the same input, so uniqueness of the output forces ajdi=aidja_jd_i=a_id_j. All periods therefore have one slope. The component’s input projection is a translated numerical semigroup; it eventually contains exactly one residue class modulo the gcd of its positive generators. A threshold is computable by shortest paths among residues modulo any generator. Taking a common multiple of the finitely many periods and a maximum of their thresholds gives an affine formula on each eventual residue class. Finite components contribute only finitely many exceptions.

It remains to identify the slopes. The longitudinal matching between columns (1,2),(3,4),(1,2),(3,4),\ldots supplies 2An/22A\left\lfloor n/2\right\rfloor alternating target trajectories, pairwise disjoint on every inspection day. A probe intercepts at most one of these trajectories on that day. Consequently TbT(n)2An/2A(n1).T b_T(n)\ge2A\left\lfloor n/2\right\rfloor\ge A(n-1). For the upper bound put q=n/Tq=\left\lceil n/T\right\rceil. When the possible rooms lie in a suffix beginning at column LL, inspect its first q+1q+1 columns, clipped to the board. After movement the suffix begins at least at L+qL+q. After T1T-1 days at most n(T1)qqn-(T-1)q\le q columns remain; inspect all of them on the final day. Thus bT(n)A(n/T+1)<An/T+2A.b_T(n)\le A(\left\lceil n/T\right\rceil+1)<An/T+2A. Internal QQ-edges never change the column index. The two bounds force every infinite affine component to have slope A/TA/T. Enlarging the period by T/gcd(A,T)T/\gcd(A,T) if necessary proves Theorem 28.1, including its effective exception table and integral additive increment.

The survivor-envelope equivalence and the exact product-fiber cost sum are verified in Lean by SurvivorEnvelope. The matrix and semilinearity arguments above are ordinary proofs. The reference transfer implementation was compared with the independently proved path and two-row formulas in 56 cases, with physical replay of its recovered inspection sets. Neither these finite comparisons nor the formal semantic lemma are being substituted for the general periodicity proof.

Geometric memory and bounds at intermediate budgets

Exact backward frontiers with three or nine thresholds

The necessary models above need not be evaluated by listing their size states. Their entire backward reachable sets have the following finite dimensional descriptions. These are exact statements about the models; physical realization and evaluation without iteration remain separate.

Write R(x)=xR(x)=\left\lceil\sqrt{x}\right\rceil and ρ(x)=(1+4x1)/2\rho(x)=\left\lceil(\sqrt{1+4x}-1)/2\right\rceil for x0x\ge0. For the corner capacities Fij,GijF_{ij},G_{ij} in (49) and (60), let Sij(t)S_{ij}(t) be the least surplus with ts+Fij(s)t\le s+F_{ij}(s), and Hij(d)H_{ij}(d) the least surplus with dGij(s)d\le G_{ij}(s). Their explicit values are Sij(t)={i+2j2+max(2,R((t2i4j+4)+)),j>0,i1+max(1,ρ((t2i+2)+)),j=0<i,min(ρ(2t),ρ(t)+1),i=j=0<t,0,i=j=t=0.S_{ij}(t)=\begin{cases} i+2j-2+\max(2,R(\left(t-2i-4j+4\right)_+)),&j>0,\\ i-1+\max(1,\rho(\left(t-2i+2\right)_+)),&j=0<i,\\ \min(\rho(2t),\rho(t)+1),&i=j=0<t,\\ 0,&i=j=t=0. \end{cases} Put A=2iA=2-i, B=2jB=2-j. Then Hij(d)={A+B+max(0,R((dB+1)+)1),B>0,A+ρ(d),B=0<A,min(ρ(2d)+1,1+R(d+1)),A=B=0<d,0,A=B=d=0.H_{ij}(d)=\begin{cases} A+B+\max(0,R(\left(d-B+1\right)_+)-1),&B>0,\\ A+\rho(d),&B=0<A,\\ \min(\rho(2d)+1,1+R(d+1)),&A=B=0<d,\\ 0,&A=B=d=0. \end{cases} These formulas include the mandatory corner domains of their quadratics.

Theorem 29.1 (Three-threshold frontier). Let wnw\le n, wnwn even, w2w\ge2, h=wn/2h=wn/2, r=w/2r=\left\lfloor w/2\right\rfloor, and kr+1k\ge r+1. Use the corner model of Theorem 11.20, optionally with its critical refinement. Its states capturable within tt days are exactly {(a,c):camin(h2+c,Bt(c))},c=0,1,2.\{(a,c):c\le a\le \min(h-2+c,B_t(c))\},\qquad c=0,1,2. Initialize B0=(0,1,1)B_0=(0,-1,-1). For a valid positive target size zz of corner class jj, set sij(z)=min(Sij(z),Hij(hz),κij),qij(z)=min(h2+i,zsij(z)).s_{ij}(z)=\min(S_{ij}(z),H_{ij}(h-z),\kappa_{ij}),\qquad q_{ij}(z)=\min(h-2+i,z-s_{ij}(z)). Set Qij(z)=qij(z)Q_{ij}(z)=q_{ij}(z) when qij(z)max(1,i)q_{ij}(z)\ge\max(1,i), and zero otherwise; also set it to zero if z<max(1,j)z<\max(1,j). In the original model κij=r\kappa_{ij}=r. In the refined model it is r+1r+1, except that it equals rr for (i,j)=(1,1)(i,j)=(1,1) when a side equals 2r2r, or (i,j)=(2,0)(i,j)=(2,0) when a side equals 2r+12r+1. Then Bt+1(c)=min(h2+c,k+maxic, 0j2Qij(Bt(j))). B_{t+1}(c)=\min\left(h-2+c, k+\max_{i\le c,\ 0\le j\le2}Q_{ij}(B_t(j))\right). (161)

Proof. For a fixed target and corner pair, admitted positive survivor sizes form the interval [max(1,i),Qij(z)][\max(1,i),Q_{ij}(z)]. Increasing surplus weakens each component inequality, and their union with the unrestricted range is the interval starting at sij(z)s_{ij}(z). The static size profile is redundant: both component capacities are bounded by s2s^2, and the unrestricted surplus is at least rr.

Moreover Qij(z)Q_{ij}(z) is nondecreasing in zz. The inverse SijS_{ij} increases by at most one at each integer increment, since s+Fij(s)s+F_{ij}(s) increases by at least one. The inverse Hij(hz)H_{ij}(h-z) is nonincreasing. Thus zSij(z)z-S_{ij}(z), zHij(hz)z-H_{ij}(h-z) and zκijz-\kappa_{ij} are nondecreasing. Taking their maximum and imposing the state cap and minimum positive survivor size preserves this property.

Induct on tt. A nonterminal first day leaves at most Qij(Bt(j))Q_{ij}(B_t(j)) rooms, proving necessity of (161). Conversely choose indices attaining a positive maximum QQ. Let =ci2k\ell=c-i\le2\le k. For any valid source size k<aBt+1(c)k<a\le B_{t+1}(c) take q=min(Q,a),p=aq.q=\min(Q,a-\ell),\qquad p=a-q. Then qmax(1,i)q\ge\max(1,i) and pk\ell\le p\le k. The fixed-target interval therefore supplies the transition to Bt(j)B_t(j). The survivor cap is consistent with all these sources because (h2+c)=h2+i(h-2+c)-\ell=h-2+i. Sources of size at most kk clear directly. This proves the entire interval assertion, including its model converse. ◻

The same proof works with the initial set consisting of all states of size at most a prescribed vv, initialized by B0(c)=min(v,h2+c)B_0(c)=\min(v,h-2+c), or 1-1 if this is below cc. It then describes reaching that set in at most tt moves. In particular v=k/2v=\left\lfloor k/2\right\rfloor tests the residual relevant to the central inspection. The graph audit in compares all state/deadline memberships in 232 cases, with 622731 agreements against an independent pre-existing graph implementation.

Theorem 29.2 (Nine-threshold erosion frontier). Let w=2b+15w=2b+1\ge5, nwn\ge w even, h=wn/2h=wn/2, and 1k<h1\le k<h. Use the weakened erosion model of Theorem 11.25, with maximal survivor retention and the all-radius bands of Theorem 29.3, but without triangle or near-square history flags. In each feature class (c,e)(c,e) its positive states capturable within tt days form the interval 1aBt(c,e)1\le a\le B_t(c,e). The nine thresholds have a fixed-size update described below.

For completeness the update can be written using elementary roots. Let Am(x)A_m(x) be zero for x0x\le0 and otherwise (m2+4xm)/2\left\lceil(\sqrt{m^2+4x}-m)/2\right\rceil; let Q(x)Q(x) be zero for x0x\le0 and otherwise (1+1+4x)/2\left\lceil(1+\sqrt{1+4x})/2\right\rceil. The least closed surplus with zσ+P(v,u,j;σ)z\le\sigma+P(v,u,j;\sigma) is L(z;v,u,j)={v+2j+A4(z2v3ju),u>0,v+2j+A3(z2v3j),u=0<v,2j+min(A5(2z6j),A2(z3j+2)),u=v=0<j,min(A1(2z),Q(z)),u=v=j=0.L(z;v,u,j)=\begin{cases} v+2j+A_4(z-2v-3j-u),&u>0,\\ v+2j+A_3(z-2v-3j),&u=0<v,\\ 2j+\min(A_5(2z-6j),A_2(z-3j+2)),&u=v=0<j,\\ \min(A_1(2z),Q(z)),&u=v=j=0. \end{cases} The least surplus with dFAB(σ)d\le F_{AB}(\sigma) is K(d;A,B)={A+2B2+max(2,Q(dA2B+2)),B>0,A1+max(1,R((dA+1)+)),B=0<A,min(Q(2d),1+R(d+1)),A=B=0<d,0,A=B=d=0.K(d;A,B)=\begin{cases} A+2B-2+\max(2,Q(d-A-2B+2)),&B>0,\\ A-1+\max(1,R(\left(d-A+1\right)_+)),&B=0<A,\\ \min(Q(2d),1+R(d+1)),&A=B=0<d,\\ 0,&A=B=d=0. \end{cases} Fix target (z,j,v)(z,j,v) and survivor corner counts (i,u)(i,u), and put δ=vi\delta=v-i, d=hzd=h-z. Set θ=min{L(z;v,u,j),K(d;2j,2v),b+1},\theta=\min\{L(z;v,u,j),K(d;2-j,2-v),b+1\}, also including bb in this minimum when (v,j)=(2,0)(v,j)=(2,0). If j=2j=2, 2r=Q(d)b2\le r=Q(d)\le b, Dr<dr(r1)D_r<d\le r(r-1), and (i,u,v)(1,2,1)(i,u,v)\ne(1,2,1), put λ=r+1δ\lambda=r+1-\delta; otherwise put λ=0\lambda=0. Here Dr=max(r(r1)/2,r(r2))D_r=\max(r(r-1)/2,r(r-2)). Define, for z>0z>0, Wiujv(z)=max{0,zδmax(θ,λ,zδ(h4+i+u),0)},W_{iujv}(z)=\max\{0,z-\delta- \max(\theta,\lambda,z-\delta-(h-4+i+u),0)\}, and Wiujv(0)=0W_{iujv}(0)=0. Initialize all nine thresholds at zero and update by Bt+1(c,e)=min{h4+c+e, k+maxWiujv(Bt(j,v))}. B_{t+1}(c,e)=\min\{h-4+c+e,\ k+\max W_{iujv}(B_t(j,v))\}. (162) The maximum is over the fixed set of indices satisfying ic,ue,uj,iv,imax(0,c+v2),ci+euk.i\le c,\quad u\le e,\quad u\le j,\quad i\le v,\quad i\ge\max(0,c+v-2),\quad c-i+e-u\le k. All corner and erosion counts range from zero to two.

Proof. Substituting the shifted variable in the four quadratic branches of PP and FF gives LL and KK. For a fixed target, closed surplus is σ=zqδ\sigma=z-q-\delta; thus admitted positive survivors form precisely the interval 1qWiujv(z)1\le q\le W_{iujv}(z). The band restriction is the additional lower bound σλ\sigma\ge\lambda. Smaller original surpluses were already excluded by the component capacities.

The upper endpoint WW is nondecreasing with target size. Away from band entrances this follows from the same inverse monotonicity as in Theorem 29.1. At an entrance the preceding hole size is r(r1)+1r(r-1)+1. Original surplus at most rr was already impossible there: its high capacity is at most r(r1)r(r-1), while its small branch, with outgoing corner count two, would have target size at most r2<hr(r1)1r^2<h-r(r-1)-1. The critical exception has outgoing count zero. Hence the extra constraint causes no downward jump. Band exits only remove a constraint, and the bands are disjoint.

Induct on the horizon. Necessity of (162) follows by taking the largest admitted target in its feature class. For sufficiency choose a positive maximum WW, let =ci+euk\ell=c-i+e-u\le k, and choose q=min(W,a)q=\min(W,a-\ell), p=aqp=a-q for any k<aBt+1(c,e)k<a\le B_{t+1}(c,e). Then qak1q\ge a-k\ge1 and pk\ell\le p\le k. The state cap is compatible because (h4+c+e)=h4+i+u(h-4+c+e)-\ell=h-4+i+u. The initial-interval property supplies the required edge. The positive lower-cardinality constraints were explicitly removed from this merger model, so none is being assumed in this reconstruction. Terminal states clear directly. ◻

Each update above uses an absolute bounded number of standard numerical operations. Iterating to the first full-state threshold is still a recurrence, not the required fixed-size expression for physical capture time. The nine-threshold theorem deliberately excludes the stronger history flag below: its interval property has not been asserted for that flagged model. The independent all-state graph comparisons are retained in .

All pronic radii and an observed outgoing corner

The localization constraints admit two uniform improvements. The first uses every subcritical radius and the corner information already present in an erosion. The second prevents a strict near-square localization from being followed immediately by another closed near-square event. Both retain the merger needed for a shared-budget lower bound. Throughout this subsection let w=2b+15,nw be even,h=wn/2,w=2b+1\ge5,\qquad n\ge w\text{ be even},\qquad h=wn/2, so that h>2b2h>2b^2. Keep the corner counts c,ec,e of Section 11.4.

Theorem 29.3 (Pronic localization at every radius). For 2rb2\le r\le b, put Ar=(r1)(r2),Cr=r(r1),Dr=max{r(r1)/2,r(r2)}.A_r=(r-1)(r-2),\qquad C_r=r(r-1),\qquad D_r=\max\{r(r-1)/2,r(r-2)\}. Let UU satisfy c(U)=0c(U)=0, UCr|U|\le C_r, and N(U)Ur|N(U)|-|U|\le r. Suppose either U>Dr,orc(N(U))=1  and  U>Ar.|U|>D_r, \qquad\text{or}\qquad c(N(U))=1\ \text{ and }\ |U|>A_r. Then UU is connected under sharing a neighbor, its surplus is exactly rr, and N(U)N(U) contains exactly one corner oo. Every room of UU has Manhattan distance at most 2r32r-3 from oo.

Proof. For each nonempty sharing-neighbor component UlU_l, the finite corner-count dichotomy and its odd-width critical extension apply. The critical exception requires a current corner and is unavailable. The large branch is impossible because hUlslhr2>r2Ψ0,j(sl).h-|U_l|-s_l\ge h-r^2>r^2\ge\Psi_{0,j}(s_l). Thus Ulsl(sl1)|U_l|\le s_l(s_l-1) and sl2s_l\ge2. Distinct components have disjoint neighborhoods. If there are at least two, convex allocation of their surpluses gives U(r2)(r3)+2ArDr(r4).|U|\le(r-2)(r-3)+2\le A_r\le D_r\qquad(r\ge4). For r=2,3r=2,3, two components already require too much surplus. Hence UU is connected. Surplus at most r1r-1 would imply UAr|U|\le A_r, also impossible. If the outgoing count is not supplied by the hypothesis, the inequalities Φ0,0(r)=Dr\Phi_{0,0}(r)=D_r and Φ0,2(r)Dr\Phi_{0,2}(r)\le D_r force it to equal one.

When r<br<b, the small side of Theorem 11.1 gives genuine corner quadrants. When r=br=b, the same separator argument as in Theorem 11.14 applies: its alternative with no adjacent unmarked columns and no current corner has outgoing count zero, and is excluded. Connectedness therefore places UU in the quadrant based at its unique outgoing corner oo. Its occupied odd diagonals are 1,3,,2L11,3,\ldots,2L-1 without gaps. Their disjoint upper shadows each contribute at least one extra room, and oo contributes one more. Thus N(U)U+L+1|N(U)|\ge|U|+L+1 and Lr1L\le r-1, proving the radius bound for the original support. ◻

Corollary 29.4 (Dual intervals and mixed-radius exclusion). Let B=N(S)B=N(S), put d=hBd=h-|B|, and suppose c(B)=2c(B)=2, dCrd\le C_r, and BSr|B|-|S|\le r for some 2rb2\le r\le b. If d>Drd>D_r, or if e(B)=1e(B)=1 and d>Ard>A_r, then BS=r,(c(S),e(S),e(B))=(1,2,1).|B|-|S|=r,\qquad (c(S),e(S),e(B))=(1,2,1). Two consecutive inspection transitions cannot both satisfy such an interval condition, even with different radii.

Proof. For U=VoppBU=V_{\mathrm{opp}}\setminus B, N(U)VsrcSN(U)\subseteq V_{\mathrm{src}}\setminus S, and c(N(U))=2e(B)c(N(U))=2-e(B). The theorem applies and forces surplus exactly rr. Equality follows in the complementary inclusion, so N(U)=VsrcSN(U)=V_{\mathrm{src}}\setminus S and c(S)=1c(S)=1. The second neighborhood of UU lies within radius 2r12r-1 of its corner. Both opposite-colored corners are at distance at least n12b+1n-1\ge2b+1, so their neighbor pairs lie in SS and e(S)=2e(S)=2. Also E(B)=SE(B)=S, hence e(B)=1e(B)=1. After one such transition the erosion count is one; deletion cannot increase it to the two required by another. ◻

Corollary 29.5 (All the dual intervals preserve the merger). The guarded merger of Theorem 11.25 remains valid when all rules of Corollary 29.4 are imposed simultaneously.

Proof. Repeat the identity argument of Corollary 11.27 at radius rr. A triggering merged target has J=2J=2, so both component outgoing counts are two. Their holes sum to dCrd\le C_r. A small closed component would have target at most σl2r2\sigma_l^2\le r^2 and holes at least hr2>Crh-r^2>C_r; the critical exception has outgoing count zero. Both components are therefore high, with dlΦ0,2vl(σl)sl(sl1).d_l\le\Phi_{0,2-v_l}(\sigma_l)\le s_l(s_l-1). If both original surpluses are positive, their sum at most rr gives d1+d2(r1)(r2)=Ard_1+d_2\le(r-1)(r-2)=A_r. This contradicts either interval trigger. The remaining component is original-full-to-full at cost zero. The merger is the identity on the constrained component, transferring its original surplus and all three features. This holds for every rr. ◻

A forbidden successor of near-square localization

Write Qr(o)\mathcal Q_r(o) for the r2r^2-room corner triangle consisting of relative diagonals 0,2,,2r20,2,\ldots,2r-2 about oo. For successive hole sets U,VU,V of one cohort and useful inspection set II, one always has N(V)UI,UN(V)U+IN(V).N(V)\subseteq U\cup I,\qquad |U\setminus N(V)|\le |U|+|I|-|N(V)|. This simple inclusion retains the cost of changing corner locations.

Lemma 29.6 (Opposite corner triangles leave a large remainder). Suppose UQr(oU)U\subseteq\mathcal Q_r(o_U) and VQs(oV)V\subseteq\mathcal Q_s(o_V) have opposite colors, where 2r,sb2\le r,s\le b and U>r(r1)|U|>r(r-1). Then UN(V)r(r1)2+12.|U\setminus N(V)|\ge \frac{r(r-1)}2+1\ge2.

Proof. The anchors have opposite colors. If adjacent, they lie at opposite ends of the even side of length nn. Reflect coordinates to put them at (0,0)(0,0) and (0,n1)(0,n-1), with the second coordinate longitudinal. Set z=n/2s1z=n/2-s\ge1. Then N(V){(x,y):yx2z}N(V)\subseteq\{(x,y):y-x\ge2z\}. On the diagonal x+y=2jx+y=2j of Qr(0,0)\mathcal Q_r(0,0), exactly min{2j+1,j+z}\min\{2j+1,j+z\} rooms lie outside this half-plane. Their total is C(r,z)={r(r1)/2+rzz(z1)/2,0zr,r2,zr.C(r,z)= \begin{cases} r(r-1)/2+rz-z(z-1)/2,&0\le z\le r,\\ r^2,&z\ge r. \end{cases} In particular C(r,z)C(r,1)=r(r+1)/2C(r,z)\ge C(r,1)=r(r+1)/2. At most r1r-1 rooms are missing from Qr(oU)\mathcal Q_r(o_U), giving the asserted remainder.

If the anchors are diagonally opposite, their distance is w+n24b+1w+n-2\ge4b+1. The radii of Qr(oU)\mathcal Q_r(o_U) and N(Qs(oV))N(\mathcal Q_s(o_V)) sum to at most 4b34b-3, so they are disjoint and the bound is stronger. The odd short side cannot join adjacent opposite-colored corners. These exhaust the orientations. ◻

For a transition with survivor (q,i,u)(q,i,u), target (t,j,v)(t,j,v) and original surplus =tq\ell=t-q, call it a strict near-square event when i=2,(j,v)=(1,2),2b,(1)<ht2. i=2,\quad (j,v)=(1,2),\quad 2\le\ell\le b,\quad \ell(\ell-1)<h-t\le\ell^2. (163) It sets a one-step history flag on the target. The flag is defined from the history’s own preceding event, and is zero initially. Every nontriggering new action clears it. For a physical history, ii is the actual corner count of its maximally retained survivor, not an optimization over unspecified supports.

Theorem 29.7 (Forbidden closed near-square successor). After a strict near-square event, the next transition cannot have (j,v)=(1,2)(j,v)=(1,2) and closed surplus σ=+iv\sigma=\ell+i-v satisfying 2σb,σ(σ1)<htσ2. 2\le\sigma\le b,\qquad \sigma(\sigma-1)<h-t\le\sigma^2. (164) This is a necessary rule for arbitrary physical histories after maximal survivor retention.

Proof. Let UU be the holes following the strict event, with its surplus parameter rr. Corner closure has no slack since i=v=2i=v=2. Thus N(U)Ur|N(U)|-|U|\le r, while the size profile forces the reverse inequality. The large corner branch is impossible because hr2>r2h-r^2>r^2. Theorem 11.17 gives UQr(oU)U\subseteq\mathcal Q_r(o_U) and U>r(r1)|U|>r(r-1).

For the proposed successor let VV be its holes. The closed-surplus bound gives N(V)Vσ|N(V)|-|V|\le\sigma. The size profile again forces equality, and the same localization gives VQσ(oV)V\subseteq\mathcal Q_\sigma(o_V). Lemma 29.6 implies UN(V)2|U\setminus N(V)|\ge2. The flagged source has (c,e)=(1,2)(c,e)=(1,2), so maximality and target v=2v=2 force survivor i=1i=1. Hence σ=vi=1\ell-\sigma=v-i=1, and the complementary inclusion gives UN(V)U+IN(V)=σ=1,|U\setminus N(V)| \le |U|+|I|-|N(V)|=\ell-\sigma=1, a contradiction. ◻

Theorem 29.8 (The near-square flag preserves the guarded merger). The weakened, closed, maximal erosion model of Theorem 11.25 remains closed under its guarded merger after adding the flag (163) and the restriction of Theorem 29.7. Earlier static interval rules and pronic flags may be retained.

Proof. First consider formation of a merged strict event of surplus rr. Merged survivor count I=2I=2 and target erosion V=2V=2 force i1=i2=v1=v2=2i_1=i_2=v_1=v_2=2, so both closure slacks vanish. Target J=1J=1 forces j1+j2=3j_1+j_2=3, hence both outgoing counts are positive. The component holes sum to D(r(r1),r2]D\in(r(r-1),r^2]. A small closed component would have target at most sl2r2s_l^2\le r^2 and holes at least hr2>r2h-r^2>r^2, impossible; the critical exception has outgoing count zero. Both components are high, and dlΦ2jl,0(sl)sl2.d_l\le\Phi_{2-j_l,0}(s_l)\le s_l^2. If both original surpluses were positive, their sum rr would give D(r1)2+1r(r1)D\le(r-1)^2+1\le r(r-1), a contradiction. Thus one component is original-full-to-full at cost zero. The merged event is the identity on the other component. Defining the merged flag from its own trigger maintains the invariant that one component is flagged and the other is full.

Now start from a flagged merged source and suppose a proposed successor satisfies (164). Target V=2V=2 forces both component target erosions to be two. Their source corner counts are one and two, so maximality forces iflag=1i_{\mathrm{flag}}=1 and ifull=2i_{\mathrm{full}}=2. Their closure slacks are one and zero; consequently the merged closed surplus σ\sigma is the sum of their closed surpluses. The same small-branch exclusion forces both high, now with dlΦ2jl,0(σl)σl2.d_l\le\Phi_{2-j_l,0}(\sigma_l)\le\sigma_l^2. Two positive closed surpluses would give total holes at most (σ1)2+1σ(σ1)(\sigma-1)^2+1\le\sigma(\sigma-1), contrary to the proposed event. One closed surplus is therefore zero. It cannot be the flagged one: its high bound would force a full target and survivor q=h1q=h-1, whereas the flagged source has at least r(r1)+13r(r-1)+1\ge3 holes. Thus the full component has closed surplus zero. Its closure slack also vanishes, so it is original-full-to-full. The successor is again an identity merger, and is excluded by the flagged component’s own rule. Nontriggering actions reset the flag.

All new restrictions transfer by these identity arguments; they do not interpret a synthetic merged support as a physical set. The older pronic flags have target erosion zero, while the new flag has target erosion two, so their formation rules do not conflict. The original strict precapture guard is unchanged. ◻

The resulting clock and its preterminal residual give lower bounds by Corollary 11.23; they still need comparison with a physical construction. In particular, a backward interval recurrence for the unflagged erosion model is not being asserted for this richer history model.

Persistent corner radii and a clipped clock

A radius certificate of relative color p{0,1}p\in\{0,1\} says that the current support lies in a Manhattan ball of radius RR about some corner of that relative color. Relative color zero means the support’s color. Put D=w+n2D=w+n-2 and use DD for an uninformative certificate. One inspection and movement sends (p,R)(p,R) to (1p,min{D,R+1})(1-p,\min\{D,R+1\}). This assertion concerns the original support and requires no compression of the inspection sets.

Theorem 29.9 (Square interval localization, including the critical radius). Suppose 2rb2\le r\le b, c(U)=1c(U)=1, r(r1)<Ur2,N(U)U=r.r(r-1)<|U|\le r^2,\qquad |N(U)|-|U|=r. Then UQr(o)U\subseteq\mathcal Q_r(o) at its unique own-colored corner. Its target has (c,e)=(0,1)(c,e)=(0,1) and relative-color-one radius at most 2r12r-1. Its next target has e=0e=0 and c1+1{r=b}c\le1+\mathbf1_{\{r=b\}}.

Proof. For r<br<b, exclude the high branch and apply the near-square localization theorem. At r=br=b, the separator case of Theorem 11.3 uses the same quadrant argument. In its nonseparator case, reflect so that the empty endpoint is U2bU_{2b}. Each even fiber U2qU_{2q} is an actual prefix of length at most bqb-q. The odd fiber R2q+1R_{2q+1} is contained in U2q+2U_{2q+2}, hence in a prefix of length at most bq1b-q-1. Under the physical map (x,j)(x,2j+(xmod2))(x,j)\mapsto(x,2j+(x\bmod2)), both bounds imply x+y2b2x+y\le2b-2. Thus the entire support lies in Qb\mathcal Q_b; equality in the size bound is unnecessary. The high branch is excluded by hr2r>r2h-r^2-r>r^2. The target radius is 2r12r-1. It omits both own-colored corners and contains the neighbor pair of oo, giving (c,e)=(0,1)(c,e)=(0,1). After another move the radius is 2r2b<n2r\le2b<n, so erosion is zero. The second own-colored corner is at distance w1=2bw-1=2b, explaining the stated critical allowance. ◻

Retain two radii ρ0,ρ1\rho_0,\rho_1. A pronic event from Theorem 29.3 with known outgoing corner tightens ρ0\rho_0 to 2r22r-2, since its target is within that radius. The square event above tightens ρ1\rho_1 to 2r12r-1. Every movement first swaps the two radii and adds one, capped at DD; each applicable tightening is then a coordinatewise minimum. These two certificates may use different corners. Their exact feature consequences are c at moste at mostρ0=R1+1{Rw1}1{Rn}+1{Rw+n3}ρ1=R1{Rn1}+1{RD}1{R1}+1{Rw}.\begin{array}{c|cc} &c\text{ at most}&e\text{ at most}\\ \hline \rho_0=R&1+\mathbf1_{\{R\ge w-1\}} &\mathbf1_{\{R\ge n\}}+\mathbf1_{\{R\ge w+n-3\}}\\ \rho_1=R&\mathbf1_{\{R\ge n-1\}}+\mathbf1_{\{R\ge D\}} &\mathbf1_{\{R\ge1\}}+\mathbf1_{\{R\ge w\}}. \end{array} An adjacent corner at distance dd has neighbors at distances d1d-1 and d+1d+1; the diagonally opposite corner has both at distance d1d-1.

Theorem 29.10 (The paired radius rules preserve the guarded merger). The two interval resets and all their later feature consequences preserve the guarded erosion merger. The coordinate invariant is ρpmergedmin{ρp(1),ρp(2)},p=0,1.\rho_p^{\rm merged}\ge \min\{\rho_p^{(1)},\rho_p^{(2)}\},\qquad p=0,1.

Proof. A merged square reset of surplus rbr\le b is an identity merger. If both component original surpluses were positive, each would be at most r1r-1. A low component would force merged survivor size at most (r1)2<r(r1)(r-1)^2<r(r-1); two high components would bound target holes by r2r^2, contrary to hr2r>r2h-r^2-r>r^2. Thus one component has zero original surplus. Its empty alternative is excluded by the positive guarded survivor, leaving a full-to-full zero-cost partner. For a pronic reset, merged outgoing count one forces both component outgoing counts to be positive. A low component with positive surplus at most r1r-1 has at most (r1)(r2)(r-1)(r-2) rooms, contradicting the strict pronic interval; two high components again contradict the hole bound. Formation is therefore an identity merger in both cases.

Propagation preserves the displayed coordinate inequality. A merged reset is an identical reset of the non-full component; any additional component reset only decreases its side of the inequality. The componentwise corner and erosion merger bounds then transfer each radius restriction. A common witness for both coordinates is not needed. ◻

Lemma 29.11 (The corner-ball lens). The largest intersection of balls of radii R0,R1R_0,R_1 about opposite-colored corners, restricted to the color of the first corner, has size M(R0,R1)=#{(x,y):0x<w, 0y<n, x+y0(mod2),x+yR0, x+n1yR1}.M(R_0,R_1)=\#\{(x,y):0\le x<w,\ 0\le y<n,\ x+y\equiv0\pmod2, x+y\le R_0,\ x+n-1-y\le R_1\}. Consequently a support with the two radius certificates satisfies aM(ρ0,ρ1)a\le M(\rho_0,\rho_1). This inequality preserves the guarded merger. For the square triangle Qr\mathcal Q_r, the corresponding intersection with an opposite-corner ball of radius RR is Lr(R)=r2Fr ⁣(Rn+12),Fr(t)=Tri(r1t)2Tri(1t)+Tri(r1t),L_r(R)=r^2-F_r\!\left(\left\lfloor\frac{R-n+1}{2}\right\rfloor\right), \quad F_r(t)=\operatorname{Tri}(r-1-t)-2\operatorname{Tri}(-1-t) +\operatorname{Tri}(-r-1-t), where Tri(z)=z+(z++1)/2\operatorname{Tri}(z)=z_+(z_++1)/2 and z+=max{z,0}z_+=\max\{z,0\}.

Proof. Reflect the first anchor to (0,0)(0,0). On each horizontal row its ball is a left prefix. The aligned opposite anchor (0,n1)(0,n-1) also gives a left prefix; the diagonal anchor gives the reflected right prefix with the same color cardinality, since w1w-1 is even. Aligned prefixes maximize the intersection. For Qr\mathcal Q_r, on diagonal x+y=2jx+y=2j the aligned old ball omits max{0,jt}max{0,jt1}\max\{0,j-t\}-\max\{0,-j-t-1\} rooms. Summing for 0j<r0\le j<r gives Fr(t)F_r(t), including negative tt and radii beyond the triangle.

If one component witnesses both merged radius bounds, its intersection bound transfers since the merged size is no larger. If the witnesses are different, let B0,B1B_0,B_1 be the two ball cardinalities. The merged size is at most B0+B1hB_0+B_1-h, which is at most the intersection of any such two balls by inclusion-exclusion, hence at most MM. Monotonicity in the radii completes the transfer. ◻

Set k=b+1k=b+1 and K=b2+b+1K=b^2+b+1. For positive qKq\le K define α0(q)=min{q,b},α1(q)=min{min{r:qr(r1)},b+1},\alpha_0(q)=\min\{\lceil\sqrt q\rceil,b\},\qquad \alpha_1(q)=\min\{\min\{r:q\le r(r-1)\},b+1\}, with both zero at q=0q=0. Define g0(q,R)=α0(q)g_0(q,R)=\alpha_0(q). To define g1g_1, start with α0(q)\alpha_0(q) and impose the following improvements: if R<n1R<n-1, use α1(q)\alpha_1(q); if R<DR<D and q>b2q>b^2, use b+1b+1; and for 1rb1\le r\le b with r(r1)<qr2r(r-1)<q\le r^2 and q>Lr(R)q>L_r(R), use r+1r+1. These conditions agree when they overlap.

Theorem 29.12 (A radius-aware clipped lower clock). Let Hp(a,R)H_p(a,R), for 0aK0\le a\le K, be the capture time of the recurrence which replaces positive aa by q=max{0,ak},a={0,q=0,q+gp(q,R),q>0,p=1p,R=min{D,R+1}.q=\max\{0,a-k\},\qquad a'=\begin{cases}0,&q=0,\\q+g_p(q,R),&q>0,\end{cases} \quad p'=1-p,\quad R'=\min\{D,R+1\}. Put Hp(a,R)=Hp(min{a,K},R)\overline H_p(a,R)=H_p(\min\{a,K\},R) and P(a,ρ0,ρ1)=max{H0(a,ρ0),H1(a,ρ1)}.\mathcal P(a,\rho_0,\rho_1) =\max\{\overline H_0(a,\rho_0),\overline H_1(a,\rho_1)\}. Every physical step, and every guarded merged step with the paired radius rules, satisfies P(source)1+P(target).\mathcal P(\text{source})\le1+\mathcal P(\text{target}). Thus P\mathcal P is a lower bound for the remaining capture time, including histories whose sizes leave the interval [0,K][0,K].

Proof. In this size sector the high branch cannot improve the square or corner-free pronic profiles. A strict square-band survivor with the cheaper surplus r<br<b must have one own corner and is localized by Theorem 29.9; the degree-two argument handles r=1r=1. At r=br=b, an informative opposite radius R<DR<D excludes the second own corner, removing the critical exception. The critical interval localization then applies. A proposed cheap survivor larger than Lr(R)L_r(R) contradicts the lens lemma. For q>b2q>b^2 and R<DR<D, all low critical capacities are too small and the same exception is absent, forcing surplus at least b+1b+1. These prove the gpg_p profiles. They are nondecreasing in qq and nonincreasing in RR; the q>b2q>b^2 clause prevents a drop at the cap. The clock recurrence is finite and monotone by comparison with the anchored prefix maps.

For a physical step put q0=max{0,min{A,K}k}q_0=\max\{0,\min\{|A|,K\}-k\}. A q0q_0-room subset of the survivor retains its radius certificate, and its neighborhood lies in the actual target. Hence the target size is at least q0+gp(q0,R)q_0+g_p(q_0,R) when q0>0q_0>0; this lower bound is at most KK. Monotonicity of HH proves its one-step inequality after clipping. The case q0=0q_0=0 has source clock at most one. Taking the maximum over the swapped coordinates preserves the inequality, and every later radius tightening only strengthens it.

For a guarded merged step, an actual survivor count qKq\ge K gives target count at least qq by nonnegative surplus (the even-board Hall inequality), so clipping already suffices. If q<Kq<K, use the same low profile and qq0q\ge q_0. Each added lens exclusion transfers by the identity merger in Theorem 29.10: the full partner’s opposite radius is DD, so any informative merged opposite radius belongs to the identical non-full component. The corner-free and critical-exception exclusions transfer by the corner bounds. This proves the merged one-step inequality as well. ◻

This potential does not assert a matching clock from the unrestricted boundary KK: initially both radii can be uninformative. Comparing its entrance value with the physical prefix clock remains a separate problem. None of these radius or lens rules asserts interval closure for a flagged backward capturable set.

A boundary-history obstruction independent of length

Theorem 29.13 (Transferred joint boundary bound). On every even-area rectangle with both side lengths at least 24, with budget 13, a full initial color class leaves at least h111h-111 rooms after 28 unsuccessful inspection-and-move steps, where hh is half the area. Full initial uncertainty leaves at least 2h1112h-111 rooms.

Proof. Use the old unrefined 24-square model and its independently verified forward and equality calculations from Corollary 11.19. Translate a physical feature (a,c)(a,c) with deficit d=had=h-a to (288d,c)(288-d,c). While source deficit is at most 112, at most 13 deletions leave a survivor of size at least h125163>112h-125\ge163>11^2. For surplus s<12s<12 the finite corner theorem is subcritical, and its small branch is impossible. Its high condition htGij(s)h-t\le G_{ij}(s) is unchanged by deficit translation. For s12s\ge12 the old 24-square model is unrestricted. Inspection costs and all corner counts are preserved.

A perfect matching gives N(S)S|N(S)|\ge|S|, so a day’s deficit increase is at most 13. Thus the translation remains valid through a first hypothetical crossing of deficit 112: all translated sizes are at least 163 and satisfy the upper corner bounds. The old forward model has no state below 176 through day 28. Therefore a solo history cannot cross 112 erased rooms by that time, and equality has corner count one.

For two cohorts, apply the same translation until a hypothetical first crossing of total deficit 112. Each individual source deficit is then at most 112. The two exact inspection allocations still sum to at most 13, and the guarded merger has size 288d1d2163>13288-d_1-d_2\ge163>13 through the crossing. The old forward bound excludes it. If equality 112 holds at day 28, the independently checked joint equality certificate forces terminal pair ((176,1),(288,2))((176,1),(288,2)) after translation. Thus one physical cohort has deficit 112 and the other is full. It remains to exclude the former physical history, rather than imposing a solo restriction on a synthetic merged set.

Suppose its final belief is AA and put U=VpAU=V_p\setminus A, so U=112|U|=112. Reversing the 28 inspections clears N(U)N(U) within 28 days. The old 24-square backward frontiers through 28 have size at most 123. This bound transfers to larger boards by backward induction: a move into target size t123t\le123 has survivor size at most 123 and source size at most 136, all valid 24-square feature sizes. A physical small branch remains the same branch; a physical high branch implies 288thtGij(s)288-t\le h-t\le G_{ij}(s); and surplus at least 12 is unrestricted in the old model. Consequently N(U)123|N(U)|\le123 on the larger board too.

The unconditional profile gives the reverse inequality, hence surplus exactly 11. The high branch is impossible since h123165>112h-123\ge165>11^2. Because 112>1110112>11\cdot10, near-square localization places UU in a 121-room corner triangle on diagonals at most 20. Its neighborhood lies on diagonals at most 21. Both therefore lie in a 24-square corner subboard with exactly the same neighborhood there.

Restricting the princess to that subboard can only make capture easier. The same strategy compression and eight-pattern certificate used in Proposition 11.18 show that its 123-room neighborhood requires at least 29 days. This contradicts reversal. It excludes solo deficit 112 and, by the separately transferred joint equality certificate, total joint deficit 112 as well. ◻

This proof reuses the old finite certificates uniformly; it requires no new shape enumeration for each length. The next consequence evaluates the resulting time-dependent lower bound without a length recurrence.

A prescribed corner change and its length dependence

Throughout this subsection the board is 2r×n2r\times n, with n2rn\ge2r. Write Pp(q)P_p(q) for the bottom-left weightlex prefix of physical color pp: rooms are ordered by increasing x+yx+y, breaking ties by decreasing xx. Its neighborhood is an opposite-color prefix; put gp(q)=N(Pp(q))g_p(q)=|N(P_p(q))|. Canonical pyramid cutoffs in neighboring columns differ by one. Their uniformly increased cutoffs contain the neighborhood and add at most rr rooms, so gp(q)q+r. g_p(q)\le q+r. (165) In particular, the deterministic prefix strategy inspecting its final min(k,q)\min(k,q) rooms terminates when k>rk>r.

Lemma 29.14 (A constant-surplus interval). If r2r\ge2, then, for either physical color, gp(q)=q+rwhenever(r1)2+1qr(nr)+r1.g_p(q)=q+r \quad\text{whenever}\quad (r-1)^2+1\le q\le r(n-r)+r-1.

Proof. Represent the prefix by its last diagonal x+y=dx+y=d and the least occupied column cc on that diagonal. The stated size interval puts dd between 2r32r-3 and nn. Count the full earlier diagonals and the last partial diagonal separately. When d=2r3d=2r-3 or 2r22r-2, the earlier neighborhood count exceeds the earlier source count by r1r-1, and the last neighborhood diagonal has one extra room. For 2r1dn22r-1\le d\le n-2, the earlier-count difference is rr and the partial lengths agree. At d=n1d=n-1, the upper size bound forces c1c\ge1; at d=nd=n it forces cr+12c\ge r+1\ge2. These are precisely the conditions preventing the top boundary from shortening the last partial neighborhood diagonal. The earlier-count difference is again rr. These cases also cover n=2rn=2r. ◻

Theorem 29.15 (An explicit minimum-budget corner change). Let r5r\ge5 and k=r+1k=r+1, and define QA=r(nr)+2r2,QB=r(nr)+3,t=2r5,Q_A=r(n-r)+2r-2,\qquad Q_B=r(n-r)+3,\qquad t=2r-5, pAn+1(mod2),pBn(mod2).p_A\equiv n+1\pmod2,\qquad p_B\equiv n\pmod2. Starting from either full color class, run the deterministic bottom-left prefix strategy until the first belief in phase pAp_A with at most QAQ_A rooms. Its size qAq_A is QAQ_A or QA1Q_A-1. A directly prescribed tt-day transport then leaves a belief contained in the bottom-right phase-pBp_B prefix of size QBQ_B. The deterministic bottom-right prefix strategy completes capture.

Thus the entrance stopping rule, bridge length, and target size require no optimization over possible splice indices. The entrance and final prefix clocks remain recurrences.

Proof. At source sizes QA+2,QA+1,QAQ_A+2,Q_A+1,Q_A, subtraction of kk leaves sizes in Lemma 29.14. Their next belief sizes are therefore QA+1,QA,QA1Q_A+1,Q_A,Q_A-1, respectively. Prefix neighborhoods are nested as the prefix size increases, so no larger belief can jump below QA+1Q_A+1. Equation (165) ensures eventual arrival at this level. The two subsequent visits have opposite phases, proving the assertion about qAq_A.

We next bound the endpoint cutoffs a,ba,b. First take n=2rn=2r. The phase-1 prefix of size r2+2r3=QA1r^2+2r-3=Q_A-1 fills all diagonals through 2r12r-1 and at least the first two rooms of diagonal 2r+12r+1: there are r32r-3\ge2 such additional rooms. Every column consequently has cutoff at least 2. The larger prefix of size QAQ_A satisfies the same bound.

Reflect the target horizontally. It becomes the phase-1 prefix of size r2+3r^2+3. Its last diagonal is 2r12r-1, with r+3r+3 rooms and least occupied column r3r-3. Its earlier diagonals have height at most 2r32r-3, and its last partial diagonal has height at most r+22r3r+2\le2r-3. Its first two rooms on that diagonal fill the only columns absent from the earlier diagonals, so every target column is nonempty.

Adding n2rn-2r to all cutoffs gives the stated prefixes on the general board: their bottom truncations are inactive, their sizes increase by r(n2r)r(n-2r), and their phases change by n2rn-2r. Hence minxaxn2r+2,maxxbxn3,maxx(bxax)t.\min_x a_x\ge n-2r+2,\qquad \max_x b_x\le n-3, \qquad \max_x(b_x-a_x)\le t. The positive-part penalty in the transport of Section 13.1 vanishes. The canonical cutoff sums give Ft(a,b)=qAQB+rtQAQB+rt=(r+1)t=kt.F_t(a,b)=q_A-Q_B+rt \le Q_A-Q_B+rt=(r+1)t=kt. The prescribed descending local-maximum word therefore supplies the bridge, without a boundary credit. Its endpoint containment suffices for the target prefix’s capture strategy. ◻

Corollary 29.16 (Two-row extension of the prescribed strategy). Fix r5r\ge5 and the initial corner phase p0p_0. Let Lr,p0(n)L_{r,p_0}(n) be the prescribed solo length in Theorem 29.15. Then Lr,p0(n+2)=Lr,p0(n)+2r.L_{r,p_0}(n+2)=L_{r,p_0}(n)+2r. The final solo inspection set has unchanged size. Consequently the full reversal construction, including the optional reflected central merger, has length increased by 4r4r. Minimizing over the two initial corner phases gives an upper bound Ur(n)=2rnCr,nmod2,U_r(n)=2rn-C_{r,n\bmod2}, where the two width constants are determined by the prescribed strategies at lengths 2r2r and 2r+12r+1.

Proof. Before the entrance stops, each survivor prefix has every column nonempty. Indeed its size is at least QAk=r(nr)+r3Q_A-k=r(n-r)+r-3; the prefix counts show that this contains the bottom room of every column in either phase when r5r\ge5. Adding two to every cutoff therefore commutes with its physical inspection-and-neighborhood steps, adding 2r2r rooms to every belief. The stopping condition and phase are unchanged, so the entrance time is unchanged. Both bridge endpoints also increase by two, preserving their differences and the prescribed bridge length.

The enlarged target has size QB+2rQ_B+2r. During its first 2r2r tail steps, the survivor sizes range from QB+2rkQ_B+2r-k down to QB+1kQ_B+1-k. They lie in the constant-surplus interval of Lemma 29.14 on the (n+2)(n+2)-long board. Thus each step removes exactly one possible room, reaching the original size-QBQ_B target in its original phase.

The remaining tail is unaffected by the taller board. The original target has maximum height at most n3n-3, and later sizes decrease by (165). In the target phase, each later prefix is contained in that target. In the other phase, it is contained in the target’s neighborhood: the latter is a prefix of size at least QBQ_B, by the rectangle’s perfect matching. Every later belief therefore has height at most n2n-2, so none of its neighborhoods can leave the old board at the top. Its inspections and neighborhoods are identical on the two boards. This proves the solo length identity and preservation of the final inspection set. The usual reversal construction doubles the length, or saves one central day when the two reflected final inspection sets fit the quota. ◻

For width 24, the directly replayed base strategies have nL12(n)final solo inspectionsU12(n)2410422072511613232\begin{array}{c|ccc} n&L_{12}(n)&\text{final solo inspections}&U_{12}(n)\\ \hline 24&104&2&207\\ 25&116&13&232 \end{array} and hence T13(24,n){24n369,n even,24n368,n odd,n24. T_{13}(24,n)\le \begin{cases} 24n-369,&n\text{ even},\\ 24n-368,&n\text{ odd}, \end{cases} \qquad n\ge24. (166) The construction also gives the replayed bounds 112 on 16×1616\times16, 144 on 16×1816\times18, and 308 on 32×3232\times32. It is not asserted to be optimal throughout its parameter range. Its dependence on length has been evaluated, but the width constants still contain prefix-clock iteration; this is not an O(1)O(1) evaluation in all parameters.

Exact scheduling of the prescribed transport word

The boundary credit of Section 13.1 counts flips invisible on every day. One might hope to improve it by scheduling other flips on days when they are invisible. For the prescribed descending word, the following result identifies exactly when that can help.

Proposition 29.17 (Physical windows and fixed-word exactness). Let a,ba,b be canonical pyramid cutoffs and t1t\ge1. Put cx=min(ax,bxt)c_x=\min(a_x,b_x-t), and list the legal descending word’s letters (x,H)(x,H), with H=ax,ax2,,cx+2H=a_x,a_x-2,\ldots,c_x+2, in decreasing height order. For 0i,j<t0\le i,j<t, define Ai=#{Hni},Bj=#{Hj}.A_i=\#\{H\ge n-i\},\qquad B_j=\#\{H\ge-j\}. This fixed word can be scheduled over tt days with at most kk visible flips per day if and only if some integers 0ij<t0\le i\le j<t satisfy BjAik(ji+1). B_j-A_i\le k(j-i+1). (167) The assertion includes empty words and k=0k=0. On width 2r2r, if krk\ge r, it is equivalent to the existing criterion Ft(a,b)kt+z(B).F_t(a,b)\le kt+z(B). Thus time-dependent visibility cannot strengthen that criterion for this prescribed word in the feasible even-width budget range.

Proof. On day dd, a letter is visible exactly when 0H+d<n0\le H+d<n. If (167) holds, leave the word untouched until day ii. Its first AiA_i letters are then above the board and free. Partition its next BjAiB_j-A_i letters among days i,,ji,\ldots,j, charging at most kk per day. Its final letters are below the board and free on day jj. This preserves the word order. When k=0k=0, the middle band is empty, so no division into nonempty paid groups is required.

For necessity, greedily execute each day’s longest remaining prefix costing at most kk visible letters, including all free letters before the next unaffordable letter. This rule dominates every other fixed-word schedule at every day boundary. Indeed, from a farther word position, the remaining part of a competing next group is its suffix and costs no more on that same day. This argument allows visibility to depend on the day.

Let qjq_j be the greedy position before day jj. Because heights are nonincreasing, greedy completes that day exactly when max(qj,Aj)+kBj\max(q_j,A_j)+k\ge B_j; otherwise qj+1=max(qj,Aj)+kq_{j+1}=\max(q_j,A_j)+k. Before the first completion, induction gives max(qj,Aj)+k=k(j+1)+max0ij(Aiki).\max(q_j,A_j)+k =k(j+1)+\max_{0\le i\le j}(A_i-ki). The completion condition is precisely (167). It includes completion without any paid letter and immediate completion of an empty word.

For width 2r2r, each integer height appears in at most rr letters, since its parity fixes a column color. Canonical initial heights lie below nn, so AirikiA_i\le ri\le ki and A0=0A_0=0. Moreover Bj+1BjrkB_{j+1}-B_j\le r\le k. Thus the best window is i=0,j=t1i=0,j=t-1, and the criterion becomes Bt1ktB_{t-1}\le kt.

Writing F=Ft(a,b)F=F_t(a,b), the difference FBt1F-B_{t-1} counts letters with HtH\le-t. There is exactly one in each empty target bottom-root fiber: there bx=2b_x=-2, cx=t2c_x=-t-2, and the last old height is t-t. The canonical initial height is at least t-t; for t=1t=1 this follows from its opposite bottom parity, and for t2t\ge2 from ax2a_x\ge-2. An empty nonroot target has bx=1b_x=-1 and last old height 1t1-t; nonempty target fibers end still higher. Hence FBt1=z(B)F-B_{t-1}=z(B), which proves the final equivalence. It concerns this word only and does not make the transport criterion necessary for all physical strategies. ◻

Buffered comparisons at linear budgets

Let w4w\ge4, nwn\ge w, wn=2hwn=2h, and wk<hw\le k<h. Write m=k/2m=\lfloor k/2\rfloor. Let Bt(c)B_t(c) be the critical three-corner backward frontier for capture within tt days, and let Ct(c)C_t(c) be the same frontier for reaching size at most mm within tt inspection-and-movement steps. Their initial vectors are (0,1,1)(0,-1,-1) and (m,m,m)(m,m,m), respectively. Write Pt(p)P_t(p) and Qt(p)Q_t(p) for the corresponding physical, fixed-corner prefix frontiers, with initial vectors (0,0)(0,0) and (m,m)(m,m). The two comparisons of interest are Bt(2)maxpQt(p),Ct(2)maxpPt+1(p). B_t(2)\le\max_p Q_t(p),\qquad C_t(2)\le\max_p P_{t+1}(p). (168) The maxima can choose different initial phases: each inequality is used separately to construct its own reflected physical strategy.

These comparisons imply a one-day bracket. Let τ\tau be the first capture time of the critical three-corner model. If its half-budget test at τ1\tau-1 fails, the merger lower bound is 2τ2\tau, while the first comparison gives a prefix palindrome of length at most 2τ+12\tau+1, sharing its two half-budget final inspections. If the test succeeds, the lower bound is 2τ12\tau-1, and the second comparison gives a solo prefix of length at most τ\tau, hence a full search of length at most 2τ2\tau. These are explicit prefix inspections and reflections; a path in the necessary model is never used as a physical inspection sequence.

Proposition 29.18 (Sufficient buffered comparison). The comparisons (168) hold in either of the following parameter regions: w=2r:mr(r1)22(kr),w=2b+1, n even:mb1b22(kb1).\begin{array}{ll} w=2r:&\displaystyle m-r\ge\left\lceil\frac{(r-1)^2}{2(k-r)}\right\rceil,\\[6pt] w=2b+1,\ n\text{ even}:&\displaystyle m-b-1\ge\left\lceil\frac{b^2}{2(k-b-1)}\right\rceil. \end{array} In the second line the hypothesis kwk\ge w makes the denominator positive. These are sufficient regions, not classifications of every partial physical support.

Proof. Put R(x)=xR(x)=\lceil\sqrt{x}\rceil and ρ(x)=min{u0:xu(u+1)}\rho(x)=\min\{u\ge0:x\le u(u+1)\}. For even width 2r2r, direct inversion of the diagonal-prefix profiles gives, for x<hx<h, Ep(x)=xmin{Lp(x),r,Hp(hx)},E_p(x)=x-\min\{L_p(x),r,H_p(h-x)\}, where L0=RL_0=R, L1=ρL_1=\rho, and Hp=RH_p=R when pn(mod2)p\equiv n\pmod2, while Hp=1+ρH_p=1+\rho otherwise. At x=hx=h set Ep(h)=hE_p(h)=h. The low roots come from inverting the two corner-triangle profiles; the plateau subtracts rr; complement and half-turn reflection give the high roots and the indicated parity. The low and high portions are disjoint since h2r2h\ge2r^2.

The unconditional profile has inverse E(x)=max(0,xmin{r,ρ(x),R(hx)}).E(x)=\max(0,x-\min\{r,\rho(x),R(h-x)\}). Consequently its scalar backward orbit S=min(h,k+E(S))S'=\min(h,k+E(S)) dominates the critical corner frontier from the same size allowance. Compare it with physical prefixes initially at min(h,a+z)\min(h,a+z) in both phases, where the scalar starts at aa and rzkrr\le z\le k-r. While u=ρ(S)<ru=\rho(S)<r, maintain minpXpmin(h,S+zu).\min_pX_p\ge\min(h,S+z-u). If the next scalar rank remains low, write u=ρ(S)u'=\rho(S'). The input x=S+zu=S(kz)x=S+z-u=S'-(k-z) satisfies xu2x\le u'^2, since Su(u+1)S'\le u'(u'+1) and kzruk-z\ge r\ge u'. Thus either physical cost is at most uu', proving the invariant. At low exit the universal cost bound rr leaves the common credit zrz-r, including direct jumps to capture. The common middle increment krk-r preserves this credit. At high entry d=hS(r1)2d=h-S\le(r-1)^2. Above SS, one physical high cost is at most R(d)R(d) and the other at most R(d)+1R(d)+1. Each trajectory alternates the two, losing at most j/2\lceil j/2\rceil credits in jj steps. At most (r1)2/(kr)\lceil(r-1)^2/(k-r)\rceil steps remain. This proves the even comparison for z=mz=m and z=kmz=k-m, the two required seeds. Clipping a physical rank at hh preserves capture thereafter.

For odd width 2b+12b+1, the exact physical backward maps are G0(x)=min(h,k+xmin{ρ(x),b,R(hx)}),G1(x)=min(h,k+xmin{R(x),b+1,1+ρ(hx)}).\begin{aligned} G_0(x)&=\min(h,k+x-\min\{\rho(x),b,R(h-x)\}),\\ G_1(x)&=\min(h,k+x-\min\{R(x),b+1,1+\rho(h-x)\}). \end{aligned} with G0(h)=G1(h)=hG_0(h)=G_1(h)=h and crossed update X0=G0(X1)X'_0=G_0(X_1), X1=G1(X0)X'_1=G_1(X_0). Write a=max{0,B2}a=\max\{0,B_2\}, δ=kb1\delta=k-b-1, A=b(b+1)+1A=b(b+1)+1, and U=hb21U=h-b^2-1. The same assertions below apply to the half-budget frontier. After the first update its reachable coordinates are ordered, with adjacent gaps at most one. The initial capture vector has a=0a=0 and first largest coordinate kk. Its largest update is bounded above by min(h,a+kmin{ρ(a),b,R(ha)})\min(h,a+k-\min\{\rho(a),b,R(h-a)\}), and is at least min(h,a+δ)\min(h,a+\delta).

Start both physical phases at a0+za_0+z, clipped at hh, with kzb+1k-z\ge b+1. Below AA the monotone invariant is minpXpmin(h,a+zmin{b+1,ρ(a)}).\min_pX_p\ge\min(h,a+z-\min\{b+1,\rho(a)\}). The even-width root argument proves this as well: for s=a+kρ(a)s=a+k-\rho(a) and v=ρ(s)bv=\rho(s)\le b, the lower input x=s(kz)x=s-(k-z) satisfies xv2x\le v^2. On leaving this portion, use the cap b+1b+1. Thus entry supplies common credit c=zb1c=z-b-1.

When AB0B2UA\le B_0\le B_2\le U, all finite root branches at surplus at most bb are excluded, except the critical pair (i,j)=(2,0)(i,j)=(2,0). The exact middle update is B0=min(h2,a+δ),B1=min(h1,a+δ),B2=min(h,max{a,B0+1}+δ).B'_0=\min(h-2,a+\delta),\quad B'_1=\min(h-1,a+\delta),\quad B'_2=\min(h,\max\{a,B_0+1\}+\delta). It preserves the aligned bounds X0min(h,B2+c)X_0\ge\min(h,B_2+c) and X1min(h,B0+c)X_1\ge\min(h,B_0+c). At first entry one may have B0<AB_0<A, but adjacent spread gives B0A2>b2B_0\ge A-2>b^2. The i=0i=0 low target capacities at surplus at most bb are at most b2b^2, and all low capacities at surplus at most b1b-1 are at most b(b1)<A2b(b-1)<A-2. Hence already B0=min(h2,a+δ)B'_0=\min(h-2,a+\delta) and B2min(h,a+δ+1)B'_2\le\min(h,a+\delta+1); these establish alignment without spending credit. Later middle steps spend none either.

At high exit hab2h-a\le b^2. Follow the physical trajectory currently in phase zero, which has all cc credits. Its next map is G1G_1; thereafter costly and noncostly maps alternate. On inputs at least aa, their costs are at most min{b,R(ha)}+1\min\{b,R(h-a)\}+1 and min{b,R(ha)}\min\{b,R(h-a)\}, respectively. At most b2/δ\lceil b^2/\delta\rceil model steps remain, so the hypothesis supplies every possible credit expenditure. Take (a0,z)=(0,m)(a_0,z)=(0,m) and (m,km)(m,k-m) to obtain the two comparisons. ◻

Theorem 29.19 (A common linear-budget one-day bracket). For every even-area rectangle with shorter side w4w\ge4, longer side nwn\ge w, and 4w/3k<wn/2\lceil4w/3\rceil\le k<wn/2, the critical three-corner lower bound and the physical prefix-palindrome upper bound differ by at most one day.

Proof. For w=2rw=2r, the first condition of Proposition 29.18 holds at k=8r/3k=\lceil8r/3\rceil: substituting r=3q,3q+1,3q+2r=3q,3q+1,3q+2 directly proves (r1)22(kr)(k/2r)(r-1)^2\le2(k-r)(\lfloor k/2\rfloor-r). For w=2b+1w=2b+1, its second condition holds at k=8b/3+2k=\lceil8b/3\rceil+2 by the same three residue cases. At the desired k0=4(2b+1)/3k_0=\lceil4(2b+1)/3\rceil, the only missing pairs are (b,k0)=(2,7),(4,12),(5,15),(7,20),(8,23),(11,31),(14,39).(b,k_0)=(2,7),(4,12),(5,15),(7,20),(8,23),(11,31),(14,39). Indeed for b=3qb=3q the condition holds; for b=3q+1b=3q+1 it reduces to q22q10q^2-2q-1\ge0, and for b=3q+2b=3q+2 to q24q40q^2-4q-4\ge0. At k0+1k_0+1 it holds on all seven lines, and increasing kk only improves the sufficient condition.

Here is a finite certificate with a uniform length proof for those seven fixed pairs. Put D=2k2b1D=2k-2b-1. In each of the two initial comparison modes, follow the five-coordinate state (B0,B1,B2,X0,X1)(B_0,B_1,B_2,X_0,X_1) to an entry with B0b(b+1)+1,B0=B1,B2B0{0,1},minXpb2+1.B_0\ge b(b+1)+1,\quad B_0=B_1,\quad B_2-B_0\in\{0,1\}, \quad\min X_p\ge b^2+1. Low root branches are then inactive. In the common middle, two updates add DD to all five coordinates. Record the largest coordinate MM through entry and its first subsequent update. The margin hM+max{b2+1,k+2}h\ge M+\max\{b^2+1,k+2\} excludes high branches and state caps in these updates. The certificate gives the following stable starting lengths and even-length periods: w591115172329k7121520233139n0101416202030342D18303850587898\begin{array}{c|rrrrrrr} w&5&9&11&15&17&23&29\\ k&7&12&15&20&23&31&39\\ n_0&10&14&16&20&20&30&34\\ 2D&18&30&38&50&58&78&98 \end{array} For any nn0n\ge n_0, increasing nn by 2D2D increases hh by wDwD. Insert ww middle pairs at the fixed entry, adding 2w2w days and wDwD to all coordinates. Throughout insertion the deficits in the larger board are at least those covered by the stable margin. After insertion the entire old tail, including capture, translates by wDwD: low branches remain inactive, high-root arguments hxh-x are unchanged, and every state cap translates. Even insertion length preserves phase. The comparison B2maxXpB_2\le\max X_p is invariant under translation, and each inserted pair has the comparison margins of the first pair.

It therefore suffices to check the even lengths from w+1w+1 through n0+2D2n_0+2D-2, covering the shorter cases and one representative of every stable residue. The recorded certificate checks all 199 such lengths and all 12,393 deadlines in both modes; every comparison holds. It separately checks 107 translated tail states. The sources and exact entry coordinates are in . This proves all lengths, and the terminal argument preceding the proposition proves the asserted one-day bracket. ◻

A sharper high-region estimate

Lemma 29.20 (Decreasing high-root deficit). Let v1v\ge1, K>vK>v, A=KvA=K-v, and d0v2d_0\le v^2. Suppose that until capture the nonnegative deficits satisfy dj+1max{0,djK+dj}.d_{j+1}\le\max\{0,d_j-K+\lceil\sqrt{d_j}\rceil\}. For t1t\ge1, capture occurs within tt steps if tA+j=0t1jA2vv2.tA+\sum_{j=0}^{t-1}\left\lfloor\frac{jA}{2v}\right\rfloor\ge v^2. In particular the fixed-operation sufficient condition 4vtA+At(t1)4v(t1)4v3 4vtA+At(t-1)-4v(t-1)\ge4v^3 (169) suffices.

Proof. As long as capture has not occurred, djv2jAd_j\le v^2-jA. Set s=jA/(2v)s=\lfloor jA/(2v)\rfloor. Noncapture gives s<vs<v, and (vs)2v22vsv2jAdj(v-s)^2\ge v^2-2vs\ge v^2-jA\ge d_j. Thus the next decrease is at least A+sA+s. Summing proves the first condition; if jAv2jA\ge v^2, the coarser bound has already proved capture. For the second condition use jA/(2v)jA/(2v)1\lfloor jA/(2v)\rfloor \ge jA/(2v)-1 for j=1,,t1j=1,\ldots,t-1 and sum. The hypothesis t1t\ge1 is retained explicitly. ◻

Corollary 29.21 (A stronger linear-budget region). For even width w=2r4w=2r\ge4, every 13w/10k<rn\lceil13w/10\rceil\le k<rn satisfies the one-day bracket of Theorem 29.19. For odd width w=2b+1w=2b+1, even length nwn\ge w, the same conclusion follows from 13b/5+3k<wn/2\lceil13b/5\rceil+3\le k<wn/2.

More sharply, retain kwk\ge w, and require (169) with t=2ct=2c, c1c\ge1, where cvKw=2rk/2rr1kw=2b+1k/2b1bk1.\begin{array}{c|ccc} &c&v&K\\ \hline w=2r&\lfloor k/2\rfloor-r&r-1&k\\ w=2b+1&\lfloor k/2\rfloor-b-1&b&k-1. \end{array} Either of these integer tests also proves both buffered comparisons.

Proof. The preceding low and middle arguments already provide cc credits. In even width the high scalar deficit obeys the lemma with K=kK=k, v=r1v=r-1. In odd width let a=B2<ha=B_2<h, d=hab2d=h-a\le b^2. Choose survivor corner count one and target corner count two in the backward update. Its large inverse is 1+ρ(d)1+R(d)1+\rho(d)\le1+R(d); the survivor is admissible because ahb2b2+3b+1a\ge h-b^2\ge b^2+3b+1 and a(1+ρ(d))>1a-(1+\rho(d))>1. Its upper cap is inactive since a<ha<h. Consequently B2min(h,a+k1R(d))B'_2\ge\min(h,a+k-1-R(d)), giving the lemma with K=k1K=k-1. Capture within 2c2c steps requires at most cc alternating credit expenditures, so both comparisons follow.

For the even clean bound, t3r/51t\ge3r/5-1 and A=kr+18r/5+1A=k-r+1\ge8r/5+1. The slack in (169) is increasing in A,tA,t on this domain. Substituting these lower bounds and multiplying by 125 gives 52r395r225r+250=52(r2)3+217(r2)2+219(r2)+236>0.52r^3-95r^2-25r+250 =52(r-2)^3+217(r-2)^2+219(r-2)+236>0. Also c1c\ge1 for every r2r\ge2. There are no finite exceptions. For the odd clean bound, t3b/5t\ge3b/5 and A8b/5+2A\ge8b/5+2; the same substitution gives positive slack (52b3+270b2+350b)/125(52b^3+270b^2+350b)/125. ◻

The new integer test is asymptotically sufficient at quota divided by half-width at least (1+17)/2(1+\sqrt{17})/2. It strengthens the previous sufficient gate; neither gate proves the entire proposed range kwk\ge w. The tests themselves use a fixed number of arithmetic operations, but the compared lower and physical upper clocks still require their stated evaluations. A uniform one-day bracket is not an exact fixed-operation formula for the minimum capture time.

Fixed numerical expressions for further odd rectangles

The number of stages in Proposition 6.4 depends on the width. The following region admits an absolute bound instead. This numerical simplification and the necessity of the scalar midpoint test are separate assertions.

Theorem 30.1 (A fixed number of solo evaluations). Fix an integer K1K\ge1, independently of all input parameters. Let nw=2b+1n\ge w=2b+1 be odd, b2b\ge2, mb+1m\ge b+1, and put D=2mwD=2m-w. If KDb2KD\ge b^2, the exact solo capture time from any canonical prefix, and its remaining count at any prescribed day, can each be evaluated by at most 3K+13K+1 conditional paired-map blocks and one bulk floor division. Each block uses an absolute bounded number of elementary arithmetic operations, integer roots, and comparisons.

In particular, fixing K=16K=16 gives 4949 blocks whenever 16(2mw)b2.16(2m-w)\ge b^2. Four such evaluations give both solo times and both precentral residuals. They therefore evaluate the exact physical capture time in this region whenever MMM\ge M_* in Theorem 7.5, and also wherever scalar necessity follows from Theorems 21.1 or 8.1, and in the larger domains of Theorems 30.4, 30.5 and Corollary 30.6 below.

Proof. Put C0=M+1C_0=M+1, C1=MC_1=M, H=b2+1H=b^2+1, and cp=b+pc_p=b+p. Retain fp(x)=gp((xm)+),Pp=f1pfp.f_p(x)=g_p(\left(x-m\right)_+),\qquad P_p=f_{1-p}\circ f_p. The profiles of Theorem 5.1 give gp(z)=z+cpg_p(z)=z+c_p throughout HzMHH\le z\le M-H. Consequently, with p=2m+Hcp,u=m+MH,\ell_p=2m+H-c_p,\qquad u=m+M-H, both successive survivor inputs lie in that interval whenever pxu\ell_p\le x\le u, and Pp(x)=xD. P_p(x)=x-D. (170) The interval may be empty. The bounds for both inputs use mb+1cpm\ge b+1\ge c_p.

For every source, the stronger global progress bound Pp(x)max(0,xD) P_p(x)\le\max(0,x-D) (171) holds. If either constituent step captures the cohort, this is immediate. Otherwise the two profile surpluses sum to at most b+(b+1)=wb+(b+1)=w, giving Pp(x)x2m+wP_p(x)\le x-2m+w. A positive output is therefore impossible when x<Dx<D.

The initial excess above the affine interval satisfies Cpu=H+1pmb2KD.C_p-u=H+1-p-m\le b^2\le KD. Write KK conditional paired blocks, each acting only while the source exceeds uu and recording capture after either constituent day. By (171), these blocks capture the cohort or leave xux\le u. If now pxu\ell_p\le x\le u, perform q=1+(xp)/Dq=1+\left\lfloor(x-\ell_p)/D\right\rfloor pairs at once, replacing xx by xqDx-qD and adding 2q2q days. Every source of these pairs is in the affine interval, so their outputs are exact and positive. Otherwise omit this bulk operation.

Unless already captured, the remaining source obeys xp1=D+b2+b+1pD+2b2(2K+1)D.x\le\ell_p-1 =D+b^2+b+1-p \le D+2b^2\le(2K+1)D. Thus another 2K+12K+1 conditional paired blocks suffice, with the last block again distinguishing capture after its first or second day. There are 3K+13K+1 blocks in total. For a prescribed day, truncate the bulk count by the available number of complete pairs, and stop a block after one constituent day if required. Subsequent blocks then do nothing. The same bound holds for every prefix size and every prescribed day.

Compute the two full-cohort durations, take their minimum τ\tau, and evaluate both full-cohort residuals at τ1\tau-1, with their physical colors determined by time parity. Their sum is the left-hand side of (24). The cited scalar-necessity theorems now select 2τ12\tau-1 or 2τ2\tau. ◻

For K=16K=16, the entire scalar calculation uses at most 196196 paired blocks and four bulk divisions. This is an absolute operation bound; integer bit lengths are not bounded. Selecting KK afresh as b2/D\left\lceil b^2/D\right\rceil would not give this conclusion. Outside a proved scalar-necessity domain, the same calculation gives the one-day interval and its sufficient central test, rather than an exact physical time. The implementation and comparisons with the independent band evaluator are recorded in .

The remaining seven-row odd strips

Theorem 30.2 (Seven-row formulas; finite certificate and ordinary period proof). Let n7n\ge7 be odd. For m{6,8,9}m\in\{6,8,9\} put D=2m7D=2m-7 and write n=7+2Dq+2jn=7+2Dq+2j, where 0j<D0\le j<D. Then Tm(P7Pn)=28q+cm(j),T_m(P_7\mathbin{\square}P_n)=28q+c_m(j), where the lists below are indexed from zero: m(cm(0),,cm(D1))6(16,21,26,32,38)8(10,12,16,18,22,25,28,31,34)9(8,10,13,16,18,20,23,26,28,30,33).\begin{array}{c|l} m& (c_m(0),\ldots,c_m(D-1))\\ \hline 6&(16,21,26,32,38)\\ 8&(10,12,16,18,22,25,28,31,34)\\ 9&(8,10,13,16,18,20,23,26,28,30,33). \end{array} The remaining intermediate budget has T7(P7Pn)=2n2T_7(P_7\mathbin{\square}P_n)=2n-2.

Proof. First establish scalar necessity at every length. Substitution of b=3b=3 into (26) and Theorem 7.5 gives the following complete finite complements of its onset: mModd lengths below onsetnumber63277,9,,934473937,9,,1115386577,9,,1879197777,9,,221108.\begin{array}{c|r|c|r} m&M_*&\text{odd lengths below onset}&\text{number}\\ \hline 6&327&7,9,\ldots,93&44\\ 7&393&7,9,\ldots,111&53\\ 8&657&7,9,\ldots,187&91\\ 9&777&7,9,\ldots,221&108. \end{array} For these 296296 cases the finite certificate verifies scalar necessity by the following exhaustive calculation. Invert the exact forward profiles to obtain the two integer inverse tables. Starting from (0,0)(0,0), apply every quota split in (27), retaining the complete coordinatewise maximal frontier at each layer. Monotonicity makes this pruning exact; no low-total mixed state is otherwise omitted. At L=τ1L=\tau-1, minimize (Exu)++(Myv)+\left(E-x-u\right)_++\left(M-y-v\right)_+ over every pair (x,y),(u,v)(x,y),(u,v) of frontier states. In every case its comparison with mm agrees with the scalar test. The certificate retains all final frontiers and the exact central minima; its independent implementation in also agrees with the retained-frontier implementation on every central minimum. There are 2774668927\,746\,689 quota transitions and at most 581581 retained states in any layer. The next odd length in each row has MMM\ge M_*, so the eventual theorem covers every remaining length. This establishes scalar necessity without extrapolating a finite pattern.

We next prove the numerical period for all lengths. Put D=2m7D=2m-7, E=M+1=(7n+1)/2E=M+1=(7n+1)/2. The two profile surpluses equal 33 and 44 on 5zM9,7zM7,5\le z\le M-9,\qquad 7\le z\le M-7, respectively. Requiring both successive survivor inputs to be in these intervals gives Pp(x)=xDP_p(x)=x-D on 0=2m+4xu0=m+M9,1=2m+1xu1=m+M7.\ell_0=2m+4\le x\le u_0=m+M-9,\qquad \ell_1=2m+1\le x\le u_1=m+M-7. Starting from the full color classes, the first paired step leaves x0=MD,x1=MDϵ,ϵ={1,m=6,0,m=7,8,9.x_0=M-D,\qquad x_1=M-D-\epsilon, \qquad \epsilon=\begin{cases}1,&m=6,\\0,&m=7,8,9.\end{cases} Indeed the first phase-zero surplus is 22, followed by 44; the first phase-one surplus is 33 for m=6m=6 and 44 otherwise, followed by 33. The increasing roots have reached their caps already at n=7n=7, while the reflected arguments depend only on mm. No capture occurs in this first pair: its smallest output is 13>m13>m.

Since M24M\ge24, one has pDxpup\ell_p-D\le x_p\le u_p for every allowed budget and length. Thus qp=1+(xpp)/D0,rp=xpqpDq_p=1+\left\lfloor(x_p-\ell_p)/D\right\rfloor\ge0, \qquad r_p=x_p-q_pD give the exact number of further affine pairs and the terminal source. In particular 11r02m+321,8r12m18.11\le r_0\le2m+3\le21,\qquad 8\le r_1\le2m\le18. Every subsequent profile argument is at most 1212. Both reflected root terms are inactive for these arguments when M24M\ge24, and counts strictly decrease because the surpluses are at most 4<m4<m. The complete terminal evolution from (p,rp)(p,r_p) is therefore independent of nn.

Replacing nn by n+2Dn+2D increases MM and each xpx_p by 7D7D, increases each qpq_p by 77, and preserves each rpr_p. Both solo durations consequently increase by exactly 1414. We must also check that the common precentral horizon lies in this invariant terminal evolution. The two numerators defining qpq_p differ by 3ϵ3-\epsilon, which lies strictly between 00 and DD. Hence q1q0{0,1}q_1-q_0\in\{0,1\}. Put Sp=2+2qpS_p=2+2q_p, the terminal entry time. Then S1{S0,S0+2}S_1\in\{S_0,S_0+2\}. The phase-zero terminal evolution takes at least two days since r0>mr_0>m, and the phase-one evolution takes at least one. Therefore L=min(τ0,τ1)1S0,LS11.L=\min(\tau_0,\tau_1)-1\ge S_0, \qquad L\ge S_1-1. Phase zero is already in its invariant tail at LL. Phase one is also in its tail, except possibly at the intermediate day of its last affine pair. In that exception q1=q0+11q_1=q_0+1\ge1; the pair starts from r1+Dr_1+D, so its intermediate count also repeats. The added 1414 days preserve physical-color parity. Thus the scalar central decision repeats, including this possible endpoint, and Tm(P7Pn+2D)=Tm(P7Pn)+28.T_m(P_7\mathbin{\square}P_{n+2D})=T_m(P_7\mathbin{\square}P_n)+28. The displayed constants are the base values at n=7,9,,7+2(D1)n=7,9,\ldots,7+2(D-1), all included in the finite certificate. For m=7m=7 the seven values are 12,16,20,24,28,32,3612,16,20,24,28,32,36; the same period simplifies to 2n22n-2. ◻

These are fixed lists of constants and ordinary floor-and-remainder expressions. The attaining inspections are the compatible prefix preparations and central inspection, or the doubled solo schedule, from Theorem 6.1. Their precentral residuals may be evaluated by Theorem 30.1 with K=16K=16 (already K=2K=2 suffices here). Listing every inspection is, of course, allowed to take time proportional to the schedule.

A shorter ancestry argument and larger scalar domains

Lemma 30.3 (A short-window coordinate bound). Put Γ=m1\Gamma=m-1. If integers q1q\ge1 and 1rb1\le r\le b satisfy q(2rb1)Γq(2r-b-1)\ge\Gamma, every attainable exceptional mixed deficit pair obeys min(x,y)Kq,r:=(q1)m+r(r1).\min(x,y)\le K_{q,r}:=(q-1)m+r(r-1).

Proof. Before solo capture, every inverse output is at most its input, and the joint input sum is at most MM. Indeed the larger solo capacity plus mm is at most MM at every proper transition, including the majority inverse’s special saturation threshold. If fewer than qq days have elapsed, the total deficit is at most (q1)m(q-1)m, which proves the claim. Otherwise suppose the final minimum exceeds Kq,rK_{q,r}. The minimum increases by at most mm in a day, so both outputs in each of the last qq transitions are at least r(r1)+1r(r-1)+1.

Writing the inverse inputs as X,YX,Y, both X,YX,Y and their complements MX,MYM-X,M-Y are at least r(r1)+1r(r-1)+1. The exact inverse formulas therefore lose at least rr on each coordinate. The joint total SS increases by at most m2rm-2r per day. The larger solo capacity AA increases by at least mb1m-b-1, since every proper inverse is at least its input minus b+1b+1. Hence ASA-S increases by at least 2rb12r-b-1 on each of these qq days. Concentration gives AS0A-S\ge0 initially, whereas exceptionality requires AS<ABΓA-S<A-B\le\Gamma finally. This contradicts the assumed inequality for q,rq,r. ◻

Theorem 30.4 (A shorter scalar onset). Let KmK\ge m be any valid minimum-coordinate bound for every exceptional state. Put H=b2+1H=b^2+1, Γ=m1\Gamma=m-1, and J0=max(2K+m+1,K+H),W0=(Γb2)+b+2min(b,Γ),M0=J0+Γ+m(W0+1).\begin{aligned} J_0&=\max(2K+m+1,K+H),\\ W_0&=\left\lceil\frac{\left(\Gamma-b^2\right)_+}b\right\rceil +2\min\bigl(b,\left\lceil\sqrt\Gamma\right\rceil\bigr),\\ M_0&=J_0+\Gamma+m(W_0+1). \end{aligned} If MM0M\ge M_0, the exact full time is given by the scalar criterion (30).

Proof. At any layer whose smaller solo capacity is BJ0B\ge J_0, an exceptional pair has a unique larger coordinate a>Ka>K and a smaller coordinate kKk\le K. Its larger coordinate satisfies aB+1KH+1a\ge B+1-K\ge H+1. Follow its initial-cohort label. The other coordinate is at most K+mK+m on the next day. If the labelled coordinate fell to at most KK, the successor total would be at most 2K+m<J02K+m<J_0, so the successor would not be exceptional. Thus a surviving exception cannot swap its numerical orientation. New mixed births from a pure endpoint are correctly oriented.

Suppose an exception is wrongly oriented: its numerical larger coordinate is its ancestry-secondary. By Lemma 7.3, its corresponding solo capacity is the smaller one, BB. Set =Ba\ell=B-a and F=k=B(a+k)F=\ell-k=B-(a+k). Coordinate domination, concentration and exceptionality give 0,ΓF<0.\ell\ge0,\qquad -\Gamma\le F<0. Allocate uu of the next day’s probes to the smaller coordinate. The larger inverse input is at least HH; the expansive inequality in Lemma 7.8 gives +u\ell'\ge\ell+u. The smaller input is at most MHM-H, so its inverse is the bottom inverse. Its positive output kk' loses at least min(k,b)\min(\left\lceil\sqrt{k'}\right\rceil,b) from its input. Consequently FF+min(k,b).F'\ge F+\min(\left\lceil\sqrt{k'}\right\rceil,b). While the exception remains wrongly oriented, v=Fv=-F and v=Fv'=-F' are positive integers, vΓv\le\Gamma, and kvk'\ge v'. Hence vvmin(v,b).v'\le v-\min(\left\lceil\sqrt{v'}\right\rceil,b). Above b2b^2 this removes at least bb per transition. Once vr2v\le r^2 with rbr\le b, it cannot remain above (r1)2(r-1)^2 for two more transitions: two decrements of at least rr would give vr22r<(r1)2v''\le r^2-2r<(r-1)^2. Thus no wrong exception survives W0W_0 such transitions. A change of faster initial cohort erases the history by fastest ancestry, so it cannot evade this argument.

Let t0t_0 be the first layer with both solo capacities at least J0J_0. Before that layer their maximum is at most J0+Γ1J_0+\Gamma-1, so no capture can bypass it under the displayed bound on MM. At entry the maximum is at most J0+Γ+m1J_0+\Gamma+m-1. For the next W0W_0 days it is at most J0+Γ+m1+msM1J_0+\Gamma+m-1+ms\le M-1. These layers are proper: at a putative first captured layer the same estimate bounds every input by M1M-1, below either saturation threshold. Both solo capacities remain at least J0J_0.

At t0+W0t_0+W_0 every surviving exception is correctly oriented, and the no-swap argument preserves this until the precentral deadline. Its common ancestry-secondary is therefore at most KK. Two such states leave at least M2K>mM-2K>m rooms in that color. Pairs with a nonexceptional state cannot improve the scalar test by Lemma 7.2; the pure endpoints give sufficiency. This proves the assertion. ◻

The original bound K=b2+2m((m1)/(2b+1)+1)K=b^2+2m(\left\lfloor(m-1)/(2b+1)\right\rfloor+1) is always available. An explicit alternative is obtained from q=max(b,m1b1),r=q(b+1)+m12q.q=\max\left(\left\lceil\sqrt b\right\rceil,\left\lceil\frac{m-1}{b-1}\right\rceil\right), \qquad r=\left\lceil\frac{q(b+1)+m-1}{2q}\right\rceil. Here q2q\ge2, rbr\le b, and q(2rb1)m1q(2r-b-1)\ge m-1, so Lemma 30.3 applies. Taking the minimum of a fixed number of such explicit bounds introduces no variable optimization. The theorem also applies directly if, for L=τ1W0L=\tau-1\ge W_0, both capacities at LW0L-W_0 are at least J0J_0.

Theorem 30.5 (Every odd rectangle up to a linear budget). For every odd nw=2b+13n\ge w=2b+1\ge3 and b+1m2bb+1\le m\le2b, the scalar criterion (30) gives the exact full time, attained by the canonical prefix construction.

Proof. For b160b\ge160 choose q=8,r=8(b+1)+m116,K8=7m+r(r1).q=8,\qquad r=\left\lceil\frac{8(b+1)+m-1}{16}\right\rceil, \qquad K_8=7m+r(r-1). The preceding lemma applies and K8mK_8\ge m. Every term of the onset is nondecreasing in mm, so it suffices to consider m=2bm=2b. There r(5b+11)/8r\le(5b+11)/8 and K825b2+966b+3364b22.K_8\le\frac{25b^2+966b+33}{64}\le\frac{b^2}{2}. The last inequality follows from 7b2966b3307b^2-966b-33\ge0 for b160b\ge160. Thus J03b2/2+1J_0\le3b^2/2+1. Also 2b12b1+1b/81,W0b/42;\left\lceil\sqrt{2b-1}\right\rceil\le\sqrt{2b-1}+1\le b/8-1, \qquad W_0\le b/4-2; squaring the positive sides reduces the second inequality to b2160b+3200b^2-160b+320\ge0. It follows that M02b2M_0\le2b^2, below the minimum board value M=2b(b+1)M=2b(b+1). For b=140,,159b=140,\ldots,159, direct substitution at m=2bm=2b gives the positive margins 184,205,226,427,450,473,96,117,324,347,370,583,608,633,852,879,1102,1131,1160,1389.\begin{gathered} 184,205,226,427,450,473,96,117,324,347,\\ 370,583,608,633,852,879,1102,1131,1160,1389. \end{gathered} This proves the theorem for every b140b\ge140.

The minimum-budget theorem covers m=b+1m=b+1. For the remaining pairs 2b1392\le b\le139, b+2m2bb+2\le m\le2b, take the minimum of K8K_8 and the original coordinate bound and form M0M_0 above. Writing n=2b+1+2jn=2b+1+2j gives M=2b(b+1)+(2b+1)jM=2b(b+1)+(2b+1)j. The complete finite complement is therefore 0j<max(0,M02b(b+1)2b+1).0\le j<\max\left(0, \left\lceil\frac{M_0-2b(b+1)}{2b+1}\right\rceil\right). It contains exactly 1985219\,852 triples in 31713\,171 nonempty budget–width intervals. A complete independent integer certificate checks all of them by Lemma 7.2: start at (0,0)(0,0), apply every quota split, retain the two pure endpoints and all mixed exceptions, prune only coordinatewise dominated pairs, and examine every pair of final frontier points in (28). Its exact central decision agrees with the scalar criterion on every input. No temporal acceleration or scalar filtering is used.

The source is , with coverage regenerated by its companion Python runner. The receipt records every interval, full input, exact central cost and source hash. It contains 64437491616\,443\,749\,161 quota transitions and has maximum frontier size 422422. The inverse lookup and per-coordinate maxima in the implementation are exact rearrangements of the displayed recurrence and Pareto pruning. This finite complement, together with the ordinary onset, covers every remaining length. ◻

Corollary 30.6 (A superlinear budget region without a width cutoff). The same exact scalar criterion holds on every odd rectangle when mb+1m\ge b+1 and 27m3b427m^3\le b^4.

Proof. If m2bm\le2b, use the preceding theorem. Otherwise the cubic inequality forces b>216b>216, so b1/612/5b^{1/6}\ge12/5 and b14\sqrt b\ge14. In particular m(5/36)b3/2m\le(5/36)b^{3/2}. Take q=bq=\left\lceil\sqrt b\right\rceil and r=(q(b+1)+m1)/(2q)r=\left\lceil(q(b+1)+m-1)/(2q)\right\rceil. Then rbr\le b, q(2rb1)m1q(2r-b-1)\ge m-1, and r41b/72+3/23b/5,Kq,r449900b2<b22.r\le41b/72+3/2\le3b/5, \qquad K_{q,r}\le\frac{449}{900}b^2<\frac{b^2}{2}. Also m5b2/504<b2/100m\le5b^2/504<b^2/100. Hence J03b2/2+1J_0\le3b^2/2+1, W02m+2W_0\le2\sqrt m+2, and 2m3/22b2/27<2b2/52m^{3/2}\le2b^2/\sqrt{27}<2b^2/5. Therefore M0J0+2m3/2+4m1<9750b2<2b2.M_0\le J_0+2m^{3/2}+4m-1 <\frac{97}{50}b^2<2b^2. Every board satisfies this onset, proving the corollary. ◻

These theorems settle the scalar decision and provide optimal strategies on the stated families. Their solo clocks still require O(b)O(b) arithmetic stages in general. An absolute bounded expression follows only in a separately proved numerical region, such as the intersection with Theorem 30.1; the decision theorem alone does not remove that numerical distinction.

Fixed numerical expressions for further even-area rectangles

Uniform numerical consequences in widths 24 and 25

The three- and nine-threshold recurrences can be evaluated uniformly in the longer side for the next two widths. A fixed entrance and exit surround an arbitrarily long plateau whose transfer is explicit. The joint physical restriction in Theorem 29.13 is essential to these bounds.

Lemma 31.1 (A backward frontier after the joint restriction). Consider a rectangle with 2h2h rooms, both sides at least 2424, and budget 1313. Use either necessary model of Theorems 29.1 and 29.2, with its guarded merger. Let BtB_t be its capture frontier, and let RtR_t be its backward frontier for reaching a state of size at most 66. Suppose that, for an integer N1N\ge1, maxB29<h,maxBNh112,maxRNh112.\max B_{29}<h,\qquad \max B_N\le h-112,\qquad \max R_N\le h-112. Then every full-board belief after L=N+28L=N+28 steps has at least h+7h+7 rooms, and T132N+58T_{13}\ge2N+58.

Proof. Write ata_t for the physical joint belief size minus hh. The guarded merger maps the history to a model history while at>13a_t>13, including the transition at its first crossing to at13a_t\le13. Such a crossing by time 2828 would permit a model capture from the full size hh by time 2929, contradicting the first hypothesis.

Theorem 29.13 gives a28h111a_{28}\ge h-111. If the first crossing to at most 1313 occurred at some tL1t\le L-1, its merged continuation and one clearing inspection would give a model capture from that time-2828 feature within t28+1Nt-28+1\le N days. This contradicts maxBNh112\max B_N\le h-112. The merger is therefore valid through time LL. A value aL6a_L\le6 would contradict the bound on RNR_N, so aL7a_L\ge7.

In any proposed schedule of length 2L+12L+1, the first LL inspections and the last LL inspections read backward each leave a belief of size at least h+7h+7 at the middle day. Undirected walk reversal justifies the second belief. Their intersection has at least 2(h+7)2h=142(h+7)-2h=14 rooms, and the middle inspection cannot cover it. An avoiding walk exists, proving T132L+2=2N+58T_{13}\ge2L+2=2N+58. ◻

Corollary 31.2 (A one-day bracket for even lengths at width 24). For every integer n24n\ge24, T13(P24Pn)24n370.T_{13}(P_{24}\mathbin{\square}P_n)\ge24n-370. For even n24n\ge24 this gives the numerical bracket 24n370T13(P24Pn)24n369.24n-370\le T_{13}(P_{24}\mathbin{\square}P_n)\le24n-369.

Proof. Set h=12n288h=12n\ge288. Use the original, unrefined corner model, so the unrestricted surplus in Theorem 29.1 is 1212 for every corner pair. For its capacities, direct substitution gives (11+Fij(11))ij=(11012185132102701128557),(Gij(11))ij=(6581908210011010112199).(11+F_{ij}(11))_{ij}= \begin{pmatrix}110&121&85\\132&102&70\\112&85&57\end{pmatrix}, \qquad (G_{ij}(11))_{ij}= \begin{pmatrix}65&81&90\\82&100&110\\101&121&99\end{pmatrix}. Thus Sij(z)12S_{ij}(z)\ge12 for z133z\ge133, and Hij(d)12H_{ij}(d)\ge12 for d122d\ge122, for every i,ji,j.

Start the capture and half-budget frontiers at B0=(0,1,1),R0=(6,6,6).B_0=(0,-1,-1),\qquad R_0=(6,6,6). The fixed first 3636 substitutions in (161) give tBtRt29(124,125,125)(125,125,125)35(133,134,134)(134,134,134)36(135,135,135)(135,135,135).\begin{array}{c|c|c} t&B_t&R_t\\ \hline 29&(124,125,125)&(125,125,125)\\ 35&(133,134,134)&(134,134,134)\\ 36&(135,135,135)&(135,135,135). \end{array} These substitutions are independent of h288h\ge288: every target used before step 3636 has size at most 134134, hence at least 154>121154>121 holes. The high branch cannot improve surplus 1212, and all state caps are inactive. The entries follow by substituting the small quadratic capacities at the fixed surpluses 0,,120,\ldots,12. Both complete entrance traces are retained in .

If all three thresholds equal aa, with 135ah122135\le a\le h-122, both capacity bounds apply. Every corner pair has minimum surplus exactly 1212, and (161) becomes (a,a,a)(a+1,a+1,a+1).(a,a,a)\longmapsto(a+1,a+1,a+1). Both frontiers therefore reach the all-(h121)(h-121) vector at time 36+(h121135)=h22036+(h-121-135)=h-220.

Write a frontier as (hd0,hd1,hd2)(h-d_0,h-d_1,h-d_2). From this point the small branch is inactive below surplus 1212, since every target is at least h121167>132h-121\ge167>132. With the state caps inactive, the exact update is the hh-independent expression dc=minic,0j2(dj+min(Hij(dj),12))13.d'_c=\min_{i\le c,\,0\le j\le2} \bigl(d_j+\min(H_{ij}(d_j),12)\bigr)-13. Its next seven substitutions are tdtd0(121,121,121)4(115,115,115)1(120,120,119)5(114,114,113)2(118,118,118)6(112,112,112)3(117,117,116)7(111,111,110).\begin{array}{c|cc|c} t&d&t&d\\ \hline 0&(121,121,121)&4&(115,115,115)\\ 1&(120,120,119)&5&(114,114,113)\\ 2&(118,118,118)&6&(112,112,112)\\ 3&(117,117,116)&7&(111,111,110). \end{array} All deficits remain at least 110110, so the stated absence of state caps holds throughout. Consequently, for N=h214N=h-214, BN=RN=(h112,h112,h112).B_N=R_N=(h-112,h-112,h-112). The initial table also gives maxB29=125<h\max B_{29}=125<h. Lemma 31.1 proves T132(h214)+58=24n370T_{13}\ge2(h-214)+58=24n-370. The upper bound for even lengths is Corollary 29.16. ◻

The arithmetic certificate for this corollary derives the entrance and exit directly from the quadratic inequalities, independently of the inverse-root formulas. It also compares every state membership in 7676 backward layers for both seeds with the full original model graph on the 2424-square: all 130872130\,872 memberships agree. The varying-length conclusion follows from the plateau identity, not from testing several lengths.

Corollary 31.3 (An exact value at width 25). For every even n26n\ge26, T13(P25Pn)=50n925.T_{13}(P_{25}\mathbin{\square}P_n)=50n-925.

Proof. Put h=25n/2325h=25n/2\ge325 and use the nine-feature model of Theorem 29.2. Its indices are (c,e)(c,e), and its closed surplus is σ\sigma; the original surplus is σ+δ\sigma+\delta, where δ=vi0\delta=v-i\ge0. The unrestricted closed surplus is 1313, with the critical value 1212 allowed for (v,j)=(2,0)(v,j)=(2,0). Direct substitution in the capacities gives maxv,u,j(12+P(v,u,j;12))=156,maxA,BFAB(12)=144,maxj,v1F2j,2v(12)=132,maxvF0,2v(12)=132,maxA,BFAB(11)=121.\begin{aligned} \max_{v,u,j}\bigl(12+P(v,u,j;12)\bigr)&=156,& \max_{A,B}F_{AB}(12)&=144,\\ \max_{j,\,v\le1}F_{2-j,2-v}(12)&=132,& \max_v F_{0,2-v}(12)&=132,\\ \max_{A,B}F_{AB}(11)&=121. \end{aligned} All corner indices range from zero to two, with uju\le j. Monotonicity extends these bounds to smaller surpluses.

Initialize B0(c,e)=0B_0(c,e)=0 and R0(c,e)=6R_0(c,e)=6. The fixed first 7070 substitutions of (162) give B70(c,e)=R70(c,e)=157for all (c,e).B_{70}(c,e)=R_{70}(c,e)=157\qquad\text{for all }(c,e). Every target used in this entrance has size at most 157157, hence at least 168>144168>144 holes. The high branch is inactive below closed surplus 1313, all state caps are inactive, and no all-radius band applies: each such band has at most 1211=13212\cdot11=132 holes. Thus these fixed substitutions are the same for every h325h\ge325. The two complete traces, obtained directly from PP and the fixed surpluses 0,,130,\ldots,13, are recorded in .

For 157ah134157\le a\le h-134, let E(a)E(a) be the all-aa vector, and let C(a)C(a) equal aa when c=0,1c=0,1 and a+1a+1 when c=2c=2, independently of ee. We claim the exact two-step identity E(a)C(a)E(a+1). E(a)\longmapsto C(a)\longmapsto E(a+1). (172) For the first step, the low branch excludes every σ12\sigma\le12 since a>156a>156, and the high branch excludes every σ11\sigma\le11 since there are at least 134>121134>121 holes. If v1v\le1, the high branch also excludes σ=12\sigma=12 by the bound 132132. A source with c1c\le1 therefore always pays original surplus at least 1313: when v=2v=2, it has δ=vi1\delta=v-i\ge1; otherwise its closed surplus is at least 1313. Its threshold cannot increase. A source with c=2c=2 attains an increase of one by choosing i=v=2i=v=2, u=j=0u=j=0, and critical surplus 1212. Every source attains the unchanged threshold by choosing i=v=u=j=0i=v=u=j=0 and surplus 1313. These choices satisfy survivor maximality and the deletion charge.

For the second step, targets with j=0,1j=0,1 still have size aa, so surplus at least 1212 bounds their contribution by a+1a+1. Targets with j=2j=2 have size a+1a+1 and at least 133133 holes. Their high capacity at σ=12\sigma=12 is at most 132132, so they require closed surplus at least 1313 and likewise contribute at most a+1a+1. Equality in every source class is attained with (j,v)=(2,0)(j,v)=(2,0), i=u=0i=u=0, and surplus 1313. All deficits in these two steps are at least 133133, so no band filter intervenes; all state caps are inactive and the deletion charges are at most 4134\le13. This proves (172).

There are h290h-290 such pairs from E(157)E(157) to E(h133)E(h-133). Both frontiers reach the latter vector at time 2h5102h-510. Subsequent target sizes are at least h133192>156h-133\ge192>156, so the low branch remains inactive below closed surplus 1313. In deficit coordinates every update now depends only on the fixed high capacities, critical exception, and all-radius bands, independently of hh. Nineteen fixed substitutions starting from the all-133133 deficit vector give, at steps 1818 and 1919, d18=(113,113,113,112,112,112,112,112,112),d19=(112,112,112,111,111,111,110,110,110),\begin{aligned} d_{18}&=(113,113,113,112,112,112,112,112,112),\\ d_{19}&=(112,112,112,111,111,111,110,110,110), \end{aligned} in feature order (0,0),(0,1),(0,2),(1,0),,(2,2)(0,0),(0,1),(0,2),(1,0),\ldots,(2,2). Every earlier deficit is at least 112112. The full exit table is in the same certificate; it checks all radii 2,,122,\ldots,12 directly. Deficits remain at least 110110, so no state cap is active. It follows that for N=2h492N=2h-492, maxBN=maxRN=h112.\max B_N=\max R_N=h-112. Also maxB29maxB70=157<h\max B_{29}\le\max B_{70}=157<h, by monotonicity of the capture sets. Lemma 31.1 would give the preliminary bound 50n92650n-926. We now use the persistent radius information of Theorem 29.10 to gain one day.

The following fixed terminal certificate is the additional input. In the persistent model with the 2525-by-2626 radius thresholds, none of the three features of size 157157 with c=0c=0 and e=0,1,2e=0,1,2 clears in 7070 days, even when both incoming radii are unknown. Their minimum time is 7171. The independent verifier retains the complete grouped-radius reachability set, without radius dominance; its receipt is . The old 7070-day frontier already bounds every successful suffix state by size 157157. At those sizes there are at least 168168 holes, so the high branches and their radius bands are inactive. Freezing the larger-board radius thresholds at n=26n=26 and replacing radii at least 4949 by an unknown radius only weakens the necessary model. Thus the same finite low graph and exclusion apply at every h325h\ge325.

The persistent 7070-day capturable set is consequently contained in the numerical hull DD, with threshold 156156 for c=0c=0 and 157157 for c=1,2c=1,2, independently of ee. This is a containing hull, not an assertion of interval closure for flagged states. One old nine-frontier predecessor maps this hull to E(157)E(157). Indeed the maximum low target capacity at closed surplus 1111 is 132132, and at surplus 1212 it is 156156. Targets of size 157157 require closed surplus 1313; the sole critical exception (v,j)=(2,0)(v,j)=(2,0) instead uses the hull’s target 156156, with original surplus at least 1212. Every predecessor contribution is therefore at most 157157. Equality for every source feature is attained using target (j,v)=(1,0)(j,v)=(1,0) of size 157157, i=u=0i=u=0, and surplus 1313.

We may therefore start the necessary numerical hull E(157)E(157) at time 7171, apply the same h290h-290 plateau pairs and then the first 1818 exit steps. At the model deadline N=2h491N=2h-491 its maximum is h112h-112. No persistent state of size at least h111h-111 can clear within NN days, whatever its incoming radii.

Put L=N+28=2h463L=N+28=2h-463 and again write ata_t for joint belief size minus hh. An early first crossing to at13a_t\le13 by time 2828 would contradict B29<hB_{29}<h. The joint boundary theorem gives a28h111a_{28}\ge h-111. A first crossing by any tL1t\le L-1 would give a persistent-model capture from that state in at most t28+1Nt-28+1\le N days, a contradiction. Hence aL1>13a_{L-1}>13. The next merged survivor is nonempty, and the perfect matching ensures aL>0a_L>0.

A proposed 2L2L-day full strategy now fails on an even cut. Its first LL inspections and moves leave more than hh rooms. Read its last LL inspections backward: after L1L-1 moves the belief has more than h+13h+13 rooms, and the last inspection still leaves more than hh. These two beliefs occupy the same cut in a graph of 2h2h rooms, so their avoiding walks intersect and concatenate. Thus T132L+1=50n925T_{13}\ge2L+1=50n-925.

For attainment use the construction underlying Proposition 21.2. At b=12b=12, its constant is L12=46L_{12}=46, and both initial prefix phases reach 157157 rooms after t=46+2h41222=25n532t_*=46+2h-4\cdot12^2-2=25n-532 steps, in opposite current phases. All subsequent counts are at most 157157 and have at least 168168 holes, so the two terminal profiles are independent of nn. Their fixed evaluations take 7070 and 7171 days; the faster phase’s last shot has size 22. These evaluations are recorded in . Choose the faster initial phase. Its solo duration is 25n46225n-462. Reflection along the even side supplies the opposite cohort, and the two central residuals have union at most 4134\le13. The resulting full strategy has length 2(25n462)1=50n9252(25n-462)-1=50n-925. ◻

The width-2525 certificate evaluates both fixed portions directly through the quadratic inequalities and independently compares each substitution with the inverse-root nine-threshold update. The unbounded part is the two-step identity (172). The additional persistent terminal exclusion makes width 2525 exact; the width-2424 statement remains a one-day bracket.

The quadratic-edge budget curve

Theorem 31.4 (The first budget below the strict quadratic threshold). Let w=2r6w=2r\ge6, n2rn\ge2r, h=rnh=rn, k=r(r1)k=r(r-1) and s=r(r2)s=r(r-2). Define j=max(0,hks3s),z=h(j+1)sk1,c=z+z.j=\max\left(0,\left\lfloor\frac{h-k-s-3}{s}\right\rfloor\right),\qquad z=h-(j+1)s-k-1,\qquad c=z+\left\lceil\sqrt z\right\rceil. Then, for every such r,nr,n, Tk(P2rPn)=2(j+3)1{2ck}.T_k(P_{2r}\mathbin{\square}P_n)=2(j+3)-\mathbf{1}_{\{2c\le k\}}. This is an absolute fixed-size numerical expression with a directly specified optimal strategy.

Proof. The scalar first step from hh is hs1h-s-1: its reflected pronic root is r1r-1, and its increasing root is saturated. All later reflected roots remain saturated, so the scalar profile is L(q)=q+min(q,r)L(q)=q+\min(\left\lceil\sqrt q\right\rceil,r). Its full-budget map is xxsx\mapsto x-s for xk+s+2x\ge k+s+2. Exactly jj such steps follow the first one; the remaining source is k+zk+z. Here z1(modr),r1zs1.z\equiv-1\pmod r,\qquad r-1\le z\le s-1. The next count is ck2c\le k-2 and the following inspection clears it. No earlier capture was omitted: the first source after the initial step is at least k+3r1k+3r-1, and the last affine source is still above kk. Thus the scalar duration is τ=j+3\tau=j+3, and the symmetric scalar lower bound is the displayed expression.

Choose the initial anchored-prefix phase (n+1)mod2(n+1)\bmod2. After deleting kk, its survivor is the full prefix through diagonal n1n-1, of size hkh-k. The preceding opposite diagonals have rr fewer rooms and the new last diagonal has 2r12r-1, so the first actual neighborhood is hs1h-s-1. The next jj steps lie in the common anchored plateau and decrease by ss. The final survivor zz has near-corner neighborhood either c=z+R(z)c=z+R(z) or c=z+Q(z)c'=z+Q(z), with RQR+1R\le Q\le R+1 and ck1c'\le k-1. This strategy therefore has the same duration τ\tau.

If 2c<k2c<k, then kk is even and ck/2c'\le k/2, so reflection attains 2τ12\tau-1. If 2c>k2c>k, the doubled solo strategy attains 2τ2\tau. Only c=k/2c=k/2 needs attention. The congruence for zz rules this out when rr is odd. For r=2ur=2u it forces R(z)=u+1R(z)=u+1 and z=2u(u1)1z=2u(u-1)-1. The root inequalities hold only for u=3,4u=3,4, hence r=6,8r=6,8. At r=6r=6, Q(11)=R(11)=4Q(11)=R(11)=4. At r=8r=8, z=23z=23, R=5R=5 and Q=6Q=6; its defining length is n=6j+16n=6j+16. The final phase is jmod2j\bmod2, so only positive odd jj needs a change of shape.

For that class use coordinates 0x<160\le x<16, 0y<n0\le y<n. After jj prefix steps the same color-zero set AA of size 127127 is reached on every board: A={(x,y):x+y even, x+y22}{(0,22)},A=\{(x,y):x+y\text{ even},\ x+y\le22\}\setminus\{(0,22)\}, with intersection with the board understood. Its column heights are 20,21,20,19,,720,21,20,19,\ldots,7. The set U={(x,y):x+y even, y8}{(0,8)}U=\{(x,y):x+y\text{ even},\ y\le8\}\setminus\{(0,8)\} has 7171 rooms and lies in AA. Inspect AUA\setminus U, using 5656 probes. Its neighborhood is the 7979-room set B={(x,y):x+y odd, y9}{(0,9)}.B=\{(x,y):x+y\text{ odd},\ y\le9\}\setminus\{(0,9)\}. Inside it take the 2525-room opposite-corner triangle Q={(x,y):x+y odd, (15x)+y8}Q=\{(x,y):x+y\text{ odd},\ (15-x)+y\le8\} and delete (14,7),(15,8)(14,7),(15,8) to leave VV of size 2323. Inspect BVB\setminus V, again using 5656 probes. The nonempty column heights of VV at x=7,,15x=7,\ldots,15 are 0,1,2,3,4,5,6,5,60,1,2,3,4,5,6,5,6; those of its neighborhood at x=6,,15x=6,\ldots,15 are 0,1,2,3,4,5,6,7,6,70,1,2,3,4,5,6,7,6,7. Thus N(V)=28|N(V)|=28. The two-day transition is 1277928127\to79\to28, and the next shot clears. Reflection across the short side switches colors, so the central union has at most 5656 rooms. The resulting full duration 2j+52j+5 equals the scalar lower bound, closing the last residue. ◻

The arithmetic audit is . The exceptional physical transition is independently replayed in and . The ordinary plateau and fixed-set construction supply the unbounded claims; the finite examples are verification receipts.

Fixed-block numerical bounds at arbitrary even-width budgets

Theorem 31.5 (Absolute block bounds for the model and physical clocks). Fix K1K\ge1 independently of the inputs. Let w=2r4w=2r\ge4, nwn\ge w, h=rnh=rn, r+2k<hr+2\le k<h, s=krs=k-r and δ=s1\delta=s-1. If Kδr2K\delta\ge r^2, a capture or half-budget backward frontier of the critical three-threshold model, at any deadline or at its first admission of the full state, uses at most 3K+33K+3 ordinary three-coordinate updates and one bulk division. A physical anchored prefix clock, including its last shot or a prescribed-day residual, uses at most 2K+12K+1 ordinary updates and one bulk division under the weaker hypothesis Ksr2Ks\ge r^2.

Thus K=16K=16 gives explicit lower and physical upper expressions using at most 168168 such blocks and four divisions in total. Equality of the resulting bounds specifies an exact numerical subfamily and an optimal physical strategy; a strict gap remains a bracket.

Proof. Use Theorem 29.1 with unrestricted cap r+1r+1 and critical cap rr at (i,j)=(1,1)(i,j)=(1,1). The extra cap at (2,0)(2,0) when n=2r+1n=2r+1 is retained. After the first update the thresholds obey B0B1B2,B1B0+1,B2B1+1.B_0\le B_1\le B_2,\qquad B_1\le B_0+1, \qquad B_2\le B_1+1. For the spread bound, delete one current survivor corner when moving to the next smaller source class and increase surplus by one. Direct substitution in the capacities gives Fi1,j(z+1)Fij(z)1F_{i-1,j}(z+1)\ge F_{ij}(z)-1 and Gi1,j(z+1)Gij(z)G_{i-1,j}(z+1)\ge G_{ij}(z), preserving both alternatives. Removing either critical corner pattern permits the raised unrestricted surplus r+1r+1. The state caps differ by one. If the survivor had size one, deletion leaves zero and the bound is immediate.

Choosing survivor corner class zero and target threshold B2B_2 with unrestricted surplus r+1r+1 gives B2min(h,B2+δ).B'_2\ge\min(h,B_2+\delta). The first update has B2kB_2\ge k. Therefore, until full admission, after t1t\ge1 updates one has B2tδ+r+1B_2\ge t\delta+r+1 and B0tδ+r1B_0\ge t\delta+r-1. When B2=hB_2=h, the spread forces the absorbing cap vector (h2,h1,h)(h-2,h-1,h).

Set A=r2+r+1A=r^2+r+1, H=r2+1H=r^2+1 and U=hmax(H,s+1)U=h-\max(H,s+1). On a source vector (x,y,z)(x,y,z) whose coordinates all lie in [A,U][A,U], the low and high capacity roots exceed rr, and the state caps are inactive. The exact update is (x,y,z)(z+δ,max(z,y+1)+δ,max(z,y+1)+δ).(x,y,z)\longmapsto (z+\delta,\max(z,y+1)+\delta,\max(z,y+1)+\delta). The extra (2,0)(2,0) exception does not alter this formula: for n2r+1n\le2r+1, Ur2+r1<AU\le r^2+r-1<A, so the interval is empty. Every nonempty common interval has only the (1,1)(1,1) exception. In at most two updates the vector is normalized to V(a)=(a1,a,a)V(a)=(a-1,a,a), unless it already exits the interval, and V(a)V(a+s)V(a)\mapsto V(a+s) there.

At most 2K2K conditional updates suffice to reach B0AB_0\ge A or admit the full state. After at most two normalizations, use 1+(Ua)/s1+\left\lfloor(U-a)/s\right\rfloor translations at once when the source is V(a)V(a) in the common interval. Upon exiting, the remaining distance hB2h-B_2 is at most max(r2,s)\max(r^2,s), so at most K+1K+1 further updates suffice. The total is 3K+33K+3. An exhausted deadline stops the conditional blocks and truncates the bulk division; an empty interval simply omits that bulk operation.

For physical prefixes, Lemma 29.14 gives gp(q)=q+rg_p(q)=q+r in both phases for (r1)2+1qhr2+r1(r-1)^2+1\le q\le h-r^2+r-1. Lemma 12.2 also gives gp(q)q+rg_p(q)\le q+r globally: the height-plus-one envelope adds at most one room in each of the rr transverse columns. Thus a positive full-budget step decreases size by at least ss, and is exactly xxsx\mapsto x-s on k+(r1)2+1xk+hr2+r1.k+(r-1)^2+1\le x\le k+h-r^2+r-1. The full starting excess above this interval is at most r2r^2, so KK ordinary steps suffice before a single bulk division. The remaining size is at most s+r2s+r^2, so K+1K+1 more steps suffice. Retain the parity of the number of bulk steps and the last preinspection count. This proves the physical block bound, also for arbitrary prefix sizes and prescribed deadlines.

Let τ\tau be the model’s first admission time of (h,2)(h,2) and Rτ1R_{\tau-1} the backward frontier with seed (k/2)3(\left\lfloor k/2\right\rfloor)^3. The guarded-merger clock gives L=2τ1+1{Rτ1(2)<h}.L=2\tau-1+\mathbf{1}_{\{R_{\tau-1}(2)<h\}}. For each physical starting phase let tpt_p and apa_p be the prefix duration and last shot. Reflection across the even short side gives U=minp=0,1(2tp1{2apk}).U=\min_{p=0,1}\bigl(2t_p-\mathbf{1}_{\{2a_p\le k\}}\bigr). The minimum with the explicit envelope upper of Section 13.1 is also valid. Two model and two prefix evaluations use 2(3K+3)+2(2K+1)=10K+82(3K+3)+2(2K+1)=10K+8 blocks, hence 168168 at K=16K=16. Whenever L=UL=U, the corresponding physical construction is optimal. No model path is asserted to be physically attainable when the bounds differ. ◻

The ordinary update, normalization and phase arithmetic are audited in : 68116\,811 deadline comparisons on 140140 finite inputs agree with the direct recurrences, along with large-length checks. The absolute block count is the theorem above, rather than an extrapolation from those comparisons.

Formal verification, reproducibility, and open problems

The shared canonical development comprises 83 source modules using Lean 4.33.1 and Std. Its main and parked application roles are listed separately in the accompanying source manifest; these are not 83 complete rectangle classification theorems. The rectangle package contains 43 modules; the parked package contains 51, with 11 shared between them. The split checks source hashes and import closure against the existing compilation receipt; it is not a new compilation or formalization. There are no admitted proofs, project-specific mathematical axioms, or trusted external solver results. Finite certificates are reduced by the Lean kernel. Printed dependencies use only propositional extensionality, classical choice, and quotient soundness where needed.

Complete classifications and reusable formal theorems

Two families in the rectangle scope have complete physical-game classifications:

  • PathClassification covers every positive path length and budget, including the one-room and one-probe cases.

  • LadderGame covers every two-row length and budget, including the single-edge degeneration.

The complete three-cube and four-cube classifications are preserved in the parked companion and use the same authoritative Lean source tree. The two rectangle classifications each include feasibility, optimal time, and attaining schedules against all legal target walks. Independent semantic reviews check the physical graph, daily budget, and indexing: formal round zero is the first inspection, so last-round index tt means t+1t+1 days.

The reusable developments formalize the following separate layers. BeliefSemantics equates possible positions with avoiding walks; CaptureRecurrence verifies the winning recurrence and losing traps. StrategyCompression compares whole strategies, including arbitrary daily budgets. Product lifting and finite stabilization have reusable formal proofs. The concrete square operators used for the four-cube theorem are documented in the companion. The generic complement/inverse identity in BipartiteProfileDuality uses actual attained graph minima, with inverse arithmetic in ProfileInverse. SurvivorEnvelope connects local column certificates to actual walk capture and global daily budgets. MiddleIntervalTransfer proves the exact bounded-counter interval theorem and constructs its legal daily allocations. RootConvolution defines the pronic and square roots internally and proves the exact two-candidate interval minimum. The more general ConvexCapacityConvolution constructs least inverses of monotone unbounded discrete-convex integer capacities and derives endpoint maximization from increasing increments. It proves an attained two-candidate interval minimum, with concrete instances for the square, pronic, and every punctured capacity ChC_h of (13). The triangular identity and the convexity of the maximum and truncated quadratic are proved inside Lean. ProbeLocalization proves on arbitrary directed graphs that retaining inspections only in the backward cone of unwanted endpoints preserves the final possible-position set exactly.

FastestAncestry proves concentration, low-total persistence, fastest-cohort ancestry after a pure reset, and the resulting midpoint obstruction for two deficit recurrences. Its inverse-concentration, proper-input, and bounded-secondary trace hypotheses are explicit. ClippedPyramidErosion uses actual nonnegative cylinder cells: it proves neighborhood inclusion after clipped erosion and the exact loss of occupied bottom roots, including empty fibers and both finite ends. Its room lists have unique entries and the asserted physical cardinalities.

Ordinary proofs and partial formalization

The other graph classifications and unbounded geometric theorems in this manuscript have ordinary proofs, not complete Lean proofs. This includes three through five rows; both general rectangle profile theorems; the uniform one-day determination and large-budget formulas; the rectangle applications of the cylinder time and eventual-period arguments; and fixed-deadline semilinearity. The companion separately states the ordinary proof boundary for higher-dimensional applications. The physical application of the formal middle-transfer lemma and the geometric bounded-interface application of probe localization are also ordinary proofs. The bounded odd frontier and its acceleration are not claimed to be Lean-verified by the root-convolution module.

Some arithmetic components of these results are formalized separately: the five-row scalar ranks, deficit consequences, four-probe transition and equality lemmas, three finite large-budget bounds, and the uniform minimum-budget scalar potential in UniformOddRank. These checks do not formalize their geometric hypotheses or the full unbounded classifications. Likewise, formal survivor-envelope semantics does not formalize the subsequent semilinearity argument. The uniform all-width minimum-budget formula also uses ordinary proofs of the rectangle inverse formulas, fresh-secondary clock, and physical midpoint reduction; FastestAncestry does not supply these instantiations. The punctured-quadrant and conditional half-strip neighborhood theorems, their every-size geometric attainment, and the corner propagation delays remain ordinary mathematics despite the formal inverse-capacity arithmetic. The erosion module does not prove the distance thresholds ensuring root occupancy, prescribed-size ideal enlargement, or maximal-erosion corrections at the top boundary. The detailed module-to-theorem map in lean/README.md records these distinctions. Successful compilation must not be described as formal verification of every theorem in the manuscript.

Reproduction and open scope

The companion at https://angelraychev.com/princess/ provides the presentation, complete proof text, formal sources, and mathematical archive. The archive includes independent physical replays, finite certificates, counterexample searches, and dated research notes. The verification receipt records the compiler version, exact source hashes, dependency order, axiom reports, and exit codes. Reproduce the complete check with python3 src/check_lean.py --lean /path/to/lean from the archive root. Compilation is sequential with one worker and requires no extra Lean packages.

The numerical target is an absolute O(1)O(1) number of standard numerical operations for Tk(a,b)T_k(a,b), independent of all three parameters, together with directly specified optimal inspections. The width-only minimum- budget clock is an evaluation gap under this criterion, even though it proves exact time and its dependence on length. The bounded odd frontier, eventual solo criteria, effective affine periods and finite boundary representations also retain parameter-dependent evaluation obligations. On shorter odd rectangles, the simpler proposed middle-day decision is not established in all intermediate budgets. On even-area rectangles, the boundary optimization is not uniformly evaluated. A proof of an optimal full-board strategy family would suffice; arbitrary partial-state optimality is not required.

The split companion at https://angelraychev.com/princess/extensions/ is parked. Its open higher-dimensional, general-cylinder and independent partial-state questions are not requirements for completing the rectangle paper. The dated combined release remains available as a historical archive.

Research and writing provenance

The new finite-board corner and erosion bounds, critical extensions, near-extremal localization, and merger theorems are ordinary proofs. Their finite applications use independently checked integer certificates and physical inspection replays. None of these newly added arguments has a complete physical-game Lean formalization in this release. The unchanged formal sources retain their source-specific earlier compiler evidence.

The path results originated in the author’s October 2019–March 2020 work. Reconstructing shorter proofs does not reassign that credit. The 2026 grid and box investigation, new arguments, experiments, formal developments, and manuscript were developed with substantial assistance from Astra 6 through the Codex harness. The research log distinguishes recovered results, established literature, new derivations with unverified priority, failed approaches, and open claims. The human author retains responsibility for the manuscript and any eventual submission.

Acknowledgments

The author thanks Dimitar Rusev for writing the preliminary section on monotonicity (Section 3) in the 2020 student-conference version of this work. By agreement, his contribution to that version is acknowledged here; both authors remain credited in its bibliographic entry. The author also thanks his mathematics teacher and mentor Dimitar Dimitrov, who encouraged him to pursue mathematical research and guided his early work.

Abramovskaya, Tatjana V., Fedor V. Fomin, Petr A. Golovach, and Michał Pilipczuk. 2016. “How to Hunt an Invisible Rabbit on a Graph.” European Journal of Combinatorics 52: 12–26. https://doi.org/10.1016/j.ejc.2015.08.002.
Beluhov, Nikolay, and Emil Kolev. 2017. “Search for a Moving Target in a Graph.” Electronic Notes in Discrete Mathematics 57: 39–46. https://doi.org/10.1016/j.endm.2017.02.008.
Ben-Ameur, Walid, Harmender Gahlawat, and Alessandro Maddaloni. 2026. “Hunting a Rabbit: Complexity, Approximability and Some Characterizations.” Theoretical Computer Science 1075: 115946. https://doi.org/10.1016/j.tcs.2026.115946.
Bezrukov, Sergei L., and Oriol Serra. 2002. “A Local–Global Principle for Vertex-Isoperimetric Problems.” Discrete Mathematics 257 (2–3): 285–309. https://doi.org/10.1016/S0012-365X(02)00431-4.
Bolkema, Jessalyn, and Corbin Groothuis. 2019. “Hunting Rabbits on the Hypercube.” Discrete Mathematics 342 (2): 360–72. https://doi.org/10.1016/j.disc.2018.10.011.
Britnell, John R., and Mark Wildon. 2013. “Finding a Princess in a Palace: A Pursuit-Evasion Problem.” The Electronic Journal of Combinatorics 20 (1): P25. https://doi.org/10.37236/2296.
Dissaux, Thomas, Foivos Fioravantes, Harmender Gahlawat, and Nicolas Nisse. 2025. “Further Results on the Hunters and Rabbit Game Through Monotonicity.” Information and Computation 305: 105302. https://doi.org/10.1016/j.ic.2025.105302.
Ginsburg, Seymour, and Edwin H. Spanier. 1966. “Semigroups, Presburger Formulas, and Languages.” Pacific Journal of Mathematics 16 (2): 285–96. https://doi.org/10.2140/pjm.1966.16.285.
Haslegrave, John. 2014. “An Evasion Game on a Graph.” Discrete Mathematics 314: 1–5. https://doi.org/10.1016/j.disc.2013.09.004.
Kamenetsky, Dmitry. 2018a. Entry A301337: Number of Steps Required in the Worst Case for Two Knights to Find the Princess in a Castle with nn Rooms Arranged in a Line. The On-Line Encyclopedia of Integer Sequences. https://oeis.org/A301337.
Kamenetsky, Dmitry. 2018b. Entry A301426: Number of Steps Required in the Worst Case for Three Knights to Find the Princess in a Castle with nn Rooms Arranged in a Line. The On-Line Encyclopedia of Integer Sequences. https://oeis.org/A301426.
Körner, János, and Victor K. Wei. 1984. “Odd and Even Hamming Spheres Also Have Minimum Boundary.” Discrete Mathematics 51 (2): 147–65. https://doi.org/10.1016/0012-365X(84)90068-2.
Raychev, Angel. 2020. “Optimal Strategies for Finding a Princess in a Linear Table.” Unpublished manuscript.
Raychev, Angel, and Dimitar Rusev. 2020. “Optimal Strategies for Finding a Princess in a Linear Graph.” Unpublished manuscript.
References from the historical combined manuscript

Moved reference: a-finite-word-certificate-for-every-even-length

Moved reference: a-side-of-length-two

Moved reference: a-two-component-integer-potential

Moved reference: a-uniform-height-strategy-for-cylinders

Moved reference: an-exact-three-dimensional-family

Moved reference: an-explicit-sweep-attaining-the-bound

Moved reference: combining-the-parity-classes

Moved reference: cor:odd-box-feasibility

Moved reference: eq:box-face-poset

Moved reference: eq:box-local-cost

Moved reference: eq:box-pair-cost

Moved reference: eq:equal-box-predecessors

Moved reference: eq:even-cube-charge

Moved reference: eq:even-three-cube-charge

Moved reference: eq:even-three-cube-profile

Moved reference: eq:fixed-box-eventual-time

Moved reference: eq:odd-box-budget-transition

Moved reference: eq:odd-box-feasibility

Moved reference: eq:odd-box-horizon-recurrence

Moved reference: eq:odd-box-inverse-duality

Moved reference: eq:odd-box-profiles

Moved reference: eq:odd-box-two-count-transition

Moved reference: eq:prism-rec

Moved reference: eq:six-probe-cylinder-potential

Moved reference: exact-profile-transfer-for-either-longitudinal-parity

Moved reference: face-compression-and-its-partial-order

Moved reference: fig:cube-layers

Moved reference: fig:cylinder-corner-costs

Moved reference: how-the-results-fit-together

Moved reference: lem:box-cost-comparison

Moved reference: lem:box-neighborhood-cost

Moved reference: lem:box-prefix-neighborhood

Moved reference: lem:box-terminal-comparison

Moved reference: prefix-neighborhoods-and-a-local-cost-identity

Moved reference: profiles-exact-capture-times-and-optimal-inspections

Moved reference: prop:cylinder-profile-transfer

Moved reference: prop:three-three-four-time

Moved reference: ref-OtachiSuda2011

Moved reference: sec:boxes

Moved reference: sec:even-cube-tables

Moved reference: sec:odd-boxes

Moved reference: sec:six-probe-even-cylinder

Moved reference: sec:three-cube-cylinder-all-lengths

Moved reference: the-complete-3times3times3-example

Moved reference: the-exact-large-budget-formula

Moved reference: the-exchange-comparison

Moved reference: the-finite-3times3times4-check-as-a-corollary

Moved reference: the-structural-results

Moved reference: thm:equal-box-compression

Moved reference: thm:even-cube-tables

Moved reference: thm:fixed-box-eventual-time

Moved reference: thm:long-cylinder-feasibility

Moved reference: thm:odd-box-nesting

Moved reference: thm:six-probe-even-cylinder-time

Moved reference: thm:three-by-three-cylinder-all-lengths

Moved reference: thm:three-by-three-cylinder-time

Moved reference: thm:two-side