1 lecture 11.09 - cis.upenn.edu

28
LGIC 310/MATH 570/PHIL 006 Fall, 2011 Scott Weinstein 1 1 Lecture 11.09.08 Logic is the science of truth. Truth arises from relations between language and the world. Logic provides mathematical models of such relations. In logic, we study formal languages L and structures A which play the role of language and the world. The central relation is truth of a sentence ϕ L in a structure A (we write this as A | = ϕ, and we say ϕ is true in A, or A satisfies ϕ). In terms of this relation, we define the notion of logical consequence: if Σ L is a set of sentences and ϕ L is a sentence we say ϕ is a logical consequence of Σ (and write Σ | = ϕ), if and only if, for all structures A, if A | , then A | = ϕ. We can also define the set V of valid sentences of L, namely, ϕ L is valid, if and only if, for every structure A, A | = ϕ. One important example of a formal language is first order logic. This lan- guage suffices for the formalization of large tracts of scientific discourse. A part of this course will be devoted to answering two interesting epistemological (even technological) questions concerning first order validity. 1. Can we find out that a sentence of first order logic is valid, if in fact it is? 2. Can we determine whether or not a sentence of first order logic is valid? The answers to both these questions emerged from work of Kurt G¨ odel, Alonzo Church, and Alan Turing. 1. G¨ odel’s Completeness Theorem: V is semi-decidable. 2. Church-Turing Theorem: V is not decidable. Reading: Enderton, Sections 1.1 & 1.2 Exercises: Enderton, Exercise 1.2.10 (Please devote some attention to this ex- ercise, since I would like to go over it during our next class meeting.) For those who would like to proceed ahead, our next reading will be sections 1.5 and 1.7; exercises 1.7.1-1.7.3.

Upload: others

Post on 22-Jan-2022

10 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: 1 Lecture 11.09 - cis.upenn.edu

LGIC 310/MATH 570/PHIL 006 Fall, 2011 Scott Weinstein 1

1 Lecture 11.09.08

Logic is the science of truth. Truth arises from relations between language andthe world. Logic provides mathematical models of such relations. In logic, westudy formal languages L and structures A which play the role of language andthe world. The central relation is truth of a sentence ϕ ∈ L in a structure A(we write this as A |= ϕ, and we say ϕ is true in A, or A satisfies ϕ). In termsof this relation, we define the notion of logical consequence: if Σ ⊆ L is a set ofsentences and ϕ ∈ L is a sentence we say ϕ is a logical consequence of Σ (andwrite Σ |= ϕ), if and only if,

for all structures A, if A |= Σ, then A |= ϕ.

We can also define the set V of valid sentences of L, namely, ϕ ∈ L is valid, ifand only if, for every structure A,A |= ϕ.

One important example of a formal language is first order logic. This lan-guage suffices for the formalization of large tracts of scientific discourse. A partof this course will be devoted to answering two interesting epistemological (eventechnological) questions concerning first order validity.

1. Can we find out that a sentence of first order logic is valid, if in fact it is?

2. Can we determine whether or not a sentence of first order logic is valid?

The answers to both these questions emerged from work of Kurt Godel, AlonzoChurch, and Alan Turing.

1. Godel’s Completeness Theorem: V is semi-decidable.

2. Church-Turing Theorem: V is not decidable.

Reading: Enderton, Sections 1.1 & 1.2Exercises: Enderton, Exercise 1.2.10 (Please devote some attention to this ex-ercise, since I would like to go over it during our next class meeting.)For those who would like to proceed ahead, our next reading will be sections1.5 and 1.7; exercises 1.7.1-1.7.3.

Page 2: 1 Lecture 11.09 - cis.upenn.edu

LGIC 310/MATH 570/PHIL 006 Fall, 2011 Scott Weinstein 2

2 Lecture 11.09.13

Some definitions:

1. O = {Ai | i ∈ N} = the set of sentence letters;

2. S = the set of sentences generated from O using the sentential connectives;

3. H = {h | h : O −→ {T,F}} = the set of truth assignments;

4. for α ∈ S and h ∈ H, h |= α, if and only if, h(α) = T (h satisfies α);

5. for Σ ⊆ S and h ∈ H, h |= Σ, if and only if, for all ϕ ∈ Σ, h |= ϕ (hsatisfies Σ);

6. for Σ ⊆ S and α ∈ S, Σ |= α if and only if for all h ∈ H, if h |= Σ, thenh |= α. (α is a logical consequence of Σ.)

7. For Σ ⊆ S let Cn(Σ) = {ϕ | Σ |= ϕ}. (The set of logical consequences ofΣ, aka the theory axiomatized by Σ.)

8. Σ is equivalent to Γ, if and only if, Cn(Γ) = Cn(Σ).

9. Σ is independent, if and only if, for all α ∈ Σ, (Σ− {α}) 6|= α.

We discussed the inductive definition of S (consult Enderton, Section 1.4 foradditional discussion of inductive definitions).

We presented a solution to Enderton, exercise 1.2.10 (a) and (b).

1.2.10(a) Show that if Σ ⊂ S is finite, then there is a ∆ ⊆ Σ such that Σ is equivalentto ∆ and ∆ is independent. We proceeded by induction on the size of Σand noted the importance of considering the case where Σ is empty, sinceany set of tautologies is equivalent to the ∅. We reduced the inductionstep to showing that for every Σ ⊆ S and α ∈ S, if (Σ − {α}) |= α, then(Σ− {α}) is equivalent to Σ.

It follows at once from the lemma below that for every Σ ⊆ S and α ∈ S,if (Σ− {α}) |= α, then (Σ− {α}) is equivalent to Σ. First, for any Σ ⊆ Swe define Mod(Σ) = {h ∈ H | h |= Σ}.

Lemma 1 For every Σ,Γ ⊆ S, if Mod(Σ) = Mod(Γ), then Cn(Σ) =Cn(Γ).

We suggested proving the converse of the foregoing lemma as an exercise(hint: apply the Compactness Theorem).

Exercise 1 For every Σ,Γ ⊆ S, if Cn(Σ) = Cn(Γ), then Mod(Σ) =Mod(Γ).

1.2.10(b) Let ϕn = (A0 ∧ . . . ∧An). Let Σ = {ϕn | n ∈ N}. Note that if Γ ⊆ Σ andΓ is independent, then Γ contains at most one sentence, whereas if Γ isequivalent to Σ then Γ is infinite. It follows that no subset of Σ is bothindependent and equivalent to Σ.

Page 3: 1 Lecture 11.09 - cis.upenn.edu

LGIC 310/MATH 570/PHIL 006 Fall, 2011 Scott Weinstein 3

3 Lecture 11.09.15

1.2.10(c) Let Σ = {σ0, σ1, . . .}. We may suppose without loss of generality that nofinite subset of Σ is equivalent to Σ. We define a sequence of sentences δi ∈Σ by induction as follows. Let δ0 = σi where i is the least j such that σj isnot a tautology. Some such j exists, for otherwise Σ would be equivalentto ∅. Let δn+1 = σi where i is the least j such that {δ0, . . . , δn} 6|= σj . Sucha j exists, for otherwise Σ is equivalent to {δ0, . . . , δn}. Now, let γ0 = δ0and γn+1 = (δ0 ∧ . . . ∧ δn) → δn+1. Let Γ = {γn | n ∈ N}. It is easy toverify that Γ is equivalent to Σ and that Γ is independent.

We began to study the expressive power of sentential logic. We first ad-dressed the finite case.

1. On = {Ai | i ≤ n};

2. Sn = the set of sentences generated from On using the sentential connec-tives;

