Predicates and Quantifiers

Slides:



Advertisements
Similar presentations
Nested Quantifiers Needed to express statements with multiple variables Example 1: “x+y = y+x for all real numbers”  x  y(x+y = y+x) where the domains.
Advertisements

The Foundations: Logic and Proofs
CS 285- Discrete Mathematics
Chapter 1, Part II: Predicate Logic With Question/Answer Animations.
Section 1.3. More Logical Equivalences Constructing New Logical Equivalences We can show that two expressions are logically equivalent by developing.
Chapter 1: The Foundations: Logic and Proofs 1.1 Propositional Logic 1.2 Propositional Equivalences 1.3 Predicates and Quantifiers 1.4 Nested Quantifiers.
Predicates and Quantifiers
22C:19 Discrete Structures Logic and Proof Spring 2014 Sukumar Ghosh.
First Order Logic (chapter 2 of the book) Lecture 3: Sep 14.
First Order Logic. Propositional Logic A proposition is a declarative sentence (a sentence that declares a fact) that is either true or false, but not.
Lecture # 21 Predicates & Quantifiers
1 Predicates and Quantifiers CS 202, Spring 2007 Epp, Sections 2.1 and 2.2 Aaron Bloomfield.
First Order Logic. This Lecture Last time we talked about propositional logic, a logic on simple statements. This time we will talk about first order.
Predicates and Quantifiers
CS 2210 (22C:019) Discrete Structures Logic and Proof Spring 2015 Sukumar Ghosh.
Predicates and Quantifiers
Predicates and Quantifiers. Predicates (aka propositional functions) Propositions (things that are true or false) that contain variables P(-2) is false.
Chapter 1: The Foundations: Logic and Proofs
The Foundations: Logic and Proofs
FUNCTIONS : Domain values When combining functions using the composite rules, it is necessary to check the domain for values that could be restricted.
Section 1.5. Section Summary Nested Quantifiers Order of Quantifiers Translating from Nested Quantifiers into English Translating Mathematical Statements.
Chapter 1, Part II: Predicate Logic With Question/Answer Animations.
First Order Logic Lecture 2: Sep 9. This Lecture Last time we talked about propositional logic, a logic on simple statements. This time we will talk about.
Chapter 1, Part II: Predicate Logic With Question/Answer Animations.
Chapter 1, Part II: Predicate Logic With Question/Answer Animations 1.
Chapter 1: The Foundations: Logic and Proofs 1.1 Propositional Logic 1.2 Propositional Equivalences 1.3 Predicates and Quantifiers 1.4 Nested Quantifiers.
Solving Quadratic Equations – Part 1 Methods for solving quadratic equations : 1. Taking the square root of both sides ( simple equations ) 2. Factoring.
Statements with Multiple Quantifiers. When a statement contains more than one quantifier, we imagine the actions suggested by the quantifiers as being.
1 Predicate (Relational) Logic 1. Introduction The propositional logic is not powerful enough to express certain types of relationship between propositions.
CS203 Discrete Mathematical Structures Logic (2).
Hazırlayan DISCRETE COMPUTATIONAL STRUCTURES Propositional Logic PROF. DR. YUSUF OYSAL.
Discrete Mathematics. Predicates - the universal quantifier 11/28/2015 Suppose P(x) is a predicate on some universe of discourse. Ex. B(x) = “x is carrying.
Nested Quantifiers Section 1.5.
CompSci 102 Discrete Math for Computer Science January 24, 2012 Prof. Rodger Slides modified from Rosen.
1 Introduction to Abstract Mathematics Predicate Logic Instructor: Hayk Melikya Purpose of Section: To introduce predicate logic (or.
Chapter 1, Part II: Predicate Logic With Question/Answer Animations 1.
Lecture 7 – Jan 28, Chapter 2 The Logic of Quantified Statements.
Lecture 8 Predicate Logic TF4233 Mathematical Logic Semester 2, 2006/2007 Dr. Rolly Intan & Cherry Ballangan, MAIT Informatics Department, Petra Christian.
CS 285- Discrete Mathematics Lecture 4. Section 1.3 Predicate logic Predicate logic is an extension of propositional logic that permits concisely reasoning.
Discrete Structures Predicate Logic 1 Dr. Muhammad Humayoun Assistant Professor COMSATS Institute of Computer Science, Lahore.
First Order Logic Lecture 3: Sep 13 (chapter 2 of the book)
Predicates and Quantifiers Dr. Yasir Ali. 1.Predicates 2.Quantifiers a.Universal Quantifiers b.Existential Quantifiers 3.Negation of Quantifiers 4.Universal.
Rules of Inference Section 1.6. Arguments in Propositional Logic A argument in propositional logic is a sequence of propositions. All but the final proposition.
22C:19 Discrete Structures Logic and Proof Fall 2014 Sukumar Ghosh.
321 Section, Week 2 Natalie Linnell. Extra Credit problem.
Mathematics for Comter I Lecture 3: Logic (2) Propositional Equivalences Predicates and Quantifiers.
Section 1.4. Propositional Functions Propositional functions become propositions (and have truth values) when their variables are each replaced by a value.
Section 1.5. Section Summary Nested Quantifiers Order of Quantifiers Translating from Nested Quantifiers into English Translating Mathematical Statements.
Propositional Logic. Assignment Write any five rules each from two games which you like by using propositional logic notations.
Chapter 1, Part II: Predicate Logic With Question/Answer Animations 1.
Uniqueness Quantifier ROI for Quantified Statement.
CSE15 Discrete Mathematics 01/25/17
CS 2210:0001 Discrete Structures Logic and Proof
Equations Quadratic in form factorable equations
Chapter 1 The Foundations: Logic and Proofs
The Foundations: Logic and Proofs
CS201: Data Structures and Discrete Mathematics I
Nested Quantifiers Nested quantifiers are often necessary to express the meaning of sentences in English as well as important concepts in computer science.
Introduction to Predicates and Quantified Statements II
First Order Logic Rosen Lecture 3: Sept 11, 12.
Discrete Mathematics Lecture 4 & 5: Predicate and Quantifier
Applied Discrete Mathematics Week 2: Proofs
Discrete Mathematics Lecture 4 & 5: Predicate and Quantifier
Predicates and Quantifiers
Discrete Mathematics Lecture 4 Logic of Quantified Statements
The Foundations: Logic and Proofs
CS201: Data Structures and Discrete Mathematics I
Equations Quadratic in form factorable equations
Predicates and Quantifiers
Presentation transcript:

Predicates and Quantifiers Dr. Yasir Ali

How do you translate the statement: All birds can fly How do you translate the statement: All birds can fly. If D= Set of all creatures Take 𝐵(𝑥)= 𝑥 is a Bird. 𝐹(𝑥)= 𝑥 can fly. ∀ 𝑥, 𝐵(𝑥)→𝐹(𝑥) We can not say, ∀ 𝑥, 𝐵(𝑥)∧𝐹(𝑥) Since it means that All creatures are bird and they can fly, which is not a correct translation of original statement.

How do you translate the statement: Some birds can fly How do you translate the statement: Some birds can fly. If D= Set of all creatures Take 𝐵(𝑥)= 𝑥 is a Bird. 𝐹(𝑥)= 𝑥 can fly. ∃ 𝑥, 𝐵(𝑥)∧𝐹(𝑥) We can not say, ∃ 𝑥, 𝐵(𝑥)→𝐹(𝑥) Since this statement will be true if 𝑥 is a frog. That is this statement will be true if 𝑥 is not a bird because in that case F→𝐹 and 𝐹→𝑇 both are the true statements.

Translate in two ways each of these statements into logical expressions using predicates, quantifiers, and logical connectives. First, let the domain consist of the students in your class and second, let it consist of all people. a) Everyone in your class has a cellular phone. b) Somebody in your class has seen a foreign movie. c) There is a person in your class who cannot swim. d) All students in your class can solve quadratic equations. e) Some student in your class does not want to be rich.

