Download data/lean/ComparatorChallenges/HyperbolicCones.lean from introvoyz045/math: direct link, hf CLI and curl.
- Browser
- Download file 2.62 kB
-
https://huggingface.co/datasets/introvoyz045/math/resolve/main/data/lean/ComparatorChallenges/HyperbolicCones.lean
- Command line
-
hf download hf://datasets/introvoyz045/math/data/lean/ComparatorChallenges/HyperbolicCones.lean
-
curl -L -o HyperbolicCones.lean https://huggingface.co/datasets/introvoyz045/math/resolve/main/data/lean/ComparatorChallenges/HyperbolicCones.lean
2.62 kB
| import Mathlib | |
| namespace OAI | |
| noncomputable section | |
| open scoped Matrix.Norms.L2Operator | |
| universe u | |
| namespace Paper256 | |
| abbrev Mat (n : β) (R : Type u) := Matrix (Fin n) (Fin n) R | |
| abbrev Sym (n : β) := selfAdjoint (Mat n β) | |
| instance instFiniteDimensionalSym (n : β) : FiniteDimensional β (Sym n) := | |
| FiniteDimensional.finiteDimensional_submodule (selfAdjoint.submodule β (Mat n β)) | |
| abbrev Ambient := (Sym 4 Γ Sym 4) Γ (Fin 3 β β) | |
| abbrev SymIndex := {ij : Fin 4 Γ Fin 4 // ij.1 β€ ij.2} | |
| abbrev Coord := (SymIndex β SymIndex) β Fin 3 | |
| def qMatrix {R : Type u} [CommRing R] (y : Fin 3 β R) : Mat 3 R := | |
| fun i j => if i = j then y i ^ 2 + y (i + 1) ^ 2 else -(y i * y j) | |
| def phi {R : Type u} [CommRing R] (y : Fin 3 β R) (X : Mat 4 R) : Mat 4 R := | |
| fun i j => Fin.cases | |
| (Fin.cases | |
| (Matrix.trace (qMatrix y * X.submatrix Fin.succ Fin.succ)) | |
| (fun j => -(β k, X 0 k.succ * qMatrix y k j)) j) | |
| (fun i => Fin.cases | |
| (-(β k, qMatrix y i k * X k.succ 0)) | |
| (fun j => X 0 0 * qMatrix y i j) j) i | |
| def matrixValue {R : Type u} [CommRing R] | |
| (X Z : Mat 4 R) (y : Fin 3 β R) : R := | |
| Matrix.det ((Matrix.det X) β’ Z - phi y (Matrix.adjugate X)) | |
| def symmetricCoordinates {R : Type u} (v : SymIndex β R) : Mat 4 R := | |
| fun i j => if h : i β€ j then v β¨(i, j), hβ© | |
| else v β¨(j, i), le_of_lt (lt_of_not_ge h)β© | |
| def polynomial : MvPolynomial Coord β := | |
| matrixValue | |
| (symmetricCoordinates fun ij => MvPolynomial.X (Sum.inl (Sum.inl ij))) | |
| (symmetricCoordinates fun ij => MvPolynomial.X (Sum.inl (Sum.inr ij))) | |
| (fun i => MvPolynomial.X (Sum.inr i)) | |
| def coordinates (x : Ambient) : Coord β β := | |
| Sum.elim (Sum.elim | |
| (fun ij => (x.1.1 : Mat 4 β) ij.val.1 ij.val.2) | |
| (fun ij => (x.1.2 : Mat 4 β) ij.val.1 ij.val.2)) x.2 | |
| def basePoint : Ambient := ((1, 1), 0) | |
| def linePolynomial (x : Ambient) : Polynomial β := | |
| MvPolynomial.evalβ Polynomial.C | |
| (fun i => Polynomial.C (coordinates basePoint i) * Polynomial.X - | |
| Polynomial.C (coordinates x i)) polynomial | |
| def cone : Set Ambient := | |
| {x | β t : β, (linePolynomial x).aeval t = 0 β t.im = 0 β§ 0 β€ t.re} | |
| theorem main_result : | |
| Module.finrank β Ambient = 23 β§ | |
| polynomial.IsHomogeneous 20 β§ | |
| polynomial.totalDegree = 20 β§ | |
| MvPolynomial.eval (coordinates basePoint) polynomial = 1 β§ | |
| (β (x : Ambient) (z : β), (linePolynomial x).aeval z = 0 β z.im = 0) β§ | |
| β (N : β) (_hN : 0 < N) (L : Ambient ββ[β] Sym N), | |
| cone β {x | (L x : Mat N β).PosSemidef} := by | |
| sorry | |
| end Paper256 | |
| end | |
| end OAI | |