Presentation is loading. Please wait.

Presentation is loading. Please wait.

Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter1 Remember: I. Construct a model where 1 and 4 are true, while 2 and 3 are false Let the u.d.

Similar presentations


Presentation on theme: "Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter1 Remember: I. Construct a model where 1 and 4 are true, while 2 and 3 are false Let the u.d."— Presentation transcript:

1

2 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter1 Remember: I. Construct a model where 1 and 4 are true, while 2 and 3 are false Let the u.d. be parking spaces at UF. Let P(x) be “x is occupied.” Let Q(x) be “x is free of charge.” 1.  x (Q(x)  P(x)) 2.  x (Q(x)  P(x)) 3.  x (Q(x)  P(x)) 4.  x (Q(x)  P(x))

3 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter2 II. Construct a model where 1 and 4 are true, while 2 and 3 are false 1.  x (Q(x)  P(x)) (true for place a below) 2.  x (Q(x)  P(x)) (false for places b below) 3.  x (Q(x)  P(x)) (false for place b below) 4.  x (Q(x)  P(x)) (true for place a below) One solution: a model with exactly two objects in it. One object has the property Q and the property P; the other object has the property Q but not the property P. In a diagram: a: Q P b: Q not-P a: Q P b: Q not-P

4 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter3 III. Construct a model where 1 and 3 and 4 are true, but 2 is false 1.  x (Q(x)  P(x)) 2.  x (Q(x)  P(x)) 3.  x (Q(x)  P(x)) 4.  x (Q(x)  P(x)) Here is such a model (using a diagram). It has just two objects in its u.d., called a and b: a: Q P b: not-Q P a: Q P b: not-Q P

5 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter4 Quantifier Equivalence Laws Expanding quantifiers: If u.d.=a,b,c,…  x P(x)  P(a)  P(b)  P(c)  …  x P(x)  P(a)  P(b)  P(c)  …Expanding quantifiers: If u.d.=a,b,c,…  x P(x)  P(a)  P(b)  P(c)  …  x P(x)  P(a)  P(b)  P(c)  … From those, we can “prove” the laws:  x P(x)   x  P(x)  x P(x)   x  P(x)From those, we can “prove” the laws:  x P(x)   x  P(x)  x P(x)   x  P(x) Topic #3 – Predicate Logic

6 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter5 Remember In propositional logic, we can strictly speaking only build formulas of finite size.In propositional logic, we can strictly speaking only build formulas of finite size. E.g., we can write P(a)  P(b) P(a)  P(b)  P(c) P(a)  P(b)  P(c)  P(d), etc.E.g., we can write P(a)  P(b) P(a)  P(b)  P(c) P(a)  P(b)  P(c)  P(d), etc. But this way, we could never say that all natural numbers have PBut this way, we could never say that all natural numbers have P

7 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter6 Formulas of infinite length? In predicate logic, you can say this easily:  xP(x)In predicate logic, you can say this easily:  xP(x) It’s sometimes useful to pretend that propositional logic allows infinitely long formulas, but in the “official” version this is not possible.It’s sometimes useful to pretend that propositional logic allows infinitely long formulas, but in the “official” version this is not possible.

8 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter7 More Equivalence Laws  x  y P(x,y)   y  x P(x,y)  x  y P(x,y)   y  x P(x,y)  x  y P(x,y)   y  x P(x,y)  x  y P(x,y)   y  x P(x,y)  x (P(x)  Q(x))  (  x P(x))  (  x Q(x))  x (P(x)  Q(x))  (  x P(x))  (  x Q(x))  x (P(x)  Q(x))  (  x P(x))  (  x Q(x))  x (P(x)  Q(x))  (  x P(x))  (  x Q(x)) Topic #3 – Predicate Logic

9 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter8 More Equivalence Laws  x  y P(x,y)   y  x P(x,y)  x  y P(x,y)   y  x P(x,y)  x  y P(x,y)   y  x P(x,y)  x  y P(x,y)   y  x P(x,y)  x (P(x)  Q(x))  (  x P(x))  (  x Q(x))  x (P(x)  Q(x))  (  x P(x))  (  x Q(x))  x (P(x)  Q(x))  (  x P(x))  (  x Q(x))  x (P(x)  Q(x))  (  x P(x))  (  x Q(x)) Let’s prove the last of these equivalences using the definition of the truth of a formula of the form  x φLet’s prove the last of these equivalences using the definition of the truth of a formula of the form  x φ Topic #3 – Predicate Logic

