Four expressions associated with observer positions
DefinitionLawsOfForm_ObserverDefines exactly four expression readings of the note’s three-branch arrangement, indexed by Fin 4, on three arbitrary expression arguments. This is an explicit table of the source expressions and does not define a physical observer or assume that the four resulting functions differ.
import Definitions.Def_LawsOfForm_Algebra import Mathlib.Data.Fin.Basic set_option autoImplicit false namespace LawsOfForm def observerView (root : Fin 4) (a b c : Expr) : Expr := match root.val with | 0 => .beside (.cross (.beside (.cross b) (.cross c))) a | 1 => .beside (.cross b) (.beside (.cross c) (.cross a)) | 2 => .beside (.cross (.beside (.cross a) (.cross c))) b | _ => .beside (.cross (.beside (.cross a) (.cross b))) c end LawsOfForm
Read-back
What the Lean code literally says, in plain math · Codex (GPT-6)
For every index and every three expressions , the definition specifies an expression , where consists of finite syntactic expressions formed from a blank symbol, variables indexed by natural numbers (including ), a unary crossing constructor , and an ordered binary juxtaposition constructor , with all nesting retained. The four cases are , , , and . Thus case juxtaposes the crossing of the juxtaposition of the crossings of and with ; case juxtaposes the crossing of with the juxtaposition of the crossings of and ; case juxtaposes the crossing of the juxtaposition of the crossings of and with ; and case juxtaposes the crossing of the juxtaposition of the crossings of and with . The index is required to be a natural number strictly less than , so the final default case applies only to , and there is no case for a negative index or an index at least . There are no further hypotheses on : any may be blank, contain variables or arbitrary finite nesting, or coincide with any other input. Each output is the displayed syntax tree without any simplification or identification of differently ordered or parenthesized expressions.