Documentation

HexRCF.Reify

theorem Hex.RCF.Cmp.scale_sub_iff (cmp : Cmp) {lhs rhs scale : ℝ} (hscale : 0 < scale) :
cmp.toProp (scale * (lhs - rhs)) 0 ↔ cmp.toProp lhs rhs

Transport any supported comparison across subtraction and multiplication by a positive scalar.

theorem Hex.RCF.Atom.toProp_iff_scale {p : ZPoly} {cmp : Cmp} {x lhs rhs scale : ℝ} (hscale : 0 < scale) (heval : (Polynomial.aeval x) (HexPolyZTheory.toPolynomial p) = scale * (lhs - rhs)) :
{ p := p, cmp := cmp }.toProp x ↔ cmp.toProp lhs rhs

A kernel-checked scaled evaluation identity validates one reified atom.

theorem Hex.RCF.Atom.toProp_iff_natScale {p : ZPoly} {cmp : Cmp} {x lhs rhs : ℝ} {scale : ℕ} (hscale : 0 < scale) (heval : (Polynomial.aeval x) (HexPolyZTheory.toPolynomial p) = ↑scale * (lhs - rhs)) :
{ p := p, cmp := cmp }.toProp x ↔ cmp.toProp lhs rhs

Natural denominator clearing is a convenient literal specialization for the meta reifier.

theorem Hex.RCF.Sentence.forallReal_iff {formula : Formula} {predicate : ℝ → Prop} (h : ∀ (x : ℝ), formula.toProp x ↔ predicate x) :
(forallReal formula).toProp ↔ ∀ (x : ℝ), predicate x

Transport a reflected universal sentence along its formula equivalence.

theorem Hex.RCF.Sentence.existsReal_iff {formula : Formula} {predicate : ℝ → Prop} (h : ∀ (x : ℝ), formula.toProp x ↔ predicate x) :
(existsReal formula).toProp ↔ ∃ (x : ℝ), predicate x

Transport a reflected existential sentence along its formula equivalence.

theorem Hex.RCF.Sentence.forallIoc_iff {a b : Dyadic} {a' b' : ℝ} {formula : Formula} {predicate : ℝ → Prop} (ha : HexRealRootsTheory.Dyadic.toReal a = a') (hb : HexRealRootsTheory.Dyadic.toReal b = b') (h : ∀ (x : ℝ), formula.toProp x ↔ predicate x) :
(forallIoc a b formula).toProp ↔ ∀ x ∈ Set.Ioc a' b', predicate x

Transport a reflected bounded universal sentence and its dyadic endpoints.

theorem Hex.RCF.Sentence.existsIoc_iff {a b : Dyadic} {a' b' : ℝ} {formula : Formula} {predicate : ℝ → Prop} (ha : HexRealRootsTheory.Dyadic.toReal a = a') (hb : HexRealRootsTheory.Dyadic.toReal b = b') (h : ∀ (x : ℝ), formula.toProp x ↔ predicate x) :
(existsIoc a b formula).toProp ↔ ∃ x ∈ Set.Ioc a' b', predicate x

Transport a reflected bounded existential sentence and its dyadic endpoints.

Close evaluation identities for literal ZPoly coefficients and accepted ring syntax. The parser remains untrusted: unsupported or misparsed syntax merely makes this proof fail during elaboration.

Equations
Instances For

    A coefficient expression and an ordinary proof that it equals a closed real value. This is syntax authentication, not a sign or domain decision.

    • value : Lean.Expr

      A real expression with no free variables or metavariables.

    • proof : Lean.Expr

      Equality of the original expression with value.

    Instances For

      Close a real coefficient using only explicit local equalities to closed values. Every free symbol needs its own direct witness. Substitution preserves all arithmetic syntax, including original divisors and zero multiplication.

      Equations
      • One or more equations did not get rendered due to their size.
      Instances For

        Rational recognition stopped at closed coefficient syntax. This is the only reification outcome that permits an optional coefficient handler.

        • expr : Lean.Expr

          The source coefficient that rational normalization did not recognize.

        • The checked closed value, including explicit local-equality witnesses.

        Instances For

          Preserve the rational frontend's diagnostic when no handler accepts.

          Equations
          Instances For

            Probe one scalar through the rational frontend's typed recognition boundary. Unsupported closed syntax is a result; runtime/resource exceptions propagate. The probe preserves caller metavariable state.

            Equations
            • One or more equations did not get rendered due to their size.
            Instances For

              Literal reflected sentence.

              Equations
              Instances For

                Literal top-level replay certificate.

                Equations
                Instances For

                  Runtime and literal forms of a reflected sentence, together with its checked equivalence to the source goal.

                  • sentence : Sentence

                    The reflected sentence used by compiled certificate construction.

                  • expr : Lean.Expr

                    The literal expression representing sentence in the generated proof.

                  • proof : Lean.Expr

                    A proof that sentence is equivalent to the source goal.

                  Instances For

                    Reify one singly quantified real sentence, distinguishing unsupported closed coefficients from terminal syntax, proof and resource errors.

                    Equations
                    • One or more equations did not get rendered due to their size.
                    Instances For

                      Reify a rational sentence, reporting unsupported coefficients as diagnostics for callers that do not participate in optional handler dispatch.

                      Equations
                      • One or more equations did not get rendered due to their size.
                      Instances For