10 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter9 A Pred. Log. equivalence proven  x (P(x)  Q(x))  (  x P(x))  (  x Q(x)) Proof:   x (P(x)  Q(x)) is true. So, there is a constant a such that (P(x)  Q(x)) (x:=a) is true. So, for that a, the formula P is true. One possibility is that P(a) is true. In this case, P(x)(x:=a) is true. So,  x P(x)  x P(x))  (  x Q(x)) is true. The other possibility is that Q(a) is true. In this case, Q(x)(x:=a) is true. So,  x Q(x)  x P(x))  (  x Q(x)) is true.  x (P(x)  Q(x))  (  x P(x))  (  x Q(x)) Proof:  Suppose  x (P(x)  Q(x)) is true. So, there is a constant a such that (P(x)  Q(x)) (x:=a) is true. So, for that a, the formula P(a)  Q(a) is true. One possibility is that P(a) is true. In this case, P(x)(x:=a) is true. So,  x P(x) is true, so (  x P(x))  (  x Q(x)) is true. The other possibility is that Q(a) is true. In this case, Q(x)(x:=a) is true. So,  x Q(x) is true, so (  x P(x))  (  x Q(x)) is true. Topic #3 – Predicate Logic

11 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter10 A Pred. Log. equivalence proven  x (P(x)  Q(x))  (  x P(x))  (  x Q(x)) Proof:  (  x P(x))  (  x Q(x))is true. One possibility is that  x P(x) is true. This would mean that there is an a such that P(x) (x:=a) is true. So, for that constant a, Pis true.Therefore, P(a)  Q(a) would also be true. Hence, (P(x)  Q(x))(x:=a) would be true. Hence,  x (P(x)  Q(x)) would be true. The other possibility is that  x Q(x). From this,  x (P(x)  Q(x)) is proven in the same way QED  x (P(x)  Q(x))  (  x P(x))  (  x Q(x)) Proof:  Suppose (  x P(x))  (  x Q(x)) is true. One possibility is that  x P(x) is true. This would mean that there is an a such that P(x) (x:=a) is true. So, for that constant a, P(a) is true.Therefore, P(a)  Q(a) would also be true. Hence, (P(x)  Q(x))(x:=a) would be true. Hence,  x (P(x)  Q(x)) would be true. The other possibility is that  x Q(x). From this,  x (P(x)  Q(x)) is proven in the same way QED Topic #3 – Predicate Logic

12 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter11 More Equivalence Laws  x  y P(x,y)   y  x P(x,y)  x  y P(x,y)   y  x P(x,y)  x  y P(x,y)   y  x P(x,y)  x  y P(x,y)   y  x P(x,y)  x (P(x)  Q(x))  (  x P(x))  (  x Q(x))  x (P(x)  Q(x))  (  x P(x))  (  x Q(x))  x (P(x)  Q(x))  (  x P(x))  (  x Q(x))  x (P(x)  Q(x))  (  x P(x))  (  x Q(x)) How about this one?How about this one?  x (P(x)  Q(x))  (  x P(x))  (  x Q(x))?  x (P(x)  Q(x))  (  x P(x))  (  x Q(x))? Topic #3 – Predicate Logic

13 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter12 More Equivalence Laws How about this one?How about this one?  x (P(x)  Q(x))  (  x P(x))  (  x Q(x)) ?  x (P(x)  Q(x))  (  x P(x))  (  x Q(x)) ? This equivalence statement is false. Counterexample (i.e. model making this false):This equivalence statement is false. Counterexample (i.e. model making this false): P(x): x’s birthday is on 30 April Q(x): x’s birthday is on 20 DecemberP(x): x’s birthday is on 30 April Q(x): x’s birthday is on 20 December Topic #3 – Predicate Logic

14 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter13 Cases to think carefully about Let’s discuss some specific cases These might seem unusual, but it’s important not to loose your way when they occur These might seem unusual, but it’s important not to loose your way when they occur 1.Quantifiers that don’t bind any variables 2.Quantification in an empty u.d. 3.  x (Q(x)  P(x)) when  yQ(y)