3. Hn = {h | h : On −→ {>,⊥}};

4. for ϕ ∈ Sn,Modn(ϕ) = {h ∈ Hn | h |= ϕ}.

Theorem 1 (Expressive Completeness Theorem for Sentential Logic)For every n and for every X ⊆ Hn, there is a ϕ ∈ Sn, such that Modn(ϕ) = X.

A proof of this theorem, essentially the same as we presented in class (withslightly different terminology), may be found in Enderton, section 1.5.

We then began to consider the infinite case. We showed that

Theorem 2 (Cantor’s Diagonal Theorem) H is not countable.

Proof: Let {h1, h2, . . .} ⊆ H. We show that there is an h ∈ H such that forevery i, h 6= hi. Let change(>) = ⊥ and change(⊥) = >. For every i, leth(Ai) = change(hi(Ai)).

Exercise 2 Show that there is a P ⊆ H such that for all Σ ⊆ S, Mod(Σ) 6= P.

Exercise 3 Show that for every finite P ⊆ H there is a Σ ⊆ S such thatMod(Σ) = P.

Next time, we will go over solutions to these exercises, and perhaps Exercise1 as well. We will then proceed to prove the compactness theorem for sententiallogic (see Enderton, section 1.7). As part of the proof, we will present solutionsto Enderton, exercises 1.7.1 & 2.

Page 4: 1 Lecture 11.09 - cis.upenn.edu

LGIC 310/MATH 570/PHIL 006 Fall, 2011 Scott Weinstein 4

4 Lecture 11.09.20

A little set theory (see also Chapter 0 of Enderton, A Mathematical Introductionto Logic).

Let X and Y be sets. X is equipollent to Y , if and only if, there is a bijectionfrom X onto Y. We write X ∼ Y for X is equipollent to Y.

X � Y, if and only if, there is an injection from X into Y.

Theorem 3 (Cantor-Schroeder-Bernstein) If X � Y and Y � X, thenX ∼ Y.

We write X ≺ Y if and only if X � Y and X 6∼ Y . Let N be the set ofnatural numbers (aka non-negative integers), Q be the set of rational numbers(ratios of integers) and R be the set of real numbers. Let X × Y = {〈a, b〉 |a ∈ X and b ∈ Y }, the cartesian product of X and Y . It is easy to see that forevery set X, X � X ×X. Define f : N×N 7→ N, by f(m,n) = 2m · 3n. Since fis injective, N× N ∼ N, by Theorem 3. It follows that Q ∼ N.

Let X2 = {f | f : X 7→ {0, 1}}, the set of 0-1 valued functions with domainX.

Theorem 4 (Cantor Diagonal Theorem) X ≺ X2.

Proof: Let X be a set and let G : X −→ X2. It suffices to show that G is notsurjective. Define f : X −→ {0, 1} as follows: for every a ∈ X,

f(a) = 1− [G(a)](a).

It is easy to see that for all b ∈ X,G(b) 6= f.We write P(X) for the powerset of X, that is, {Y | Y ⊆ X}. Observe that

P(X) ∼ X2.

Theorem 5 R ∼ N2.

Proof: For r ∈ R define D(r) = {q ∈ Q | q < r} (the left, open Dedekind cutin Q determined by r). It follows at once from the fact that for all r, s ∈ Rwith r < s, there is a q ∈ Q such that r < q < s, that D is an injection fromR into P(Q). Hence, R � N2. On the other hand, for each f ∈ N{0, 2} defineC(f) =

∑∞i=0 f(i) · 3i+1. It follows from the least upper bound principle (which

allows us to show that the summation of an infinite series is well-defined) thatC is an injection. Thus, N2 � R.

In light of the fact that N ≺ R the following question is quite natural. Is therean infinite set Y ⊂ R such that Y 6∼ N and Y 6∼ R? Cantor conjectured that theanswer to this question is negative (Cantor’s Continuum Hypothesis - CH) andHilbert placed the question first on the famous list of problems he promulgated inhis address to the 1900 International Congress of Mathematicians. The questionis yet to be resolved. Indeed, the solution will require new insights into thenature of sets, since the current definitive axiomatization of set theory, Zermelo-Fraenkel set theory with the axiom of choice (ZFC), fails to settle the question,as the following results show.

Page 5: 1 Lecture 11.09 - cis.upenn.edu

LGIC 310/MATH 570/PHIL 006 Fall, 2011 Scott Weinstein 5

Theorem (Godel, 1939): CH is not refutable in ZFC.Theorem (Cohen, 1963): CH is not provable in ZFC.

Page 6: 1 Lecture 11.09 - cis.upenn.edu

LGIC 310/MATH 570/PHIL 006 Fall, 2011 Scott Weinstein 6

5 Lecture 11.09.22

We began by exploring the expressive power of sentential logic in the infinitecase. First we showed, in contrast to the finite case, that

Proposition 1 There is a P ⊆ H such that for all Σ ⊆ S, Mod(Σ) 6= P.

Proof: It is easy to see that P(S) ∼ H, from which it follows, by Theorem4, that P(S) ≺ P(H).

We next showed that

Proposition 2 For every finite P ⊆ H, there is a Σ ⊆ S such that Mod(Σ) =P.

Proof: Let P = {h1, . . . , hn}. Recall that Thlit(h) = {λ | λ is a literal and h |=λ}. The important properties of Thlit(h) are

1. h |= Thlit(h);

2. for every g ∈ H, if g |= Thlit(h), then g = h.

Let

