Structured proof · Unit 148
lemma IntegralPlace.IsStdLevel.heisenbergMeasure_eq_floorModulus
unipotentBelow a): heisenbergMeasure(a)(\{y:\exists u\in S,u\cdot(y\cdot1)\in\mathtt{unitaryLevel}(R,g,J)\})= floorModulus(F,a,g)=\operatorname{md}(g)^{k+1+2(\varrho-a-1)}\cdot\operatorname{md}(g)^{1/2}.floorModulus(F,a,g); the equality of sets uses the gauge (sizes of Heisenberg elements) in one direction and u=1 in the other.Unfold
heisenbergMeasureat a<\varrho as an image measure; the preimage of the set is (\prod\{x:g^{-1}x\in R\})\times\{\beta:g^{-1}\beta\in R\} (set equality, steps 4–6), whose measure is the product;skewMeasureof \{\beta:g^{-1}\beta\in R\} is \operatorname{md}(g)-scaled.The product of the volumes is
floorModulus(F,a,g).Write the vector part of p as g\cdot w.
Split the membership in the product and use
p_1 lies in the g-scaled lattice iff g^{-1}\cdot g\cdot w is integral.
Lean states
p.1 ∈ _ ↔Set equality: if u\in S and u\cdot\nu(p)\in K(g), the gauge shows that the Heisenberg coordinates have size 0, i.e. lie in the g-scaled lattices; conversely, for such coordinates u=1 works (\nu(p) is integral and \equiv1 mod g).