15 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter14 1. Quantifiers that do not bind:  xP(b) Recall definition: Let  be a formula. Then  x  is true in D if every expression  (x:=a) is true in D, and false otherwise.Recall definition: Let  be a formula. Then  x  is true in D if every expression  (x:=a) is true in D, and false otherwise.  xP(b) is true in D if every expression of the form P(b)(x:=a) is true in D, and false otherwise.  xP(b) is true in D if every expression of the form P(b)(x:=a) is true in D, and false otherwise. What is the set of all the expression of the form P(b)(x:=a)?What is the set of all the expression of the form P(b)(x:=a)?

16 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter15 Consider  xP(b) What is the set of all the expression of the form P(b)(x:=a)?What is the set of all the expression of the form P(b)(x:=a)? That’s the singleton set {P(b)} ! So,That’s the singleton set {P(b)} ! So,  xP(b) is true in D if P(b) is true, and false otherwise.  xP(b) is true in D if P(b) is true, and false otherwise. So,  xP(b) means just P(b)So,  xP(b) means just P(b)

17 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter16 2. Empty u.d.: We defined Let  be a formula. Then the proposition  x  is true in D if every expression  (x:=a) is true in D, and false otherwise.Let  be a formula. Then the proposition  x  is true in D if every expression  (x:=a) is true in D, and false otherwise. This is read as follows: Let  be a formula. Then the proposition  x  is false in D if at least one expression  (x:=a) is false in D, and true otherwise.Let  be a formula. Then the proposition  x  is false in D if at least one expression  (x:=a) is false in D, and true otherwise.

18 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter17  could have been defined differently. For example, Let  be a formula. Then the proposition  x  is true in D if D is nonempty and every expression  (x:=a) is true in D, and false otherwise.Let  be a formula. Then the proposition  x  is true in D if D is nonempty and every expression  (x:=a) is true in D, and false otherwise. –Under this definition,  x P(x) would have been false whenever D is empty (e.g., when there are no parking spaces at U.F., and P = “occupied”) –But that’s not how it’s done!

19 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter18 Suppose D is empty Suppose the u.d. is empty. Consider  x P(x) (e.g., P(x) means “x is occupied.”)  x P(x) (e.g., P(x) means “x is occupied.”) This counts as true. (Sometimes called “vacuously true”) For the same reason,  x  P(x) is also true  x  P(x) is also true

20 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter19 Consequences of the standard position Two logical equivalences in Predicate Logic:  x P(x)   x  P(x) (“no counterexample against P”)  x P(x)   x  P(x) So, one of the two quantifiers suffices (cf., functional completeness of a set of connectives in propositional logic) We’ll return to these equivalences later.

21 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter20 3.  x (Q(x)  P(x)) when  yQ(y)

22 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter21 When many implications are combined Consider the formula r =  x (Q(x)  P(x)) with respect to a nonempty u.d.Consider the formula r =  x (Q(x)  P(x)) with respect to a nonempty u.d. Suppose  yQ(y)Suppose  yQ(y) (For example, Q might mean “being more than 4 meters tall”)(For example, Q might mean “being more than 4 meters tall”) Can you work out whether r is true?Can you work out whether r is true?

23 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter22 When many implications are combined Consider  x (Q(x)  P(x)) in a nonempty u.d.Consider  x (Q(x)  P(x)) in a nonempty u.d. Suppose, however,  yQ(y)Suppose, however,  yQ(y) Then Q(a)  P(a) is true for every a (since Q(a) is false for every a)Then Q(a)  P(a) is true for every a (since Q(a) is false for every a) Consequently  x (Q(x)  P(x)) is trueConsequently  x (Q(x)  P(x)) is true Once again, we sometimes say: it is vacuously true (because the antecedent is always false, so you can never use the formula to conclude that P holds of something).Once again, we sometimes say: it is vacuously true (because the antecedent is always false, so you can never use the formula to conclude that P holds of something).

24 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter23 Vacuous truth Example 1: Think of a tax form: “Have you sent us details about all your children?” No children  You’ve complied (without doing anything)Example 1: Think of a tax form: “Have you sent us details about all your children?” No children  You’ve complied (without doing anything) Example 2: Think of our definition of  (x:=a) as “the result of substituting all free occurrences of x in  by a” No occurrences  don’t do anything (after which it’s true that all occurrences have been substituted)Example 2: Think of our definition of  (x:=a) as “the result of substituting all free occurrences of x in  by a” No occurrences  don’t do anything (after which it’s true that all occurrences have been substituted)

