Download data/lean/OAI/Computability/PerfectCompleteness/Decoding/LeftDecoderKnownRows.lean from introvoyz045/math: direct link, hf CLI and curl.
- Browser
- Download file 3.9 kB
-
https://huggingface.co/datasets/introvoyz045/math/resolve/main/data/lean/OAI/Computability/PerfectCompleteness/Decoding/LeftDecoderKnownRows.lean
- Command line
-
hf download hf://datasets/introvoyz045/math/data/lean/OAI/Computability/PerfectCompleteness/Decoding/LeftDecoderKnownRows.lean
-
curl -L -o LeftDecoderKnownRows.lean https://huggingface.co/datasets/introvoyz045/math/resolve/main/data/lean/OAI/Computability/PerfectCompleteness/Decoding/LeftDecoderKnownRows.lean
3.9 kB
| import OAI.Computability.PerfectCompleteness.Decoding.LeftDecoder | |
| namespace OAI | |
| namespace PerfectCompleteness.LeftDecoderKnownRows | |
| open scoped Classical | |
| open UniqueGamesTheorem.Foundations.Games | |
| open ClauseSupport MixedSupport | |
| open LeftDecoder (F2) | |
| noncomputable section | |
| variable {n : Nat} {K Z : Type*} [AddCommGroup K] [Module F2 K] | |
| (slots : Fin n β Slot) (H : Submodule F2 (Assignment slots β F2)) | |
| (other : Assignment slots β Z) (labeling : KeyStrategy.Strategy n) | |
| (W : Submodule F2 H) (s : (H β§Έ W) ββ[F2] H) | |
| (hs : W.mkQ.comp s = LinearMap.id) | |
| theorem exists_fallback_candidate_realizer | |
| (hW : RepresentativeMatrixTable.Determined slots H other W) : | |
| β x : Assignment slots, | |
| other x = (CanonicalMatrixTable.response slots H other labeling | |
| (0 : CanonicalMatrixTable.Matrix (K := K) slots H)).2 β§ | |
| β q : PulledColumnSpace.Candidates W β₯ | |
| (RepresentativeMatrixTable.correctionFunctional slots H other W s hs | |
| (CanonicalMatrixTable.response slots H other labeling | |
| (0 : CanonicalMatrixTable.Matrix (K := K) slots H)).2), | |
| β b : W, q.val (b : H) = b.val.val x := by | |
| obtain β¨x, _, hxβ© := CanonicalMatrixTable.response_realized slots H other labeling | |
| (0 : CanonicalMatrixTable.Matrix (K := K) slots H) | |
| refine β¨x, hx, ?_β© | |
| intro q b | |
| rw [PulledColumnSpace.candidate_apply_known, β hx] | |
| simpa only [add_zero] using RepresentativeDecoder.coset_apply_at_image | |
| slots H other W s hs hW x 0 W.dualAnnihilator.zero_mem b | |
| attribute [local instance] UniqueGamesTheorem.Appendix.RankLevelFilter.linearMapFintype | |
| variable [FiniteDimensional F2 H] | |
| [Fintype H] [Fintype K] | |
| (useful : (Module.Dual F2 (H β§Έ W) ββ[F2] K) β Prop) | |
| local instance representativeDualFintype : Fintype (Module.Dual F2 H) := | |
| LeftDecoder.dualFintype (V := H) | |
| theorem adviceLaw_probability_eq_one_of_known_realizer | |
| (hW : RepresentativeMatrixTable.Determined slots H other W) | |
| (r : Nat) (Ο : β) (hΟ : 0 < Ο) (A : ManyGoodRows.RowMap K r) | |
| (U : Module.Dual F2 (H β§Έ W) ββ[F2] (Fin r β F2)) | |
| (event : Module.Dual F2 H β Bool) | |
| (hevent : β q : Module.Dual F2 H, | |
| (β x : Assignment slots, β b : W, q (b : H) = b.val.val x) β event q = true) : | |
| (LeftDecoder.adviceLaw slots H other labeling W s hs useful r Ο A U).probability | |
| event = 1 := by | |
| by_cases hgood : ManyGoodRows.GoodRow | |
| (RepresentativeMatrixTable.partialTable slots H other labeling W s useful) r Ο A U | |
| Β· rw [LeftDecoder.adviceLaw_of_good slots H other labeling W s hs useful r Ο A U hgood] | |
| unfold LeftDecoder.law | |
| apply LeftDecoder.affineLaw_probability_eq_one | |
| intro q | |
| obtain β¨x, _, hknownβ© := LeftDecoder.exists_candidate_realizer | |
| slots H other labeling W s hs useful hW | |
| (ManyGoodRows.selectWitness | |
| (RepresentativeMatrixTable.partialTable slots H other labeling W s useful) | |
| r Ο A U hgood) hΟ | |
| exact hevent q.val β¨x, hknown qβ© | |
| Β· simp only [LeftDecoder.adviceLaw, dite_eq_right hgood] | |
| apply LeftDecoder.affineLaw_probability_eq_one | |
| intro q | |
| obtain β¨x, _, hknownβ© := | |
| exists_fallback_candidate_realizer (K := K) slots H other labeling W s hs hW | |
| exact hevent q.val β¨x, hknown qβ© | |
| theorem adviceLaw_known_realizer | |
| (hW : RepresentativeMatrixTable.Determined slots H other W) | |
| (r : Nat) (Ο : β) (hΟ : 0 < Ο) (A : ManyGoodRows.RowMap K r) | |
| (U : Module.Dual F2 (H β§Έ W) ββ[F2] (Fin r β F2)) : | |
| (LeftDecoder.adviceLaw slots H other labeling W s hs useful r Ο A U).probability | |
| (fun q => decide (β x : Assignment slots, | |
| β b : W, q (b : H) = b.val.val x)) = 1 := | |
| adviceLaw_probability_eq_one_of_known_realizer | |
| slots H other labeling W s hs useful hW r Ο hΟ A U _ | |
| (fun _ hx => decide_eq_true hx) | |
| end | |
| end PerfectCompleteness.LeftDecoderKnownRows | |
| end OAI | |