Documentation

DescriptiveComplexity.Problems.Pcp.Cert

A match, read off as a finite certificate #

The mathematical content of DescriptiveComplexity.PCP ∈ RE: a Post system has a match exactly when a finite amount of data witnesses it, and that data is a handful of relations over the instance extended by a segment of invented slots – the places of the sequence of dominoes.

The shape of the certificate #

DescriptiveComplexity.Pcp.Cert is the data:

The common word is not invented, and no length or position of it is ever named. The top concatenation is cut into blocks by the slots, so its letters are indexed by the pairs (slot, position of the top word of the domino there), in lexicographic order (DescriptiveComplexity.Pcp.parseIx); the bottom concatenation is indexed the same way by its own parse. Mt s p s' p' says that the letter at the top index (s, p) is the same occurrence as the letter at the bottom index (s', p').

Why a matching is as good as an equality #

Equality of the two concatenations is not first-order in the instance: it compares two words of unbounded length. A matching is a relation variable, and what a kernel can ask of it is local: that it lands in the two parses, that it is defined everywhere on both, that it reflects the two lexicographic orders, and that matched indices carry the same letter. That is already enough (DescriptiveComplexity.Pcp.forall₂_of_matching): a relation between the members of two strictly sorted lists that is total on both sides and reflects the order pairs their entries index by index, so the two concatenations agree letter by letter. Functionality and injectivity of the matching are not asked: they follow.

The two directions of DescriptiveComplexity.Pcp.pcpOn_iff_cert are therefore not symmetric in effort. A match hands its matching back for free – the two parses have the same length, so pairing them index by index (DescriptiveComplexity.Pcp.IdxMatch) does it – while a certificate has to rebuild the two words from their enumerations before the matching lemma applies.

The certificate #

A match of a Post correspondence system, as relations on a segment of invented slots. SLe orders the slots; Dm s d says the domino d sits at the slot s; Mt s p s' p' matches the position p of the top word at the slot s with the position p' of the bottom word at the slot s', as occurrences of the same letter of the common word.

  • SLe : DDProp

    The order of the slots.

  • Dm : DAProp

    Dm s d: the domino d sits at the slot s.

  • Mt : DADAProp

    Mt s p s' p': the top index (s, p) and the bottom index (s', p') are the same occurrence of the common word.

Instances For
    Dependency graph
    def DescriptiveComplexity.Pcp.Cert.SLt {A D : Type} (c : Cert A D) (s t : D) :

    Strictly earlier, in the order of the slots.

    Equations
    Instances For
      Dependency graph

      p is a position of the top word of the domino sitting at the slot s.

      Equations
      Instances For
        Dependency graph

        p is a position of the bottom word of the domino sitting at the slot s.

        Equations
        Instances For
          Dependency graph
          def DescriptiveComplexity.Pcp.Cert.LexLt {A D : Type} [FirstOrder.Language.pcp.Structure A] (c : Cert A D) (s : D) (p : A) (t : D) (q : A) :

          The lexicographic order on the indices of a parse: first the slot, then the position inside the word sitting there. Both parses are ordered by it, which is why one matching relates them.

          Equations
          Instances For
            Dependency graph

            The conditions on a certificate. The instance is well-formed, the slots are a nonempty sequence carrying one domino each, and the matching is a letter-preserving order isomorphism between the two parses – stated as being inside them, defined everywhere on both, order-reflecting, and letter-preserving.

            • wf : IsWF A

              The instance is well-formed.

            • sle_lin : IsLinOrd c.SLe

              The slots are linearly ordered.

            • slot_ex : ∃ (s : D), c.SLe s s

              There is at least one slot: a match is a nonempty sequence.

            • dm_tot (s : D) : ∃ (d : A), c.Dm s d

              Every slot carries a domino.

            • dm_fun (s : D) (d d' : A) : c.Dm s dc.Dm s d'd = d'

              A slot carries only one domino.

            • dm_dom (s : D) (d : A) : c.Dm s dDomG d

              What a slot carries is a domino of the instance.

            • mt_ix (s : D) (p : A) (s' : D) (p' : A) : c.Mt s p s' p'c.TopIx s p c.BotIx s' p'

              The matching relates an index of the top parse to one of the bottom parse.

            • mt_left (s : D) (p : A) : c.TopIx s p∃ (s' : D) (p' : A), c.Mt s p s' p'

              Every index of the top parse is matched.

            • mt_right (s' : D) (p' : A) : c.BotIx s' p'∃ (s : D) (p : A), c.Mt s p s' p'

              Every index of the bottom parse is matched.

            • mt_mono (s : D) (p : A) (s' : D) (p' : A) (t : D) (q : A) (t' : D) (q' : A) : c.Mt s p s' p'c.Mt t q t' q' → (c.LexLt s p t q c.LexLt s' p' t' q')

              The matching reflects the lexicographic order of the two parses.

            • mt_lab (s : D) (p : A) (s' : D) (p' d d' : A) : c.Mt s p s' p'c.Dm s dc.Dm s' d' → (UAt d p VAt d' p' )

              Matched indices carry the same letter.

            Instances For
              Dependency graph

              The order of the positions #

              The order symbol of a well-formed instance is a linear order.

              Dependency graph
              theorem DescriptiveComplexity.Pcp.asymm_ordLt {A : Type} [FirstOrder.Language.pcp.Structure A] (h : IsWF A) (a b : A) (hab : OrdLt a b) (hba : OrdLt b a) :

              Strict precedence of positions is asymmetric.

              Dependency graph

              From a certificate to a match #

              A certificate exhibits a match. The slots are enumerated in their order, the positions of each word in theirs, and the matching lemma turns the guessed relation into the equality of the two concatenations.

              Dependency graph

              From a match to a certificate #

              A match is a certificate. The slots are the places of the sequence of dominoes, and the matching is the pairing of the two parses index by index, which is legitimate exactly because the two concatenations are the same word.

              Dependency graph

              A Post system has a match exactly when a finite certificate says so. The certificate invents a segment of slots and nothing else: the common word, whose length no function of the instance bounds, is never written down – only the matching between the two ways of cutting it into blocks is.

              Dependency graph