AFTD Auto-Formalizing Theoretical Domains

FieldStatistic.ofList_append

theoremverifiedformalizationimported Lean

FieldStatistic.ofList_append

Statement

set_option autoImplicit true in
set_option relaxedAutoImplicit true in
open FieldStatistic in
variable {𝓕 : Type} in
set_option backward.isDefEq.respectTransparency false in
@[simp]
lemma FieldStatistic.ofList_append (s : 𝓕 → FieldStatistic) (φs φs' : List 𝓕) :
    ofList s (φs ++ φs') = if ofList s φs = ofList s φs' then bosonic else fermionic
Formalizes
Physlib, `FieldStatistic.ofList_append`
Lean proof
By Joseph Tooby-Smith, from github.com/leanprover-community/physlib at e411c6e89692 (Copyright (c) 2024 Joseph Tooby-Smith. All rights reserved, Apache-2.0). Compiled here against leanprover/lean4:v4.33.1, Mathlib v4.33.1; written for leanprover/lean4:v4.34.1.
Verified
10 Oct 2026
Axioms
Classical.choiceQuot.soundpropext
Built on 19
Used by 22

Lean source view module on GitHub

set_option autoImplicit true inset_option relaxedAutoImplicit true inopen FieldStatistic invariable {𝓕 : Type} inset_option backward.isDefEq.respectTransparency false in@[simp]lemma FieldStatistic.ofList_append (s : 𝓕 → FieldStatistic) (φs φs' : List 𝓕) :    ofList s (φs ++ φs') = if ofList s φs = ofList s φs' then bosonic else fermionic := by  induction φs with  | nil =>    simp only [List.nil_append, ofList_empty, eq_self_if_bosonic_eq]  | cons a l ih =>    have hab (a b c : FieldStatistic) :        (if a = (if b = c then bosonic else fermionic) then bosonic else fermionic) =        if (if a = b then bosonic else fermionic) = c then bosonic else fermionic := by      fin_cases a <;> fin_cases b <;> fin_cases c <;> rfl    simp only [List.cons_append, ofList, ih, hab]
See it in the graphDiscuss this resultChallenge it