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

6 Lecture 10.10.05

These memoirs begin with material presented during lecture 5, but omitted from the memoir of that lecture. We observed that the notion of a strict linear order can be characterized by a first-order sentence, the conjunction of the following conditions: • (∀x)¬x < x (irreflexivity) • (∀x)(∀y)(∀z)(x < y → (y < z → x < z)) (transitivity) • (∀x)(∀y)(x 6= y → (x < y ∨ y < x)) (comparability) We noted that for every natural number n there is a unique, up to isomor- phism, linear order on the set [n] = {1, . . . , n}. On the other hand,

Exercise 1 Show that there are 2ℵ0 linear orders, up to isomorphism, on the set {1, 2, 3,...}.

1 We gave several examples of infinite linear orders:

1. hN,

2 We examined first-order conditions that distinguish among these orderings. 1. (∃x)(∀y)¬y < x (there is a least element) 2. (∃x)(∀y)¬x < y (there is a greatest element) 3. (∀x)((∃w)x < w → (∃y)(x < y ∧ (∀z)¬(x < z ∧ z < y))) (discrete) 4. (∀x)(∀y)(x < y → (∃z)(x < z ∧ z < y)) (dense) 5. (∃x)((∃y)y < x ∧ (∀z)(z < x → (∃w)(z < w ∧ w < x))) (there is a limit point)

Observe that orders (1)1 and 2 are discrete and have no limit point, moreover, the first of these has a least element while the second does not. The orders (1)3, 4, and 5 all have at least one limit point, moreover, the first two are dense while the last is discrete. Exercise 2 Show that hQ,

Here begins the memoir of lecture 6. Thus far we have been exploring the expressive power of first-order logic by looking at classes of structures which are first-order definable. We say a of structures K is an elementary class if and only if there is a first-sentence ϕ such that K = Mod(ϕ) and we say K is and extended elementary class if and only if there is a set of first-order sentences Σ such that K = Mod(Σ). Another approach to the study of expressive power is via consideration of the relations which are first-definable on a fixed structure. If ϕ(x1, . . . , xn) is a formula with free variables among x1, . . . , xn, and A is a structure which interprets all the non-logical symbols occurring in ϕ, then ϕ[A] denotes the n-ary relation defined by ϕ on A, that is,

ϕ[A] = {< a1, . . . , an >| A |= ϕ[a1, . . . , an]}.

We presented solutions to problems 2.2.9 and 2.2.11 in Enderton, which deal with definable collections of structures and definability within a fixed structure respectively. Let A = h|A|,P Ai be a structure for a language with a binary relation P and with no further relation, function, or constant symbols other than identity. We will often use A, rather than |A|, to denote the universe of A when no confusion is 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 P A is the graph of f if and only if for all a, b ∈ A, ha, bi ∈ P A ⇐⇒ f(a) = b. Let α be the sentence

∀x∃yP xy ∧ ∀x∀y∀z((P xy ∧ P xz) → y = z).

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

∀x∀y∀z((P xz ∧ P yz) → x = y).

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

∀x∃yP yx.

Note that Mod(α ∧ γ) is the collection of all structures A such that P A is the graph of a surjection from A onto A. Finally, note that Mod(α ∧ β ∧ γ) is the collection of all structures A such that P A 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 = hN, +, ·i 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 exercise 2.2.11.

(a) ∀y(x + y = y)[N] = {0}. LGIC 310/MATH 570/PHIL 006 Fall, 2010 Scott Weinstein 11

(b) ∀y(x · y = y)[N] = {1}. (c) ∃z(∀w(z · w = w) ∧ x + z = y)[N] = {hm, ni | n = m + 1}. (d) ∃z(∀w(z + w 6= w) ∧ x + z = y)[N] = {hm, ni | m < n}. We next considered the structures N = hN,

ha, bi ∈ P A ⇐⇒ hf(a), f(b)i ∈ P B.

An automorphism of A is an isomorphism of A onto A. We write Aut(A) for the set of automorphisms of A. We stated the following theorem, which says that first-order logic satisfies a natural desideratum for a language to be logical – it does not distinguish between structurally identical models. Theorem 1 (Isomorphism Theorem) Suppose f is an isomorphism of A onto 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 1 (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 in Z = hZ,

Exercise 3 1. Let B = {f | f is a bijection from N onto N} and let C = {f | f : N 7→ {0, 1}}. Show that there is a bijection of B onto C.

2. With C as above show that there is a bijection from C onto Aut(hQ,

7 Lecture 10.10.07

We continued our study of the expressive power of first-order logic. Today we focused on finite structures. We recalled our earlier observation that for every finite directed graph A, there is a sentence ψ such that for all graphs directed graphs B, B |= ψ ⇐⇒ A =∼ B. Exercise 4 Let A be a finite structure that interprets an infinite collection of relation symbols Rn where Rn is n-ary. Show that for every structure B,

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

With Exercise 2.2.16 we meet another measure of expressive power that is specially 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 positive even 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-free undirected graph which is 1-regular, that is, all vertices have degree 1. It is easy to see that such a graph must have an even number of elements, and that for every even number n, there is such a graph of size n. We proceeded to give an example of a sentence ϕ whose spectrum is the set of perfect squares. The sentence used one ternary relation symbol R and one unary relation symbol F . A structure A satisfies ϕ if and only if RA is the graph of a bijection of F A × F A onto |A|. We may chose ϕ to be the conjunction of the following sentences. • (∀x)(∀y)(∃z)(∀w)((F x ∧ F y) → (Rxyw ↔ w = z))

• (∀x)(∀y)(∀v)(∀w)(∀z)((Rxyz ∧ Rvwz) → (F x ∧ F y ∧ x = v ∧ y = w)) • (∀z)(∃x)(∃y)Rxyz LGIC 310/MATH 570/PHIL 006 Fall, 2010 Scott Weinstein 13

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

We briefly discussed the Spectrum Problem: Is the collection of first- order spectra closed under complementation? We remarked that this problem is equivalent to the closure of NEXP under complementation, a deep question in the theory of computational complexity. Recall that a set X ⊆ N is cofinite if and only if N − X is finite. We began to show that for every first-order sentence α in the language of directed graphs Spec(α) is cofinite or Spec(¬α) is cofinite. This result is a corollary of the following two central theorems about first-order logic.

Theorem 2 () If a set of first-order sentences is finitely satisfiable, then it is satisfiable.

Theorem 3 (Downward L¨owenheim-Skolem Theorem) If a countable set of first-order sentences has an infinite model, it has a countable model.