Integral homogenization of rational polytope vertices #
This module chooses one common denominator for the vertices of a rational
polytope, embeds the resulting integral coordinates into one higher dimension
with final coordinate 1, and forms the integer submodule generated by the
vertices on each face. The final coordinate turns linear combinations in the
homogenized module into affine combinations in the original polytope.
Add a final affine coordinate equal to one.
Equations
- z.homogenize i = Fin.lastCases 1 z i
Instances For
A simultaneous choice of integral scaled coordinates for all vertices of
P. Positivity of denominator is recorded so that scaling can be
cancelled over the reals.
- denominator : ℕ
Common positive denominator used to scale the rational vertices.
Integer coordinates of the vertices after scaling by the common denominator.
Instances For
The canonical common-denominator choice supplied by finiteness and rationality of the vertex set.
Equations
- P.vertexHomogenization = { denominator := Classical.choose ⋯, denominator_pos := ⋯, scaledVertex := fun (q : ↑P.vertexSet) => Classical.choose ⋯, scaledVertex_real := ⋯ }
Instances For
Homogenized integral coordinate of a vertex.
Equations
- H.homogenizedVertex q = (H.scaledVertex q).homogenize
Instances For
Homogenized vertices lying on a face.
Equations
- H.faceHomogenizedSet F = Set.range fun (q : { q : EGZ.RealCoord d // q ∈ P.vertexSet ∩ F.carrier }) => H.homogenizedVertex ⟨↑q, ⋯⟩
Instances For
The integer submodule generated by homogenized vertices on a face.
Equations
- H.faceSubmodule F = Submodule.span ℤ (H.faceHomogenizedSet F)
Instances For
A vertex lying on F is one of the generators of the face submodule.
Membership of an integral point with final coordinate 1 in the
homogenized face submodule is equivalent to affine-integer-span membership of
the corresponding real point.
A single threshold makes every face submodule p-saturated.