Documentation

MIPRE.Background.QLD.Game

The Pauli basis test #

Blueprint def:qld-game, the paper's game game^pauli_{(q,m,d)} (ldt.tex, sec:qld-game for the question distribution and fig:decider_pauli for the decision procedure). This is the game thm:qld is about and lem:qld-win unpacks.

The test certifies that the players share |EPR_q⟩^{⊗ M}, M = 2^m. A player asked (Pauli, W) measures {τ^W_h}_{h ∈ F_q^M} and reports h; every other question probes limited information about h through its low-degree encoding g_h : F_q^m → F_q (MIPRE.LowDegree.ldEnc), and the subtests check that those probes are consistent with each other and across the two bases.

The three groups of question types #

type^pauli = ({Point, ALine, DLine, Pauli, Pair} × {X, Z}) ∪ type^MS ∪ {Pair} --- twenty-six types, Ty below, in three groups with three different jobs.

The distribution #

adj is the type graph fig:type-graph-pauli: thirty non-loop edges (eighteen Magic Square incidences, six line/point and point/Pauli edges, two point/variable edges, four through the commutation check) and a self-loop at every one of the twenty-six vertices. The verifier draws an ordered pair of adjacent types --- the graph distribution of def:graph-distribution, each non-loop edge contributing two ordered pairs and each self-loop one, so uniform over the 2 * 30 + 26 = 86 ordered pairs --- then (u_X, u_Z, s, v, r_X, r_Z) uniformly, and hands each player the content its type prescribes. Sampling the pair and the content independently and uniformly is what makes Sample a product and μ_sum_one one division.

The decision procedure #

fig:decider_pauli is a format check and then seven rules. Question.fmtOk is the check --- the table at the top of the figure --- and subtests the rules, with accepts their conjunction.

The separation is not cosmetic, and the warning is on the record: the seeded CL game shipped without its format check, which made the test vacuous and thm:lidt-cl-soundness false about it (reports/clgame-format-check-missing.md). The same class of error is available here with twenty-six types instead of three, so every rule below has a witness that it can fail: rejects_* for the format check and for each of the seven rules.

Two structural facts about the rules are worth stating mechanically rather than trusting. subtests_covers_adj says the catch-all --- fig:ld-decider's "in all cases where no action is indicated, accept", which this figure inherits --- is reached only at non-adjacent type pairs, so it never accepts anything the distribution actually asks. And lowDeg_eq_cl says the low-degree rule is the seeded CL decider at ldc = 1 and not a paraphrase of it, which is what the figure prescribes ("accept if D^ld_{(q,m,d,1)} accepts").

Bases #

inductive MIPRE.QLD.Bas :

The two Pauli bases the test probes.

