Exact Lean source
Nonadditivity.HaarRefinedWeight
Download original .lean · View on GitHub · Jump to source
Direct imports
Imported by project modules
2 direct reverse imports
Relationships above come from literal import commands. The declarations below link to types and references extracted from Lean’s environment. Source text is complete and unchanged.
Declarations in this module
23 project constants, including generated, internal and private declarations.
23 declarations
Nonadditivity.HaarPathClasses.RefinedPattern.integral_pathProduct_eqNonadditivity.HaarPathClasses.RefinedPattern.positionPermNonadditivity.HaarPathClasses.RefinedPattern.positionPerm._proof_1internal/detail/privateNonadditivity.HaarPathClasses.RefinedPattern.positionPerm.congr_simpNonadditivity.HaarPathClasses.RefinedPattern.positionPerm_colorNonadditivity.HaarPathClasses.RefinedPattern.positionPerm_fixNonadditivity.HaarPathClasses.RefinedPattern.weightDartEquivNonadditivity.HaarPathClasses.RefinedPattern.weightDartEquiv.congr_simpNonadditivity.HaarPathClasses.RefinedPattern.weightDartEquiv_colorNonadditivity.HaarPathClasses.RefinedPattern.weightDartEquiv_coreNonadditivity.HaarPathClasses.RefinedPattern.weightDartEquiv_core_iffNonadditivity.HaarPathClasses.RefinedPattern.weightDartEquiv_countNonadditivity.HaarPathClasses.RefinedPattern.weightDartEquiv_reverseNonadditivity.HaarPathClasses.RefinedPattern.weightDartEquiv_valNonadditivity.HaarPathClasses.SamePattern.dartEquivNonadditivity.HaarPathClasses.SamePattern.dartEquiv._proof_1internal/detail/privateNonadditivity.HaarPathClasses.SamePattern.dartEquiv._proof_2internal/detail/privateNonadditivity.HaarPathClasses.SamePattern.dartEquiv._proof_3internal/detail/privateNonadditivity.HaarPathClasses.SamePattern.dartEquiv._proof_4internal/detail/privateNonadditivity.HaarPathClasses.SamePattern.dartEquiv._proof_5internal/detail/privateNonadditivity.HaarPathClasses.SamePattern.dartEquiv._proof_6internal/detail/privateNonadditivity.HaarPathClasses.SamePattern.dartEquiv_countNonadditivity.HaarPathClasses.SamePattern.dartEquiv_val
Full module
1/-2Copyright (c) 2026 the Nonadditivity project contributors.3All rights reserved. See COPYRIGHT.md for licensing and attribution.4-/56import Nonadditivity.HaarChainReindex7import Nonadditivity.HaarProfilePermutations8import Nonadditivity.HaarPathWeightTransport910/-! # Haar weights are constant on actual refined path classes1112Equal complete-chain profiles give endpoint-fixed permutations of the positions13inside each unoriented core edge. They preserve reversal and directed traversal14multiplicity. Independent row and column Haar invariance then identifies the15literal expectations, without a weight-invariance hypothesis.16-/17noncomputable section18attribute [local instance 2000] instBEqOfDecidableEq19set_option backward.isDefEq.respectTransparency false20set_option maxHeartbeats 150000021set_option linter.unusedSectionVars false22namespace Nonadditivity.HaarPathClasses23open HaarPathGraph HaarPathProfiles HaarProfilePermutations24variable {V : Type*} [Fintype V] [DecidableEq V] {d m : ℕ}25variable {P Q : Path V d m}2627namespace SamePattern2829def dartEquiv (h : SamePattern P Q) : P.darts ≃ Q.darts where30toFun q := ⟨h.dartPerm q.val,(h.dartPerm_mem_iff q.val).mpr q.property⟩31invFun q := ⟨h.dartPerm.symm q.val,(h.dartPerm_mem_iff _).mp (by simpa using q.property)⟩32left_inv := by intro q; apply Subtype.ext; exact h.dartPerm.symm_apply_apply q.val33right_inv := by intro q; apply Subtype.ext; exact h.dartPerm.apply_symm_apply q.val3435@[simp] theorem dartEquiv_val (h : SamePattern P Q) (q : P.darts) :36(h.dartEquiv q).val=h.dartPerm q.val := rfl3738theorem dartEquiv_count (h : SamePattern P Q) (q : P.darts) :39P.traversalList.count q.val=Q.traversalList.count (h.dartEquiv q).val := by40rw [dartEquiv_val,←h.traversalList_map,List.count_map_of_injective _ _ h.dartPerm.injective]4142end SamePattern43namespace RefinedPattern4445def positionPerm (h : RefinedPattern P Q) (e : P.unorientedChains) :46Equiv.Perm (Fin (P.representative e).val.length) :=47Classical.choose (exists_coreChain_positionPerm h (P.representative e))4849theorem positionPerm_color (h : RefinedPattern P Q) (e : P.unorientedChains)50(i : Fin (P.representative e).val.length) :51color (h.samePattern.dartPerm ((P.representative e).val.get (h.positionPerm e i)))=52color ((P.representative e).val.get i) :=53(Classical.choose_spec (exists_coreChain_positionPerm h (P.representative e))).1 i5455theorem positionPerm_fix (h : RefinedPattern P Q) (e : P.unorientedChains)56(i : Fin (P.representative e).val.length)57(hi : i.val=0 ∨ i.val+1=(P.representative e).val.length) : h.positionPerm e i=i :=58(Classical.choose_spec (exists_coreChain_positionPerm h (P.representative e))).2 i hi5960/-- An actual dart bijection, built from profile equality alone. -/61def weightDartEquiv (h : RefinedPattern P Q) : P.darts ≃ Q.darts :=62(P.chainReindex h.positionPerm).trans h.samePattern.dartEquiv6364@[simp] theorem weightDartEquiv_val (h : RefinedPattern P Q) (q : P.darts) :65(h.weightDartEquiv q).val=h.samePattern.dartPerm (P.chainReindex h.positionPerm q).val := rfl6667theorem weightDartEquiv_color (h : RefinedPattern P Q) (q : P.darts) :68color (h.weightDartEquiv q).val=color q.val := by69obtain ⟨⟨e,i,b⟩,rfl⟩ := P.representativePositionEquiv.surjective q70rw [h.weightDartEquiv_val,P.chainReindex_apply_position]71simp only [P.representativePositionEquiv_val]72cases b73· simp only [Bool.false_eq_true,ite_false]74rw [h.samePattern.dartPerm_reverse (P.toCore_mem (P.representative e).property.1 (List.get_mem _ _))]75exact congrArg (fun c : Color d => flipColor c) (h.positionPerm_color e i)76· exact h.positionPerm_color e i7778theorem weightDartEquiv_core (h : RefinedPattern P Q) (q : P.darts)79(hq : source q.val∈P.coreVertices) :80source (h.weightDartEquiv q).val=h.samePattern.vertexPerm (source q.val) := by81rw [h.weightDartEquiv_val,P.chainReindex_fixed_core _ h.positionPerm_fix q hq]82exact h.samePattern.source_dartPerm q.property8384theorem weightDartEquiv_core_iff (h : RefinedPattern P Q) (q : P.darts) :85source (h.weightDartEquiv q).val∈Q.coreVertices ↔ source q.val∈P.coreVertices := by86rw [h.weightDartEquiv_val,h.samePattern.source_dartPerm (P.chainReindex h.positionPerm q).property,87h.samePattern.vertexPerm_mem_core_iff]88exact P.chainReindex_mem_core_iff _ h.positionPerm_fix q8990theorem weightDartEquiv_reverse (h : RefinedPattern P Q) (q : P.darts) :91h.weightDartEquiv ⟨reverse q.val,P.reverse_mem q.property⟩ =92⟨reverse (h.weightDartEquiv q).val,Q.reverse_mem (h.weightDartEquiv q).property⟩ := by93apply Subtype.ext94rw [h.weightDartEquiv_val,P.chainReindex_reverse]95exact h.samePattern.dartPerm_reverse (P.chainReindex h.positionPerm q).property9697theorem weightDartEquiv_count (h : RefinedPattern P Q) (q : P.darts) :98P.traversalList.count q.val=Q.traversalList.count (h.weightDartEquiv q).val :=99(P.chainReindex_count h.positionPerm q).trans100(h.samePattern.dartEquiv_count (P.chainReindex h.positionPerm q))101102/-- BC Lemma 5.7 for the literal pair-Haar path integral. No invariance premise103or dimension restriction is needed. -/104theorem integral_pathProduct_eq {N m : ℕ} {P Q : Path (Fin (N+1)) 2 m}105(h : RefinedPattern P Q) :106(∫ U : HaarModel.LocalUnitary N × HaarModel.LocalUnitary N,107HaarPathWeights.pathProduct P U ∂(HaarModel.haar N).prod (HaarModel.haar N)) =108∫ U : HaarModel.LocalUnitary N × HaarModel.LocalUnitary N,109HaarPathWeights.pathProduct Q U ∂(HaarModel.haar N).prod (HaarModel.haar N) := by110exact HaarPathWeightTransport.integral_pathProduct_eq_of_dart_transport h.samePattern111h.weightDartEquiv h.weightDartEquiv_color h.weightDartEquiv_core112h.weightDartEquiv_core_iff h.weightDartEquiv_reverse (by113intro q114simpa only [List.count, Bool.beq_eq_decide_eq] using h.weightDartEquiv_count q)115116end RefinedPattern117end Nonadditivity.HaarPathClasses