Theorem 15 — Canon with respect to a variable
ProvedLawsOfForm.variable_canonFor any expression and any selected variable, an algebraically equivalent expression contains at most two occurrences of that variable and no new variables. The representative may depend on the selected variable; no simultaneous bound on all variables is asserted.
import Definitions.Def_LawsOfForm_Canonical set_option autoImplicit false
namespace LawsOfForm theorem variable_canon (e : Expr) (v : Nat) : ∃ f : Expr, Algebra e f ∧ occurrences v f ≤ 2 ∧ freeVars f ⊆ freeVars e := by sorry end LawsOfForm
Read-back
What the Lean code literally says, in plain math · Codex (GPT-6)
An expression is a finite syntactic term built from a blank symbol , variables indexed by natural numbers , a unary operation , and a binary operation . Write for the least equivalence relation on these terms that is preserved by , by either argument of , and by every simultaneous substitution assigning an arbitrary expression to each variable and extending recursively while preserving , , and ; this relation contains, for all expressions , the identities , , , , and . For every expression and every natural number , there exists an expression such that , the total number of syntactic occurrences of in is at most two, and every variable index appearing in also appears in . Here occurrence counting assigns zero to the blank, one to , zero to any other variable, leaves the count unchanged under , and adds the counts of the two arguments of ; the set of variable indices is empty for the blank, is for , is unchanged under , and is the union of the two sets for . There are no hypotheses on or : the assertion includes , the blank expression, expressions containing no variables, and choices of absent from ; in that last case is also absent from . The witness may depend on both and , the bound permits zero, one, or two occurrences of , and the assertion imposes no occurrence bound on the other variables.
Confirmed by the mission captain (proposal self-audit).
Confirmed by the moderator at approval.