Precedence of Quantifiers The quantifiers ∀ and ∃ have higher precedence than all logical operators from propositional calculus. For example, ∀𝑥𝑃(𝑥) ∨ 𝑄(𝑥) is the disjunction of ∀𝑥𝑃(𝑥) and 𝑄(𝑥). In other words, it means (∀𝑥𝑃(𝑥)) ∨ 𝑄(𝑥) rather than ∀𝑥(𝑃(𝑥) ∨ 𝑄(𝑥)).

Express each of these statements using quantifiers Express each of these statements using quantifiers. Then form the negation of the statement so that no negation is to the left of a quantifier. Next, express the negation in simple English. (Do not simply use the phrase “It is not the case that.”) a) All dogs have fleas. b) There is a horse that can add. c) Every koala can climb. d) No monkey can speak French. e) There exists a pig that can swim and catch fish.

Translate into formal language. “All lions are fierce Translate into formal language. “All lions are fierce.” “Some lions do not drink coffee.” “Some fierce creatures do not drink coffee.”

Multiple Quantified Statements Assume that the domain for the variables 𝑥 and 𝑦 consists of all real numbers. The statement ∀𝑥 ∀𝑦(𝑥 + 𝑦 = 𝑦 + 𝑥) says that 𝑥 + 𝑦 = 𝑦 + 𝑥 for all real numbers 𝑥 and 𝑦. This is the commutative law for addition of real numbers. Translate into English the statement ∀𝑥 ∀𝑦((𝑥 > 0) ∧ (𝑦 < 0) → (𝑥𝑦 < 0)), where the domain for both variables consists of all real numbers. The product of a positive real number and a negative real number is always a negative real number.”