25 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter24 Some consequences of these definitions Sometimes, predicate logic is taught very informallySometimes, predicate logic is taught very informally This makes it easy to understand simple formulasThis makes it easy to understand simple formulas But each more complex case has to be explained separately, as if it was an exceptionBut each more complex case has to be explained separately, as if it was an exception By defining things properly once, complex formulas fall out as special casesBy defining things properly once, complex formulas fall out as special cases One example: quantifier nestingOne example: quantifier nesting

26 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter25 Back to Quantifier Exercise R(x,y)=“x relies upon y”. Suppose the u.d. is empty. Now consider these formulas: 1.  x(  y R(x,y)) 2.  y(  x R(x,y)) 3.  x(  y R(x,y)) Which of them is most informative? Which of them is least informative? Topic #3 – Predicate Logic

27 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter26 Back to our Quantifier Exercise Now that the u.d. is empty, 1.  x(  y R(x,y)) is uninformative 2.  y(  x R(x,y)) is false! 3.  x(  y R(x,y)) is uninformative  x(P(x)) is true if P(a) is true for all a. If no x exist then this makes  x(P(x)) (“vacuously”) true If no x exist then this makes  x(P(x)) (“vacuously”) true  x(P(x)) is true if P(a) is true for some a. If no x exist then this makes  x(P(x)) false. If no x exist then this makes  x(P(x)) false. Topic #3 – Predicate Logic

28 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter27 Back to models: Look at the old formula 3 again 3.  x (Q(x)  P(x)) Consider this model: a:  Q P b:  Q  P a:  Q P b:  Q  P c:  Q P d:  Q  P c:  Q P d:  Q  P Is the proposition true or false in the model?

29 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter28 Look at formula number 3 again 3.  x (Q(x)  P(x)) is true in this model: a:  Q P b:  Q  P a:  Q P b:  Q  P c:  Q P d:  Q  P c:  Q P d:  Q  P (3) Is true iff each of these is true:  x (Q(a)  P(a))  x (Q(b)  P(b))  x (Q(c)  P(c))  x (Q(d)  P(d))

30 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter29 Look at formula number 3 again 3.  x (Q(x)  P(x)) is true in this model: a:  Q P b:  Q  P a:  Q P b:  Q  P c:  Q P d:  Q  P c:  Q P d:  Q  P (3) Is true because each of these is true: Q(a)  P(a) … F T, hence T Q(b)  P(b) … F F, hence T Q(c)  P(c) … F T, hence T Q(d)  P(d) … F F, hence T

31 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter30 Predicate Logic essentials Predicates of different arity (one-place, two- place, etc.)Predicates of different arity (one-place, two- place, etc.) Quantifiers: [  x P(x)] :≡ “For all x, P(x).” [  x P(x)] :≡ “There is/are x such that P(x).”Quantifiers: [  x P(x)] :≡ “For all x, P(x).” [  x P(x)] :≡ “There is/are x such that P(x).” Universes of discourse, bound & free vars.Universes of discourse, bound & free vars. The rest follows: empty domains, quantified implications, quantifier nestingThe rest follows: empty domains, quantified implications, quantifier nesting

32 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter31 Some common shorthands Sometimes the universe of discourse is restricted within the quantification, e.g.,Sometimes the universe of discourse is restricted within the quantification, e.g., –  x>0 P(x) is shorthand for “For all x that are greater than zero, P(x).” How would you write this in formal notation?How would you write this in formal notation? Topic #3 – Predicate Logic

33 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter32 Some common shorthands Sometimes the universe of discourse is restricted within the quantification, e.g.,Sometimes the universe of discourse is restricted within the quantification, e.g., –  x>0 P(x) is shorthand for “For all x that are greater than zero, P(x).” =  x ( x>0  P(x) ) Topic #3 – Predicate Logic

34 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter33 Some common shorthands Sometimes the universe of discourse is restricted within the quantification, e.g.,Sometimes the universe of discourse is restricted within the quantification, e.g., –  x>0 P(x) is shorthand for “For all x that are greater than zero, P(x).” =  x ( x>0  P(x) ) –  x>0 P(x) is shorthand for “There is an x greater than zero such that P(x).” =  x ( x>0  P(x) ) Topic #3 – Predicate Logic