λik ={Ak if hi(Ak) = >;¬Ak if hi(Ak) = ⊥.

Note that Thlit(hi) = {λik | k ≥ 1}. Now, let αij be the sentence

λi1 ∧ λi2 ∧ . . . ∧ λij ,

and let βj be the sentence

α1j ∨ α2j ∨ . . . ∨ αnj .

Finally, letΣ = {βj | j ≥ 1}.

It is straightforward to verify that for each 1 ≤ i ≤ n, hi |= Σ. It then remainsto show that for every h ∈ H, if h |= Σ, then for some 1 ≤ i ≤ n, h = hi.Suppose h ∈ H and h |= Σ. Note that for every 1 ≤ i < i′ ≤ n, there is a j suchthat λij 6= λi′j . It follows that for some l, for all l ≤ j and all 1 ≤ i < i′ ≤ n,h 6|= (αij ∧ αi′j). Hence, since h |= Σ, there is an i and an l such that for everyl ≤ j, h |= αij . It follows immediately that h = hi.

Recall that Σ is satisfiable if and only if there an h such that h |= Σ andthat Σ is finitely satisfiable if and only if for every finite ∆ ⊆ Σ, ∆ is satisfiable.We stated the

Theorem 6 (Compactness Theorem for Sentential Logic) If Σ ⊆ S isfinitely satisfiable, then Σ is satisfiable.

We applied the Compactness Theorem to provide a solution to Exercise 1.

Corollary 1 For every Σ,Γ ⊆ S, if Cn(Σ) = Cn(Γ), then Mod(Σ) = Mod(Γ).

Page 7: 1 Lecture 11.09 - cis.upenn.edu

LGIC 310/MATH 570/PHIL 006 Fall, 2011 Scott Weinstein 7

Proof: Suppose that Cn(Σ) = Cn(Γ), but that Mod(Σ) 6= Mod(Γ). We maysuppose, without loss of generality, that for some h ∈ H, h ∈ Mod(Σ) andh 6∈ Mod(Γ). It follows at once that Γ∪Thlit(h) is not satisfiable (recall that h isthe unique truth assignment satisfying Thlit(h)). But then, by the CompactnessTheorem, for some {λ1, . . . , λk} ⊆ Thlit(h),

Γ |= ¬(λ1 ∧ . . . ∧ λk).

But this contradicts the hypothesis that Cn(Σ) = Cn(Γ) and h ∈ Mod(Σ).We then proceeded to begin the proof of the Compactness Theorem.Proof: The Theorem is a corollary of the following two lemmas. First recall

that a set of sentences Σ′ is complete if and only if for every α ∈ S, α ∈ Σ′ or(¬α) ∈ Σ′.

Lemma 2 (Completion Lemma) If Σ is finitely satisfiable, then there is aΣ′ such that

1. Σ ⊆ Σ′;

2. Σ′ is finitely satisfiable;

3. Σ′ is complete.

The canonical truth assignment, hΣ′ for Σ′ is defined as follows: for everysentence letter A ∈ O,

hΣ′(A) = > if and only if A ∈ Σ′.

Lemma 3 (Canonical Truth Assignment Lemma) Let Σ′ ⊆ S. If Σ′ isfinitely satisfiable and complete, then hΣ′ |= Σ′.

Page 8: 1 Lecture 11.09 - cis.upenn.edu

LGIC 310/MATH 570/PHIL 006 Fall, 2011 Scott Weinstein 8

6 Lecture 11.09.27

Proof of Lemma 2: Let S = {α1, α2, . . .}. We construct a sequence of sets ofsentences Σ0,Σ1, . . . to satisfy the following conditions (i)-(iv), and then defineΣ′ to be

⋃i∈N Σi.

(i) Σ0 = Σ;

(ii) Σn ⊆ Σn+1, for all n;

(iii) Σn is finitely satisfiable, for all n;

(iv) αn ∈ Σn or (¬αn) ∈ Σn, for all n > 0.

Note that conditions (i) and (iv) immediately imply that Σ′ satisfies conditions1. and 3. of Lemma 1, while conditions (ii) and (iii) imply that Σ′ satisfiescondition 2. of the Lemma 1.

At stage 0 of the construction we set Σ0 = Σ. At stage n+ 1 we set

Σn+1 ={

Σn ∪ {αn+1} if Σn ∪ {αn+1} is consistent;Σn ∪ {¬αn+1} otherwise.

We first show by induction that for all n, Σn is finitely satisfiable. Σ0 = Σis finitely satisfiable by hypothesis. Suppose Σn is finitely satisfiable. Thefollowing sublemma then guarantees that Σn+1 is finitely satisfiable, and therebyconcludes the proof of Lemma 2.

Sublemma 1 Let Γ ⊆ S and α ∈ S. If Γ is finitely satisfiable, then Γ∪ {α} orΓ ∪ {¬α} is finitely satisfiable.

Proof of Sublemma 1: Suppose, for reductio, that Γ is finitely satisfiable andthat for some α neither Γ ∪ {α} nor Γ ∪ {¬α} is finitely satisfiable. Then thereare finite ∆,∆′ ⊆ Γ such that neither ∆∪{α} nor ∆′ ∪{¬α} is satisfiable. Butthen, ∆ ∪∆′ ⊆ Γ is finite and is not satisfiable, contrary to hypothesis.

Proof Sketch of Lemma 3: Let hΣ′ be the canonical truth assignment for Σ′.We show by induction on sentences that for every sentence α,

hΣ′ |= α ⇐⇒ α ∈ Σ′.

Observe that the basis case of the induction is immediate from the definition ofcanonical truth assignment. The induction step is a straightforward applicationof the definitons of satisfaction, completeness, and finite satisfiablity. We wentover the case of disjunction in detail in class.

With the proof of the Compactness Theorem thus concluded, we went on toderive the following corollary.

Corollary 2 (Compactness Theorem for Tautological Consequence) Forevery Σ ⊆ S and every α ∈ S, if Σ |= α, then for some finite ∆ ⊆ Σ such that∆ |= α.

Page 9: 1 Lecture 11.09 - cis.upenn.edu

LGIC 310/MATH 570/PHIL 006 Fall, 2011 Scott Weinstein 9

Proof: Suppose Σ |= α. Then, Σ∪{¬α} is not satisfiable. It follows from theCompactness Theorem (for sentential satisfiablity) that there is a finite ∆ ⊆ Σsuch that ∆ ∪ {¬α} is not satisfiable. It follows that ∆ |= α.

We began to discuss the expressive power of first-order logic. We consideredtwo structures, UDT, an undirected triangle, and BIC, an undirected bi-infinitechain. We observed that both these structures are 2-regular simple graphs, acondition that is expressible by the conjunction of the following three first-ordersentences.

• (∀x)¬Exx (irreflexivity)

• (∀x)(∀y)(Exy → Eyx) (symmetry)

• (∀x)(∃y)(∃z)(y 6= z ∧ (∀w)(Exw ↔ (w = y ∨ w = z))) 2-regularity

We noted that UDT is characterized up to isomorphism by the additionalcondition that the universe has exactly three members, which is expressibleby a first-order sentence. We asked whether BIC can be characterized up toisomorphism by a set of first-order sentences. We will pursue this, and relatedquestions, next time.

Page 10: 1 Lecture 11.09 - cis.upenn.edu

LGIC 310/MATH 570/PHIL 006 Fall, 2011 Scott Weinstein 10

7 Lecture 11.09.29

We began to study the expressive power of first-order logic by giving somesimple examples of first-order definable classes of structures and of first-orderdefinable relations on a fixed structure. For a first-order sentence α, we defineMod(α) = {A | A |= α}. We say a collection of structures C is first-orderdefinable if and only if for some first order sentence α, C = Mod(α). Given astructure A and a formula α(x1, . . . , xn), with at most the variables indicatedfree, we define the n-ary relation defined by α on A as follows:

α[A] = {< a1, . . . , an >| A |= α[(x1|a1), . . . , (xn|an)]}.

We presented solutions to problems 2.2.9 and 2.2.11 in Enderton, which dealwith definable collections of structures and definability within a fixed structurerespectively.

Let A = 〈|A|, PA〉 be a structure for a language with a binary relation P andwith no further relation, function, or constant symbols other than identity. Wewill often use A, rather than |A|, to denote the universe of A when no confusionis likely to result. If f is a function with domain A and range contained in A,that is, a function from A into A, we say that PA is the graph of f if and onlyif for all a, b ∈ A,

〈a, b〉 ∈ PA ⇐⇒ f(a) = b.

Let α be the sentence

∀x∃yPxy ∧ ∀x∀y∀z((Pxy ∧ Pxz)→ y = z).

Note that Mod(α) is the collection of all structures A such that PA is the graphof a function from A into A. Let β be the sentence

∀x∀y∀z((Pxz ∧ Pyz)→ x = y).

Note that Mod(α ∧ β) is the collection of all structures A such that PA is thegraph of an injection (that is, 1-1 function) from A into A. Let γ be the sentence

∀x∃yPyx.

Note that Mod(α ∧ γ) is the collection of all structures A such that PA is thegraph of a surjection from A onto A. Finally, note that Mod(α ∧ β ∧ γ) is thecollection of all structures A such that PA is the graph of a permutation of A,that is, a bijection from A onto A.

We next considered definability within the fixed structure N = 〈N,+, ·〉where N = {0, 1, 2, . . .} and + and · are the usual arithmetic operations on N.We considered the definability of simple sets and relations on N per exercise2.2.11.

(a) ∀y(x+ y = y)[N] = {0}.

(b) ∀y(x · y = y)[N] = {1}.

Page 11: 1 Lecture 11.09 - cis.upenn.edu

LGIC 310/MATH 570/PHIL 006 Fall, 2011 Scott Weinstein 11

(c) ∃z(∀w(z · w = w) ∧ x+ z = y)[N] = {〈m,n〉 | n = m+ 1}.

(d) ∃z(∀w(z + w 6= w) ∧ x+ z = y)[N] = {〈m,n〉 | m < n}.

We next considered the structures N = 〈N,<〉 and Z = 〈Z,<〉 where Z ={. . . − 1, 0, 1, . . .}. We noted that ∀y¬(y < x)[N] = {0} and asked whether {0}is definable in Z. The general sentiment was negative, but we agreed that we’dneed a new idea to settle the question. To this end, we introduced the notionof an isomorphism of one structure onto another and of an automorphism, thatis, an isomorphism of a structure onto itself. We say that f is an isomorphismof A onto B if and only if f is a bijection of A onto B and for all a, b ∈ A

〈a, b〉 ∈ PA ⇐⇒ 〈f(a), f(b)〉 ∈ PB .

An automorphism of A is an isomorphism of A onto A. We write Aut(A) for theset of automorphisms of A. We stated the following theorem, which says thatfirst-order logic satisfies a natural desideratum for a language to be logical – itdoes not distinguish between structurally identical models.

Theorem 7 (Isomorphism Theorem) Suppose f is an isomorphism of Aonto B. Then for every formula α(x1, . . . , xn), with at most the variables indi-cated free, and for all a1, . . . , an ∈ A,

A |= α[(x1|a1), . . . , (xn|an)] ⇐⇒ B |= α[(x1|f(a1)), . . . , (xn|f(an))].

As a corollary to the Isomorphism Theorem, we have the

Corollary 3 (Automorphism Theorem) If f is an automorphism of A andα(x) is a formula with at most x free, then for all a ∈ A,

a ∈ α[A] ⇐⇒ f(a) ∈ α[A].

We applied the automorphism theorem to show that the only sets definable inZ = 〈Z,<〉 are Z and ∅. This follows from the observation that for every p ∈ Zthe function fp ∈ Aut(Z), where fp(q) = p+ q, for all q ∈ Z.

We reflected on this last resulted and introduced the notion of an orbit. Leta ∈ A;

Orb(a,A) = {f(a) | f ∈ Aut(A)}.As a corollary to the Automorphism Theorem, we noted that for every structureA, a ∈ A and X ⊆ A, if X is definable on A, then Orb(a,A) ⊆ X or Orb(a,A)∩X = ∅.

Exercise 4 Let A be a structure and for all a, b ∈ A let a ≈ b if and only ifb ∈ Orb(a,A). Show that a ≈ b is an equivalence relation, that is, a reflexive,symmetric, and transitive relation.

We asked whether the usual order on N is definable over 〈N, ·〉. We observedthat the answer is no, since for every permutation f of the set of prime numbersP , there is an automorphism g of 〈N, ·〉 such that gdP = f .

Exercise 5 Show that NN ∼ N2.

Page 12: 1 Lecture 11.09 - cis.upenn.edu

LGIC 310/MATH 570/PHIL 006 Fall, 2011 Scott Weinstein 12

8 Lecture 11.10.04

A structure A is rigid if and only if card(Aut(A)) = 1. If A is rigid, then theAutomorphism Theorem cannot be deployed directly to analyze the collectionof sets definable over A. We observed that N = 〈N, 0, S〉 (the natural numbersequipped with zero and the successor function) is a rigid structure. We notedthat every finite and co-finite subset of N is definable. We explore the matterfurther in an exam problem.

With Exercise 2.2.16 we meet another measure of expressive power that isspecially suited to measure expressiveness in the context of finite structures.Given a first-order sentence α, we define the spectrum of α as follows:

Spec(α) = {n ∈ N | ∃A(card(A) = n and A |= α}.

We are asked to exhibit a sentence α whose spectrum is the set of positiveeven numbers. Here is such a sentence:

∀x¬Rxx ∧ ∀x∀y(Rxy → Ryx) ∧ ∀x∃y∀z(Rxz ↔ z = y).

The sentence is true in a structure just in case that structure is a loop-freeundirected graph which is 1-regular, that is, all vertices have degree 1. It is easyto see that such a graph must have an even number of elements, and that forevery even number n, there is such a graph of size n.

We proceeded to give an example of a sentence ϕ whose spectrum is the setof perfect squares. The sentence used one ternary relation symbol R and oneunary relation symbol F . A structure A satisfies ϕ if and only if RA is the graphof a bijection of FA × FA onto |A|. We may choose ϕ to be the conjunction ofthe following sentences.

• (∀x)(∀y)(∃z)(∀w)((Fx ∧ Fy)→(Rxyw ↔ w = z))

• (∀x)(∀y)(∀v)(∀w)(∀z)((Rxyz ∧Rvwz)→(Fx ∧ Fy ∧ x = v ∧ y = w))

• (∀z)(∃x)(∃y)Rxyz

It is unusual that Spec(¬ϕ) = N−Spec(ϕ). An exam problem illustrates justhow badly this identity fails. We briefly discussed the Spectrum Problem: Isthe collection of first-order spectra closed under complementation? We remarkedthat this problem is equivalent to the closure of NEXP under complementation,a deep question in the theory of computational complexity.

We showed that for every finite directed graph A, there is a sentence ϕAsuch that for all directed graphs B,

B |= ϕA ⇐⇒ A ∼= B.

Definition 1 The first-order theory of A (Th(A)) is equal to {ϕ | A |= ϕ}. Ais elementarily equivalent to B (A ≡ B) if and only if Th(A) = Th(B).

Page 13: 1 Lecture 11.09 - cis.upenn.edu

LGIC 310/MATH 570/PHIL 006 Fall, 2011 Scott Weinstein 13

We began to explore the question whether there is an infinite structure Asuch that for all B, if B ≡ A, then B ∼= A. In particular, we started toaxiomatize Th(〈N, 0, S〉) and investigate structures not isomorphic to 〈N, 0, S〉which satisfy our axioms.

Page 14: 1 Lecture 11.09 - cis.upenn.edu

LGIC 310/MATH 570/PHIL 006 Fall, 2011 Scott Weinstein 14

9 Lecture 11.10.06

We continued our study of N = 〈N, 0, S〉. Much of the material we covered maybe found in Enderton, Section 3.1. Last time we introduced the following set ofsentences Γ, all true in the structure N, as a potential axiomatization of Th(N).

1. (∀x)Sx 6= 0

2. (∀x)(∀y)(Sx = Sy → x = y)

3. (∀x)(x 6= 0→ (∃y)Sy = x)

4. for each n, the sentence (∀x)Snx 6= x

We considered how well these sentences describe N.

Definition 2 A satisfiable set of sentences Σ is categorical if and only if forall A,B ∈ Mod(Σ), A ∼= B. Let κ be an infinite cardinal (see the notes on settheory at the end of this memoir for explanation). A satisfiable set of sentencesΣ is κ-categorical if and only if for all A,B ∈ Mod(Σ),if card(A) = card(B) = κ,then A ∼= B.

We observed that the Peano induction axiom, a sentence of monadic second-order logic, that is, a sentence involving quantification over subsets of the uni-verse of discourse as well as elements of the universe of discourse, when conjoinedwith sentences 1-3 above, provides a categorical description of N.

Induction Axiom: (∀P )((P0 ∧ (∀x)(Px→ PSx))→ (∀x)Px)

We discussed a first-order formulation of the induction axiom as an axiomschema yielding infinitely many induction axioms, one for each substitutioninstance of a first-order formula. We considered the possibility that the addi-tion of these axioms to Γ might provide a better description of N than Γ alone,perhaps even a categorical description.

We analyzed the models of Γ up to isomorphism. For each cardinal numberκ ≥ 0 there is a model Aκ |= Γ where Aκ consists of a copy of N together with κmany copies of 〈Z, S〉 (the integers equipped with the usual successor function).It follows at once that Γ is κ-categorical for all κ > ℵ0.

Theorem 8 ( Los-Vaught Test) If Σ is κ-categorical for some infinite cardi-nal κ and Σ has no finite models, then Cn(Σ) is complete.

It follows at once that Cn(Γ) = Th(N).Addendum: notes on set theory

Let X be a set and R be a binary relation on X, that is, R ⊆ X ×X. R isa well-ordering of X, if and only if, R is transitive and asymmetric, and everynonempty subset of X has an R-least element.

Ordinal numbers provide representatives for well-orderings. Suppose X is aset of sets. We say X is a transitive set, if and only if, for every y ∈ X, y ⊆ X. A

Page 15: 1 Lecture 11.09 - cis.upenn.edu

LGIC 310/MATH 570/PHIL 006 Fall, 2011 Scott Weinstein 15

set of sets X is an (von Neumann) ordinal number, if and only if, X is transitiveand X is well-ordered by ∈ (restricted to X). The (proper class of) ordinals isitself, in the obvious sense, well-ordered by ∈ . Every ordinal is equal to its setof predecessors. The successor of an ordinal α is α∪{α}; the supremum of a setof ordinals is its union. For every well-ordering 〈X,R〉 there is a unique ordinalnumber α such that 〈X,R〉 is isomorphic to 〈α,∈〉.

Some ordinals: 0, 1, 2, . . . , ω, ω + 1, . . . , ω + ω, . . . , ω × ω, . . .Zermelo’s Well-Ordering Principle (a version of the Axiom of Choice): For

every set X, there is an ordinal α such that X ∼ α.We call the least ordinal number α such that X ∼ α the cardinality of X.

An ordinal number α is a cardinal number, if and only if, the cardinality of αis α.

For any set X, the power set of X (written P(X)) is the set of all subsetsof X and X2 = {f | f : X −→ {0, 1}}. Observe that X2 ∼ P(X). If κ is acardinal number, we write 2κ for the cardinality of κ2. By Cantor’s DiagonalTheorem, for every cardinal number κ, κ < 2κ. The infinite cardinals form awell-ordered class. For each ordinal α, we denote the αth infinite cardinal byℵα. Thus, ℵ0 = ω = {0, 1, 2, . . .} is the smallest infinite cardinal. We say a setis countable, if and only if, its cardinality is less than or equal to ℵ0. Note thatℵ1, the first uncountable cardinal, is the set of countable ordinals. Thus, we canrestate Cantor’s Continuum Hypothesis (CH) as 2ℵ0 = ℵ1.

Page 16: 1 Lecture 11.09 - cis.upenn.edu

LGIC 310/MATH 570/PHIL 006 Fall, 2011 Scott Weinstein 16

10 Lecture 11.10.13

We proved Theorem 8. The proof relied on

Theorem 9 (Lowenheim-Skolem Theorem) If a countable set of first-ordersentences has an infinite model, then for every infinite cardinal κ, it has a modelof cardinality κ.

Proof (of Theorem 8): Suppose Γ is a countable set of first-order sen-tences which has no finite models and κ is an infinite cardinal such that Γ isκ-categorical. Suppose, for reductio that Γ is not complete. Then there is asentence ϕ such that Γ 6|= ϕ and Γ 6|= ¬ϕ. Since Γ has no finite models, itfollows at once, from Theorem , that there are models A and B of Γ such thatA |= ϕ and B |= ¬ϕ and card(A) = card(B) = κ. Hence, A ∼= B.

In order to prove Theorem 9, we divided the result into its upward anddownward aspects.

Theorem 10 (Upward Lowenheim-Skolem Theorem) If a set of first-ordersentences has an infinite model, then for every infinite cardinal κ, it has a modelof cardinality ≥ κ.

Theorem 10 is a corollary of the following fundamental result about first-orderlogic.

Theorem 11 (Compactness Theorem) If a set of first-order sentences isfinitely satisfiable, then it is satisfiable.

Proof (of Theorem 10): Suppose Γ is a set of first-order sentence with aninfinite model and κ is an infinite cardinal. Let {cξ | ξ < κ} be a set of distinctconstant symbols disjoint from the language of Γ. Let ∆ = {cξ 6= cζ | ξ < ζ <κ}. Since Γ has an infinite model, Γ ∪∆ is finitely satisfiable. The result nowfollows immediately from Theorem 11.

In order to state the downward aspect we require a definition.

Definition 3 A is an elementary substructure of B (equivalently, B is an ele-mentary extension of A, written A � B), if and only if, A is a substructure ofB and for every first order formula ϕ(x1, . . . , xn) and every a1, . . . , an ∈ A,

A |= ϕ[a1, . . . , an] ⇐⇒ B |= ϕ[a1, . . . , an].

Theorem 12 (Downward Lowenheim-Skolem Theorem) Suppose B is in-finite. Moreover, suppose the signature of B is countable. If X is contained inthe universe of B, then there is a structure A such that X ⊆ A, A � B andcard(A) = max(ℵ0, card(X)).

The following useful criterion for one structure to be an elementary substructureof another may be established by a straightforward induction on formulas.

Theorem 13 (Tarski-Vaught Criterion) Suppose A is a substructure of B.Then, A � B, if and only if, for every formula ϕ and every assignment s in A,if B |= ∃xϕ[s], then for some a ∈ A B |= ϕ[s(x|a)].

Page 17: 1 Lecture 11.09 - cis.upenn.edu

LGIC 310/MATH 570/PHIL 006 Fall, 2011 Scott Weinstein 17

Proof (of Theorem 12): Now, suppose that B is an infinite structure witha countable signature. For each formula in the language of B of the formϕ(y, x1, . . . , xn) let fϕ : Bn −→ B satisfy the following condition:

∀a1, . . . , an ∈ B(B |= ∃yϕ[a1, . . . , an]→ B |= ϕ[fϕ(a1, . . . , an), a1, . . . , an]).

The existence of such an fϕ is guaranteed by the axiom of choice. The set of allthe fϕ for ϕ a formula in the language of B is called a set of Skolem functionsfor B. Note that this set is countable, since the signature of B is countable. ForX ⊆ B let H(X) be the closure of X under a set of Skolem functions for Band let H(X) be the substructure of B with universe H(X). H(X) is called theSkolem hull of X in B. Now, for every formula ϕ(y, x1, . . . , xn) in the languageof B

∀a1, . . . , an ∈ H(X)(B |= ∃yϕ[a1, . . . , an]→ ∃b ∈ H(X)(B |= ϕ[b, a1, . . . , an])).

It follows at once, by the Tarski-Vaught Criterion, that H(X) � B.

Page 18: 1 Lecture 11.09 - cis.upenn.edu

LGIC 310/MATH 570/PHIL 006 Fall, 2011 Scott Weinstein 18

11 Lecture 11.10.18

We discussed the October 17 draft of the Bring Back Examination and arrivedat a definitive version.

We discussed some typical applications of the Compactness Theorem to es-tablish limits on the expressive power of first-order logic.

Proposition 3 There is no set of first-order sentences Σ such that for everyA, A |= Σ if and only if A is a connected simple graph.

Proof: Suppose, for reductio, that Σ is such a set of sentences. Introduceconstant symbols s and t, and for each k ≥ 1, let δk be the following sentence.

s 6= t ∧ ¬Est ∧ ¬(∃x1) . . . (∃xk)(Esx1 ∧ Ex1x2 ∧ . . . ∧ Exk−1xk ∧ Exkt)

Let ∆ = {δk | k ≥ 1}. Note that if a simple source-target graph 〈G, sG, tG〉 |= ∆,then G is not connected. Note also that Σ ∪∆ is finitely satisfiable. Apply theCompactness Theorem to derive a contraction.

Proposition 4 There is no set of first-order sentences Σ such that for everyA, A |= Σ if and only if A is a finite simple graph.

Proof: Suppose, for reductio, that Σ is such a set of sentences. For eachk ≥ 2, let λk be the following sentence.

(∃x1) . . . (∃xk)∧

1≤i<j≤k

xi 6= xj

Let Λ = {λk | k ≥ 1}. Note that if a simple graph G |= Λ, then G is infinite.Note also that Σ∪Λ is finitely satisfiable. Apply the Compactness Theorem toderive a contraction.

In potential contrast to Proposition 3 we asked whether there is a first-ordersentence ϕ such that for every finite simple graph G, G |= ϕ if and only if Gis connected. As Proposition 4 demonstrates, the Compactness Theorem doesnot hold in the finite context: it is not the case that if every finite subset of aset of first-order sentences is satisfied by a finite structure, then the entire set ofsentences is satisfied by a finite structure. Therefore, the method of Proposition3 does not resolve this question.

Page 19: 1 Lecture 11.09 - cis.upenn.edu

LGIC 310/MATH 570/PHIL 006 Fall, 2011 Scott Weinstein 19

12 Lecture 11.10.20

Proposition 5 If C is an isomorphism-closed class of finite graphs, then thereis a set of first-order sentences Σ such that for every finite graph G, G ∈ C ifand only if G |= Σ.

Proof: We showed earlier that for every finite graph G there is a first-ordersentence ϕG such that for all H, H |= ϕG if and only if H ∼= G. We may takeΣ to be {¬ϕG | G 6∈ C}.

Proposition 6 There is no first-order sentence ϕ such that for all simple finitegraphs G, G |= ϕ if and only if G is connected.

Proof: Let Γ be the following set of first-order sentences.

• (∀x)¬Exx

• (∀x)(∀y)(Exy → Eyx)

• (∀x)(∃y)(∃z)(Exy ∧ Exz ∧ y 6= z ∧ ∀w(Exw → w = y ∨ w = z))

• γn : ¬(∃x1) . . . (∃xn)(∧

1≤i<j≤n xi 6= xj∧Ex1x2∧ . . .∧Exn−1xn∧Exnx1),for n ≥ 3

Note that Γ has no finite models and is κ-categorical for every uncountablecardinal κ. Hence, by the Los-Vaught Test, Cn(Γ) is complete. Now suppose ϕis a first-order sentence and Γ |= ϕ. Then, for some finite ∆ ⊆ Γ, ∆ |= ϕ. Itfollows at once that there are graphs G and H such that G is connected, H isnot connected, and both G and H satisfy ϕ.

Page 20: 1 Lecture 11.09 - cis.upenn.edu

LGIC 310/MATH 570/PHIL 006 Fall, 2011 Scott Weinstein 20

13 Lecture 11.10.27

We presented solutions to the first three Bring Back Examination problems.

1. Prove the Cantor-Schroeder-Bernstein Theorem.

Solution: Let X and Y be sets and recall that X ∼ Y if and only if thereis a bijection f from X onto Y . We write X � Y if and only if there is aZ ⊆ Y such that X ∼ Z. Prove that if X � Y and Y � X, then X ∼ Y.Suppose that X � Y and Y � X, and let f : X 7→ Y and g : Y 7→ X withf and g injective. We define sequences of sets Xi, Yi, i ∈ N by induction,with Xi ⊆ X and Yi ⊆ Y . Let Y0 = Y − f [X] and for all i let Xi = g[Yi]and Yi+1 = f [Xi]. Let Xω =

⋃i∈N Xi and Yω =

⋃i∈N Yi. Now define

h : X 7→ Y as follows.

h(a) ={f(a) if a ∈ X −Xω

g−1(a) if a ∈ Xω

We show that h is a bijection. First note that by definition

h[Xω] = Yω.

To conclude the argument, it suffice to show that

f [X −Xω] = Y − Yω.

In order to do so, we need to show that

(a) if a ∈ X −Xω, then f(a) ∈ Y − Yω; and

(b) if b ∈ Y − Yω, then there is an a ∈ X −Xω with f(a) = b.

Ad (a): Suppose f(a) ∈ Yω. Since f(a) 6∈ Y0, it follows that f(a) ∈ Yi+1

for some i. But then f(a) = f(a′) for some a′ ∈ Xi. Since f is injective,this implies that a = a′. Ad (b): Suppose b ∈ Y − Yω. Since b 6∈ Y0 thereis an a ∈ X with f(a) = b. If a ∈ Xω, then f(a) ∈ Yω.

2. Let N = 〈N, 0, S〉. Recall that a set X ⊆ N is co-finite if and only if N−Xis finite. Is there a first-order formula ϕ(x) such that ϕ[N] is neither finitenor co-finite?

Solution: We show that for every formula ϕ(x), ϕ[N] is finite or ϕ[N] isco-finite. For reduction, suppose to the contrary that for some ϕ(x) bothϕ[N] and ¬ϕ[N] are infinite. Let c and d be new constant symbols andlet Γ = Th(N) ∪ {c 6= n | n ∈ N} ∪ {d 6= n | n ∈ N} ∪ {ϕ(c),¬ϕ(d)}. Itfollows from our hypothesis that Γ is finitely satisfiable and, hence, by thethe Compactness Theorem, that Γ is satisfiable. Suppose that A |= Γ andlet A′ be the reduct of A to the language without c, d. It follows at oncethat both cA and dA are in the non-standard part of A′. Hence, thereis an automorphism h of A′ such that h(cA) = dA. But this contradictsA′ |= ϕ[cA] and A′ |= ¬ϕ[dA].

Page 21: 1 Lecture 11.09 - cis.upenn.edu

LGIC 310/MATH 570/PHIL 006 Fall, 2011 Scott Weinstein 21

3. Show that there is a rigid directed graph A such that for every a ∈ A, {a}is not definable.

Solution: For each X ⊆ N we define a graph DX which represents X inthe sense that for all Y , if X 6= Y , then DX 6∼= DY . The universe of DX isN×{X}∪X×{{X}}. The edge relation ofDX = {〈〈i, {X}〉, 〈i+ 1, {X}〉〉 |i ∈ N} ∪ {〈〈i, {X}〉, 〈i, {{X}}〉〉 | i ∈ X}. That is, DX is an ordinarysuccessor chain of length N with a “bristle” at each i ∈ X. For ζ ⊆ P(N),Dζ =

⋃X∈ζ DX and 2Dζ is the disjoint union of Dζ with itself. Observe

that for every ζ ⊆ P(N), Dζ is rigid, whereas there is an automorphism of2Dζ which has no fixed points. The latter implies that for every formulaϕ,

2Dζ |= (∃x)(∃y)(x 6= y ∧ ϕ(x) ∧ ϕ(y)).

Let ζ be the collection of finite subsets of N. We will establish, as corollaryto a fundamental locality property of first-order logic, that 2Dζ ≡ Dζ ,thereby concluding the solution.

Page 22: 1 Lecture 11.09 - cis.upenn.edu

LGIC 310/MATH 570/PHIL 006 Fall, 2011 Scott Weinstein 22

14 Lecture 11.11.01

4. Let A be a finite structure that interprets an infinite collection of relationsymbols Rn where Rn is n-ary. Show that for every structure B,

B |= Th(A) ⇐⇒ A ∼= B.

Solution: Suppose, toward a contradiction, that A ≡ B, but A 6∼= B. Letλn be the following first-order sentence,

∃x1 . . . ∃xn(x1 6= x2 . . . xn−1 6= xn)

and let χn be the conjunction of λn and ¬λn+1. Notice that a structureC |= ηn if and only if card(C) = n. Suppose A = {a1, . . . , an}. It followsat once that card(B) = n. Let a enumerate A and for each bijection hfrom A onto B, let bh be the image of the enumeration a via h. Since, byhypothesis, A is not isomorphic to B, for each bijection h there is a literalαh in the free variables x1, . . . , xn such that A |= αh[a] and B 6|= αh[b]. LetX be the (finite) collection of bijections of A onto B. Then the followingsentence is true in A but false in B, contradicting the hypothesis thatA ≡ B.

∃x1 . . . ∃xn(x1 6= x2 . . . xn−1 6= xn ∧∧h∈X

αh)

5. Let L be the first-order order language with only one ternary relationsymbol F and two unary predicate symbols P and Q and identity. Givean example of a sentence γ of L whose spectrum is the set of powers of 2.

Solution: We construct a sentence γ such that a structure A satisfies γif and only if card(A) = 2card(PA) and PA is non-empty. The spectrumof γ consists of the powers of two which are greater than 1. If we wish toinclude 1, we disjoin γ with (∀x)(∀y)x = y. γ is the conjunction of thefollowing sentences.

• (∃x)(∃y)(x 6= y ∧Qx ∧Qy ∧ (∀z)(Qz ↔ (z = x ∨ z = y)))

• (∀x)(∀y)(∀z)(Fxyz → (Py ∧Qz))• (∀x)(∀y)(Py → (∃z)(∀w)(Fxyw ↔ w = z))

• (∀x)(∀y)(x 6= y → (∃z)(∃w)(Fxzw ∧ ¬Fyzw)

• (∀x)(∀y)(∀z)((Py∧Qz)→ (∃w)(Fwyz∧(∀u)(∀v)(u 6= y → (Fxuv ↔Fyuv))))

6. Show that for every first-order sentence α in the language of directedgraphs Spec(α) is co-finite or Spec(¬α) is co-finite.

Solution: Let E be a binary relation symbol and suppose E is the onlynon-logical symbol occurring in α. Let λn be the following first-order sen-tence.

∃x1 . . . ∃xn(x1 6= x2 . . . xn−1 6= xn)

Page 23: 1 Lecture 11.09 - cis.upenn.edu

LGIC 310/MATH 570/PHIL 006 Fall, 2011 Scott Weinstein 23

Notice that a structure A |= λn if and only if card(|A|) ≥ n. Let Γ ={λn | n ∈ N} ∪ {∀x∀y¬Exy}. Recall the Los-Vaught Test: if a countableset of first-order sentences Σ is κ-categorical for some infinite cardinal κand Σ has no finite models, then Cn(Σ) is complete. Note that the setof sentences Γ defined above is κ-categorical for all infinite cardinals κand has no finite models. Therefore, Cn(Γ) is complete. Hence eitherΓ |= α or Γ |= ¬α. Suppose Γ |= α (the other case is handled similarly).Then, by the Compactness Theorem for first-order logic, there is an msuch that {λn | n ≤ m} ∪ {∀x∀y¬Exy} |= α. But then, for every n ≥ m,m ∈ Spec(α).

We decided to migrate the remaining problems on the Bring Back Examinationto the (Bring Back) Final Examination.

We returned to our study of the rational numbers with their usual order andset about proving that

Theorem 14 (Cantor) The theory of dense linear order without endpoints isℵ0-categorical.

We introduce some notions which will be useful in the proof of this theorem. Afunction f is a partial isomorphism from A toB if and only if f is an isomorphismfrom a substructure of A onto a substructure of B.

Definition 4 A is partially isomorphic to B (A ∼=p B) if and only if there is anonempty set P of partial isomorphisms of A to B with the following properties:

Forth Property: for every a ∈ |A| and f ∈ P, there is a g ∈ P such thatf ⊆ g and a ∈ dom(g).

Back Property: for every b ∈ |B| and f ∈ P, there is a g ∈ P such thatf ⊆ g and b ∈ rng(g).

We write P : A ∼=p B, if P witnesses that A ∼=p B.

Theorem 14 is a corollary of the following two results.

Theorem 15 If A and B are dense strict linear orders without endpoints, thenA ∼=p B.

Proof: Let A and B be dense strict linear orders without endpoints, andlet P be the set of finite partial isomorphisms from A to B. It is easy to verifythat P witnesses A ∼=p B.

Theorem 16 If A and B are countable and A ∼=p B, then A ∼= B.

Page 24: 1 Lecture 11.09 - cis.upenn.edu

LGIC 310/MATH 570/PHIL 006 Fall, 2011 Scott Weinstein 24

15 Lecture 11.11.03

Proof of Theorem 16: Suppose that A and B are countable and that P :A ∼=p B. Let A = {a0, a1, . . .} and B = {b0, b1, . . .}. We construct a sequenceof partial isomorphisms f0, f1, . . . such that for all i ∈ ω

1. fi ∈ P

2. fi ⊆ fi+1

3. ai ∈ f2i and bi ∈ f2i+1.

The construction is by induction, alternately using the forth property and theback property at even and odd stages, respectively. Let f =

⋃i∈ω fi. It is easy

to verify that f is an isomorphism of A onto B.Thus far we have seen examples of countable first-order theories which are

κ-categorical for all infinite cardinals κ (the theory of the empty graph), ℵ0-categorical, but not categorical for any κ > ℵ0 (the theory of dense linear orderwithout endpoints), κ-categorical for all cardinals > ℵ0, but not ℵ0-categorical(successor arithmetic – all such theories have exactly ℵ0 countable models upto isomorphism). By the Morley Categoricity Theorem, there is only one otherpossibility, namely theories which are categorical for no infinite cardinal κ. Wediscussed an example of such a theory, namely, TN = Th(〈N, S, 0, <,+, ·〉).

Proposition 7 TN has 2ℵ0 countable models up to isomorphism.

We introduce some notions which will be useful in the proof of Proposition 7.A (complete) type is a (complete) set of formulas with at most one free variablex. If A is a structure and a ∈ A, τA(a) = {ϕ(x) | A |= ϕ[a]} (the type of a inA). We say the type Σ(x) is realized in A if and only if Σ ⊆ τA(a) for somea ∈ A. τ [A] is the set of complete types realized by elements of A, that is,τ [A] = {τA(a) | a ∈ A}. Let T be a theory and Σ a type. Σ is consistent withT if and only if for every finite {δ1, . . . , δk} ⊆ Σ, T ∪ {(∃x)(δ1(x)∧ . . .∧ δk(x))}is satisfiable. We write S(A) for the set of complete types which are consistentwith the theory of A.

Theorem 17 If T is a countable theory and Σ is a type consistent with T , thenthere is a countable structure A such that A |= T and A realizes Σ.

Proof: Invoke the Compactness and Downward Lowenheim-Skolem Theo-rems.

Proof of Proposition 7: By Theorem 17, it suffices to show that

card(S(〈N, S, 0, <,+, ·〉)) = 2ℵ0

. Let πn(x) be a formula which is true of a ∈ N if and only if the n-th primedivides a. For each Z ⊆ N, let ΣZ = {πn(x) | n ∈ Z} ∪ {¬πn(x) | n 6∈ Z}.Note that for every Z ⊆ N, ΣZ is consistent with TN. It is easy to see that ifZ 6= Z ′ and ΣZ ⊆ τ ∈ S(〈N, S, 0, <,+, ·〉) and ΣZ′ ⊆ τ ′ ∈ S(〈N, S, 0, <,+, ·〉),then τ 6= τ ′. It follows immediately that card(S(〈N, S, 0, <,+, ·〉)) = 2ℵ0 .

Page 25: 1 Lecture 11.09 - cis.upenn.edu

LGIC 310/MATH 570/PHIL 006 Fall, 2011 Scott Weinstein 25

16 Lecture 11.11.08

We began to prove theAbstract Completeness Theorem: The set of valid sentences of an ef-

fectively presented first order language is semi-decidable.Proof: The proof of the theorem will proceed via a number of lemmas. First

observe that a sentence is valid, if and only if, its negation is unsatisfiable. So itsuffices to show that the set of unsatisfiable sentences of an effectively presentedfirst order language is semi-decidable. We begin with the

Skolem Normal Form for Satisfiability Lemma: We can effectivelyconstruct for every first order sentence ϕ a universal sentence θ (in an expandedlanguage) such that ϕ is satisfiable, if and only if, θ is satisfiable. (θ is calledthe Skolem normal form for satisfiability of ϕ.)

The lemma is proven by introducing symbols for Skolem functions.Let θ = ∀x1 . . . ∀xnχ, be a universal sentence with quantifier free matrix χ.

Let H be the set of closed terms in the language of θ (we suppose without lossof generality that H is nonempty). An H-instance of χ is a sentence of the formχ(x1|t1, . . . , xn|tn) for some t1, . . . , tn ∈ H. The H-expansion of θ is the set ofall H-instances of θ.

Expansion Lemma: Let θ be an identity free universal sentence. θ issatisfiable, if and only if, the H-expansion of θ is (truth functionally) satisfiable.

The lemma is proven by constructing a model whose universe is the set ofclosed terms.

Next time we will complete the proof of the abstract completeness theoremby treating formulas with identity.

Page 26: 1 Lecture 11.09 - cis.upenn.edu

LGIC 310/MATH 570/PHIL 006 Fall, 2011 Scott Weinstein 26

17 Lecture 11.11.10

We had a free-wheeling discussion.

18 Lecture 11.11.15

Quotient Lemma: Let E be a distinguished binary relation symbol and letθ be a sentence containing E. There is a universal sentence γ (which dependson the language of θ) such that θ has a model A in which EA is the identityrelation on A, if and only if, θ ∧ γ is satisfiable.

Construct γ to say that E is an equivalence relation which is a congruencewith respect to the relation and function symbols appearing in θ. Then take Ato be the quotient by EB of a model B for θ∧γ. Note that the map which sendsb ∈ B to its EB-equivalence class is a surjective homomorphism from B to A,and that EA is the identity relation. The result now follows immediately fromthe Homomorphism Theorem (see Enderton, Section 2.2).

We are now in a position to describe a semi-decision procedure for unsat-isfiability. Let ϕ be a first order sentence. Effectively construct the universalsentence θ which is the Skolem normal form for satisifiability of ϕ. Next, replaceall occurrences of = in θ with a new distinguished binary relation symbol Eand construct γ to satisfy the conditions of the Quotient Lemma. Let ζ be aneffectively constructed universal sentence equivalent to θ ∧ γ. Observe that ϕ issatisfiable, if and only if, ζ is satisfiable. By the Expansion Lemma, ζ is satisfi-able, if and only if, the H-expansion of ζ is truth-functionally satisfiable. Now,construct an effective enumeration of the H-expansion of ζ and test the con-junction of ever larger initial segments of this enumeration for truth functionalsatisfiablity. It follows at once from the compactness theorem for sentential logicthat this procedure terminates with a “no,” if and only if, the H-expansion ofζ is truth functionally unsatisfiable.

Page 27: 1 Lecture 11.09 - cis.upenn.edu

LGIC 310/MATH 570/PHIL 006 Fall, 2011 Scott Weinstein 27

19 Lecture 11.11.17

We discussed the first Godel Incompleteness Theorem. Let N = 〈N, 0, S,<,+, ·〉be the standard model of arithmetic.

Theorem 18 If T ⊆ Th(N) is semi-decidable, then Cn(T ) 6= Th(N).

As a corollary to Theorem 18, we concluded that second-order logic failsto enjoy a complete proof procedure. Let V2 be the set of valid sentences ofsecond-order logic.

Corollary 4 V2 is not semi-decidable.

Proof: We exhibited a second-order sentence Θ such that for all structuresA, A |= Θ if and only if A ∼= N. The corollary follows immediately from Theorem18. The sentence Θ formulates the Peano postulates, namely, it asserts the basicproperties of 0 and S, the “recursive definitions” of addition, multiplication, andthe usual linear order, and the induction axiom.

Our next topic is the Lindstrom Characterization Theorem.

Theorem 19 If L is a model-theoretic logic extending first-order logic, and Lhas the compactness property and the downward Lowenheim-Skolem property,then L coincides with first-order logic.

In order to get in the spirit of the enterprise we decided to consider exam-ples of model-theoretic logics extending first-order logic. We noticed that theproof of Corollary 4 also established that second-order logic fails to enjoy thecompactness property. We had earlier remarked that the structure 〈R, <〉 canbe categorically described by a second-order sentence, from which it follows atonce that second-order logic fails to possess the downward Lowenheim-Skolemproperty.

We began to discuss the extension of first-order logic by addition of gener-alized quantifiers. We considered the quantifier I, where A |= (Ix)ϕ(x) if andonly if card({a ∈ A | A |= ϕ[a]}) ≥ ℵ0. We showed that N can be categoricallydescribed by a sentence in the extension of first-order logic by the addition of I.It follows at once that this logic lacks the compactness property.

Page 28: 1 Lecture 11.09 - cis.upenn.edu

LGIC 310/MATH 570/PHIL 006 Bring Back Final ExaminationFall, 2011DRAFT

1. F is an elementary embedding of A into B if and only if F is an injectionfrom A into B and for every first-order formula ϕ(x1, . . . , xn) and everya1, . . . , an ∈ A,

A |= ϕ[a1, . . . , an] ⇐⇒ B |= ϕ[F (a1), . . . , F (an)].

Show that there are structures A and B such that A ≡ B but there isno elementary embedding of A into B and no elementary embedding of Binto A.

2. Let Q = 〈Q, <〉 be the structure consisting of the rational numbers withtheir usual ordering. Let ϕ be the conjunction of the following sentences.

• (∀x)¬Exx• (∀x)(∀y)(x 6= y → (Exy ∨ Eyx))

• (∀x)(∀y)(∀z)((Exy ∧ Eyz)→ Exz)

Show that for every universal sentence α, Q |= α if and only if ϕ |= α.

3. Let L be the language with no constant or function symbols, and no rela-tion symbols besides identity. Show that every sentence of L is equivalentto an existential-universal sentence.

4. Show that for every cardinal κ > ℵ0 there are structures A and B suchthat card(A) = card(B) = κ, A ≡ B ≡ 〈Q, <〉, and A 6∼= B.