Translate these statements into English, where the domain for each variable consists of all real numbers. a) ∀𝑥∃𝑦(𝑥 < 𝑦) b) ∀𝑥∀𝑦(((𝑥 ≥ 0) ∧ (𝑦 ≥ 0)) → (𝑥𝑦 ≥ 0)) c) ∀𝑥∀𝑦∃𝑧(𝑥𝑦 = 𝑧) Suppose the domain of the propositional function is {1,2,3}. Write out these propositions using disjunctions and conjunctions and determine the truth value of each of these statements. ∀𝑥∃𝑦(𝑥 + 𝑦 = 1) ∀𝑥∀𝑦∃𝑧(𝑧 = (𝑥 + 𝑦))

The Order of Quantifiers Consider the statements: ∀ 𝑝𝑒𝑜𝑝𝑙𝑒 𝑥 ∃ 𝑎 𝑝𝑒𝑟𝑠𝑜𝑛 𝑦 𝑠𝑢𝑐ℎ 𝑡ℎ𝑎𝑡 𝑥 𝑙𝑜𝑣𝑒𝑠 𝑦. ∃ 𝑎 𝑝𝑒𝑟𝑠𝑜𝑛 𝑦 ∀ 𝑝𝑒𝑜𝑝𝑙𝑒 𝑥 𝑠𝑢𝑐ℎ 𝑡ℎ𝑎𝑡 𝑥 𝑙𝑜𝑣𝑒𝑠 𝑦.

Let 𝑄(𝑥, 𝑦) denote “𝑥 + 𝑦 = 0.” What are the truth values of the quantifications ∃𝑦∀𝑥𝑄(𝑥, 𝑦) and ∀𝑥∃𝑦𝑄(𝑥, 𝑦), where the domain for all variables consists of all real numbers? ∃𝑦∀𝑥𝑄(𝑥, 𝑦) denotes the proposition “There is a real number 𝑦 such that for every real number 𝑥, 𝑄(𝑥, 𝑦).” The quantification ∀𝑥∃𝑦𝑄(𝑥, 𝑦) “For every real number 𝑥 there is a real number 𝑦 such that 𝑄(𝑥, 𝑦).”

Quantifications of Two Variables Statement When True? When False? ∀𝑥∀𝑦𝑃(𝑥, 𝑦) ∀𝑦∀𝑥𝑃(𝑥, 𝑦) 𝑃(𝑥, 𝑦) is true for every pair 𝑥, 𝑦. There is a pair 𝑥, 𝑦 for which 𝑃(𝑥, 𝑦) is false. ∀𝑥∃𝑦𝑃(𝑥, 𝑦) For every 𝑥 there is a 𝑦 for which 𝑃(𝑥, 𝑦) is true. There is an x such that 𝑃(𝑥, 𝑦) is false for every 𝑦. ∃𝑥∀𝑦𝑃(𝑥, 𝑦) There is an 𝑥 for which 𝑃(𝑥, 𝑦) is true for every 𝑦. For every 𝑥 there is a 𝑦 for which 𝑃(𝑥, 𝑦) is false. ∃𝑥∃𝑦𝑃(𝑥, 𝑦) ∃𝑦∃𝑥𝑃(𝑥, 𝑦) There is a pair 𝑥, 𝑦 for which 𝑃(𝑥, 𝑦) is true. 𝑃(𝑥, 𝑦) is false for every pair 𝑥, 𝑦.

Express each of these mathematical statements using predicates, quantifiers, logical connectives, and mathematical operators. a) The product of two negative real numbers is positive. b) The difference of a real number and itself is zero. d) A negative real number does not have a square root that is a real number.

Let F(x, y) be the statement “x can fool y,” where the domain consists of all people in the world. Use quantifiers to express each of these statements. a) Everybody can fool Fred. b) Evelyn can fool everybody. c) Everybody can fool somebody. d) There is no one who can fool everybody. e) Everyone can be fooled by somebody. f ) No one can fool both Fred and Jerry. g) Nancy can fool exactly two people.

Translate each of these nested quantifications into an English statement that expresses a mathematical fact. The domain in each case consists of all real numbers. a) ∃𝑥∀𝑦(𝑥 + 𝑦 = 𝑦) b) ∀𝑥∀𝑦(((𝑥 ≥ 0) ∧ (𝑦 < 0)) → (𝑥 −𝑦 > 0)) c) ∃𝑥∃𝑦(((𝑥 ≤ 0) ∧ (𝑦 ≤ 0)) ∧ (𝑥 −𝑦 > 0)) d) ∀𝑥∀𝑦((𝑥 = 0) ∧ (𝑦 = 0) ↔ (𝑥𝑦 = 0))

Rules of inference for quantified statements Rule of Inference Name ∀xP(x) ∴ P(c) Universal instantiation P(c) for an arbitrary c ∴ ∀xP(x) Universal generalization ∃xP(x) ∴ P(c) for some element c Existential instantiation P(c) for some element c ∴ ∃xP(x) Existential generalization

Show that the following argument is valid or not: “Ali, a student in this class, knows how to write programs in JAVA. Everyone who knows how to write programs in JAVA can get a high-paying job. Therefore, someone in this class can get a high-paying job.” Everyone enrolled in the university has lived in a dormitory. Mia has never lived in a dormitory. Therefore, Mia is not enrolled in the university.