Documentation

Complexity.Logics.FirstOrder.Ordered.Basic

Canonical ordered first-order structures #

The numeric vocabulary contains ≤, BIT, and the constants 0, 1, and max. On Fin n, with 2 ≤ n, these have their canonical meanings computed from the natural indices. In BIT(x, i), bit zero is the least significant bit. The numeric tables are not additional input. An input language is expanded by Mathlib's Language.sum; its existing functions, constants and relations retain their interpretations. Formulas and terms are Mathlib's existing syntax, so numeric constants can occur directly in relation arguments, equalities and quantified formulas.

This is the canonical-structure prerequisite for ordered descriptive complexity. Native full-tuple BIT and canonical full-tuple interpretations are supplied in Ordered.TupleBit and Ordered.FullTuple; their composition is in Ordered.FullTuple.Composition. Machine and circuit capture theorems require separate developments.

Main definitions #

Main results #

References #

The numeric function symbols are constants only.

Instances For
    Instances For
      @[reducible, inline]

      The natural index of a canonical numeric constant in a universe of size m.

      Instances For

        Canonical order and zero-indexed binary digits.

        Instances For
          Instances For
            @[reducible, inline]

            The canonical numeric vocabulary, including genuine nullary function symbols.

            Instances For
              @[reducible, inline]

              Preserve input symbols and adjoin the canonical numeric vocabulary.

              Instances For
                @[instance_reducible]

                Canonical numeric semantics; the lower bound makes zero and one distinct elements.

                Instances For

                  The numeric zero, as an ordinary Mathlib constant term.

                  Instances For

                    The numeric one, as an ordinary Mathlib constant term.

                    Instances For

                      The greatest element, as an ordinary Mathlib constant term.

                      Instances For
                        def Cslib.Logic.FO.Ordered.le (L : FirstOrder.Language) {α : Type u_1} (s t : (language L).Term α) :

                        Canonical weak order applied to arbitrary terms, including constants.

                        Instances For

                          Canonical BIT applied to arbitrary terms; the second argument is the zero-based bit index.

                          Instances For
                            @[simp]
                            theorem Cslib.Logic.FO.Ordered.realize_zero_val {L : FirstOrder.Language} {α : Type u_1} {n : ℕ} [Fact (2 ≤ n)] [L.Structure (Fin n)] (v : α → Fin n) :
                            @[simp]
                            theorem Cslib.Logic.FO.Ordered.realize_one_val {L : FirstOrder.Language} {α : Type u_1} {n : ℕ} [Fact (2 ≤ n)] [L.Structure (Fin n)] (v : α → Fin n) :
                            @[simp]
                            theorem Cslib.Logic.FO.Ordered.realize_max_val {L : FirstOrder.Language} {α : Type u_1} {n : ℕ} [Fact (2 ≤ n)] [L.Structure (Fin n)] (v : α → Fin n) :

                            The numeric constants are distinct in every canonical expanded structure.

                            @[simp]
                            @[simp]
                            theorem Cslib.Logic.FO.Ordered.realize_bit {L : FirstOrder.Language} {α : Type u_1} {n : ℕ} [Fact (2 ≤ n)] [L.Structure (Fin n)] (s i : (language L).Term α) (v : α → Fin n) :

                            bit L s i holds exactly when bit i of s is set, counting from the least significant bit.

                            The language inclusion preserves the truth of every input formula, including constants and quantifiers already present in the input language.