import YM.WilsonBulk.Slice.Print import YM.WilsonBulk.Trees.Predictor import YM.Work.F05.Reindex /-! # K.k contact to independent finite-coordinate step Compass κ, unit conventions unchanged. Use absolute log and mean (compatible every index basis) to shift. Seed Scripts obtains all Cradle shapes, caller must give actual `Scripts` and `LocalRatio`. Branch noise uses *all* likelihood, but predictors analytic/constant theta-independent near the formal branch; later shown. These claims do not calculate a bare sector integral. -/ set_option autoImplicit false noncomputable section namespace YM.WilsonBulk namespace Atelier open Lattice Laurent Function Bloch RG Precision Exterior Stationary FreeResolvent open scoped Classical Topology BigOperators Matrix open Sheet Matrix variable {c f n : Side} {P : Patch} {G : Gauge} {S : StepData c f} {p : ℝ} variable (G) abbrev Pennant (n : Side) := FreeResolvent.Slot G n 1 abbrev Logbook (n : Side) := Tape (Pennant G n) -- canonical data from Bed metrics def matrixK (n : Side) (P : Bed) : Matrix (Pennant G n) (Pennant G n) ℝ := patron G (Precision.K (P.metric.acts n)) abbrev Ticket (x : ℝ) (n : Side) (P : Bed) := (P.metric.acts n).IsSymm ∧ Gap (P.metric.acts n) x omit G in lemma floor_qual {P : Bed} {p : Clip} {σ C : ℝ} {n : Side} (hf : Floor P p n σ C) : Ticket σ n P := ⟨hf.symmetric.1,⟨fun v=> (hf.uniform.1 v).1⟩⟩ def probeX (S : StepData c f) : Matrix (Pennant G c) (Pennant G f) ℝ := patron G (probe S) def regionJ (F : Tree.Forest S.ratio) (P : Bed) : Matrix (Pennant G f) (Pennant G f) ℝ := covariance G S F P.metric def predictor (F : Tree.Forest S.ratio) (P : Bed) := S.kernel.penalty • (regionJ G F P*(probeX G S).transpose) structure Coursing (ι : Type) (S : StepData c f) where tree : Tree.Forest S.ratio label : ι ≃ tree.Free namespace Coursing variable {ι : Type} (F : Coursing ι S) abbrev LegsT (ι : Type) := ι × G.ColorIndex def flag : LegsT G ι ≃ Active G F.tree := Equiv.prodCongr F.label (Equiv.refl _) abbrev dock := plant F.tree ∘ flag G F def trunk : Matrix (Pennant G f) (LegsT G ι) ℝ := insertion (dock G F) def isolate (P : Bed) := (treeInverse G S F.tree P.metric 0).submatrix (F.flag G) (F.flag G) def gravity (P : Bed) := (treeMatrix G S F.tree P.metric).submatrix (F.flag G) (F.flag G) lemma trunk_past : F.trunk G=(insertion (plant F.tree)).submatrix id (F.flag G) := rfl lemma trunk_formula (P : Bed) : (trunk G F).transpose*fullMatrix G S P.metric*trunk G F=gravity G F P := insertion.compress (F.dock G) _ variable [Fintype ι] lemma region_project (P : Bed) : trunk G F*isolate G F P*(trunk G F).transpose=regionJ G F.tree P := by rw [trunk_past, isolate, submatrix_mul_equiv,transpose_submatrix,submatrix_mul_equiv]; rfl omit [Fintype ι] in lemma confines (P : Bed) (h : Ticket p f P) : (gravity G F P).IsSymm := by rw [gravity,treeMatrix,Matrix.IsSymm, transpose_submatrix,transpose_submatrix,full_symmetric P.metric h.1] omit [Fintype ι] in lemma short_law (P : Bed) (h : Ticket p f P) : (isolate G F P).IsSymm := by unfold Matrix.IsSymm isolate treeInverse resolve; rw [transpose_submatrix]; refine congrArg (fun x=>Matrix.submatrix x _ _) ?_; rw [Matrix.transpose_nonsing_inv]; simp only [treeMatrix,transpose_add,transpose_smul,transpose_one,transpose_submatrix, full_symmetric P.metric h.1] lemma prepared [DecidableEq ι] (hl : Bid.Larger (G:=G) S) (hp : 0