the lower predicate calculus with identity, lpci

47
THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI Contents 1. Examples of structures ....................................... 2 1.3. The structure of arithmetic ............................. 3 2. Syntax of LPCI ............................................... 4 2.3. Terms and formulas ..................................... 5 2.6. Unique readability ...................................... 5 2.7. Free and bound variables ................................ 6 2.10. Extended terms and formulas ........................... 8 3. Semantics of LPCI ............................................ 8 3.1. Structures .............................................. 9 3.2. Isomorphisms ........................................... 9 3.3. Expansions and reducts ................................. 9 3.4. Substructures ........................................... 10 3.5. Assignments ............................................ 10 3.6. Denotations ............................................. 10 3.7. The Tarski truth conditions ............................. 11 3.7. Compositionality ........................................ 11 3.8. Denotations of extended expressions ..................... 12 4. First order expressibility ..................................... 12 4.1. Elementary definability ................................. 13 4.2. Elementary relations and functions ...................... 13 5. Arithmetical functions and relations .......................... 15 5.1. Primitive recursion ...................................... 15 5.3. Dedekind’s analysis of recursion ......................... 16 5.4. The Chinese Remainder Theorem ....................... 16 5.5.G¨odel’s β -function ...................................... 17 6. Quantifier elimination ........................................ 19 6.1. Basic logical equivalences ............................... 20 6.3. Disjunctive normal form ................................ 21 6.4. Prenex normal forms .................................... 21 6.5. Decidable structures .................................... 21 6.6. Quantifier elimination test .............................. 22 6.8. Dense linear orderings .................................. 23 7. Theories and elementary classes .............................. 26 7.1. Elementary classes of structures ......................... 26 7.2. Theories and models .................................... 26 Math. 114L, Spring 2015, Y. N. Moschovakis Lower Predicate Calculus with identity May 9, 2015, 9:17, 1

Upload: dragan-rukavina

Post on 18-Dec-2015

24 views

Category:

Documents


1 download

DESCRIPTION

THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI

TRANSCRIPT

  • THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI

    Contents

    1. Examples of structures . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21.3. The structure of arithmetic . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3

    2. Syntax of LPCI . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42.3. Terms and formulas . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 52.6. Unique readability . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 52.7. Free and bound variables. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 62.10. Extended terms and formulas . . . . . . . . . . . . . . . . . . . . . . . . . . . 8

    3. Semantics of LPCI . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 83.1. Structures . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 93.2. Isomorphisms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 93.3. Expansions and reducts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 93.4. Substructures . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 103.5. Assignments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 103.6. Denotations. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 103.7. The Tarski truth conditions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 113.7. Compositionality. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 113.8. Denotations of extended expressions. . . . . . . . . . . . . . . . . . . . . 12

    4. First order expressibility . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 124.1. Elementary definability . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 134.2. Elementary relations and functions . . . . . . . . . . . . . . . . . . . . . . 13

    5. Arithmetical functions and relations . . . . . . . . . . . . . . . . . . . . . . . . . . 155.1. Primitive recursion. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 155.3. Dedekinds analysis of recursion . . . . . . . . . . . . . . . . . . . . . . . . . 165.4. The Chinese Remainder Theorem . . . . . . . . . . . . . . . . . . . . . . . 165.5. Godels -function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17

    6. Quantifier elimination . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 196.1. Basic logical equivalences . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 206.3. Disjunctive normal form . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 216.4. Prenex normal forms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 216.5. Decidable structures . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 216.6. Quantifier elimination test . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 226.8. Dense linear orderings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23

    7. Theories and elementary classes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 267.1. Elementary classes of structures . . . . . . . . . . . . . . . . . . . . . . . . . 267.2. Theories and models . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 1

  • 2 THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI

    7.2. Logical consequence . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 277.3. Elementary equivalence . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 277.9. Peano Arithmetic, PA . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 297.10. The Robinson system Q . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29

    8. Deduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 298.1. The axiom schemes and rules for LPCI() . . . . . . . . . . . . . . . 298.5. The Soundness Theorem . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 328.6. Constant Substitution Lemma . . . . . . . . . . . . . . . . . . . . . . . . . . 338.7. The Deduction Theorem . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 338.9. The natural introduction rules . . . . . . . . . . . . . . . . . . . . . . . . . . 358.10. The natural elimination rules . . . . . . . . . . . . . . . . . . . . . . . . . . . 35

    9. The Completeness and Compactness Theorems . . . . . . . . . . . . . . . 369.1. Godels Completeness Theorem, I . . . . . . . . . . . . . . . . . . . . . . . 369.2. Consistent theories . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 369.3. Godels Completeness Theorem, II . . . . . . . . . . . . . . . . . . . . . . 369.5. Non-standard models of arithmetic . . . . . . . . . . . . . . . . . . . . . . 379.7. Complete theories . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 389.8. Henkin sets . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 389.12. The Compactness Theorem . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 429.13. The Weak Skolem-Lowenheim Theorem . . . . . . . . . . . . . . . . . 42

    10. Problems. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42

    1. Examples of structures. The Lower Predicate (or First Order)Calculus is interpreted in mathematical structures, like the following.

    1.1. Definition. A graph is a pair

    G = (G,E)

    where G 6= is a non-empty set (the nodes) and E G2 is a binaryrelation on G, (the edges); G is symmetric or unordered if

    E(x, y)=E(y, x).1.2. Definition. A partial ordering is a pair

    P = (P,),where P is a non-empty set and is a binary relation on P satisfying thefollowing conditions:1. For all x P , x x (reflexivity).2. For all x, y, z P , if x y and y z, then x z (transitivity).3. For all x, y P , if x y and y x, then x = y (antisymmetry).

    A linear ordering is a partial ordering in which every two elements arecomparable, i.e., such that4. For all x, y P , either x y or y x.

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 2

  • THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI 3

    1.3. Definition. The structure of arithmetic or the natural num-bers is the tuple

    N = (N, 0, S,+, )where N = {0, 1, 2, . . . } is the set of (non-negative) integers and S, +, are the operations of successor, addition and multiplication on N. Thestructure N has the following characteristic properties:

    1. The successor function S is an injection, i.e.,

    S(x) = S(y)=x = y,and 0 is not a successor, i.e., for all x, S(x) 6= 0.

    2. Induction Principle: for every set of numbers X N, if 0 X andfor every x, x X =S(x) X, then X = N.

    3. For all x, y, x+ 0 = x and x+ S(y) = S(x+ y).4. For all x, y, x 0 = 0 and x S(y) = x y + x.

    These properties (or sometimes just the first two of them) are called thePeano Axioms for the natural numbers.

    1.4. Definition. A field is a structure of the form

    K = (K, 0, 1,+, )where 0, 1 K, + and are binary operations on K and the followingfield axioms are true.(1) (K, 0,+) is a commutative group, i.e., the following hold:

    1. For all x, x+ 0 = x.2. For all x, y, z, x+ (y + z) = (x+ y) + z.3. For all x, y, x+ y = y + x.4. For each x there exists some y such that x+ y = 0.

    (2) 1 6= 0 and for all x, x 0 = 0, x 1 = x.(3) The structure (K \ {0}, 1, ) is a commutative group, and in partic-

    ular

    x, y 6= 0=x y 6= 0.Together with (2), this means that for all x, y in K,

    x y = 0 x = 0 or y = 0.(4) For all x, y, z, x (y + z) = x y + x z.We will be using the following notations for the standard number fields

    of the rational, the real and the complex numbers:

    Q = (Q, 0, 1,+, ), R = (R, 0, 1,+, ), C = (C, 0, 1,+, ).

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 3

  • 4 THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI

    2. Syntax of LPCI. The name LPCI abbreviates Lower Predicate Cal-culus with Identity. It is actually a family of languages LPCI(), one foreach signature , where the signature provides names for the distin-guished elements, relations and functions of the structures we want totalk about.LPCI is also known as First Order Logic with Identity, or Elementary

    Logic with Identity.

    2.1. Definition. A vocabulary or signature is a quadruple

    = (Const,Rel,Funct, arity),

    the sets of constant symbols Const, relation symbols Rel, and functionsymbols Funct are disjoint and

    arity : Rel Funct {1, 2, . . . }.A relation or function symbol P is n-ary if arity(P ) = n. We will assumethat Rel and Funct are finite, but it is convenient to allow the set ofconstant symbols Const to be infinite; and we should also keep in mindthat any oneor allof these sets may be empty. When they are allfinite, we usually exhibit signatures by enumerating their symbols: forexample,

    1 = (R) (with R binary)

    is a signature for graphs;

    2 = (0, S,+, .)

    is a signature for arithmetic (with 0 a constant, S a unary function symboland +, binary function symbols), and for fields

    3 = (0, 1,+, )with the appropriate arities. We say a rather than the signature becausethe symbols R,S,+ etc. are arbitrary.

    2.2. Definition. The alphabet of the first order language with identityLPCI() comprises the symbols in the vocabulary and the following,additional symbols which are common to all LPCI().1. The logical symbols =2. The punctuation symbols ( ) ,3. The (individual) variables: v0, v1, v2, . . .

    The new logical symbols and are the quantifiers, and they are readfor all and there exists.Words are finite strings of symbols and lh() is the length of the word

    . We use to denote identity of strings, df and are the same string.

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 4

  • THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI 5

    We also set

    v df is an initial segment of ,so that e.g., v0 v v0R(v0). The concatenation of two strings is thestring produced by putting them together, with first, so that v .2.3. Definition. Terms are defined by the recursion: (a) Each vari-

    able is a term. (b) Each constant symbol is a term. (c) If t1, . . . , tn areterms and f is an n-ary function symbol, then f(t1, . . . , tn) is a term. Inabbreviated notation:

    t : v | c | f(t1, . . . , tn),where | is read as or.2.4. Definition. Formulas are defined by the recursion: (a) If s, t are

    terms, then s = t is a formula. (b) If t1, . . . , tn are terms and R is ann-ary relation symbol, then R(t1, . . . , tn) is a formula. (c) If , areformulas and v is a variable, then the following are formulas:

    () ( ) ( ) ( ) v vIn abbreviated form:

    : t1 = t2 | R(t1, . . . , tn)| () | ( ) | ( ) | ( ) | v | v

    A formula is quantifier-free if neither of the quantifier symbols , occurs in it. A formula is in prenex normal form (prenex ) if it lookslike

    Q1x1 Qnxnwhere each Qi or Qi and is quantifier-free.Terms and formulas are collectively called (well formed) expressions.

    2.5. Proposition (Unique readability for terms). Each term t satis-fies exactly one of the following three conditions.1. t v for a uniquely determined variable v.2. t c for a uniquely determined constant c.3. t f(t1, . . . , tn) for a uniquely determined function symbol f and

    uniquely determined terms t1, . . . , tn.

    2.6. Proposition (Unique readability for formulas). Each formula sat-isfies exactly one of the following conditions.1. s = t for uniquely determined terms s, t.2. R(t1, . . . , tn) for a uniquely determined relation symbol R and

    uniquely determined terms t1, . . . , tn.3. () for a uniquely determined formula .4. ( ) for uniquely determined formulas , .

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 5

  • 6 THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI

    5. ( ) for uniquely determined formulas , .6. ( ) for uniquely determined formulas , .7. v for a uniquely determined variable v and a uniquely deter-

    mined formula .8. v for a uniquely determined variable v and a uniquely deter-

    mined formula .

    The prime formulas are those which satisfy 1 or 2 in this lemma.These lemmas allow us to give definitions by (structural) recursion on

    the length of terms and formulas. We will apply them first to define theimportant and somewhat subtle notion of free and bound occurrences ofvariables in formulas of LPCI.

    2.7. Definition (Free and bound variables). Every occurrence of a vari-able in a term is free.The free occurrences of variables in formulas are defined by structural

    recursion on formulas, as follows.1. FO(s = t) = FO(s) FO(t).2. FO(()) = FO(), FO(( )) = FO() FO(), and similarly

    for .3. FO(v) = FO(v) = FO() \ {v}, meaning that we remove from

    the free occurrences of variables in all the occurrences of the vari-able v.

    An occurrence of a variable which is not free in an expression is boundin . The free variables of are the variables which have at least one freeoccurrence in ; the bound variables of are those which have at leastone bound occurrence in .To illustrate what these notions mean, consider the three formulas in

    the language of arithmetic

    : v1 + (v2, v1) = 0, : v5 + (v2, v5) = 0, : v1 + (v5, v1) = 0

    As we read these formulas in English (unabbreviating the formal symbols),the first two of them say exactly the same thing: that we can add somenumber to v2 and get 0which is true exactly when v2 is a name of 0.The third formula says the same thing about whatever number v5 names,which need not be the same as the number named by v2. In short, themeaning (and truth value) of a formula does not change if we replaceits bound variables by others, but it may change when we change its freevariables. A customary example from calculus is the notation we use forintegrals: for a 6= b, a

    0x2dx =

    a0y2dy =

    a3

    3but

    a0x2dx 6=

    b0x2dx =

    b3

    3,

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 6

  • THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI 7

    which means that in the expression a0 x

    2dx the occurrences of x arebound, while a occurs freely.An expression is closed if it has no free occurrences of variables. A

    closed formula is a sentence. The universal closure of a formula isthe sentence

    ~ df v0v1 . . .vn,where n is least so that all the free variables of are among v0, . . . , vn.

    Note that a variable may occur both free and bound within a formula.For example, the following are well formed by the rules:

    v1v1R(v1, v1), v1v1R(v1, v1)(Think through what they mean.)

    2.8. Note (Abbreviations and misspellings). As in the propositional cal-culus, we will almost never spell formulas correctly: we will use infixnotation for terms, e.g.,

    s+ t for + (s, t)

    in arithmetic, introduce and use abbreviations, use (meta)variables (names)x, y, z, u, v, . . . , for the formal variables of the language, skip (or add)parentheses, replace parentheses by brackets or other punctuation marks,and (in general) be satisfied with giving instructions for writing out aformula rather than exhibiting the actual formula. For example, thefollowing sentence says about arithmetic that there are infinitely manyprime numbers:

    (x)(y)[x y (u)(v)[(y = u v) (u = 1 v = 1)]where we have used the abbreviations

    x y : (z)[x+ z = y] 1 : S(0)The correctly spelled sentence which corresponds to this is quite long (andunreadable).Two useful logical abbreviations are for the iff

    ( ) : (( ) ( ))and the quantifier there exists exactly one

    (!x) : (z)(x)[ x = z],where z 6 x. (Think this through.)2.9. Definition (Substitution). For each expression , each variable v

    and each term t, the expression {v : t} is the result of replacing allfree occurrences of v in by the term t. The simultaneous substitution

    {v1 : t1, . . . , vn : tn}

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 7

  • 8 THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI

    is defined similarly: we replace simultaneously all the free occurrences ofeach vi in by ti. Note than in general

    {v1 : t1}{v2 : t2} 6 {v1 : t1, v2 : t2}.If is an expression, then {v1 : t1, . . . , vn : tn} is also an expression,and of the same kindterm or formula.A term ti is free for vi in a substitution if no occurrence of a variable

    in ti is bound in the result of the substitution. We will only performfree substitutions of this kind, sometimes without explicitly stating thehypotheses.

    2.10. Definition (Extended terms and formulas). If is a term or for-mula and v1, . . . , vn is a list of distinct variables which includes all thefree variables of , we set

    (v1, . . . , vn) : (, (v1, . . . , vn)).So (v1, . . . , vn) is a pair of an expression and a sequence of variables.This is a very useful notion: for example, if (v1, . . . , vn) is an extendedexpression and t1, . . . , tn a sequence of terms, we can then set

    (t1, . . . , tn) : {v1 : t1, . . . , vn : tn}exhibiting the result of the free substitution operation in a useful way.Notice that (t1, . . . , tn) is an expression, not an extended one, because

    no list of variables is specified; and in particular, every extended expressioncan be viewed as a (plain) expression, the result of the trivial substitution

    {v1 : v1, . . . , vn : vn}.We will find this notational convention useful in a few places.

    2.11. Definition (Sublanguages). If and are vocabularies and eachsymbol of is a symbol (of the same kind and with the same arity) in ,we say that is a reduct of and is an expansion of , and we write . For example, (0, 1, ) (0, 1,+, ).2.12. Definition (LPC). We will also work with the smaller language

    LPC, which is obtained by removing the symbol = and the clauses in-volving it in the definitions. There are no formulas in LPC(), unless thesignature has at least one relation symbol. In stating theorems aboutLPC we will tacitly assume that the signature has at least one relationsymbol, so we have sentences.

    3. Semantics of LPCI. As we already mentioned, we will interpretthe terms and formulas of LPCI() in structures of signature , defined asfollows:

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 8

  • THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI 9

    3.1. Definition (Structures). A -structure is a pair A = (A, I) whereA is a non-empty set and I assigns to each constant symbol c a memberI(c) of A; to each n-ary relation symbol an n-ary relation I(R) An;and to each n-ary function symbol f an n-ary function I(f) : An A.The set A is the universe of the structure A, and the constants, relationsand functions which interpret the symbols of the signature in A are itsprimitives.In the typical case where there are only finitely many symbols in , we

    denote structures as tuples, as in Section 1, so that a graph G = (G,E)is an (E)-structure and the structure N = (N, 0, S,+, ) of arithmetic is a(0, S,+, )-structure. It is also convenient sometimes to use the notation

    cA = I(c), RA = I(R), fA = I(f),

    so that in arithmetic, for example, addition would be denoted by +N, andthe specification of a -structure could be given in the form

    A = (A, {cA}cConst, {RA}RRel, {fA}fFunct).We use this notation in the next, important definition.

    3.2. Definition (Isomorphisms). An isomorphism

    : ABbetween two -structures A = (A, I), B = (B, J) is a bijection : ABsuch that:1. For each constant c, (cA) = cB.2. For each n-ary relation symbol R and all x1, . . . , xn A,

    RA(x1, . . . , xn) RB((x1, ), . . . , (xn)).3. For each n-ary function symbol f and all x1, . . . , xn A,

    (fA(x1, . . . , xn)) = fB((x1), . . . , (xn)).

    An isomorphism : AA of a structure with itself is called an auto-morphism of A.

    3.3. Definition (Expansions and reducts). Suppose are signa-tures, A = (A, I) is a -structure and B = (B, J) is a -structure. Wecall A a reduct of B and B an expansion of A if A = B and for allsymbols C , I(C) = J(C). If B is a given -structure and , wedefine the reduct of B to by deleting from B the objects assigned to thesymbols not in , formally

    B = (B, J ).Conversely, if , we can define expansions of B by assigning inter-pretations to the symbols in which are not in . The notation for thisis

    (B,K) =df the expansion of B by K,

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 9

  • 10 THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI

    which is easier to understand in examples: (N, 0, S) and (N, 0,+) arereducts of the structure of arithmetic N obtained (in the first case) bydeleting from the signature the symbols + and , so that

    (N, 0, S) = N{0, S}.A useful expansion of N is obtained by adding to the signature a symbolexp for exponentiation, and to N the corresponding operation,

    (N, exp) = the expansion of N by exp, where exp(t, x) = xt.

    3.4. Definition (Substructures). Suppose A = (A, I), B = (B, J) are -structures. We call A a substructure of B and write A B if thefollowing conditions hold.1. A B2. For each constant symbol c of , cB = cA A.3. For each n-ary relation symbol R and all x1 . . . , xn A,

    RB(x1 . . . , xn) RA(x1 . . . , xn).4. For each n-ary function symbol f and all x1 . . . , xn A,

    fB(x1 . . . , xn) = fA(x1 . . . , xn) A.For example, the field of rationals (the fractions) is a substructure of thefield of real numbers, in the language of fields.The difference between reducts and substructures is important.

    As with propositional logic, we will use 1 and 0 for the truth values.

    3.5. Definition. An assignment into a structure A is any associationof objects in A with the variables, i.e., any function pi : Variables A. Ifv is a variable and x A, then pi{v := x} is the assignment which agreeswith pi on all variables except v, to which it assigns x:

    pi{v := x}(u) ={x, if u v,pi(u), otherwise.

    We call pi{v := x} the update of pi by (the reassignment) v := x.3.6. Definition (Denotations). The value or denotation of a term

    for an assignment pi is defined by structural recursion on the terms asfollows:1. value(v, pi) =df pi(v).2. value(c, pi) =df I(c).3. value(f(t1, . . . , tn), pi) =df fA(value(t1, pi), . . . , value(tn, pi)).

    In the same way, by recursion on the length of formulas, we define hetruth value or denotation of a formula for an assignment pi:

    1. value(s = t, pi) =df

    {1, if value(s, pi) = value(t, pi),0, otherwise.

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 10

  • THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI 11

    2. value(R(t1, . . . , tn), pi) =df{1, if RA(value(t1, pi), . . . , value(tn, pi)),0, otherwise.

    3. value(, pi) =df 1 value(, pi) ={0, if value(, pi) = 1,1, otherwise.

    4. value( , pi) = min(value(, pi), value(, pi)). For we take themaximum and for implication we use

    value( , pi) =df value(() ).5. value(v(), pi) =df max{value(, ) | for all v 6 v, (v) = pi(v)}.6. value(v(), pi) =df min{value(, ) | for all v 6 v, (v) = pi(v)}.

    The value function depends on the structure, of course, although we sup-pressed this in the notation. When we need to exhibit the dependence wewrite

    valueA(, pi) = value(, pi).

    For formulas, we also write

    A, pi |= df valueA(, pi) = 1,and if A, pi |= we say that the assignment pi satisfies in the structureA.

    3.7. Theorem (The Tarski truth conditions). The satisfaction relationsatisfies the following conditions:

    A, pi |= s = t valueA(t, pi) = valueA(s, pi)A, pi |= A, pi 6|=

    A, pi |= A, pi |= and A, pi |= A, pi |= A, pi |= or A, pi |= A, pi |= either A, pi 6|= or A, pi |= A, pi |= v there exists an x A such that A, pi{v := x} |= A, pi |= v for all x A,A, pi{v := x} |=

    Proof is by structural induction on formulas. aCompositionality. Denotations of terms and formulas are defined in

    such a way that the value of an expression is a function of the values ofits subexpressions. This is generally referred to as the CompositionalityPrinciple for denotations, and it is the key to a mathematical analysisof denotations. The next theorem expresses it rigorously.

    3.8. Theorem. (1) If the -structure A is a reduct of the -structureB where and is a formula of LPCI(), then for every expression and every assignment pi,

    valueA(, pi) = valueB(, pi).

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 11

  • 12 THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI

    (2) If pi, are two assignments into the same structure A and for everyvariable v which occurs free in an expression , pi(v) = (v), then

    valueA(, pi) = valueA(, ).

    In particular, for formulas,

    A, pi |= A, |= .Proof of both claims is by structural induction on . aIn particular, if is a sentence, then value(A, , pi) is independent of

    the assignment pi. We set:

    A |= df for some assignment pi,A, pi |= for every assignment pi,A, pi |= df is true in A.

    Denotations of extended expressions. There is an analogous nota-tion for terms and formulas in which free variables (may) occur, using thenotation of Definition 2.10: if t(~v) is an extended term ( so that the vari-ables in t are all included in the list ~v = (v1, . . . , vn)) and ~x = (x1, . . . , xn)is an arbitrary n-tuple in A, we set

    tA[~x] = valueA(t, pi{~v := ~x}) (for any assignment pi);and if (v1, . . . , vn) is an extended formula and ~x = (x1, . . . , xn) is anarbitrary n-tuple in A,

    A[~x] A, pi{~v := ~x} |= .Here pi{~v := ~x} is the update of pi obtained by changing pi only on thevariables in the list ~v,

    pi{~v := ~x}(v) ={xi, if v vi for some i,pi(v), otherwise,

    and Theorem 3.8 is used to show that the definitions do not depend onwhich pi we use to give them.

    4. First order expressibility. A proposition of ordinary (mathe-matical) English, about a certain -structure A is expressed by a sentence of LPCI() if and mean the same thing; similarly, a proposition(x) about an arbitrary object x in a structure A is expressed by a for-mula (x) with one free variable x, if for each x A, (x) and (x)mean the same thing. For example,

    (x)[x+ 0 = x] means every number added to 0 yields itself.We cannot make this notion of expressing precise unless we first de-

    fine meaning rigorously for both natural language and LPCI. (Notice thatwe cannot identify meaning with truth value, else we would need only

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 12

  • THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI 13

    the two sentences (x)[x = x] and its negation to express all propositionswhich do not refer to variables.) On the other hand, we have a clear, in-tuitive understanding of this notion of expressibility which is importantfor applications: roughly speaking, expresses if we can construct thefirst from the second by straightforward translation, more-or-less wordfor word, and, but, also going to , all, each, any going to, etc. For example, every number is either odd or even refers to thestructure of arithmetic and translates to something of the form

    (x)[(x) (x)]where (x) and (x) can be constructed to express the properties of beingodd or even.Although the full notion of expressibility in a formal language cannot

    be defined rigorously, there are several related, precise notions which arevery useful. We collect them in this section for easy reference, before wego into their more detailed study.

    4.1. Definition (Elementary definability). A relation R An on theuniverse of a structure A is first order definable or elementary on A,if there is an extended formula (v1, . . . , vn) such that

    R(~x) A[~x].A function g : An A on the universe of a structure A is first orderdefinable or elementary on A if its graph

    Gg(~x,w) g(~x) = wis elementary on A, i.e., if there is an extended formula (~v, u) such that

    g(~x) = w A[~x,w].The elementary functions and relations of the standard structure N of

    arithmetic (Definition 1.3) are called arithmetical.

    The next theorem is useful, as it often frees us from needing to worryexcessively about the formal syntax of LPCI.

    4.2. Theorem (Elementary relations and functions). The collection E(A)of A-elementary functions and relations on the universe of a structure

    A = (A, {cA}cConst, {RA}RRel, {fA}fFunct).has the following properties:(1) Each primitive relation RA is A-elementary; and the (binary) iden-

    tity relation x = y is A-elementary.(2) For each constant symbol c and each n, the n-ary constant function

    g(~x) = cA

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 13

  • 14 THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI

    is A-elementary; each primitive function fA is A-elementary; andevery projection function

    Pni (x1, . . . , xn) = xi (1 i n)is A-elementary.

    (3) E(A) is closed under substitutions of A-elementary functions: i.e., ifh(u1, . . . , um) is anm-ary A-elementary function and g1(~x), . . . , gm(~x)are n-ary, A-elementary, then the function

    f(~x) = h(g1(~x), . . . , gm(~x))

    is A-elementary; and if P (u1, . . . , um) is an m-ary A-elementaryrelation, then the n-ary relation

    Q(~x) P (g1(~x), . . . , gm(~x))is A-elementary.

    (4) E(A) is closed under the propositional operations: i.e., if P1(~x) andP2(~x) are A-elementary, n-ary relations, then so are the followingrelations:

    Q1(~x) P1(~x),Q2(~x) P1(~x) P2(~x),Q3(~x) P1(~x) P2(~x),Q4(~x) P1(~x) P2(~x).

    (5) E(A) is closed under quantification on A, i.e., if P (~y) is A-elementary,then so are the relations

    Q1(~x) (y)P (~x, y),Q2(~x) (y)P (~x, y).

    Moreover: E(A) is the smallest collection of functions and relations onA which satisfies (1) (5).

    Proof. To show that E(A) has these properties, we need to constructlots of formulas and appeal repeatedly to the definition of A-elementaryfunctions and relations; this is tedious, but not difficult.For the second (moreover) claim, we first make it precise by replacing

    E(A) by F throughout (1) (5), and (temporarily) calling a class F offunctions and relations good if it satisfies all these conditionsso whathas already been shown is that E(A) is good. The additional claim isthat every good F contains all A-elementary functions and relations, andit is verified by structural induction on the formula (~v) which definesa given, A-elementary relationafter showing, easily, that the graph ofevery function defined by a term is in F . a

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 14

  • THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI 15

    The theorem suggests that E(A) is a very rich class of relations andfunctions. As it turns out, this is true for rich structures like N but nottrue for simple structures, like the usual ordering (Q,) on the rationalnumbers. We consider this important difference between structuresandwhat it impliesin the next two sections, and then again in Part 3 of thisclass.

    5. Arithmetical functions and relations. Is the exponential func-tion

    exp(t, x) = xt (x, t N)arithmetical? Not obviouslybut it is, as a corollary of a basic resultabout definition by recursion in N which we will prove in this section,and which has many important applications.

    We will need to appeal to several, simple but not trivial facts fromnumber theory. We will outline proofs for most of these, but it is notsurprizing that we need them: the results we will prove are about thenatural numbers, and their truth ultimately depends on what they are.

    5.1. Definition (Primitive recursion). A function f : N N is definedby primitive recursion from the number w0 N and the binary functionh(w, t) if it satisfies the following two equations, for all t:

    f(0) = w0, f(t+ 1) = h(f(t), t);(5-1)

    in greater generality, a function f : Nn+1 N of n + 1 arguments onthe natural numbers is defined by primitive recursion from the n-aryfunction g and the (n + 2)-ary function h if it satisfies the following twoequations, for all t, ~x:

    f(0, ~x) = g(~x), f(t+ 1, ~x) = h(f(t, ~x), t, ~x).(5-2)

    For example, if we set

    f(0, x) = x, f(t+ 1, x) = S(f(t, x)),

    then (easily, by induction on t)

    f(t, x) = t+ x,

    and so addition is defined by primitive recursion from the two, simplerfunctions

    g(x) = x, h(w, t, x) = S(w),

    i.e., (essentially) the identity and the successor. Similarly, if we set

    f(0, x) = 0, f(t+ 1, x) = f(t, x) + x,

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 15

  • 16 THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI

    then, easily, f(t, x) = t x, and so multiplication is defined by primitiverecursion from the functions

    g(x) = 0, h(w, t, x) = w + t,

    i.e., essentially the constant 0 and addition. More significantly (for ourpurposes here),

    exp(0, x) = x0 = 1, exp(t+ 1, x) = xt+1 = xt x = exp(t, x) x,so that exponentiation is defined by primitive recursion from the functions

    g(x) = 1, h(w, t, x) = w x,i.e., (essentially) the constant 1 and multiplication.Notice that this definition of exponentiation gives 00 = 1, which is not

    a useful convention in calculus but does not introduce any problems innumber theory.

    5.2. Theorem. If f : Nn+1 N is defined by the primitive recur-sion (5-2) above and g, h are arithmetical, then so is f .

    To prove this we must reduce the recursive definition of f into an explicitone, and this is done using Dedekinds analysis of recursion:

    5.3. Proposition. If f : Nn+1 N is defined by the primitive recur-sion in (5-2), then for all t, ~x,w,

    (5-3) f(t, ~x) = w there exists a sequence (w0, . . . , wt) such thatw0 = g(~x) (s < t)[ws+1 = h(ws, s, ~x)] w = wt.

    Proof. If f(t, ~x) = w, set ws = f(s, ~x) for s t, and verify easily thatthe sequence (w0, . . . , wt) satisfies the conditions on the right. For theconverse, suppose that (w0, . . . , wt) satisfies the conditions on the rightand prove by (finite) induction on s t that ws = f(s, ~x). aWe can view the equivalence (5-3) as a theorem about recursive defini-

    tions which have already been justified in some other way; or we can see itas a definition of a function f which satisfies the recursive equations (5-2)and so justifies recursive definitionswhich is how Dedekind saw it. Inany case, it reduces proving Theorem 5.2 to justifying quantification overfinite sequences within the class of arithmetical relations, and we will dothis by an arithmetical coding of finite sequences. The key tool is thefollowing classical Lemma from algebra.

    5.4. Theorem (The Chinese Remainder Theorem). If d0, . . . , dt are rel-atively prime numbers and w0 < d0, . . . , wt < dt, then there exists somenumber a such that

    w0 = rem(a, d0), . . . , wt = rem(a, dt).

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 16

  • THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI 17

    Proof. Consider the set D of all (t+ 1)-tuples bounded by the givennumbers d0, . . . , dt,

    D = {(w0, . . . , wt) | w0 < d0, . . . , wt < dt},which has |D| = d0d1 dt members, and let

    A = {a | a < |D|}which is equinumerous with D. Define the function pi : A D by

    pi(a) = (rem(a, d0), rem(a, d1), . . . , rem(a, dt)).

    Now pi is injective (one-to-one), because if f(a) = f(b) with a < b < |D|,then b a is divisible by each of d0, . . . , dt and hence by their product D(which is what their being relatively prime implies); hence d ba, whichis absurd since a < b < |D|. We now apply the Pigeonhole Principle: sinceA and D are equinumerous and pi : A D is an injection, it must bea surjection, and hence whatever (w0, . . . , wt) may be, there is an a < dsuch that

    pi(a) = (rem(a, d0), rem(a, d1), . . . , rem(a, dt)) = (w0, . . . , wt). aThe idea now is to code an arbitrary tuple (w0, . . . , wt) by a pair of

    numbers (d, a), where d can be used to produce uniformly t+1 relativelyprime numbers d0, . . . , dt and then a comes from the Chinese RemainderTheorem.

    5.5. Lemma (Godels -function). Set

    (a, d, i) = rem(a, 1 + (i+ 1)d).

    This is an arithmetical function, and for every tuple of numbers w0, . . . , wtthere exist numbers a and d such that

    (a, d, 0) = w0, . . . , (a, d, t) = wt.

    Proof. The -function is arithmetical because it is defined by substi-tutions from addition, multiplication and the remainder function, whichis arithmetical since (by convention for the case y = 0),

    rem(x, y) = r [y = 0 r = 0] [y 6= 0 (q)[x = yq + r r < y].To find the required a, d which code the tuple (w0, . . . , wt), set

    s = max(t+ 1, w0, . . . , wt), d = s!

    and verify that the t+ 1 numbers

    d0 = 1 + (0 + 1)d, d1 = 1 + (1 + 1)d, . . . , dt = 1 + (t+ 1)d

    are relatively prime. (If a prime p divides 1+(1+i)s! and also 1+(1+j)s!with i < j, then it must divide their difference (j i)s!, and hence it mustdivide one of (j i) or s!; in either case, it divides s!, since (j i) s,and then it must divide 1, since it is assumed to divide 1+(1+ i)s!, which

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 17

  • 18 THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI

    is absurd.) It is also immediate that wi < d = s!, by the definition of s,and so the Chinese remainder theorem supplies some a such that

    (w0, . . . , wt) = (rem(a, d0), . . . , dt) = ((a, d, 0), . . . , (a, d, t))

    as required. aProof of Theorem 5.2. By the Dedekind analysis and using the -

    function to code tuples, we have

    f(t, ~x) = w (a)(d)[(a, d, 0) = g(~x)

    (s < t)[(a, d, s+ 1) = h((a, d, s), s, ~x)] (a, d, t) = w]

    Thus the graph of f is arithmetical, by the closure properties of thearithmetical functions and relations in Theorem 4.2. aThere is no standard definition of rich structure, but the following no-

    tion covers the most important examples:

    5.6. Definition (Structures with tuple coding). A copy of N in a struc-ture A is a structure N = (N, 0, S,+, ) such that:1. N is isomorphic with the structure of arithmetic N.2. N A.3. The set N, the object 0 and the functions S,+ and are all A-

    elementary.A structure A admits tuple coding if it has a copy of N and there

    is an A-elementary function : An+1 A such that for every tuplew0, . . . , wt A, there is some ~a An such that

    (~a, 0) = w0, (~a, 1) = w1, . . . , (~a, t) = wt,

    where 0, 1, . . . , t are the A-numbers 0, 1, . . . , t (i.e., the copies of thesenumbers into A by the given isomorphism of N with N).

    In this definition, plays the role of the -function in N, and we haveallowed for the possibility that triples (n = 3) or quadruples (n = 4) areneeded to code tuples of arbitrary length in A using . We might havealso allowed the natural numbers to be coded by pairs of elements of Aor tweak the definition in various other ways, but this version capturesall the examples we will discuss here. The key result is:

    5.7. Proposition. Suppose A admits coding of tuples,

    g : An A, h : An+2 A;are A-elementary, f : An+1 A, and for t N , y / N ,

    f(0, ~x) = g(~x), f(t+ 1, ~x) = h(f(t, ~x), t, ~x)), f(y, ~x) = y;(5-4)

    it follows that f is A-elementary.

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 18

  • THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI 19

    This is proved by a simple adjustment of the proof of Theorem 5.2 andit can be used to show that structures which admit tuple coding have arich class of elementary functions and relations.

    5.8. Example (The integers). The ring of (rational) integers

    Z = (Z, 0, 1,+, ) (Z = {. . . ,2,1, 0, 1, 2, . . . })(5-5)admits tuple coding.To see this, we use the fact that N Z, and it is a Z-elementary set

    because of Lagranges Theorem, by which every natural number is the sumof four squares:

    x N (u, v, s, t)[x = u2 + v2 + s2 + t2] (x Z).We can then use the -function (with some tweaking) to code tuples ofintegers.

    5.9. Example (The fractions). The field of rational numbers (fractions)

    Q = (Q, 0, 1,+, )admits tuple coding.This is a classical theorem of Julia Robinson which depends on a non-

    trivial, Q-elementary definition of N within Q. (Robinsons Theoremdepends on some results from number theory which are considerably moredifficult than Lagranges Theorem.)

    5.10. Example (The real numbers, with Z). The structure of analysis

    (R,Z) = (R, 0, 1,Z,+, )admits tuple coding.This requires some workand it is not a luxury that we have included

    the integers as a distinguished subset: the field of real numbers

    R = (R, 0, 1,+, )does not admit tuple coding. We will discuss this very interesting, classicalstructure in the next section.

    6. Quantifier elimination. At the other end of the class of struc-tures which admit tuple coding are some important, classical structureswhich are, in some sense, very simple: the elementary functions and re-lations on them are quite trivial. We will consider some examples of suchstructures in this section, and we will isolate the property of quantifierelimination which makes them simplemuch as tuple coding makesthe structures in the preceding section complex.We list first, for reference, some simple logical equivalences which we

    will be using, and to simplify notation, we set for arbitrary formulas ,

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 19

  • 20 THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI

    and any structure A:

    A A |= , |= ( for all A, A ).

    6.1. Proposition (Basic logical equivalences).(1) The distributive laws:

    ( ) ( ) ( ) ( ) ( ) ( )

    (2) De Morgans laws:

    ( ) ( )

    (3) Double negation, implication and the universal quantifier:

    , , x (x)(4) Renaming of bound variables: if y is a variable which does not

    occur in and {x : y} is the result of replacing x by y in all its freeoccurrences, then

    x y{x : y}x y{x : y}

    (5) Distribution law for over :x(1 n) x1 xn

    (6) Pulling the quantifiers to the front: if x does not occur free in ,then

    x x( )x x( )x x( )x x( )

    6.2. Note (Notation for Truth and falsity). For the constructions in thissection, it is useful to enrich the language LPCI() with propositional con-stants tt,ff for truth and falsity. We may think of these as abbreviations,

    tt : x(x = x), ff : x(x 6= x),considered (by convention) as prime formulas.A literal is either a prime formula R(t1, . . . , tn), s = t, tt, ff, or the

    negation of a prime formula.

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 20

  • THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI 21

    6.3. Proposition (Disjunctive normal form). Every quantifier-free for-mula is (effectively) logically equivalent to a disjunction of conjunctionsof literals which has no more variables than : i.e., for suitable n, ni, andliterals `ij (i = 1, . . . , n, j = 1, . . . , ni) whose variables all occur in ,

    1 n, where for i = 1, . . . , n, i `i1 `ini .By the definition in the proposition, x = y(z = z) is not a disjunctive

    normal form of x = y (if all three variables are distinct), even though

    x = y x = y (z = z)Proof. We use Proposition 6.1 to show that the class F of formulas

    for which we can effectively compute a logically equivalent disjunctivenormal form contains the literals, because

    ` ` ffand F is closed under disjunction, conjunction and negation. (The messi-est part is the argument that F is closed under conjunction , whichwe do by induction on the number of disjuncts in .) a6.4. Proposition (Prenex normal forms). Every formula is (effec-

    tively) logically equivalent to a formula

    Q1x1 Qnxn ( quantifier-free)in prenex form, whose free variables are among the free variables of .

    6.5. Definition (Quantifier elimination for structures). A quantifier-freenormal form for a formula in a structure A, is any quantifier-free for-mula whose variables are among the free variables of and such that

    A .A structure A admits elimination of quantifiers, if every formula

    has a quantifier-free normal form in A; and it admits effective elimina-tion of quantifiers, if there is an effective procedure which will computefor each a quantifier-free normal form for in A.

    Decidable structures. To see the importance of this notion, supposethe vocabulary is purely relational, i.e., it has no constant or functionsymbols. Now the only quantifier-free sentences are tt and ff; and so if a -structure A admits effective quantifier elimination, then we can effectivelydecide for each sentence whether it is logically equivalent in A to tt orffin other words, we have a decision procedure for truth in A.More generally, suppose may have constants and function symbols and

    A admits effective quantifier elimination: if we have a decision procedurefor quantifier-free sentences (with no variables), then we have a decisionprocedure for truth in A. The hypothesis is, in fact, satisfied in mostexamples of structures which admit quantifier elimination.

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 21

  • 22 THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI

    6.6. Lemma (Quantifier elimination test). If every formula of the form

    x[1 n] (where 1, . . . , n are literals)is effectively equivalent in a structure A to a quantifier-free formula whosevariables are all among the free variables of , then A admits effectivequantifier elimination.

    Proof. It is enough by (3) of Proposition 6.1 to eliminate quantifiersfor formulas which dont have any implications or universal quantifiers.Thus, if F is the class of all such formulas which (effectively) have quanti-fier free forms in A, then it is enough to show that it contains all literals,which it clearly does; that it is closed under , and , which it clearlyis; and that it is closed under existential quantification. For the latter, if

    xwith quantifier-free, we bring to disjunctive normal form, so that

    x[1 n] x1 xnwhere each i is a conjunction of literals and then we use the hypothesisof the Lemma. a6.7. Proposition. For each infinite set A, the structure A = (A) in the

    language with empty vocabulary admits effective quantifier elimination.

    Proof. By the test 6.6, it is enough to eliminate quantifiers from everyformula of the form

    x[(x = z1 x = zk) (u1 = v1 ul = vl) (x 6= w1 x 6= wm) (s1 6= t1 to 6= so)]

    where we have grouped the variable equations and inequations accord-ing to whether x occurs in them or not; i.e., x is none of the variablesui, vi, si, ti. We can also assume that x is none of the variables zi, becausethe equation x = x can simply be deleted; and it is none of the variableswi, since if x 6= x is one of the conjuncts, then ff.Case 1, k = 0, i.e., there is no equation of the form x = z in the matrix

    of . In this case

    (u1 = v1 ul = vl) (s1 6= t1 tm 6= sm).This is because if pi is any assignment which satisfies

    (u1 = v1 ul = vl) (s1 6= t1 tm 6= sm)and t is any element in the (infinite) setA which is distinct from pi(w1), . . . ,pi(wm), then pi{x := t} satisfies the matrix of .

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 22

  • THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI 23

    Case 2, k > 0, so there is an equation x = zi in the matrix of . In thiscase,

    (x = z1 x = zk){x : zi} (u1 = v1 ul = vl) (x 6= w1 x 6= wm){x : zi} (s1 6= t1 tm 6= sm)]

    since every assignment which satisfies must assign to x the same valuethat it assigns to zi. aThis proposition is about a structure of no interest whatsoever, but the

    method of proof is typical of many quantifier elimination proofs.

    6.8. Definition (Dense linear orderings). A linear ordering L = (L,)is dense in itself if for every x, y L such that x < y, there is a z suchthat x < z < y.

    Standard examples are the usual orderings (Q,) and (R,) on therational and the real numbers. They also have no least or greatest element,so they are covered by the next result.

    6.9. Theorem. If L = (L,) is a dense linear ordering without leastor greatest element, then L admits effective quantifier elimination.

    Outline or proof. It is convenient to introduce a new symbol < forstrict inequality, so that

    (6-1) ff L x < x, tt L x = x, x y L x = y x < y,x < y L x y x 6= y.

    We can use the equivalences in the first line to eliminate the truth valuesand the symbol , so that every formula is logically equivalent in L toone in which only the symbols = and < occur. In particular, the literalswhich occur in disjunctive normal forms of quantifier free formulas are allin one of the forms

    x = y, x 6= y, x < y, (x < y)We now replace all the negated literals by quantifier free formulas whichhave no negation, using the equivalences

    (6-2) x 6= y L x < y y < x, (x y) L y < x,(x < y) L x = y y < x

    and then we apply repeatedly the Distributive Laws in Proposition 6.1(which do not introduce negations) to construct a disjunctive normal formwith only positive literals x = y and x < y. This means that in applying

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 23

  • 24 THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI

    the basic test Lemma 6.6, we need consider only formulas of the form

    x[(x = z1 x = zk) (x < u1 x < ul) (v1 < x vm < x)

    (s1 < s1 sn < sn) (t1 = t1 to = to)]If some ui x of some vj x, then L ff, so we may assume that

    these variables are all distinct from x.Case 1, k > 0, so that some equation x = zi is present in the matrix.

    Now is equivalent to the quantifier-free formula which is constructed byreplacing x by zi in the matrix.Case 2, k = l = m = 0, so that x does not occur in the matrix of .

    We simply delete the quantifier.Case 3, k = l = 0 but m > 0. In this case

    L (s1 < s1 sn < sn) (t1 = t1 to = to)]because whatever values are assigned to v1, . . . , vm by an assignment,some greater value can be assigned to x since L has no largest element.Case 4, k = m = 0 but l > 0. This case is symmetric to Case 2, and

    we handle it using the fact that L has no least element.Case 5, k = 0 butm > 0, l > 0. Since L is dense in itself, the restrictions

    on x in the matrix will be satisfied by some x exactly when

    max{v1, . . . , vm} < min{u1, . . . , ul},and we can say this formally by a big conjunction: i.e.,

    L

    1il,1jm(vj < ui)

    (s1 < s1 sn < sn) (t1 = t1 to = to)This completes the verification of the test, Lemma 6.6 for dense linearorderings with no first and last element, and so these structures admiteffective quantifier elimination. aThere are many interesting structures which admit effective quantifier

    elimination, including the following:

    6.10. Example. The reduct (N, 0, S) of N without addition or mul-tiplication admits effective quantifier elimination, as does the somewhatricher structure (N, 0, S,

  • THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI 25

    and consider (for once) the expansion of (N, 0, S,+) by these infinitelymany relations,

    NP = (N, 0, S,+, {m}mN).This structure admits effective quantifier elimination and there is a triv-ial decision procedure for quantifier free sentences, which involve onlynumerals and congruence assertions about them; and so it is a decidablestructure, and then the structure (N, 0, S,+) of additive arithmetic is alsodecidable, since it is a reduct of NP .This is a famous and not so simple theorem of Presburger, Theorem

    32E in Enderton.Note that the expansion of the language by these congruence relations

    is quite similar to the expansion with tt and ff which we have already as-sumed, because we need it. The congruence relations are simply definablein additive arithmetic, one-at-a-time:

    x m y : (z)[(x+ z + z + + z m times

    = y) (y + z + z + + z m times

    = x)].

    The quantifier elimination in Presburgers structure NP yields for each a quantifier-free formula in which these new, prime formulas x m yoccur, for various values of m; we can then replace all of them with theirdefinition, which gives us a formula which is NP with and in whichexistential quantifiers occur only in the literals. This is exactly the sortof extended quantifier-free formulas that we will get if we replace tt andff by their definitions after the quantifier elimination procedure has beencompleted.

    6.12. Example (The field of complex numbers). The field of complexnumbers

    C = (C, 0, 1,+, )admits effective quantifier elimination, and so it is decidable, since thequantifier-free sentences in the language involve only trivial equalitiesand inequalities about numerals.

    6.13. Example (The ordered field of real numbers). The structure

    Ro = (R, 0, 1,+, ,)admits effective quantifier elimination, and so it is decidable, as above.This is a famous theorem of Tarski, especially important because it es-

    tablishes the decidability of classical (ancient) Euclidean plane and spacegeometry: it is easy to see that if we use Cartesian coordinates, we cantranslate all the propositions studied in Euclidean geometry into sen-tences in the language of Ro, and then decide them by Tarskis algorithm.Contrast this result with Example 5.10: if we just add a name for theset of integers Z to the language, we get a structure which admits tuple

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 25

  • 26 THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI

    coding, in whose language we can express all the propositions of classicalanalysisincluding calculus.

    7. Theories and elementary classes. Next we consider how for-mal, LPCI sentences can be used to define properties of structures.

    7.1. Definition (Elementary classes of structures). A property of -structures is basic elementary if there exists a sentence in LPCI()such that for every -structure A,

    A has property A |= ;it is elementary if there exists a (possibly infinite) set of sentences Tsuch that

    A has property for every T ,A |= .Basic elementary properties of -structures are (obviously) elementary,but not always vice versa, as we will see.Instead of a property of -structures, we often speak of a class (col-

    lection) of structures and formulate these conditions for classes, in theform

    A A |= (basic elementary class)A for every T ,A |= (elementary class).

    The basic use for these notions is in defining the following, fundamentalconcept of a (first order) theories and their models:

    7.2. Definition (Theories and models). A theory in a language LPCI()is any (possibly infinite) set of sentences T of LPCI(). The members ofT are its axioms.A -structure A is a model of T if every sentence of T is true in A: we

    write

    A |= T df for all T, A |= ,(7-1)and we collect all the models of T into a class,

    Mod(T ) =df {A | A |= T}.(7-2)Notice that Mod(T ) is an elementary class of structuresand if T is finite,then Mod(T ) is a basic elementary class, axiomatized by the conjunctionof all the axioms in T .In the opposite direction, the theory of a -structure A is the set of

    all LPCI()-sentences that it satisfies,

    Th(A) =df { | is a sentence and A |= }.(7-3)

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 26

  • THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI 27

    Finally, we define the fundamental relation of logical consequencesbetween a theory and a sentence,

    T |= for every A, if A |= T, then A |= .(7-4)One of the basic problems in logic is the relation between a structure A

    and its theory Th(A): how much of A is captured by all the first-orderfacts about A collected in Th(A)?

    7.3. Definition (Elementary equivalence). Two -structures are ele-mentarily equivalent if they satisfy the same LPCI()-sentences, insymbols

    A B df Th(A) = Th(B).(7-5)Must elementarily equivalent structures be isomorphic? (We will answer

    this further on.)Axiomatic theories are useful, because they allow us to prove properties

    of many, related structures simultaneously, for all of them, by derivingthem from the axioms. We formulate here a few, basic theories we canuse for examples later on.

    7.4. Definition (Graphs). The theory SG of symmetric graphs is for-mulated in the language LPCI(E) with just one, binary relation symbolE and one axiom,

    xy[E(x, y) E(y, x)].The symmetric graphs then are exactly the models of SG.

    7.5. Definition (Theories of order). The theories of partial and linearorderings are also formulated in the language with vocabulary just one,binary relation symbol, which, however, we now denote as :

    PO=df {x(x x), xy[(x y y x) x = y],xyz[(x y y z) x z]}

    LO=df PO {xy[x y y x]}DLO=df LO {xy[x < y z(x < z z < y)]

    xy[x < y], yx[x < y]}The last of these is the theory of dense linear orderings without first

    and last element, and we have shown that every model of DLO admitseffective quantifier elimination, Theorem 6.9. The proof, actually, wasuniform, and so it shows that the theory DLO admits effective quantifierelimination, in the following, precise sense.

    7.6. Definition (Quantifier elimination for theories). A theory T in thelanguage LPCI() admits elimination of quantifiers, if for every -formula , there is a quantifier-free formula (whose variables are all

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 27

  • 28 THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI

    among the free variables of ) such that

    T |= .As with structures, we assume here that the language is expanded by theprime, propositional constants tt and ff which may occur in .A structure A admits (effective) quantifier elimination exactly when its

    theory Th(A) admits (effective) quantifier elimination.

    7.7. Corollary. The theory DLO of dense linear orderings without firstor last element admits effective quantifier elimination, and so it is decid-able.

    Proof follows immediately from the proof of Theorem 6.9, which pro-duces the same quantifier-free form L-equivalent to a given , indepen-dently of the specific L, just so long as L |= DLO.The second claim simply means that we can decide for any given sen-

    tence whether or not DLO |= . It is true because the quantifier elimi-nation procedure yields either tt or ff as L-equivalent to , independentlyof the specific L. a7.8. Definition (Fields). The theory Fields comprises the formal ex-

    pressions of the axioms for a field listed in Definition 1.4, in the languageLPCI(0, 1,+, ).For each number n 1 define the term n 1 by the recursion

    1 1 1, (n+ 1) 1 (n 1) + (1),so that e.g., 3 1 ((1) + (1)) + (1). (Make sure you understand herewhat is a term of LPCI(0, 1,+, ), what is an ordinary number, and which+ is meant in the various places.)For each prime number p, the finite set of sentences

    Fieldsp =df Fields, (2 1 = 0), . . . ,((p 1) 1 = 0), p 1 = 0is the theory of fields of characteristic p. The theory of fields of charac-teristic 0 is defined by

    Fields0 =df Fields, (2 1 = 0), (3 1 = 0), . . . .In describing sets of formulas we use , to indicate union, i.e., in setnotation,

    Fields0 =df Fields {(2 1 = 0), (3 1 = 0), . . . }.The simplest example of a field of characteristic p is the finite structure

    Fp = ({0, 1, . . . , p 1}, 0, 1,+, )with the usual operations on it executed modulo p, but it takes some(algebra) work to show that this is a field. There are many other fields ofcharacteristic p, both finite and infinite. The number fields Q, R and Chave characteristic 0.

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 28

  • THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI 29

    For each p N, Fieldsp is a finite set of sentences, while Fields0 is infinite.7.9. Definition (Peano Arithmetic, PA). The axioms of Peano arith-

    metic PA are the universal closures of the following formulas, in the lan-guage LPCI(0, S,+, ) of the structure of arithmetic (which we will callfrom now on the language of Peano arithmetic).1. [S(x) = 0].2. S(x) = S(y) x = y.3. x+ 0 = x, x+ S(y) = S(x+ y).4. x 0 = 0, x (Sy) = x y + x.5. For every formula (x, ~y),[

    (0, ~y) (x)[(x, ~y) (S(x), ~y)]] (x)(x, ~y).

    The last is the Elementary Axiom Scheme of Induction which ap-proximates in LPCI the intended meaning of the full Axiom of Inductionin 1. It has infinitely many instances, one for each formula (x, ~y).The standard (intended) model of PA is, of course, N, but we will see

    that it has many others!

    7.10. Definition (The Robinson system Q). This is a weak, finite the-ory of natural numbers in the language of Peano arithmetic, which re-places the Induction Scheme by the single claim that each non-zero num-ber is a successor:1. [S(x) = 0].2. S(x) = S(y) x = y.3. x+ 0 = x, x+ (S(y) = S(x+ y).4. x 0 = 0, x (Sy) = x y + x.5. x = 0 (y)[x = S(y)].

    It is clear that N is a model of Q, but it is a weak theory, and so it isquite easy to construct many peculiar models of it.

    8. Deduction. The (Hilbert style) proof system for LPCI is the nat-ural extension to LPCI of the system of axioms and rules for the propo-sitional calculus that we have studied. In the precise definition whichfollows, t stands for an arbitrary term of LPCI(), for a fixed ; , , stand for arbitrary formulas of LPCI(); and (v, ~u) stands for an ex-tended formula, so that all the free variables of are in the list v, ~u.Some of the axioms and rules have a condition, the most significant beingthe hypothesis that

    t is free for v in (v, ~u);

    it means that no variable which occurs in t is bound in (t, ~u).

    8.1. Definition. The axiom schemes and rules for LPCI() are dividedinto four groups, as follows:

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 29

  • 30 THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI

    (A) Propositional axioms.

    (1) ( )(2) ( ) (( ( )) ( ))(3) ( ) (( ) )(4) (5) ( ( ))(6a) ( ) (6b) ( ) (7a) ( ) (7b) ( )(8) ( ) (( ) (( ) ))

    (B) Predicate axioms.

    (9) v(v, ~u) (t, ~u) (t free for v in (v, ~u))(10) v( ) ( v) (v not free in )(11) (t, ~u) v(v, ~u) (t free for v in (v, ~u))

    (C) Rules of inference.

    (12) From and , infer . (Modus Ponens)(13) From , infer v. (Generalization)(14) From , infer v , provided v is not free in .

    (Exists Elimination)

    (D) Identity axioms.

    (15) v = v v = v v = v v = v (v = v (v = v))(16) (v1 = w1 . . . vn = wn) (R(v1, . . . , vn) R(w1, . . . , wn))

    (R n-ary relation symbol)(17) (v1 = w1 . . . vn = wn) (f(v1, . . . , vn) = f(w1, . . . , wn))

    (f n-ary function symbol)The axioms and rules in (A) (C) are for LPC(), the lower predicate

    calculus without identity.

    8.2. Definition. A deduction in LPCI from a theory (set of sentences)T is any sequence of formulas

    0, 1, . . . , n,

    where each i is either an axiom, or a sentence in T , or the same as somej for some j < i, or follows from previously listed formulas by one of therules of inference. We set

    T ` df there exists a deduction 0, . . . , n from T.If T = we just write ` . A proof is a deduction from the empty theory.A deduction is propositional if it only uses the propositional axioms in

    group (A) and the Modus Ponens inference rule (12). (The formulas in apropositional deduction may have the identity symbol = and quantifiersin them.)

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 30

  • THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI 31

    If T is a theory, is a sentence, and T ` , we call a proof theoreticconsequence or just a theorem of T . A propositional theorem of Tis any formula for which there is a propositional deduction from T ;these are easy to recognize, because they are substitution instances ofpropositional tautologies, cf. Problem x2.24.The proof theoretic consequences of the empty theory are the theorems

    of LPCI().

    8.3. Lemma (Soundness of the axioms). If is any instance of theaxiom schemes (1) (11) and (15) (17) of LPCI() and A is any -structure, then A |= ~.Proof. First we verify easily, directly from the definitions and the

    Composotionality Theorem 3.8 that

    A |= ~ for every assignment pi,A, pi |= ;(8-1)and then we prove by direct computation that if is an instance of oneof the axiom schemes (1) (11), (15) (17), then for every assignmentpi, A, pi |= . As a sample, we treat just one case which has a restriction.Case (10). Show that for every pi,

    A, pi |= v( ) ( v)assuming that v does not occur free in .It is enough to show that if an assignment pi satisfies v( ) (always

    in A), then it also satisfies ( v); i.e., if pi satisfies v( ) and, then it satisfies v. The hypothesis means that for every x A,

    A, pi{v := x} |= ;the restriction that v does not occur in means that

    A, pi |= A, pi{v := x} |= ,by (2) of the Compositionality Theorem 3.8; and so the assumption thatA, pi |= implies that

    A, pi{v := x} |= .So we have shown that for every x A, A, pi{v := x} |= , which meansexactly that A, pi |= v. aMore interesting than these straight verifications of the axiom schemes

    are the counterexamples which show that the restrictions in (9) (11) arenecessary.

    8.4. Note. Axiom scheme (9)

    v(v, ~u) (t, ~u) (t free for v in (v, ~u))

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 31

  • 32 THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI

    is not valid in every structure without the restriction. A counterexampleis the instance in the language of arithmetic

    vy[y = S(v)] y[y = S(t)]which with t : y becomes

    vy[y = S(v)] y[y = S(y)],which is clearly false in N.Axiom scheme (11)

    (t, ~u) v(v, ~u) (t free for v in (v, ~u))is not valid without the restriction. A counterexample which uses justthe identity symbol is (v, ~u) s[s = v]. Now the instance of (11) is

    s[s = t]) vs[s = v];and if we substitute (the forbidden) t : s, we get

    s[s = s] vs[s = v],which is clearly false in every structure which has more than one element.We leave (10) for the problems.

    8.5. Theorem (The Soundness Theorem). Every theorem of a theoryT is a logical consequence of T , i.e., for every sentence ,

    if T ` , then T |= .Proof. It is enough to show that if 0, . . . , n is a deduction from T ,

    then for every structure A |= T and every assignment pi,A, pi |= i (i = 0, . . . , n)

    and we do this by (complete) induction on i n. The conclusion is truewhen i is an axiom by Lemma 8.3; it is trivial if is an identity axiom;and it is also trivial if occurs earlier in the deduction or is inferred fromformulas earlier in the deduction by Modus Ponens. Thus it is enough toconsider only the case when is inferred from a formula preceding it inthe proof by one of the predicate rules of inference (13) or (14).

    (13), Generalization. By the induction hypothesis, for every assignment, we know that A, |= , and we must show that for every assignmentpi, A, pi |= v, i.e.,

    for every x A, A, pi{v := x} |= ;but this follows immediately by applying the induction hypothesis to =pi{v := x}.(14) Exists Elimination. By the induction hypothesis, for every assign-

    ment , we know that

    A, |= ,

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 32

  • THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI 33

    and we must show that for every pi,

    A, pi |= v .If A, pi 6|= v, then we are done, by the definition of satisfaction formaterial implication. If the opposite holds, then we know that

    A, pi |= v,so that for some x A, we have

    A, pi{v := x} |= ;applying the hypothesis to = pi{v := x}, we get

    A, pi{v := x} |= ;and since v does not occur free in (by the condition on the rule) andpi agrees with pi{v := x} on all other variables, we have the requiredA, pi |= by (2) of the Compositionality Theorem 3.8. aFor the converse we will need to construct proofs, of course, but we will

    keep this to a minimum.

    8.6. Lemma (Constant Substitution Lemma). Suppose T is a theory,the variable v does not occur bound in the sequence of formulas

    0, . . . , n

    of LPCI(), and c is a fresh constant, i.e., a constant which does notoccur in T or in any i; then

    0, . . . , n is a deduction from T

    0{v : c}, . . . , n{v : c} is a deduction from T .Proof is easy, by taking cases on the justification which allows the

    insertion of each i and the corresponding i{v : c} in these deductions.The relevant observation (for the direction = of the equivalence) is thatv cannot be the active variable in any application od Generalization orExists Elimination, because if it were, it would occur bound in someformula of the given deduction. a8.7. Theorem (The Deduction Theorem). For every theory T , every

    sentence and every formula ,

    if T, ` , then T ` .Proof. We follow the architecture of the proof of the Deduction The-

    orem for the Propositional Calculus, and there are only two additionalcases to consider, when n is derived from some earlier formula in thegiven deduction (from T, ) by one of the predicate rules of inference.

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 33

  • 34 THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI

    (13) Generalization. Now n v, and the induction hypothesis givesus a deduction from T of ; we follow this proof by the formulasv( ) (13), v( ) ( v) (10),

    v (Modus Ponens)where v( ) ( v) is an instance of Axiom (10), justifiedbecause v does not occur free in (which is a sentence).

    (14) Exists Elimination. Now n (v ) and it is inferred in thegiven deduction from T, by applying (14) to , so that v does notoccur free in . The induction hypothesis gives us a proof from T of

    ( ),and we follow this with the following sequence of formulas to complete adeduction of (v ) from T :. . . ( ) (Prop. steps)

    v ( ) (14). . . (v ) (Prop. steps),

    where the application of (14) is justified because v does not occur in , by the hypothesis and the assumption that is a sentence. a8.8. Lemma (Alphabetic change of bound variables). If the variable w

    is free for v in , then

    ` v w{v : w}` v w{v : w}

    Proof. It is enough to show that

    ` w{v : w} v,since the rest follows by symmetry, the equivalence of with andpropositional logic. Here is a deduction of it:

    . . . {v : w} {v : w} (Propositional),{v : w} v (with t : w in Axiom (11)),

    w{v : w} v (Rule (14)) a

    It is possible to define an extension to LPCI of the Gentzen-style proofsystem Gs we developed for Propositional Logic, but we do not have asmuch need for it here (because of Problem x2.24) and we will not botherwith it. We only list in the next theorem some Gentzen-style rules whichare interesting and useful on some occasions.

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 34

  • THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI 35

    8.9. Theorem (The natural introduction rules). If T is a set of sen-tences, the indicated substitutions are free, and the indicated restrictionsare obeyed, then then the following hold:

    () If T, ` , then T ` . Restriction: is a sentence.() If T ` and T ` , then T ` .() If T ` or T ` , then T ` .() If T, ` and T, ` , then T ` . Restriction: a sentence.() If T ` , then T ` v.() If T ` {v : t}, then T ` v.8.10. Theorem (The natural elimination rules). If T is a set of sen-

    tences, the indicated substitutions are free, and the indicated restrictionsare obeyed, then the following hold:

    () If T ` and T ` , then T ` .() If T ` , then T ` and T ` .() If T, ` and T, ` , then T, ` Restriction: , are sentences.

    () If T ` , then T ` .() If T ` v, then T ` {v : t}() If T, {v : c} ` , then T,v ` Restriction: v is a sentence and c is a constant which does not occurin T or in .

    Proof. We verify only the last rule of ()-elimination whose proof isthe fussiest.By appealing to the Deduction Theorem and Modus Ponens, it is enough

    to show that

    if T ` {v : c} , then T ` v .So suppose we are given a deduction from T

    0, . . . , n, {v : c} in which the constant c may occur, but also the variable v may occur insome iwhich is what causes some complexity in the argument. Choosea variable w which does not occur in any of the formulas in this deductionand notice that the sequence

    0{c : w}, . . . , n{c : w}, {v : w} (8-2)is also a deduction from T , where each i{c : w} is naturally defined byreplacing every occurrence of c in i by the fresh variable w; this followsby the Constant Substitution Lemma 8.6, since, obviously,

    i{c : w}{w : c} i,

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 35

  • 36 THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI

    {v : w}{w : c} {v : c} and c does not occur in . We nowappend to the deduction (8-2) the formula

    w{v : w} by Rule (14)to get T ` w{v : w} , which implies T ` v by Lemma 8.8and propositional steps. a8.11. Proposition. If T ` and T ` , then for every sentence ,

    T ` , so that, in particular, T ` ff.Proof. For any sentence , by the hypothesis,

    T, ` , T, ` ;hence T ` by ()-introduction, hence T ` , by ()-elimination. a

    9. The Completeness and Compactness Theorems. A vocab-ulary is finite if it has finitely many constant, relation and functionsymbols. A -theory is a set T of sentences in LPCI().Our main aim in this section is to prove the following, converse to the

    Soundness Theorem 8.5:

    9.1. Theorem (Godels Completeness Theorem, I). If is finite, thenevery logical consequence of a -theory T is a theorem of T , i.e., for everysentence ,

    if T |= , then T ` .For the proof, we will need some new notions and various facts about

    them.

    9.2. Definition (Consistent theories). A theory T is consistent if itdoes not prove a contradiction, equivalently if T 6` ff; it is inconsistentin the opposite case, i.e., if T ` ff.If T has a model, then it is consistent, since it cannot be that A |=

    for every . This remark suggests a different version of the CompletenessTheorem, which is very useful:

    9.3. Theorem (Godels Completeness Theorem, II). If is finite, thenevery consistent -theory T has a model.

    Proof of CT I from CT II. Suppose T |= but (towards a contra-diction), T 6` . Now T{} is consistent, since the opposite assumptiongives T, ` and then (easily) T ` . By the assumed version II of theCompleteness Theorem, this implies that T {} has a model A; butthen A |= T and A 6|= , which contradicts the hypothesis. aIt ia also easy to prove CT II assuming CT I, cf. Problem x2.26, so both

    versions of the Completeness express the same, basic mathematical fact.They are also equally useful in applications.

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 36

  • THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI 37

    Before we plunge into the proof of the Completeness Theorem, we con-sider one important (and surprizing) application of it, which depends onthe following, simple property of consistency:

    9.4. Lemma. A theory T is consistent if and only if every finite subsetT0 T of it is consistent.9.5. Example (Non-standard models of arithmetic). We define the func-

    tion n 7 (n) from natural numbers to terms of the language of arith-metic by the recursion,

    (0) 0, (n+ 1) S((n)),(9-1)so that (1) S(0), (2) S(S(0)), etc. These numerals are thestandard (unary) names of numbers in the language of PA.Let (c) = (0, c, S,+, ) be the expansion of the vocabulary of Peano

    arithmetic by a new constant c, and let

    T (c) = Th(N) {c 6= (0), c 6= (1), . . . }.(9-2)It is easy to check that every finite subset of T (c) is consistent, and so itis consistent, and by Theorem 9.3 it has a model

    A = (A, 0, c, S,+, ).This model satisfies all the true sentences in the language of arithmetic,since Th(N) T (c), and so its reduct

    N = (A, 0, S,+, )(9-3)satisfies all the true sentences of arithmetic. But N is not isomorphicwith N: because if pi : NA were an isomorphism, then (easily)

    pi(n) = (n)A,

    and the interpretations of the numerals do not exhaust the universe Asince A |= c 6= (n) for every n.In short, N is a structure which is elementarily equivalent with N

    but not isomorphic with N: we call it a non-standard model of truearithmetic.

    We now proceed to the proof of the Completeness Theorem 9.3, startingwith a few properties of consistent theories.

    9.6. Lemma. Suppose T is a consistent theory in LPCI().(1) For every sentence , either T {} is consistent, or T {} is

    consistent.(2) If v is a sentence, T {v} is consistent and c is a constant

    which does not occur in T or in v, then T {{v : c}} is consistent.

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 37

  • 38 THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI

    Proof. (1) If both T {} and T {} are inconsistent, then forany sentence ,

    T, ` and T, ` ,and so by ()-elimination T, ` ; but ` (propositionally),and so T ` . Thus T proves every sentence and it is inconsistent,contrary to hypothesis.

    (2) If T {{v : c}} is inconsistent, then T, {v : c} ` for everysentence ; but then, by ()-elimination, T,v ` , and so T {v} isinconsistent, contrary to hypothesis. a9.7. Definition (Complete theories). A theory T in a language LPCI()

    is complete if for each sentence of LPCI(), either T ` or T ` .The standard example of a complete theory is the theory Th(A) of a

    structure, since for every sentence , either A |= or A |= .9.8. Definition (Henkin sets). A theoryH is aHenkin set of LPCI()

    if it satisfies the following conditions:(H1) H is consistent.(H2) For each sentence , either H or H, so that in particular,

    H is complete.(H3) If v H, then there is a constant c such that {v : c} H.The constant c in the last condition is called a Henkin witness forthe existential sentence (v), so (briefly) a Henkin set is a consistent,strongly complete theory which has Henkin witnesses.

    9.9. Lemma (Properties of Henkin sets). Suppose H is a Henkin set.

    (1) H is deductively closed, i.e., for every sentence ,

    if H ` , then H.(2) For all sentences , ,v(v):

    H / H H H and H H H or H H / H or Hv H there is some c such that {v : c} Hv H for all c, {v : c} H

    Proof. (1) Suppose H ` but / H; then H by (H2), and soH ` , which makes H inconsistent contradicting property (H1).(2) We consider just two of these equivalences.

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 38

  • THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI 39

    If H, then , H by the deductive completeness of H, since ` and ` ; and for the converse of this, we use the fact that, ` , so that if , H, then H ` and so H.If v H, then {v : c} H for some c, by the key property

    (H3). The converse holds because {v : c} ` v and H is deductivelycomplete. aThis lemma suggests that every Henkin set is Th(A) for some structure

    A, and so to construct a model of some consistent theory T we shouldaim to construct a Henkin set which extends T . There are but two, smallsubtleties that we need to deal with to turn this idea into a proof.The Completeness Theorem 9.3 will follow from the following two, cru-

    cial lemmas, which have independent interest:

    9.10. Lemma A. Suppose is a finite vocabulary.Every consistent theory T in LPCI() is contained in a Henkin set H

    T of LPCI(), where the vocabulary is an expansion of by an infinitesequence of fresh constants (d0, d1, . . . ), so that

    (9-4) if = (Const,Rel,Funct, arity),

    then = (Const {d0, d1, . . . },Rel,Funct, arity).9.11. Lemma B. If H is a Henkin set in LPCI() (as in Lemma A),

    then there is a LPCI()-structure

    A = (A, {c}cConst, {di}iN, {R}RRel, {f}fFunct),such that for every LPCI()-sentence ,

    A |= H.In particular, A is a model of H.

    Assuming these two lemmas:Proof of Theorem 9.3. Suppose T is a consistent LPCI()-theory,

    H is a Henkin extension of it in LPCI() by Lemma 9.10, and A is amodel of H by Lemma 9.11: now the reduct

    A = (A, {c}cConst, {R}RRel, {f}fFunct),is a model of T by (1) of the Compositionality Theorem 3.8. aWe should mention that the restriction to finite in these lemmas is

    not necessary: in fact they hold for arbitrary . But all the interestingapplications are to -theories with finite ; and if is infinite, then theconstruction of the (necessarily infinite) and the proof that LPCI()has the necessary properties requires some non-trivial results from settheory which are not relevant to the task at hand.

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 39

  • 40 THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI

    Proof of Lemma A, 9.10. We assume the hypotheses and the nota-tion of Lemma A.Sublemma 1. There is a sequence of LPCI() sentences

    0, 1, . . .

    which contains all the LPCI() sentences, such that for each n, the con-stant dn does not occur in any of the first n sentences 0, . . . , n1.

    Proof. For each n = 0, 1, . . . , let

    Sn = the set of all sentences of LPCI() of length 5 + nwhose variables are in {v0, . . . , vn}, and in which

    only d0, . . . , dn1 of the fresh constants may occur.

    The choice of 5 in this definition insures that S0 is not empty, since

    v0v0 = v0, v0 = v0 S0.At the same time, easily:1. Each Sn is finite.2. Sn Sn+1, for each n.3. d0 does not occur in any sentence in S0, and for n > 0, dn does not

    occur in any sentence of Sn1.We now enumerate in some standard way all these finite sets,

    Sn = (n0 , . . . , nkn),

    and conclude that the required enumeration of all the LPCI()- sentencesis the concatenation of all these enumerations,

    00, . . . , 0k0 ,

    10, . . . ,

    1k1 , . . . . a (Sublemma 1)

    Sublemma 2. There exists a sequence

    0, 1, . . . ,(9-5)

    of LPCI()-sentences with the following properties:1. For each n, 2n n or 2n n.2. For each n, if 2n v(v) for some variable v and formula (v),

    then 2n+1 (dn), otherwise 2n+1 2n.3. For each n, the set T {0, . . . , 2n+1} is consistent.Proof. The sentences 2n, 2n+1 are defined by recursion on n, using

    Lemma 9.6and their definition is basically determined by the conditionsthey are required to satisfy. a (Sublemma 2)It is now easy to verify that the rangeH = {0, 1, . . . , } of the sequence

    of sentences in (9-5) constructed in the proof of Sublemma 2 is a Henkinset.

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 40

  • THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI 41

    To see that it includes T , suppose T . Now n for some n, andso either 2n or 2n ; but T {0, . . . , 2n+1} is consistent, andso it cannot contain both and so it must be that 2n . aProof of Lemma B 9.11. Let H be the Henkin set guaranteed by

    Lemma A, and let

    C = Const {d0, d1, . . . , }be the set of the constants in , including all the fresh constants weadded to the vocabulary . Lemma 9.9 suggests that we can construct amodel C of H on the universe C, by setting for e1, . . . , en, e C,

    RC(e1, . . . , en) R(e1, . . . , en) H,fC(e1, . . . , en) = e f(e1, . . . , en) = e H,

    and this almost works, except that it gives multiple valued interpreta-tions of the constants: it may well be that c = c H for two distinctconstants in . To deal with this, we need to identify constants whichH thinks to be equal, as follows. We set:

    a b (a = b) H (a, b C).Sublemma 1. The relation is an equivalence relation on the set C of

    constants, i.e., for all a, b, c C:a a, a b= b a, [a b & b c] = a c

    Proof is immediate from the axioms of equality, which are satisfiedby H, since it is deductively closed. For example, (a = a) H for everyconstant a, simply because ` a = a. a (Sublemma 1)The same kind of argument gives the next two facts we need:Sublemma 2. For every n-ary relation symbol R and all constants

    a1, . . . , an, b1, . . . , bn C,a1 b1, . . . an bn= [R(a1, . . . , an) H R(b1, . . . , bn) H].Sublemma 3. For every n-ary function symbol f and all constants

    a1, . . . , an C, there is a constant u C such that(f(a1, . . . , an) = u) H;

    and for all constants a1, . . . , an, u, b1, . . . , bn, v C,a1 b1, . . . an bn, u v

    = (f(a1, . . . , an) = u) H (f(b1, . . . , bn) = v) H.We now let C be the set of equivalence classes of this equivalence rela-

    tion on C and choose a set A C of representatives for them: this meansthat we define a function a 7 a on C to itself such that

    a b a = b.

    Math. 114L, Spring 2015, Y. N. MoschovakisLower Predicate Calculus with identity May 9, 2015, 9:17, 41

  • 42 THE LOWER PREDICATE CALCULUS WITH IDENTITY, LPCI

    This set A is the universe of the structure A that we want to construct.On it we interpret each constant c by c, and for the relation and functionsymbols as set

    R(a1, . . . , an) R(a1, . . . , an) H,f(a1, . . . , an) = e (f(a1, . . . , an) = e) H.

    The Sublemmas insure that these are good definitions; and then Lemma 9.9implies easily that for this structure A and all in LPCI(),

    A |= H,so that, in particular, A is a model of H. aWe end the section with two important corollaries of the Completeness

    Theorem which are formulated entirely in semantic terms, i.e., withoutreference to the proof theory of LPCI.

    9.12. Theorem (The Compactness Theorem). If every finite subset ofa theory T has a model, then T has a model.

    9.13. Theorem (The Weak Skolem-Lowenheim Theorem). If a theoryT has a model, then it has a model A = (A, . . . ) whose universe is count-able, i.e., A = {a0, a1, . . . , } is the range of a sequence.We will leave the (easy) proofs of these and some of their consequences

    for the problems.

    10. Problems.x2.1. Prove that the function (x) = x+1 is an automorphism of the

    usual linear ordering (Q,) on the rational numbers.x2.2. Suppose : AB is an isomorphism between the two -