Instances For
    @[instance_reducible]
    Equations
    @[instance_reducible]
    Equations

    Question types #

    inductive MIPRE.QLD.Ty :

    The twenty-six question types of eq:pauli-type.

    Instances For
      def MIPRE.QLD.instDecidableEqTy.decEq (x✝ x✝¹ : Ty) :
      Decidable (x✝ = x✝¹)
      Equations
      Instances For
        @[instance_reducible]
        Equations
        • One or more equations did not get rendered due to their size.
        def MIPRE.QLD.adj (t u : Ty) :

        {t, u} ∈ E(G^pauli): the graph of fig:type-graph-pauli, with the self-loop at every vertex that the figure's caption adds.

        Equations
        Instances For
          theorem MIPRE.QLD.adj_symm (t u : Ty) :
          adj t u = adj u t
          @[simp]
          theorem MIPRE.QLD.adj_self (t : Ty) :
          adj t t = true
          theorem MIPRE.QLD.card_adj :
          {p : Ty × Ty | adj p.1 p.2 = true}.card = 86

          The thirty non-loop edges and twenty-six self-loops make 86 ordered pairs.

          Questions #

          structure MIPRE.QLD.Omega (F : Type u_1) (m : ℕ) :
          Type u_1

          The tuple ω = (u_X, u_Z, r_X, r_Z) every Magic Square and commutation-check question carries.

          • uX : LIDT.Point F m

            The X-side point.

          • uZ : LIDT.Point F m

            The Z-side point.

          • rX : F

            The X-side qubit basis element.

          • rZ : F

            The Z-side qubit basis element.

          Instances For
            def MIPRE.QLD.instDecidableEqOmega.decEq {F✝ : Type u_1} {m✝ : ℕ} [DecidableEq F✝] (x✝ x✝¹ : Omega F✝ m✝) :
            Decidable (x✝ = x✝¹)
            Equations
            • One or more equations did not get rendered due to their size.
            Instances For
              @[instance_reducible]
              instance MIPRE.QLD.instFintypeOmega {F✝ : Type u_1} {m✝ : ℕ} [Fintype F✝] :
              Fintype (Omega F✝ m✝)
              Equations
              def MIPRE.QLD.Omega.pt {F : Type u_1} {m : ℕ} (ω : Omega F m) :
              Bas → LIDT.Point F m

              The point of ω on the W side.

              Equations
              Instances For
                def MIPRE.QLD.Omega.r {F : Type u_1} {m : ℕ} (ω : Omega F m) :
                Bas → F

                The qubit basis element of ω on the W side.

                Equations
                Instances For
                  inductive MIPRE.QLD.Question (F : Type u_2) (m : ℕ) :
                  Type u_2

                  Questions: a type together with the content that type prescribes, in the ``Question Content'' column of fig:decider_pauli's table. A (Pauli, W) question carries no content (the paper's x_w = 0).

                  Instances For
                    def MIPRE.QLD.instDecidableEqQuestion.decEq {F✝ : Type u_2} {m✝ : ℕ} [DecidableEq F✝] (x✝ x✝¹ : Question F✝ m✝) :
                    Decidable (x✝ = x✝¹)
                    Equations
                    Instances For
                      @[instance_reducible]
                      instance MIPRE.QLD.instFintypeQuestion {F✝ : Type u_2} {m✝ : ℕ} [Fintype F✝] :
                      Fintype (Question F✝ m✝)
                      Equations
                      • One or more equations did not get rendered due to their size.
                      inductive MIPRE.QLD.Answer (F : Type u_2) (m d : ℕ) :
                      Type u_2

                      Answers, in the ``Answer Format'' column of fig:decider_pauli's table.

                      • val {F : Type u_2} {m d : ℕ} (a : F) : Answer F m d

                        A point answer, an element of F_q.

                      • apoly {F : Type u_2} {m d : ℕ} (f : LIDT.LinePoly F d) : Answer F m d

                        An axis-parallel line answer, of degree at most d.

                      • dpoly {F : Type u_2} {m d : ℕ} (f : LIDT.LinePoly F (m * d)) : Answer F m d

                        A diagonal line answer, of degree at most m·d.

                      • pauliAns {F : Type u_2} {m d : ℕ} (h : (Fin m → Bool) → F) : Answer F m d

                        A (Pauli, W) answer, an element of F_q^M with M = 2^m.

                      • bit {F : Type u_2} {m d : ℕ} (b : ZMod 2) : Answer F m d

                        A single bit: the answer to (Pair, W) and to Variable_j.

                      • bitPair {F : Type u_2} {m d : ℕ} (β : Bas → ZMod 2) : Answer F m d

                        (β_X, β_Z) ∈ F_2^2, the answer to Pair.

                      • bitTriple {F : Type u_2} {m d : ℕ} (α : Fin 3 → ZMod 2) : Answer F m d

                        (α_{v_1}, α_{v_2}, α_{v_3}) ∈ F_2^3, the answer to Constraint_i, indexed by the position of the variable in the constraint's support (MIPRE.LCS.MagicSquare.cell).

                      Instances For
                        def MIPRE.QLD.instDecidableEqAnswer.decEq {F✝ : Type u_2} {m✝ d✝ : ℕ} [DecidableEq F✝] (x✝ x✝¹ : Answer F✝ m✝ d✝) :
                        Decidable (x✝ = x✝¹)
                        Equations
                        Instances For
                          @[instance_reducible]
                          instance MIPRE.QLD.instDecidableEqAnswer {F✝ : Type u_2} {m✝ d✝ : ℕ} [DecidableEq F✝] :
                          DecidableEq (Answer F✝ m✝ d✝)
                          Equations
                          @[instance_reducible]
                          instance MIPRE.QLD.instFintypeAnswer {F✝ : Type u_2} {m✝ d✝ : ℕ} [Fintype F✝] :
                          Fintype (Answer F✝ m✝ d✝)
                          Equations
                          • One or more equations did not get rendered due to their size.
                          def MIPRE.QLD.Question.omega {F : Type u_1} [Field F] {m : ℕ} :
                          Question F m → Omega F m

                          The tuple a question carries, 0 for the types that carry none.

                          Equations
                          Instances For

                            The sample space #

                            structure MIPRE.QLD.Content (F : Type u_2) (m : ℕ) :
                            Type u_2

                            The ambient content of a sample: two points, a seed, a raw diagonal direction, and the two qubit basis elements, all uniform and independent.

                            • uX : LIDT.Point F m

                              The X-side point.

                            • uZ : LIDT.Point F m

                              The Z-side point.

                            • s : F

                              The seed, which selects the axis-parallel direction through χ.

                            • v : LIDT.Point F m

                              The raw diagonal direction.

                            • rX : F

                              The X-side qubit basis element.

                            • rZ : F

                              The Z-side qubit basis element.

                            Instances For
                              def MIPRE.QLD.instDecidableEqContent.decEq {F✝ : Type u_2} {m✝ : ℕ} [DecidableEq F✝] (x✝ x✝¹ : Content F✝ m✝) :
                              Decidable (x✝ = x✝¹)
                              Equations
                              • One or more equations did not get rendered due to their size.
                              Instances For
                                @[instance_reducible]
                                instance MIPRE.QLD.instFintypeContent {F✝ : Type u_2} {m✝ : ℕ} [Fintype F✝] :
                                Fintype (Content F✝ m✝)
                                Equations
                                • One or more equations did not get rendered due to their size.
                                @[reducible, inline]

                                The ordered type pairs the graph distribution puts mass on.

                                Equations
                                Instances For
                                  @[reducible, inline]
                                  abbrev MIPRE.QLD.Sample (F : Type u_2) (m : ℕ) :
                                  Type u_2

                                  A run of the verifier's random choices: an ordered edge of the type graph and the ambient content, drawn independently and uniformly.

                                  Equations
                                  Instances For
                                    def MIPRE.QLD.Content.omega {F : Type u_1} {m : ℕ} (c : Content F m) :
                                    Omega F m

                                    The tuple ω a content carries.

                                    Equations
                                    Instances For
                                      def MIPRE.QLD.Content.pt {F : Type u_1} {m : ℕ} (c : Content F m) :
                                      Bas → LIDT.Point F m

                                      The point of a content on the W side.

                                      Equations
                                      Instances For
                                        noncomputable def MIPRE.QLD.Content.question {F : Type u_1} [Field F] [Fintype F] {m : ℕ} [NeZero m] (hm : m ∣ Fintype.card F) (c : Content F m) :
                                        Ty → Question F m

                                        The question a player of type t receives, the paper's typed CL functions read off the ambient sample. The line types read it exactly as MIPRE.LIDT.CL.Sample.question does, on the point of the relevant basis.

                                        Equations
                                        Instances For
                                          @[simp]
                                          theorem MIPRE.QLD.Content.question_ty {F : Type u_1} [Field F] [Fintype F] {m : ℕ} [NeZero m] (hm : m ∣ Fintype.card F) (c : Content F m) (t : Ty) :
                                          (question hm c t).ty = t

                                          The format check #

                                          def MIPRE.QLD.Question.fmtOk {F : Type u_1} {m d : ℕ} :
                                          Question F m → Answer F m d → Bool

                                          Whether an answer has the format its question's type prescribes, which is the table at the top of fig:decider_pauli. The decider's first step is this check and it rejects if it fails: "first checks that ... a_A and a_B also have the correct length, as can be inferred from the table above. If not, it rejects."

                                          Equations
                                          Instances For

                                            Inverting the format check #

                                            accepts rejects before any rule runs unless both answers have the shape their question's type prescribes, so each rule may be read on one pair of constructors only. These are the inversions, one per answer format; they are what keeps the proofs of the items below to a single branch instead of the forty-nine a blind case split would produce.

                                            theorem MIPRE.QLD.eq_val_of_fmtOk {F : Type u_1} {m d : ℕ} {W : Bas} {y : LIDT.Point F m} {a : Answer F m d} (h : (Question.point W y).fmtOk a = true) :
                                            ∃ (a' : F), a = Answer.val a'
                                            theorem MIPRE.QLD.eq_apoly_of_fmtOk {F : Type u_1} {m d : ℕ} {W : Bas} {u₀ : LIDT.Point F m} {s : F} {a : Answer F m d} (h : (Question.aline W u₀ s).fmtOk a = true) :
                                            ∃ (p : LIDT.LinePoly F d), a = Answer.apoly p
                                            theorem MIPRE.QLD.eq_dpoly_of_fmtOk {F : Type u_1} {m d : ℕ} {W : Bas} {u₀ : LIDT.Point F m} {s : F} {w : LIDT.Point F m} {a : Answer F m d} (h : (Question.dline W u₀ s w).fmtOk a = true) :
                                            ∃ (p : LIDT.LinePoly F (m * d)), a = Answer.dpoly p
                                            theorem MIPRE.QLD.eq_pauliAns_of_fmtOk {F : Type u_1} {m d : ℕ} {W : Bas} {a : Answer F m d} (h : (Question.pauli W).fmtOk a = true) :
                                            ∃ (h' : (Fin m → Bool) → F), a = Answer.pauliAns h'
                                            theorem MIPRE.QLD.eq_bit_of_fmtOk_pairB {F : Type u_1} {m d : ℕ} {W : Bas} {ω : Omega F m} {a : Answer F m d} (h : (Question.pairB W ω).fmtOk a = true) :
                                            ∃ (b : ZMod 2), a = Answer.bit b
                                            theorem MIPRE.QLD.eq_bitPair_of_fmtOk {F : Type u_1} {m d : ℕ} {ω : Omega F m} {a : Answer F m d} (h : (Question.pair ω).fmtOk a = true) :
                                            ∃ (β : Bas → ZMod 2), a = Answer.bitPair β
                                            theorem MIPRE.QLD.eq_bit_of_fmtOk_var {F : Type u_1} {m d : ℕ} {j : Fin LCS.MagicSquare.layout.s} {ω : Omega F m} {a : Answer F m d} (h : (Question.var j ω).fmtOk a = true) :
                                            ∃ (b : ZMod 2), a = Answer.bit b
                                            theorem MIPRE.QLD.eq_bitTriple_of_fmtOk {F : Type u_1} {m d : ℕ} {i : Fin LCS.MagicSquare.layout.r} {ω : Omega F m} {a : Answer F m d} (h : (Question.con i ω).fmtOk a = true) :
                                            ∃ (α : Fin 3 → ZMod 2), a = Answer.bitTriple α

                                            The rules #

                                            noncomputable def MIPRE.QLD.gam {F : Type u_1} [Field F] {m : ℕ} [Algebra (ZMod 2) F] (ω : Omega F m) :

                                            γ(ω), whose vanishing says that the two two-outcome measurements of ω commute (MIPRE.LowDegree.acGamma, blueprint fact:omega-anticomm-prob).

                                            Equations
                                            Instances For
                                              noncomputable def MIPRE.QLD.prb {F : Type u_1} [Field F] [Algebra (ZMod 2) F] (a r : F) :

                                              tr_{q → 2}(a · r), the two-outcome probe of fig:decider_pauli.

                                              Equations
                                              Instances For
                                                def MIPRE.QLD.lowDeg {F : Type u_1} [Field F] [Fintype F] [DecidableEq F] {m n : ℕ} (u₀ w y : LIDT.Point F m) (f : LIDT.LinePoly F n) (a : F) :

                                                The seeded CL decider's line-against-point check at ldc = 1: the point lies on the line and the polynomial evaluated at its parameter is the point answer.

                                                Equations
                                                Instances For
                                                  noncomputable def MIPRE.QLD.pairTest {F : Type u_1} [Field F] [Fintype F] [DecidableEq F] {m d : ℕ} [Algebra (ZMod 2) F] [NeZero m] (hm : m ∣ Fintype.card F) :
                                                  Question F m → Question F m → Answer F m d → Answer F m d → Bool

                                                  The seven rules of fig:decider_pauli, on distinct types and correctly formatted answers. Each rule is stated in both orientations, as the figure's "for w ∈ {A, B}" prescribes; the catch-all is the figure's inherited "in all cases where no action is indicated, accept", and subtests_covers_adj checks it is reached only off the type graph.

                                                  Equations
                                                  Instances For
                                                    noncomputable def MIPRE.QLD.subtests {F : Type u_1} [Field F] [Fintype F] [DecidableEq F] {m d : ℕ} [Algebra (ZMod 2) F] [NeZero m] (hm : m ∣ Fintype.card F) (x y : Question F m) (a b : Answer F m d) :

                                                    The rules of fig:decider_pauli: equal types compare the answers, distinct types run pairTest.

                                                    Equations
                                                    Instances For
                                                      noncomputable def MIPRE.QLD.accepts {F : Type u_1} [Field F] [Fintype F] [DecidableEq F] {m d : ℕ} [Algebra (ZMod 2) F] [NeZero m] (hm : m ∣ Fintype.card F) (x y : Question F m) (a b : Answer F m d) :

                                                      The decision procedure of fig:decider_pauli: the format check, then the rules.

                                                      Equations
                                                      Instances For

                                                        The rules cover the type graph #

                                                        The vacuity failure mode is a rule that is missing, so that an edge of the type graph falls through to the catch-all and the test checks nothing on it. handled lists the type pairs pairTest has a branch for, and handled_of_adj checks by decide that every non-loop edge of fig:type-graph-pauli is among them. Together with the rejection witnesses below --- one per branch, each exhibiting formatted answers that branch rejects --- that is what says no question pair the distribution asks is accepted regardless of the answers.

                                                        The converse fails, and harmlessly: pairTest rejects some non-adjacent pairs too, for instance (Point, X) against Variable_j for j ≠ 0, which the distribution never asks.

                                                        theorem MIPRE.QLD.handled_of_adj (t u : Ty) :
                                                        adj t u = true → t ≠ u → handled t u = true

                                                        Every non-loop edge of the type graph has a rule.

                                                        The low-degree rule is the seeded CL decider #

                                                        fig:decider_pauli says "accept if D^ld_{(q,m,d,1)} accepts", so the rule must be the seeded CL decider of def:lidt-cl at ldc = 1 and not a paraphrase of it. Both halves hold by rfl: MIPRE.LIDT.CL.accepts's own format check is discharged by the formats these two questions carry, and what is left is its lineVsPoint.

                                                        theorem MIPRE.QLD.lowDeg_eq_cl {F : Type u_1} [Field F] [Fintype F] [DecidableEq F] {m d : ℕ} [NeZero m] (hm : m ∣ Fintype.card F) (u₀ : LIDT.Point F m) (s : F) (y : LIDT.Point F m) (f : LIDT.LinePoly F d) (a : F) :
                                                        theorem MIPRE.QLD.lowDeg_eq_cl_dline {F : Type u_1} [Field F] [Fintype F] [DecidableEq F] {m d : ℕ} [NeZero m] (hm : m ∣ Fintype.card F) (u₀ : LIDT.Point F m) (s : F) (w y : LIDT.Point F m) (f : LIDT.LinePoly F (m * d)) (a : F) :
                                                        lowDeg u₀ w y f a = LIDT.CL.accepts hm (LIDT.CL.Question.point y) (LIDT.CL.Question.dline u₀ s w) (LIDT.CL.Answer.values fun (x : Fin 1) => a) (LIDT.CL.Answer.dpolys fun (x : Fin 1) => f)

                                                        Non-vacuity #

                                                        Each of the eight rules is pinned by an explicit pair of answers it rejects, which is what says the rule reads its answers at all. The four rules gated on γ need the gate as a hypothesis: each of them checks nothing on the other value of γ, by design, and that is the point of the gate. MIPRE/LCS/MagicSquare/Game.lean does the same for the Magic Square game itself.

                                                        @[simp]
                                                        theorem MIPRE.QLD.accepts_eq_false_left {F : Type u_1} [Field F] [Fintype F] [DecidableEq F] {m d : ℕ} [Algebra (ZMod 2) F] [NeZero m] {hm : m ∣ Fintype.card F} {x y : Question F m} {a b : Answer F m d} (h : x.fmtOk a = false) :
                                                        accepts hm x y a b = false
                                                        @[simp]
                                                        theorem MIPRE.QLD.accepts_eq_false_right {F : Type u_1} [Field F] [Fintype F] [DecidableEq F] {m d : ℕ} [Algebra (ZMod 2) F] [NeZero m] {hm : m ∣ Fintype.card F} {x y : Question F m} {a b : Answer F m d} (h : y.fmtOk b = false) :
                                                        accepts hm x y a b = false
                                                        theorem MIPRE.QLD.rejects_point_apoly {F : Type u_1} [Field F] [Fintype F] [DecidableEq F] {m d : ℕ} [Algebra (ZMod 2) F] [NeZero m] {hm : m ∣ Fintype.card F} (W : Bas) (y : LIDT.Point F m) (t : Question F m) (f : LIDT.LinePoly F d) (b : Answer F m d) :

                                                        The format check rejects. A point question answered by a polynomial is rejected --- the case whose absence made the seeded CL game vacuous.

                                                        theorem MIPRE.QLD.rejects_pauli_val {F : Type u_1} [Field F] [Fintype F] [DecidableEq F] {m d : ℕ} [Algebra (ZMod 2) F] [NeZero m] {hm : m ∣ Fintype.card F} (W : Bas) (t : Question F m) (a : F) (b : Answer F m d) :

                                                        A (Pauli, W) question answered by a field element is rejected: the answer alphabet there is F_q^M, not F_q.

                                                        theorem MIPRE.QLD.rejects_con_bit {F : Type u_1} [Field F] [Fintype F] [DecidableEq F] {m d : ℕ} [Algebra (ZMod 2) F] [NeZero m] {hm : m ∣ Fintype.card F} (i : Fin LCS.MagicSquare.layout.r) (ω : Omega F m) (t : Question F m) (c : ZMod 2) (b : Answer F m d) :

                                                        A Constraint_i question answered by a single bit is rejected.

                                                        theorem MIPRE.QLD.rejects_var_bitTriple {F : Type u_1} [Field F] [Fintype F] [DecidableEq F] {m d : ℕ} [Algebra (ZMod 2) F] [NeZero m] {hm : m ∣ Fintype.card F} (j : Fin LCS.MagicSquare.layout.s) (ω : Omega F m) (t : Question F m) (α : Fin 3 → ZMod 2) (b : Answer F m d) :

                                                        A Variable_j question answered by a triple is rejected.

                                                        theorem MIPRE.QLD.rejects_disagree {F : Type u_1} [Field F] [Fintype F] [DecidableEq F] {m d : ℕ} [Algebra (ZMod 2) F] [NeZero m] {hm : m ∣ Fintype.card F} {x y : Question F m} {a b : Answer F m d} (h : x.ty = y.ty) (hab : a ≠ b) :
                                                        accepts hm x y a b = false

                                                        Rule 1 rejects. Equal types with unequal answers lose, whatever the answers are.

                                                        theorem MIPRE.QLD.rejects_lowDeg_aline {F : Type u_1} [Field F] [Fintype F] [DecidableEq F] {m d : ℕ} [Algebra (ZMod 2) F] [NeZero m] {hm : m ∣ Fintype.card F} (W : Bas) (u₀ : LIDT.Point F m) (s : F) :

                                                        Rule 2a rejects. The zero polynomial does not evaluate to 1 at the base point.

                                                        theorem MIPRE.QLD.rejects_lowDeg_dline {F : Type u_1} [Field F] [Fintype F] [DecidableEq F] {m d : ℕ} [Algebra (ZMod 2) F] [NeZero m] {hm : m ∣ Fintype.card F} (W : Bas) (u₀ : LIDT.Point F m) (s : F) (v : LIDT.Point F m) :

                                                        Rule 2b rejects.

                                                        theorem MIPRE.QLD.rejects_pauli_consistency {F : Type u_1} [Field F] [Fintype F] [DecidableEq F] {m d : ℕ} [Algebra (ZMod 2) F] [NeZero m] {hm : m ∣ Fintype.card F} (W : Bas) (y : LIDT.Point F m) :

                                                        Rule 3 rejects. The all-zero Pauli outcome has zero low-degree encoding, so it cannot report 1 at a point.

                                                        theorem MIPRE.QLD.accepts_pauli_consistency {F : Type u_1} [Field F] [Fintype F] [DecidableEq F] {m d : ℕ} [Algebra (ZMod 2) F] [NeZero m] {hm : m ∣ Fintype.card F} (W : Bas) (y : LIDT.Point F m) :
                                                        accepts hm (Question.point W y) (Question.pauli W) (Answer.val 0) (Answer.pauliAns fun (x : Fin m → Bool) => 0) = true

                                                        ... and accepts the matching answer.

                                                        theorem MIPRE.QLD.rejects_commutation {F : Type u_1} [Field F] [Fintype F] [DecidableEq F] {m d : ℕ} [Algebra (ZMod 2) F] [NeZero m] {hm : m ∣ Fintype.card F} {ω : Omega F m} (hγ : gam ω = 0) (W : Bas) :

                                                        Rule 4 rejects, on a commuting tuple: the (Pair, W) bit must be the W-component of the Pair answer.

                                                        theorem MIPRE.QLD.accepts_commutation {F : Type u_1} [Field F] [Fintype F] [DecidableEq F] {m d : ℕ} [Algebra (ZMod 2) F] [NeZero m] {hm : m ∣ Fintype.card F} (ω : Omega F m) (W : Bas) (β : Bas → ZMod 2) :

                                                        ... and accepts the matching answer, whatever γ is.

                                                        theorem MIPRE.QLD.rejects_commutation_consistency {F : Type u_1} [Field F] [Fintype F] [DecidableEq F] {m d : ℕ} [Algebra (ZMod 2) F] [NeZero m] {hm : m ∣ Fintype.card F} {ω : Omega F m} (hγ : gam ω = 0) (W : Bas) (y : LIDT.Point F m) :

                                                        Rule 5 rejects, on a commuting tuple: the probe of the point answer must be the (Pair, W) bit.

                                                        Rule 6 rejects an unequal bit, on an anticommuting tuple.

                                                        Rule 6 rejects an assignment that violates its equation, with the bits agreeing: this isolates the parity check from the consistency check.

                                                        Rule 6 rejects an off-support incidence, which the type graph never asks: variable 3 does not occur in equation 0.

                                                        ... and accepts a parity-valid assignment reporting its bit.

                                                        Rule 7 rejects, on an anticommuting tuple: the paper's distinguished pair is (Point, X) against Variable_1, which is var 0 at this file's 0-indexing.

                                                        theorem MIPRE.QLD.accepts_aline_dline {F : Type u_1} [Field F] [Fintype F] [DecidableEq F] {m d : ℕ} [Algebra (ZMod 2) F] [NeZero m] {hm : m ∣ Fintype.card F} (W W' : Bas) (u₀ u₀' : LIDT.Point F m) (s s' : F) (v : LIDT.Point F m) (f : LIDT.LinePoly F d) (g : LIDT.LinePoly F (m * d)) :
                                                        accepts hm (Question.aline W u₀ s) (Question.dline W' u₀' s' v) (Answer.apoly f) (Answer.dpoly g) = true

                                                        The catch-all accepts, as fig:ld-decider's "in all cases where no action is indicated, accept" prescribes. The two line types are never asked together --- they are not adjacent --- so this costs the test nothing.

                                                        The game #

                                                        noncomputable def MIPRE.QLD.qldGame {F : Type u_1} [Field F] [Fintype F] [DecidableEq F] {m d : ℕ} [Algebra (ZMod 2) F] [NeZero m] (hm : m ∣ Fintype.card F) :
                                                        Game (Question F m) (Question F m) (Answer F m d) (Answer F m d)

                                                        The Pauli basis test as a game (blueprint def:qld-game).

                                                        Equations
                                                        • One or more equations did not get rendered due to their size.
                                                        Instances For
                                                          @[simp]
                                                          theorem MIPRE.QLD.qldGame_D {F : Type u_1} [Field F] [Fintype F] [DecidableEq F] {m d : ℕ} [Algebra (ZMod 2) F] [NeZero m] (hm : m ∣ Fintype.card F) (x y : Question F m) (a b : Answer F m d) :
                                                          (qldGame hm).D x y a b = accepts hm x y a b