Documentation

Complexitylib.Classes.PCP.Internal.AlgPreRot

Reading a half-edge's endpoint #

A half-edge is numbered 2 e or 2 e + 1 according to which end of edge e it is, so the vertex it hangs from is one of that edge's two endpoints — and both are written down in the encoded graph. Halving the number picks the edge, its parity picks the end.

Main definitions #

Main results #

Main results #

noncomputable def Complexity.ownerFn (z : List Bool) :

The vertex a half-edge hangs from, on pair (encoded graph) (unary p).

Equations
  • One or more equations did not get rendered due to their size.
Instances For

    Counting a cloud #

    noncomputable def Complexity.cloudMark (w : List Bool) :

    One mark when the half-edge j hangs from the vertex asked for. The argument is pair (pair (encoded graph) (unary u)) (unary j).

    Equations
    • One or more equations did not get rendered due to their size.
    Instances For
      noncomputable def Complexity.cloudSizeFn (z : List Bool) :

      How many half-edges hang from the vertex asked for, on pair (encoded graph) (unary u).

      Equations
      • One or more equations did not get rendered due to their size.
      Instances For
        theorem Complexity.length_cloudSizeFn (Gz u : List Bool) (m : ) (hm : (mulC 2 (posCount (pairSnd Gz))).length = m) :

        The count is the number of half-edges the rule accepts.

        noncomputable def Complexity.cloudIdxFn (z : List Bool) :

        How many half-edges before this one hang from the same vertex, on pair (encoded graph) (unary p).

        Equations
        • One or more equations did not get rendered due to their size.
        Instances For

          The index is the number of earlier half-edges in the same cloud.

          Finding a cloud's members #

          noncomputable def Complexity.eltMark (w : List Bool) :

          One mark when the half-edge c is the k-th of the cloud of u. The argument is pair (pair (encoded graph) (pair (unary u) (unary k))) (unary c).

          Equations
          • One or more equations did not get rendered due to their size.
          Instances For
            theorem Complexity.length_eltMark (Gz u k c : List Bool) :
            (eltMark (pair (pair Gz (pair u k)) c)).length = if (ownerFn (pair Gz c)).length = u.length then if (cloudIdxFn (pair Gz c)).length = k.length then 1 else 0 else 0
            noncomputable def Complexity.cloudEltFn (z : List Bool) :

            The k-th half-edge of the cloud of u, on pair (encoded graph) (pair (unary u) (unary k)).

            Equations
            • One or more equations did not get rendered due to their size.
            Instances For

              The reading is the owner.

              Counting numbers is counting half-edges.

              Counting numbers below a bound is counting codes below it.

              What the counts compute #

              The size the algorithm counts is the size of the cloud.

              The index the algorithm counts is the position in the cloud.

              theorem Complexity.halfCode_lt {α : Type} (G : ConstraintGraph α) (p : G.HalfEdge) :

              The code of a half-edge is below twice the edge count.

              The search finds the k-th half-edge of the cloud.

              The two moves that need the expander #

              noncomputable def Complexity.cloudStepFn (F : FinBase) (pol : Polynomial ) (z : List Bool) :

              The cloud move, on pair (pair (graph) (unary owner)) (pair (unary code) (unary dart)): rotate the half-edge's index inside its cloud, then read off the half-edge the new index names.

              Equations
              • One or more equations did not get rendered due to their size.
              Instances For
                noncomputable def Complexity.expStepFn (F : FinBase) (pol : Polynomial ) (z : List Bool) :

                The expander move, on pair (graph) (pair (unary vertex) (unary dart)).

                Equations
                • One or more equations did not get rendered due to their size.
                Instances For
                  theorem Complexity.cloudStepFn_eq {α : Type} [Fintype α] [DecidableEq α] (G : ConstraintGraph α) (F : FinBase) (pol : Polynomial ) (hd : 1 < F.deg) (v : Fin G.numVerts) (c j : ) (hc : c < 2 * G.numEdges) (hown : G.ownerNum c = v) (hj : j < (F.toFamily hd).degree) (hp : F.fitLevel hd (G.cloudList v).length Polynomial.eval (G.cloudList v).length pol) :

                  The cloud move computes what it should.

                  theorem Complexity.expStepFn_eq {α : Type} [Fintype α] [DecidableEq α] (G : ConstraintGraph α) (F : FinBase) (pol : Polynomial ) (hd : 1 < F.deg) (v j : ) (hn : 0 < 2 * G.numEdges) (hp : F.fitLevel hd (2 * G.numEdges) Polynomial.eval (2 * G.numEdges) pol) :

                  The expander move computes what it should.

                  The whole rotation map #

                  noncomputable def Complexity.flipFn (v : List Bool) :

                  Crossing an edge: flip the last bit of the vertex number.

                  Equations
                  Instances For
                    theorem Complexity.flipFn_mem_FP {f : List BoolList Bool} (hf : f FP) :
                    (fun (z : List Bool) => flipFn (f z)) FP
                    noncomputable def Complexity.preRotFn (F : FinBase) (pol : Polynomial ) (deg : ) (z : List Bool) :

                    The preprocessed graph's rotation map, on pair (graph) (pair (unary vertex) (unary dart)). Dart 0 is the self-loop, dart 1 crosses the edge, the next deg are the cloud's, and the rest are the superposed expander's.

                    Equations
                    • One or more equations did not get rendered due to their size.
                    Instances For
                      theorem Complexity.preRotFn_mem_FP (F : FinBase) (pol : Polynomial ) (deg : ) :
                      preRotFn F pol deg FP
                      theorem Complexity.preRotFn_eq {α : Type} [Fintype α] [DecidableEq α] (G : ConstraintGraph α) (F : FinBase) (pol : Polynomial ) (hd : 1 < F.deg) (v d : ) (hv : v < 2 * G.numEdges) (hdlt : d < 2 + 2 * (F.toFamily hd).degree) (hpc : ∀ (u : Fin G.numVerts), F.fitLevel hd (G.cloudList u).length Polynomial.eval (G.cloudList u).length pol) (hpe : F.fitLevel hd (2 * G.numEdges) Polynomial.eval (2 * G.numEdges) pol) :

                      The whole rotation map computes what it should.