Logic: Lecture 16, 11 October 2012 ---------------------------------- Quantifier elimination: T admits quantifier elimination if for every formula phi there is a quantifier free formula psi such that T |= phi <-> psi Aside: What does it mean to say T |= alpha for a formula alpha with free variables? For every intpretation (M,s) such that (M,s) |= T, (M,s) |= alpha. Of course, (M,s) |= T is independent of s, so effectively we have that for every M such that M |= T, for every s, (M,s) |= alpha. This is equivalent to implicit universal quantification of all free variables in alpha. Suffices to consider Ex (a_1 and ... and a_n), each a_i atomic or negation of atomic Proof: Convert Ex theta to Disjunctive Normal Form (DNF): - Each clause is a conjunction of literals (atomic formula or negation), formula is disjunction of clauses - DNF can be constructed from truth table. One clause per row that evaluate to tt Distribute Ex over or to get (Ex clause_1) or ... or (Ex clause_k) Eliminiate quantifiers "inside out" from innermost Ex, so each step works with formulas of the form above Assume x appears in each a_i: otherwise Ex (a and b) = a and Ex b Terms are of the form S^k(u) where u is either 0 or a variable. Atomic formulas are of the form S^i(u) = S^j(v). Thus, in Ex (a_1 and ... and a_n), each a_k is S^i(x) = S^j(u) or its negation. Can assume that u is not x --- otherwise reduce S^i(x) = S^i(x) to 0=0 (i.e. tt) and S^i(x) = S^j(x), i =/= j to 0 =/= 0 (i.e. ff). Case 1: Each a_i is of the form ~(S^j(x) = u). Can always find x that satisfies finitely many inequations, so reduce to 0=0. Case 2: At least one equality. Wlog, assume a_1 is S^m(x) = u. - Add (u =/= 0 and u =/= S(0) and .. u =/= S^{m-1}(0) so that any assignment for variable in u yields a valid assignment for x. - Transform every other atomic formula of the form S^j(x) = v to S^{j+m}(x) = S^m(v) and substitute u to get S^j(u) = S^m(v). Now we have an equivalent formula in which x no longer occurs. This yields an alternate proof that A_S is complete: Let phi be any sentence. By quantifier elimination, there is a quantifier free sentence psi such that A_S |- phi <-> psi. Atomic formulas in psi are of the form S^k(0) = S^l(0). Can effectively decide if psi is true or false, correponding to which phi is true or false, so A_S |= phi or A_S |= ~phi Definability: Subsets of Nat: Only finite/co-finite subsets of Nat are definable - Verify this formally for youselves Binary relations: Can define a set of pairs (x,y) only if it is covered by a finite set of lines (linear) or its complete is. Corollary: < is not definable. ======================================================================