Documentation

LeanPool.BlockSpectralSensitivity.LLL.GateExists

The local lemma produces a good gate labelling #

This file proves the existence of a gate labelling satisfying the local certificate-list conditions, and corresponds to Section 10 of bs_lambda.txt.

There are two families of bad events (Section 10):

Two events are declared adjacent when their vertex supports meet in at least two vertices. This is a legitimate dependency graph: by disjoint_offDiag_of_card_inter_le_one, supports meeting in at most one vertex use disjoint sets of gate variables.

The dependency counts of Section 10.1 are D11, D12, D21, D22 from BSLambda/Numerics/LLLBounds.lean, where the two local-lemma inequalities lll_cond_one and lll_cond_two have already been verified in exact rational arithmetic. Feeding all of this into pr_avoid_pos_two_type gives a configuration avoiding every bad event, and Section 10.3 turns that into the conditions (L1) and (L2).

Adapted for Lean Pool from Timeroot/BS_Lam at commit 7bd39a8d41ee7910d3296d0477ad18f8fff9d870; ported to Lean Pool with proof and dependency cleanup.

The index type of bad events #

def BSLambda.LLL.BadIdx {ι : Type u_1} [DecidableEq ι] (Arc : ι → ι → Bool) :
Type u_1

The bad events (Section 10): an active radius-one flag, or a nine-element support carrying the consolidated radius-two obstruction. Inactive flags and supports of the wrong size are excluded, because the dependency counts of Section 10.1 count only the active patterns.