35 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter34 Some common shorthands Consecutive quantifiers of the same type can be combined:  xyz P(x,y,z)  def  x  y  z P(x,y,z)  xyz P(x,y,z)  def  x  y  z P(x,y,z)Consecutive quantifiers of the same type can be combined:  xyz P(x,y,z)  def  x  y  z P(x,y,z)  xyz P(x,y,z)  def  x  y  z P(x,y,z) Topic #3 – Predicate Logic

36 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter35 Theorems about logic We are studying logical languages/calculi to allow you to use them (better)We are studying logical languages/calculi to allow you to use them (better) Logicians study logical languages/calculi to understand their limitationsLogicians study logical languages/calculi to understand their limitations Meta-theorems can, e.g., say things like “… cannot be expressed in predicate logic”Meta-theorems can, e.g., say things like “… cannot be expressed in predicate logic”

37 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter36 Theorems about logic About propositional logic, we asked “What types of things can we express?” How many connectives do we need?About propositional logic, we asked “What types of things can we express?” How many connectives do we need? About predicate logic, logicians ask similar questions. For example, are these two quantifiers enough to be able to ‘say everything’?About predicate logic, logicians ask similar questions. For example, are these two quantifiers enough to be able to ‘say everything’? This is a question about the expressive power of predicate logicThis is a question about the expressive power of predicate logic

38 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter37 Example: one As per their name, quantifiers can be used to express that a predicate is true of a given quantity (number) of objects.As per their name, quantifiers can be used to express that a predicate is true of a given quantity (number) of objects. Example: Can predicate logic say “there exists at most one object with property P”?Example: Can predicate logic say “there exists at most one object with property P”?

39 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter38 Example: at most one Example: Can predicate logic say “there exists at most one object with property P”?Example: Can predicate logic say “there exists at most one object with property P”? Yes (provided we have equality): Yes (provided we have equality):  x  y (( P(x)  P(y))  x= y )  x  y (( P(x)  P(y))  x= y )

40 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter39 Example: one Can predicate logic say “there exists exactly one object with property P”?Can predicate logic say “there exists exactly one object with property P”?

41 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter40 Example: one Can predicate logic say “there exists exactly one object with property P”?  xP(x)   x  y (( P(x)  P(y))  x= y)Can predicate logic say “there exists exactly one object with property P”?  xP(x)   x  y (( P(x)  P(y))  x= y) “There exist x such that P(x)” and “There exists at most one x such that P(x)”“There exist x such that P(x)” and “There exists at most one x such that P(x)” Abbreviation:  !x P(x) (“there exists exactly one x such that P(x)”)Abbreviation:  !x P(x) (“there exists exactly one x such that P(x)”)

42 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter41 Example: one Another way to write this:Another way to write this:  x ( P(x)   y ( P(y)  y  x ) ) “There is an x such that P(x), such that there is no y such that P(y) and y  x.”  x ( P(x)   y ( P(y)  y  x ) ) “There is an x such that P(x), such that there is no y such that P(y) and y  x.”  x binds x throughout the conjunction:  x ( P(x)   y ( P(y)  y  x ) )  x binds x throughout the conjunction:  x ( P(x)   y ( P(y)  y  x ) )

43 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter42 At least two Can predicate logic say “there exist at least two objects with property P”?Can predicate logic say “there exist at least two objects with property P”?

44 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter43 At least two Can predicate logic say “there exist at least two objects with property P”?Can predicate logic say “there exist at least two objects with property P”? Yes:  x  y ( (P(x)  P(y))  x  y )Yes:  x  y ( (P(x)  P(y))  x  y ) Incorrect would be  xP(x)   y(P(y)  x  y), (where x occurs free, and which therefore does not express a proposition)Incorrect would be  xP(x)   y(P(y)  x  y), (where x occurs free, and which therefore does not express a proposition)

45 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter44 Exactly two Can predicate logic say “there exist exactly two objects with property P”?Can predicate logic say “there exist exactly two objects with property P”?

46 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter45 Exactly wo Can predicate logic say “there exist exactly two objects with property P”?Can predicate logic say “there exist exactly two objects with property P”? Yes:Yes:  x  y ( P(x)  P(y)  x  y   z ( P(z)  (z= x  z= y) ) )  x  y ( P(x)  P(y)  x  y   z ( P(z)  (z= x  z= y) ) )

