Documentation

Foundation.FirstOrder.Basic.Coding

def LO.FirstOrder.Semiterm.toNat {L : Language} [(k : ) → Encodable (L.Func k)] {ξ : Type u_1} [Encodable ξ] {n : } :
Semiterm L ξ n
Equations
Instances For
    @[irreducible]
    def LO.FirstOrder.Semiterm.ofNat {L : Language} [(k : ) → Encodable (L.Func k)] {ξ : Type u_1} [Encodable ξ] (n a✝ : ) :
    Option (Semiterm L ξ n)
    Equations
    Instances For
      theorem LO.FirstOrder.Semiterm.ofNat_toNat {L : Language} [(k : ) → Encodable (L.Func k)] {ξ : Type u_1} [Encodable ξ] {n : } (t : Semiterm L ξ n) :
      instance LO.FirstOrder.Semiterm.encodable {L : Language} [(k : ) → Encodable (L.Func k)] {ξ : Type u_1} [Encodable ξ] {n : } :
      Equations
      theorem LO.FirstOrder.Semiterm.encode_eq_toNat {L : Language} [(k : ) → Encodable (L.Func k)] {ξ : Type u_1} [Encodable ξ] {n : } (t : Semiterm L ξ n) :
      theorem LO.FirstOrder.Semiterm.toNat_func {L : Language} [(k : ) → Encodable (L.Func k)] {ξ : Type u_1} [Encodable ξ] {n k : } (f : L.Func k) (v : Fin kSemiterm L ξ n) :
      (func f v).toNat = Nat.pair 2 (Nat.pair k (Nat.pair (Encodable.encode f) (Matrix.vecToNat fun (i : Fin k) => (v i).toNat))) + 1
      @[simp]
      @[irreducible]
      def LO.FirstOrder.Semiformula.ofNat {L : Language} [(k : ) → Encodable (L.Func k)] {ξ : Type u_1} [Encodable ξ] [(k : ) → Encodable (L.Rel k)] (n a✝ : ) :
      Equations
      Instances For
        theorem LO.FirstOrder.Semiformula.ofNat_toNat {L : Language} [(k : ) → Encodable (L.Func k)] {ξ : Type u_1} [Encodable ξ] [(k : ) → Encodable (L.Rel k)] {n : } (φ : Semiformula L ξ n) :
        ofNat n φ.toNat = some φ
        instance LO.FirstOrder.Semiformula.encodable {L : Language} [(k : ) → Encodable (L.Func k)] {ξ : Type u_1} [Encodable ξ] [(k : ) → Encodable (L.Rel k)] {n : } :
        Equations
        theorem LO.FirstOrder.Semiformula.encode_eq_toNat {L : Language} [(k : ) → Encodable (L.Func k)] {ξ : Type u_1} [Encodable ξ] [(k : ) → Encodable (L.Rel k)] {n : } (φ : Semiformula L ξ n) :
        theorem LO.FirstOrder.Semiformula.encode_rel {L : Language} [(k : ) → Encodable (L.Func k)] {ξ : Type u_1} [Encodable ξ] [(k : ) → Encodable (L.Rel k)] {n arity : } (R : L.Rel arity) (v : Fin aritySemiterm L ξ n) :
        theorem LO.FirstOrder.Semiformula.encode_nrel {L : Language} [(k : ) → Encodable (L.Func k)] {ξ : Type u_1} [Encodable ξ] [(k : ) → Encodable (L.Rel k)] {n arity : } (R : L.Rel arity) (v : Fin aritySemiterm L ξ n) :
        theorem LO.FirstOrder.Semiformula.encode_verum {L : Language} [(k : ) → Encodable (L.Func k)] {ξ : Type u_1} [Encodable ξ] [(k : ) → Encodable (L.Rel k)] {n : } :
        theorem LO.FirstOrder.Semiformula.encode_falsum {L : Language} [(k : ) → Encodable (L.Func k)] {ξ : Type u_1} [Encodable ξ] [(k : ) → Encodable (L.Rel k)] {n : } :
        theorem LO.FirstOrder.Semiformula.encode_and {L : Language} [(k : ) → Encodable (L.Func k)] {ξ : Type u_1} [Encodable ξ] [(k : ) → Encodable (L.Rel k)] {n : } (φ ψ : Semiformula L ξ n) :
        theorem LO.FirstOrder.Semiformula.encode_or {L : Language} [(k : ) → Encodable (L.Func k)] {ξ : Type u_1} [Encodable ξ] [(k : ) → Encodable (L.Rel k)] {n : } (φ ψ : Semiformula L ξ n) :
        theorem LO.FirstOrder.Semiformula.encode_all {L : Language} [(k : ) → Encodable (L.Func k)] {ξ : Type u_1} [Encodable ξ] [(k : ) → Encodable (L.Rel k)] {n : } (φ : Semiformula L ξ (n + 1)) :
        theorem LO.FirstOrder.Semiformula.encode_ex {L : Language} [(k : ) → Encodable (L.Func k)] {ξ : Type u_1} [Encodable ξ] [(k : ) → Encodable (L.Rel k)] {n : } (φ : Semiformula L ξ (n + 1)) :
        @[simp]
        theorem LO.FirstOrder.Semiformula.encode_emb {L : Language} [(k : ) → Encodable (L.Func k)] {ξ : Type u_1} [Encodable ξ] [(k : ) → Encodable (L.Rel k)] {n : } (σ : Semisentence L n) :
        @[simp]
        theorem LO.FirstOrder.Semiformula.encode_inj_sentence {L : Language} [(k : ) → Encodable (L.Func k)] {ξ : Type u_1} [Encodable ξ] [(k : ) → Encodable (L.Rel k)] {n : } {σ : Semisentence L n} {φ : Semiformula L ξ n} :
        @[simp]
        theorem LO.FirstOrder.Semiformula.encode_inj_sentence' {L : Language} [(k : ) → Encodable (L.Func k)] {ξ : Type u_1} [Encodable ξ] [(k : ) → Encodable (L.Rel k)] {n : } {σ : Semisentence L n} {φ : Semiformula L ξ n} :