DiamondOdometerExistsUnique #
Adapted from Wesley Pegden’s Apache-2.0 Trellis formalization of Levine–Pegden–Smart. Changes: pool module paths, public exports, project namespace and current Mathlib compatibility.
theorem
ApollonianSuperharmonic.DiamondOdometerExistsUnique
(K : DiamondParameter)
:
∃! g : IntegerLatticeFunction, (∀ (x : GaussianInt),
g (x + { re := 0, im := -(2 * ↑↑K) }) = g x + -↑↑K * x.re + (↑↑K - 1) * x.im - ↑↑K * (↑↑K - 2)) ∧ (∀ (x : GaussianInt), g (x + { re := ↑↑K + 1, im := ↑↑K }) = g x + ↑↑K * x.re + x.im + ↑↑K * (↑↑K + 1) / 2) ∧ (∀ (x : GaussianInt), g (x + { re := -↑↑K - 1, im := ↑↑K }) = g x - ↑↑K * x.im - ↑↑K * (↑↑K + 1) / 2) ∧ ∀ x ∈ DiamondVertexDomains K false, g x = ↑x.re.natAbs * (↑x.re.natAbs - 1) / 2 - (x.re - x.im) ^ 2 / 4