47 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter46 What’s wrong with  x  y (P(x)  P(y)  x  y)   z ( P(z)  (z= x  z= y ) ) as a formalisation of ‘exactly two’?  x  y (P(x)  P(y)  x  y)   z ( P(z)  (z= x  z= y ) ) as a formalisation of ‘exactly two’?

48 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter47 What’s wrong with  x  y (P(x)  P(y)  x  y)   z ( P(z)  (z= x  z= y ) ) as a formalisation of ‘exactly two’?  x  y (P(x)  P(y)  x  y)   z ( P(z)  (z= x  z= y ) ) as a formalisation of ‘exactly two’? This is a conjunction of two separate propositions. As a result, x and y are not bound, so this is not even a propositionThis is a conjunction of two separate propositions. As a result, x and y are not bound, so this is not even a proposition

49 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter48 infinitely many Can predicate logic say “there exist infinitely many objects with property P”?Can predicate logic say “there exist infinitely many objects with property P”? No! [This follows from the so-called Compactness Theorem: “An infinite set S of formulas has a model iff every finite subset of S has a model”]No! [This follows from the so-called Compactness Theorem: “An infinite set S of formulas has a model iff every finite subset of S has a model”] How about finitely many?How about finitely many?

50 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter49 finitely many How about finitely many?How about finitely many? Suppose there existed a formula  = “there exist only finitely many x such that so and so”Suppose there existed a formula  = “there exist only finitely many x such that so and so” Then  = “there exist infinitely many x such that so and so”Then  = “there exist infinitely many x such that so and so” We know that such a formula does not existWe know that such a formula does not exist So, also  does not existSo, also  does not exist

51 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter50 ( Of course if we allow infinite conjunctions then all this can be expressed:  !x P(x)   2!x P(x)   3!x P(x)  … ) ( Of course if we allow infinite conjunctions then all this can be expressed:  !x P(x)   2!x P(x)   3!x P(x)  … )

52 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter51 Can predicate logic say “most objects have property P”?Can predicate logic say “most objects have property P”? No! [This follows from the Compactness Theorem as well. Again, this is unless we allow infinitely long disjunctions.]No! [This follows from the Compactness Theorem as well. Again, this is unless we allow infinitely long disjunctions.] Can predicate logic say “many objects have property P”?Can predicate logic say “many objects have property P”? No, only precisely defined quantitiesNo, only precisely defined quantities

53 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter52 Bonus: Number Theory Examples Let u.d. = the natural numbers 0, 1, 2, … What do the following mean?  x (E(x)  (  y x=2y))  x (E(x)  (  y x=2y))  x ( P(x)  (x>1   yz x=yz  y  1  z  1 ) )  x ( P(x)  (x>1   yz x=yz  y  1  z  1 ) ) Topic #3 – Predicate Logic

54 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter53 Bonus: more Number Theory Examples Let u.d. = the natural numbers 0, 1, 2, …Let u.d. = the natural numbers 0, 1, 2, … “A number x has the property E if and only if it is equal to 2 times some other number.” (even!)  x (E(x)  (  y x=2y))“A number x has the property E if and only if it is equal to 2 times some other number.” (even!)  x (E(x)  (  y x=2y)) “A number has P, iff it’s greater than 1 and it isn’t the product of any non-unity numbers.” (prime!)“A number has P, iff it’s greater than 1 and it isn’t the product of any non-unity numbers.” (prime!)  x ( P(x)  (x>1   yz x=yz  y  1  z  1 ) )  x ( P(x)  (x>1   yz x=yz  y  1  z  1 ) ) Topic #3 – Predicate Logic

55 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter54 Goldbach’s Conjecture (unproven) Using E(x) and P(x) from previous slide,  x( [x>2  E(x)] →  x( [x>2  E(x)] →  p  q P(p)  P(q)  p+q = x).  p  q P(p)  P(q)  p+q = x). Topic #3 – Predicate Logic

56 Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter55 Goldbach’s Conjecture (unproven) Using E(x) and P(x) from previous slide,  x( [x>2  E(x)] →  x( [x>2  E(x)] →  p  q P(p)  P(q)  p+q = x).  p  q P(p)  P(q)  p+q = x). “Every even number greater than 2 is the sum of two primes.” Topic #3 – Predicate Logic


Download ppt "Module #1 - Logic 8/28/2015Michael Frank / Kees van Deemter1 Remember: I. Construct a model where 1 and 4 are true, while 2 and 3 are false Let the u.d."

Similar presentations


Ads by Google