Equations
Instances For
    @[instance_reducible]
    noncomputable instance BSLambda.LLL.instFintypeBadIdx {ι : Type u_1} [Fintype ι] [DecidableEq ι] {Arc : ι → ι → Bool} :
    Equations
    @[instance_reducible]
    instance BSLambda.LLL.instDecidableEqBadIdx {ι : Type u_1} [DecidableEq ι] {Arc : ι → ι → Bool} :
    Equations
    def BSLambda.LLL.badVerts {ι : Type u_1} [DecidableEq ι] {Arc : ι → ι → Bool} :
    BadIdx Arc → Finset ι

    The vertex support of a bad event: five vertices for type 1, nine for type 2.

    Equations
    Instances For
      def BSLambda.LLL.badSupp {ι : Type u_1} [DecidableEq ι] {Arc : ι → ι → Bool} (i : BadIdx Arc) :
      Finset (ι × ι)

      The variable support of a bad event: the arc variables internal to its vertices, that is, the off-diagonal pairs of badVerts i.

      Equations
      Instances For
        def BSLambda.LLL.badTy {ι : Type u_1} [DecidableEq ι] {Arc : ι → ι → Bool} :
        BadIdx Arc → Bool

        The type of a bad event: false for radius one, true for radius two.

        Equations
        Instances For
          theorem BSLambda.LLL.exists_inl_of_badTy_eq_false {ι : Type u_1} [DecidableEq ι] {Arc : ι → ι → Bool} {j : BadIdx Arc} (hj : badTy j = false) :
          ∃ (F : { F : Flag1 ι // F.Active Arc }), j = Sum.inl F

          A bad event of type false is an active radius-one flag.

          theorem BSLambda.LLL.exists_inr_of_badTy_eq_true {ι : Type u_1} [DecidableEq ι] {Arc : ι → ι → Bool} {j : BadIdx Arc} (hj : badTy j = true) :
          ∃ (S : { S : Finset ι // S.card = 9 }), j = Sum.inr S

          A bad event of type true is a nine-element vertex support.

          noncomputable def BSLambda.LLL.badEvent {ι : Type u_1} [Fintype ι] [DecidableEq ι] {r : ℕ} (Arc : ι → ι → Bool) :
          BadIdx Arc → Finset (GateCfg ι r)

          The bad event itself, as a set of gate configurations.

          Equations
          • One or more equations did not get rendered due to their size.
          Instances For
            noncomputable def BSLambda.LLL.badP :
            Bool → ℝ

            The probability bound for each type (Sections 8.1 and 9).

            Equations
            Instances For
              noncomputable def BSLambda.LLL.badX :
              Bool → ℝ

              The local-lemma weights of Section 10.2.

              Equations
              Instances For

                The hypotheses of the local lemma #

                theorem BSLambda.LLL.badEvent_determined {ι : Type u_1} [Fintype ι] [DecidableEq ι] {r : ℕ} {Arc : ι → ι → Bool} (hT : IsTournament Arc) (i : BadIdx Arc) :

                Each bad event depends only on the arc variables internal to its own support (Section 10).

                theorem BSLambda.LLL.pr_badEvent_le {ι : Type u_1} [Fintype ι] [DecidableEq ι] {r : ℕ} {Arc : ι → ι → Bool} [NeZero r] (hT : IsTournament Arc) (hr : r = 144) (i : BadIdx Arc) :
                pr (badEvent Arc i) ≤ badP (badTy i)

                Each bad event of type t has probability at most badP t (Sections 8.1 and 9).

                theorem BSLambda.LLL.two_le_card_inter_of_mem_nbr {ι : Type u_1} [Fintype ι] [DecidableEq ι] {Arc : ι → ι → Bool} {i j : BadIdx Arc} (h : j ∈ nbr badSupp i) :

                Two adjacent bad events have vertex supports meeting in at least two vertices: sharing a gate variable forces sharing two vertices (Section 10).

                Counting helpers for the dependency bounds (Section 10.1) #

                theorem BSLambda.LLL.exists_pair_subset_of_two_le_card_inter {ι : Type u_1} [DecidableEq ι] {V W : Finset ι} (h : 2 ≤ (V ∩ W).card) :
                ∃ p ∈ Finset.powersetCard 2 V, p ⊆ W

                Two vertices shared between V and W yield a two-element subset of V contained in W. This is what turns two_le_card_inter_of_mem_nbr into "the neighbour's support contains one of the C(|V|,2) pairs of V" (Section 10.1).

                theorem BSLambda.LLL.card_filter_card_inter_eq {ι : Type u_1} [Fintype ι] [DecidableEq ι] (V : Finset ι) {s m : ℕ} (hsm : s ≤ m) :
                {S : Finset ι | S.card = m ∧ (V ∩ S).card = s}.card = V.card.choose s * (Fintype.card ι - V.card).choose (m - s)

                The m-element subsets of ι meeting a fixed V in exactly s vertices are counted by choosing the s shared vertices inside V and the other m - s outside V (Section 10.1); this is the Finset-level refinement of Vandermonde's identity.

                theorem BSLambda.LLL.card_filter_two_le_card_inter_le {ι : Type u_1} [Fintype ι] [DecidableEq ι] (V : Finset ι) {m : ℕ} (hvm : V.card ≤ m) :
                {S : Finset ι | S.card = m ∧ 2 ≤ (V ∩ S).card}.card ≤ ∑ s ∈ Finset.Icc 2 V.card, V.card.choose s * (Fintype.card ι - V.card).choose (m - s)

                Summing card_filter_card_inter_eq over the possible intersection sizes bounds the number of m-element subsets meeting V in at least two vertices (Section 10.1).

                From dependency neighbourhoods to vertex supports (Section 10.1) #

                theorem BSLambda.LLL.badVerts_mem_filter_of_mem_nbr {ι : Type u_1} [Fintype ι] [DecidableEq ι] {Arc : ι → ι → Bool} {i j : BadIdx Arc} (hj : j ∈ {j ∈ nbr badSupp i | badTy j = true}) :
                badVerts j ∈ {S : Finset ι | S.card = 9 ∧ 2 ≤ (badVerts i ∩ S).card}

                The vertex support of a type-two neighbour of a bad event is a nine-element set meeting the event's own vertex set in at least two vertices (Section 10.1).

                theorem BSLambda.LLL.badVerts_injOn_type_two {ι : Type u_1} [Fintype ι] [DecidableEq ι] {Arc : ι → ι → Bool} (i : BadIdx Arc) :
                Set.InjOn badVerts ↑({j ∈ nbr badSupp i | badTy j = true})

                A type-two bad event is determined by its vertex support, so the type-two neighbours of a bad event are counted by their supports (Section 10.1).

                theorem BSLambda.LLL.card_nbr_type_two_le {ι : Type u_1} [Fintype ι] [DecidableEq ι] {Arc : ι → ι → Bool} (i : BadIdx Arc) :
                {j ∈ nbr badSupp i | badTy j = true}.card ≤ {S : Finset ι | S.card = 9 ∧ 2 ≤ (badVerts i ∩ S).card}.card

                The type-two neighbours of a bad event are counted by the nine-element supports meeting its vertex set in at least two vertices (Section 10.1).

                theorem BSLambda.LLL.card_nbr_type_two_two_le {ι : Type u_1} [Fintype ι] [DecidableEq ι] {Arc : ι → ι → Bool} (S : { S : Finset ι // S.card = 9 }) :
                {j ∈ nbr badSupp (Sum.inr S) | badTy j = true}.card ≤ {T : Finset ι | T.card = 9 ∧ 2 ≤ (↑S ∩ T).card}.card - 1

                Sharpened form of card_nbr_type_two_le for a type-two event: its own support is not one of its neighbours, which is the - 1 in D22.

                theorem BSLambda.LLL.card_nbr_type_one_le {ι : Type u_1} [Fintype ι] [DecidableEq ι] {Arc : ι → ι → Bool} (i : BadIdx Arc) :
                {j ∈ nbr badSupp i | badTy j = false}.card ≤ ∑ p ∈ Finset.powersetCard 2 (badVerts i), {G : Flag1 ι | G.Active Arc ∧ p ⊆ G.supp}.card

                Every type-one neighbour of a bad event is an active flag whose support contains one of the C(|V|,2) pairs of the event's vertex set V (Section 10.1).

                Active radius-one flags through a fixed pair (Section 8.2) #

                def BSLambda.LLL.headOut {ι : Type u_1} [Fintype ι] [DecidableEq ι] (Arc : ι → ι → Bool) (q : ι × Option ι) :

                The common out-neighbourhood of a flag head (Section 8.2): the vertices dominated by the owner q.1 and, when it is present, by the top vertex q.2. The bottom set of an active flag is a subset of this (Flag1.Active.bot_subset_headOut), and its size is d = 7005 for a Type-A head and t = 3502 for a Type-B head.

                Equations
                Instances For
                  @[simp]
                  theorem BSLambda.LLL.headOut_none {ι : Type u_1} [Fintype ι] [DecidableEq ι] {Arc : ι → ι → Bool} (o : ι) :
                  headOut Arc (o, none) = outNbrs Arc o

                  The common out-neighbourhood of a Type-A head is the out-neighbourhood of the owner.

                  @[simp]
                  theorem BSLambda.LLL.headOut_some {ι : Type u_1} [Fintype ι] [DecidableEq ι] {Arc : ι → ι → Bool} (o a : ι) :
                  headOut Arc (o, some a) = commonOut Arc o a

                  The common out-neighbourhood of a Type-B head is the set of common out-neighbours of the owner and the top vertex.

                  theorem BSLambda.LLL.Flag1.Active.bot_subset_headOut {ι : Type u_1} [Fintype ι] [DecidableEq ι] {Arc : ι → ι → Bool} {G : Flag1 ι} (hG : G.Active Arc) :
                  G.bot ⊆ headOut Arc (G.owner, G.top)

                  The bottom set of an active flag lies in the common out-neighbourhood of its head.

                  theorem BSLambda.LLL.card_flags_le_mul_choose {ι : Type u_1} [Fintype ι] [DecidableEq ι] {Arc : ι → ι → Bool} {P : Flag1 ι → Prop} [DecidablePred P] {H : Finset (ι × Option ι)} {W : Finset ι} {c N : ℕ} (hact : ∀ (G : Flag1 ι), P G → G.Active Arc) (hhead : ∀ (G : Flag1 ι), P G → (G.owner, G.top) ∈ H) (hW : ∀ (G : Flag1 ι), P G → W ⊆ G.bot) (hbot : ∀ (G : Flag1 ι), P G → G.bot.card = c) (hN : ∀ (G : Flag1 ι), P G → (headOut Arc (G.owner, G.top) \ W).card ≤ N) :

                  The counting scheme behind all six flag counts of Section 8.2. An active flag is determined by its head (owner, top) together with its bottom set, and the bottom set is a c-element subset of the common out-neighbourhood of the head containing the forced vertices W. So if every flag satisfying P has its head in H and at most N unforced candidates for the remaining c - |W| bottom vertices, there are at most |H| * C(N, c - |W|) of them.

                  theorem BSLambda.LLL.card_typeA_owner_bot {ι : Type u_1} [Fintype ι] [DecidableEq ι] {Arc : ι → ι → Bool} {d t : ℕ} (hT : IsDRTournamentWith Arc d t) {u v : ι} :
                  {G : Flag1 ι | G.Active Arc ∧ G.top = none ∧ G.owner = u ∧ v ∈ G.bot}.card ≤ (d - 1).choose 3

                  Section 8.2, Type A, the fixed pair being owner and bottom vertex: at most C(d-1,3) such flags, specializing to C(7004,3) in the construction.

                  theorem BSLambda.LLL.card_typeA_bot_bot {ι : Type u_1} [Fintype ι] [DecidableEq ι] {Arc : ι → ι → Bool} {d t : ℕ} (hT : IsDRTournamentWith Arc d t) {u v : ι} (huv : u ≠ v) :
                  {G : Flag1 ι | G.Active Arc ∧ G.top = none ∧ u ∈ G.bot ∧ v ∈ G.bot}.card ≤ t * (d - 2).choose 2

                  Section 8.2, Type A with an owner outside the fixed pair: at most t * C(d-2,2) such flags, with d = 7005, t = 3502 in the construction.

                  theorem BSLambda.LLL.card_typeA_through_pair {ι : Type u_1} [Fintype ι] [DecidableEq ι] {Arc : ι → ι → Bool} (hT : IsDRTournamentWith Arc 7005 3502) {u v : ι} (huv : u ≠ v) (harc : Arc u v = true) :
                  {G : Flag1 ι | G.Active Arc ∧ G.top = none ∧ u ∈ G.supp ∧ v ∈ G.supp}.card ≤ 143100492510

                  Section 8.2: at most N_A = C(d-1,3) + t C(d-2,2) = 143,100,492,510 Type-A flags pass through the ordered pair u → v. The case owner = v is empty: it needs the reverse arc.

                  theorem BSLambda.LLL.card_typeB_top_owner {ι : Type u_1} [Fintype ι] [DecidableEq ι] {Arc : ι → ι → Bool} {d t : ℕ} (hT : IsDRTournamentWith Arc d t) {u v : ι} (huv : u ≠ v) :
                  {G : Flag1 ι | G.Active Arc ∧ G.top = some u ∧ G.owner = v}.card ≤ t.choose 3

                  Section 8.2, Type B, the fixed pair being the ordered top pair (a, h) = (u, v): at most C(t,3) such flags, with t = 3502 in the construction.

                  theorem BSLambda.LLL.card_typeB_top_bot {ι : Type u_1} [Fintype ι] [DecidableEq ι] {Arc : ι → ι → Bool} {d t : ℕ} (hT : IsDRTournamentWith Arc d t) {u v : ι} (harc : Arc u v = true) :
                  {G : Flag1 ι | G.Active Arc ∧ G.top = some u ∧ v ∈ G.bot}.card ≤ t * (t - 1).choose 2

                  Section 8.2, Type B with u the upper top vertex and v a bottom vertex: at most t * C(t-1,2) such flags, with t = 3502 in the construction.

                  theorem BSLambda.LLL.card_typeB_owner_bot {ι : Type u_1} [Fintype ι] [DecidableEq ι] {Arc : ι → ι → Bool} {d t : ℕ} (hT : IsDRTournamentWith Arc d t) {u v : ι} (huv : u ≠ v) :
                  {G : Flag1 ι | G.Active Arc ∧ G.top ≠ none ∧ G.owner = u ∧ v ∈ G.bot}.card ≤ t * (t - 1).choose 2

                  Section 8.2, Type B with u the owner and v a bottom vertex: at most t * C(t-1,2) such flags, with t = 3502 in the construction.

                  theorem BSLambda.LLL.card_typeB_bot_bot {ι : Type u_1} [Fintype ι] [DecidableEq ι] {Arc : ι → ι → Bool} {d t : ℕ} (hT : IsDRTournamentWith Arc d t) {u v : ι} (huv : u ≠ v) :
                  {G : Flag1 ι | G.Active Arc ∧ G.top ≠ none ∧ u ∈ G.bot ∧ v ∈ G.bot}.card ≤ t.choose 2 * (t - 2)

                  Section 8.2, Type B with both fixed vertices at the bottom: the top pair is one of the C(t,2) arcs between the common in-neighbours of u and v, and the third bottom vertex is one of t - 2, giving at most C(t,2) * (t-2) such flags.

                  theorem BSLambda.LLL.card_typeB_through_pair {ι : Type u_1} [Fintype ι] [DecidableEq ι] {Arc : ι → ι → Bool} (hT : IsDRTournamentWith Arc 7005 3502) {u v : ι} (huv : u ≠ v) (harc : Arc u v = true) :
                  {G : Flag1 ι | G.Active Arc ∧ G.top ≠ none ∧ u ∈ G.supp ∧ v ∈ G.supp}.card ≤ 71519595000

                  Section 8.2: at most N_B = C(t,3) + 2 t C(t-1,2) + C(t,2)(t-2) = 71,519,595,000 Type-B flags pass through the ordered pair u → v. Of the nine possible pairs of roles for u and v, two are impossible and three need the reverse arc v → u.

                  theorem BSLambda.LLL.card_active_flag_through_ordered_pair {ι : Type u_1} [Fintype ι] [DecidableEq ι] {Arc : ι → ι → Bool} (hT : IsDRTournamentWith Arc 7005 3502) {u v : ι} (huv : u ≠ v) (harc : Arc u v = true) :
                  {G : Flag1 ι | G.Active Arc ∧ u ∈ G.supp ∧ v ∈ G.supp}.card ≤ 214620087510

                  Section 8.2: at most N_1 = N_A + N_B = 214,620,087,510 active flags pass through the ordered pair u → v.

                  theorem BSLambda.LLL.card_active_flag_through_pair {ι : Type u_1} [Fintype ι] [DecidableEq ι] {Arc : ι → ι → Bool} (hT : IsDRTournamentWith Arc 7005 3502) {p : Finset ι} (hp : p.card = 2) :
                  {G : Flag1 ι | G.Active Arc ∧ p ⊆ G.supp}.card ≤ 214620087510

                  Section 8.2: at most N_1 active flags pass through any two-element vertex set.

                  The four reduced dependency counts #

                  theorem BSLambda.LLL.card_nbr_one_one_le_D11 {ι : Type u_1} [Fintype ι] [DecidableEq ι] {Arc : ι → ι → Bool} (hT : IsDRTournamentWith Arc 7005 3502) (F : { F : Flag1 ι // F.Active Arc }) :

                  A type-one event has at most D11 type-one neighbours (Section 10.1).

                  theorem BSLambda.LLL.card_nbr_one_two_le_D12 {ι : Type u_1} [Fintype ι] [DecidableEq ι] {Arc : ι → ι → Bool} (hk : Fintype.card ι = 14011) (F : { F : Flag1 ι // F.Active Arc }) :

                  A type-one event has at most D12 type-two neighbours (Section 10.1).

                  theorem BSLambda.LLL.card_nbr_two_one_le_D21 {ι : Type u_1} [Fintype ι] [DecidableEq ι] {Arc : ι → ι → Bool} (hT : IsDRTournamentWith Arc 7005 3502) (S : { S : Finset ι // S.card = 9 }) :

                  A type-two event has at most D21 type-one neighbours (Section 10.1).

                  theorem BSLambda.LLL.card_nbr_two_two_le_D22 {ι : Type u_1} [Fintype ι] [DecidableEq ι] {Arc : ι → ι → Bool} (hk : Fintype.card ι = 14011) (S : { S : Finset ι // S.card = 9 }) :

                  A type-two event has at most D22 other type-two neighbours (Section 10.1).

                  theorem BSLambda.LLL.card_nbr_le {ι : Type u_1} [Fintype ι] [DecidableEq ι] {Arc : ι → ι → Bool} (hk : Fintype.card ι = 14011) (hT : IsDRTournamentWith Arc 7005 3502) (i : BadIdx Arc) (t : Bool) :
                  {j ∈ nbr badSupp i | badTy j = t}.card ≤ badD (badTy i) t

                  The dependency counts, packaged as required by pr_avoid_pos_two_type. Double regularity is what pins the number N_1 of active flags through a pair (Section 8.2).

                  The two local-lemma inequalities of Section 10.2, in the shape required by pr_avoid_pos_two_type.

                  theorem BSLambda.LLL.badX_pos (t : Bool) :
                  0 < badX t

                  The weights are positive.

                  theorem BSLambda.LLL.badX_lt_one (t : Bool) :
                  badX t < 1

                  The weights are less than one.

                  The good configuration #

                  theorem BSLambda.LLL.exists_good_config {ι : Type u_1} [Fintype ι] [DecidableEq ι] {r : ℕ} {Arc : ι → ι → Bool} [NeZero r] (hk : Fintype.card ι = 14011) (hT : IsDRTournamentWith Arc 7005 3502) (hr : r = 144) :
                  ∃ (ω : GateCfg ι r), ∀ (i : BadIdx Arc), ω ∉ badEvent Arc i

                  Section 10.2: some gate configuration avoids every bad event.

                  Consequences for certificate lists (Section 10.3) #

                  theorem BSLambda.LLL.not_intObstruction_five {ι : Type u_1} [Fintype ι] [DecidableEq ι] {r : ℕ} {Arc : ι → ι → Bool} (hT : IsTournament Arc) {ω : GateCfg ι r} (hgood : ∀ (i : BadIdx Arc), ω ∉ badEvent Arc i) {S : Finset ι} (hS : S.card = 5) {h : ι} (hh : h ∈ S) (hobs : IntObstruction Arc 1 S h (toGamma ω)) :

                  Section 10.3: a good configuration admits no radius-one internal obstruction on a five-element support: mem_flagEvent_of_intObstruction would produce an active flag whose event contains ω.

                  theorem BSLambda.LLL.not_intObstruction_nine {ι : Type u_1} [Fintype ι] [DecidableEq ι] {r : ℕ} {Arc : ι → ι → Bool} {ω : GateCfg ι r} (hgood : ∀ (i : BadIdx Arc), ω ∉ badEvent Arc i) {S : Finset ι} (hS : S.card = 9) {h : ι} (hh : h ∈ S) (hobs : IntObstruction Arc 2 S h (toGamma ω)) :

                  Section 10.3: a good configuration admits no radius-two internal obstruction on a nine-element support, since such an obstruction puts ω into radiusTwoEvent.

                  theorem BSLambda.LLL.not_close_five {ι : Type u_1} [Fintype ι] [DecidableEq ι] {r : ℕ} {Arc : ι → ι → Bool} (hT : IsTournament Arc) {ω : GateCfg ι r} (hgood : ∀ (i : BadIdx Arc), ω ∉ badEvent Arc i) {S : Finset ι} (hS : S.card = 5) {h : ι} (hh : h ∈ S) {x : Input (Construction.Coord ι r)} (hx : (Construction.cert Arc (toGamma ω) h).Sat x) (hclose : ∀ i ∈ S, i ≠ h → (Construction.cert Arc (toGamma ω) i).dist x ≤ 1) :

                  Section 10.3: a positive point of C_h cannot have four further certificates of a five-element support at distance at most one.

                  theorem BSLambda.LLL.not_close_nine {ι : Type u_1} [Fintype ι] [DecidableEq ι] {r : ℕ} {Arc : ι → ι → Bool} (hT : IsTournament Arc) {ω : GateCfg ι r} (hgood : ∀ (i : BadIdx Arc), ω ∉ badEvent Arc i) {S : Finset ι} (hS : S.card = 9) {h : ι} (hh : h ∈ S) {x : Input (Construction.Coord ι r)} (hx : (Construction.cert Arc (toGamma ω) h).Sat x) (hclose : ∀ i ∈ S, i ≠ h → (Construction.cert Arc (toGamma ω) i).dist x ≤ 2) :

                  Section 10.3: a positive point of C_h cannot have eight further certificates of a nine-element support at distance at most two.

                  theorem BSLambda.LLL.card_filter_le_of_no_support {ι : Type u_1} [Fintype ι] [DecidableEq ι] {P : ι → Prop} [DecidablePred P] {h : ι} {m : ℕ} (hno : ∀ (S : Finset ι), S.card = m + 2 → h ∈ S → (∀ i ∈ S, i ≠ h → P i) → False) :
                  {j : ι | j ≠ h ∧ P j}.card ≤ m

                  The counting step behind both (L1) and (L2): if adjoining h to any m + 1 indices satisfying P gives a support on which P is impossible, then at most m indices other than h satisfy P.

                  theorem BSLambda.LLL.card_le_three_of_good {ι : Type u_1} [Fintype ι] [DecidableEq ι] {r : ℕ} {Arc : ι → ι → Bool} (hT : IsTournament Arc) {ω : GateCfg ι r} (hgood : ∀ (i : BadIdx Arc), ω ∉ badEvent Arc i) (h : ι) (x : Input (Construction.Coord ι r)) (hx : (Construction.cert Arc (toGamma ω) h).Sat x) :
                  {j : ι | j ≠ h ∧ (Construction.cert Arc (toGamma ω) j).dist x = 1}.card ≤ 3

                  (L1) (Section 10.3): a positive point has at most three other certificates at distance one.

                  theorem BSLambda.LLL.card_le_seven_of_good {ι : Type u_1} [Fintype ι] [DecidableEq ι] {r : ℕ} {Arc : ι → ι → Bool} (hT : IsTournament Arc) {ω : GateCfg ι r} (hgood : ∀ (i : BadIdx Arc), ω ∉ badEvent Arc i) (h : ι) (x : Input (Construction.Coord ι r)) (hx : (Construction.cert Arc (toGamma ω) h).Sat x) :
                  {j : ι | j ≠ h ∧ (Construction.cert Arc (toGamma ω) j).dist x ≤ 2}.card ≤ 7

                  (L2) (Section 10.3): a positive point has at most seven other certificates at distance at most two.

                  theorem BSLambda.LLL.exists_gate_labelling {ι : Type u_1} [Fintype ι] [DecidableEq ι] {r : ℕ} {Arc : ι → ι → Bool} [NeZero r] (hk : Fintype.card ι = 14011) (hT : IsDRTournamentWith Arc 7005 3502) (hr : r = 144) :
                  ∃ (γ : ι → ι → Fin r), (∀ (h : ι) (x : Input (Construction.Coord ι r)), (Construction.cert Arc γ h).Sat x → {j : ι | j ≠ h ∧ (Construction.cert Arc γ j).dist x = 1}.card ≤ 3) ∧ ∀ (h : ι) (x : Input (Construction.Coord ι r)), (Construction.cert Arc γ h).Sat x → {j : ι | j ≠ h ∧ (Construction.cert Arc γ j).dist x ≤ 2}.card ≤ 7

                  Section 10: a gate labelling satisfying the local certificate-list conditions (L1) and (L2) exists.