The seam displacement calculus #
Fix a graph H, two marks x ≠ y, the seam divisor α = (x) - (y)
(seamDivisor, from EdgeAddition.lean), and a base divisor C. For m : ℤ
the m-twist is C + m • α (seamTwist). A firing script f : V → ℤ acts
on divisors through prin H f (the note's Δf), and its displacement is
t(f) = f x - f y (displacement). The displacement set of the m-twist is
d(A_m) = { t(f) : C + m • α + Δf ≥ 0 } (IsDisplacement).
The junction class of the pair m | m+1 is
ξ_m = [C + m•α - (y)] = [C + (m+1)•α - (x)] (junction), and the junction
has a gap when every displacement of the (m+1)-twist strictly exceeds every
displacement of the m-twist (HasGap). The main theorem, hasGap_iff, is
Theorem C together with Theorem C′ of §5/§12:
HasGap C x y m ↔ ¬ winnable H (junction C x y m).
Index of the main results #
script_min_at_of_qReduced— the master lemma (level-set firing).script_const_of_prin_eq_zero,displacement_eq_of_prin_eq—tis well defined on representatives (uses connectedness).winnable_sub_one_chip_iff_of_qReduced— the chip test for reduced divisors.isMaxDisplacement_of_qReduced_y,isMinDisplacement_of_qReduced_x— Proposition 1, extremal half:b_mis attained at they-reduced representative,a_mat thex-reduced one.isDisplacement_succ_of_junction_winnable,isDisplacement_succ_of_isMaxDisplacement— Theorem C.isDisplacement_pred_of_junction_winnable,isDisplacement_of_isMinDisplacement_succ— Theorem C from thex-side (the same junction class controls the junction from both sides).le_displacement_of_qReduced_succ,exists_isDisplacement_succ_ge,isMaxDisplacement_mono,exists_isDisplacement_le— Lemma M.lt_script_of_qReduced_no_chip,hasGap_of_junction_not_winnable— Theorem C′, andhasGap_ifffor the equivalence.not_hasGap_of_rank_pos— Corollary C1.
Phase-0 API survey (.lake/packages/chip-firing-with-lean) #
What the library has (all of it used below):
CFDiv G = G.V → ℤ,oneChip v,effective D = ∀ v, D v ≥ 0,deg,winnable G D,linearEquiv G D D',principalDivisors G(ChipFiringWithLean.Basic).- Firing scripts as plain functions:
firingScript G = G.V → ℤtogether with the additive mapprin G : firingScript G →+ CFDiv G, given byprin G σ v = ∑ u, (σ u - σ v) * numEdges G v u. This is theΔof the note (the negative of the Laplacian action; see the docstring ofprin).principal_iff_eq_prinidentifiesprincipalDivisorswith the image ofprin. There is alsofiringVector,setFiring,laplacianMatrix,applyLaplacian, none of which are needed here. qReduced G q D:qEffective q Dtogether with "every nonemptyS ⊆ V ∖ {q}contains a vertexvwithD v < ∑ w ∉ S, numEdges G v w" — i.e. noq-avoiding set is legal.exists_q_reduced_representativeandunique_q_reduced(both needgraphConnected),q_reduced_unique,qReducedRep(RRGHelpers),winnable_iff_q_reduced_effective,effective_of_winnable_and_q_reduced.winnable_equiv_winnable,winnable_of_effective,rank,rank_geq_iff,rank_nonneg_iff_winnable, Riemann–Roch.seamDivisor x y = oneChip x - oneChip y(Utilities.EdgeAddition).
What the library lacks, and how it is handled here:
- Dhar's algorithm as a certified firing path.
Algorithms.leandefinesdhar_outdeg,dharBurningSet,findQReducedDivisor,dhar,burn, but proves nothing about them: there is no lemma "every effective divisor reaches itsq-reduced representative by a finite sequence of legalq-avoiding firings". Consequently the interval half of Proposition 1 of the note ("every intermediate displacement is attained") is not formalized here. Nothing below needs it: the extremal half of Proposition 1, Lemma M, Theorem C and Theorem C′ are all proved by direct level-set (threshold-firing) arguments, unconditionally. - Level sets of a script.
Basic.leancontains aprivate lemma maxset_of_scriptwith exactly the required inequality, but it is private and hard-wired to one particular level set. It is re-proved here astopSet,prin_le_neg_outdeg_S, and thebotSetmirroroutdeg_S_le_prin. - "A
q-reducedDsatisfiesD q ≥ 1iff[D] - (q)is effective". Absent; proved here aswinnable_sub_one_chip_iff_of_qReduced. - "Two scripts with the same principal divisor differ by a constant".
Absent (only the connectivity-free
qReducershadow, which is private); proved here asscript_const_of_prin_eq_zero. - ℚ-valued potentials and effective resistance: absent. Theorems B and D of the note need them and are deliberately not attempted.
No sorry, no new axioms, no stated-but-unproved hypotheses: every result
below is proved outright from the library's API.
Pointwise lemmas for chips and seams #
Level sets of a firing script #
The argmax level set topSet g and its mirror botSet g = topSet (-g).
One fact drives the whole calculus: at a vertex of topSet g the script g
removes at least the out-degree of the level set (prin_le_neg_outdeg_S), so
a level set avoiding q is a legal firing set and therefore certifies
non-q-reducedness.
The set of vertices where a firing script attains its maximum.
Equations
- Utilities.topSet g = {v : H.V | ∀ (u : H.V), g u ≤ g v}
Instances For
The set of vertices where a firing script attains its minimum.
Equations
Instances For
Outside the argmax level set the script is strictly smaller.
The level-set inequality. Firing a script whose maximum is attained at
v costs v at least its out-degree from the maximal level set.
The argmin mirror of prin_le_neg_outdeg_S.
Connectivity ⇒ the kernel of Δ consists of the constant scripts.
q-reduced divisors: the chip test #
A q-reduced divisor stays q-reduced after a chip is removed at q, which
converts "the class minus (q) is effective" into the pointwise test D q ≥ 1.
Scripts, twists and displacements #
The m-th seam twist C + m • α of the base divisor C.
Equations
- Utilities.seamTwist C x y m = C + m • Utilities.seamDivisor x y
Instances For
The displacement t(f) = f x - f y of a firing script.
Equations
- Utilities.displacement x y f = f x - f y
Instances For
t is a displacement of the m-twist: some script puts the m-twist into
effective position with displacement t.
Equations
- Utilities.IsDisplacement C x y m t = ∃ (f : firingScript H), effective (Utilities.seamTwist C x y m + (prin H) f) ∧ Utilities.displacement x y f = t
Instances For
t is the largest displacement of the m-twist (b_m of the note).
Equations
- Utilities.IsMaxDisplacement C x y m t = (Utilities.IsDisplacement C x y m t ∧ ∀ (s : ℤ), Utilities.IsDisplacement C x y m s → s ≤ t)
Instances For
t is the smallest displacement of the m-twist (a_m of the note).
Equations
- Utilities.IsMinDisplacement C x y m t = (Utilities.IsDisplacement C x y m t ∧ ∀ (s : ℤ), Utilities.IsDisplacement C x y m s → t ≤ s)
Instances For
The junction class ξ_m = [C + m•α - (y)] of the pair m | m+1.
Equations
- Utilities.junction C x y m = Utilities.seamTwist C x y m - oneChip y
Instances For
A constant script has zero displacement.
Displacement is well defined on representatives #
t is well defined on representatives. On a connected graph two
scripts with the same principal divisor differ by a constant, hence have the
same displacement.
Hence the displacement attached to an effective representative of a twist depends only on the representative.
Non-vacuity: an effective base divisor has displacement 0 at twist 0.
Every winnable divisor has a q-reduced effective representative, presented
as an explicit script.
The master lemma #
Everything below rests on one statement: if a q-reduced divisor is reached
from an effective divisor by adding a divisor that is nonnegative off q and
then firing a script g, then g attains its minimum at q.
Master lemma. Let D be effective, let β be nonnegative away from
q, and suppose D + β + Δg is q-reduced. Then g is minimized at q.
Proposition 1 (extremal half): the reduced representatives are extremal #
The y-reduced representative maximizes the displacement, the x-reduced one
minimizes it. (The other half of Proposition 1 of the note — that every
intermediate integer is attained, so that d(A_m) is an interval — requires
the Dhar reduction path, which the library does not certify. It is not used
anywhere below.)
The y-reduced effective representative attains the maximal displacement.
The x-reduced effective representative attains the minimal displacement.
A winnable twist has a maximal displacement.
A winnable twist has a minimal displacement.
Theorem C: an effective junction class kills the gap #
Theorem C (forward form). If the junction class ξ_m is effective then
the y-reduced effective representative of the m-twist, translated by the
seam, is an effective representative of the (m+1)-twist with the same
script — hence with the same displacement.
Theorem C, packaged. If the junction class is effective then the
maximal displacement of the m-twist is again a displacement of the
(m+1)-twist; in particular b_{m+1} ≥ b_m, i.e. gap_m ≤ 0.
Lemma M: monotonicity of the displacement interval #
Lemma M (b-side, non-strict). Every displacement of the m-twist is
at most the displacement of the y-reduced representative of the
(m+1)-twist. Equivalently b_m ≤ b_{m+1}.
Lemma M, ∃-representative form. If the (m+1)-twist is winnable then
every displacement of the m-twist is dominated by some displacement of the
(m+1)-twist.
Lemma M, maximal form: b_m ≤ b_{m+1}.
Theorem C′: a non-effective junction class forces a gap #
This is §12 of the note. The argument there runs a terminating level-set
firing iteration; the proof below shortcuts it. A single level set decides
the matter: a y-reduced representative of the m-twist with no chip at y
cannot tolerate y sitting at the top level of the transition script.
The level-set core of Theorem C′. Let D be effective and y-reduced
with no chip at y, and suppose D + α + Δg is effective. Then g is
strictly larger at x than at y: the seam step strictly increases the
displacement.
The junction m | m+1 has a gap: every displacement of the (m+1)-twist
strictly exceeds every displacement of the m-twist. In the notation of the
note this is gap_m = a_{m+1} - b_m ≥ 1.
Equations
- Utilities.HasGap C x y m = ∀ (s t : ℤ), Utilities.IsDisplacement C x y m s → Utilities.IsDisplacement C x y (m + 1) t → s < t
Instances For
Theorem C, contrapositive form. An effective junction class rules out a
gap (assuming the m-twist is winnable, so that there is something to rule
out).
Theorem C iff Theorem C′ (gap rigidity is an equivalence). For a winnable
m-twist on a connected graph, the junction m | m+1 has a gap exactly when
its junction class ξ_m = [C + m•α - (y)] = [C + (m+1)•α - (x)] fails to be
effective.
Corollary C1 (rank kills gaps). If the m-twist has positive rank then
its junction class is effective, so the junction m | m+1 has no gap.
Lemma M, strict form. When the junction class is not effective the
displacement strictly increases: b_{m+1} ≥ b_m + 1.
The x ↔ y symmetry, and the a-side of Lemma M #
Swapping the two marks negates the seam, the twist index and the displacement.
Theorem C, x-side form. The junction has a single obstruction
class, seen from both sides (§5 of the note): the same hypothesis
ξ_m = [C + (m+1)•α - (x)] effective shows that the x-reduced effective
representative of the (m+1)-twist, translated back by the seam, is an
effective representative of the m-twist with the same script.
Theorem C, x-side packaged. If the junction class is effective, the
minimal displacement of the (m+1)-twist is again a displacement of the
m-twist; in particular a_m ≤ a_{m+1} is not strict.
Lemma M (a-side). If the m-twist is winnable then every
displacement of the (m+1)-twist dominates some displacement of the m-twist:
a_m ≤ a_{m+1}.
The a-side gap statement. A non-effective junction class also forces
the strict inequality on the x-reduced side.