CSE115/ENGR160 Discrete Mathematics 01/20/11 Ming-Hsuan Yang UC Merced 1.

Slides:



Advertisements
Similar presentations
Propositional Predicate
Advertisements

Chapter 1: The Foundations: Logic and Proofs 1.1 Propositional Logic 1.2 Propositional Equivalences 1.3 Predicates and Quantifiers 1.4 Nested Quantifiers.
© by Kenneth H. Rosen, Discrete Mathematics & its Applications, Sixth Edition, Mc Graw-Hill, 2007 Chapter 1: (Part 2): The Foundations: Logic and Proofs.
L41 Lecture 2: Predicates and Quantifiers.. L42 Agenda Predicates and Quantifiers –Existential Quantifier  –Universal Quantifier 
Propositions and Connectives Conditionals and Bi-conditionals Quantifiers.
CS128 – Discrete Mathematics for Computer Science
Discrete Mathematics Math 6A Instructor: M. Welling.
CSE115/ENGR160 Discrete Mathematics 01/25/11 Ming-Hsuan Yang UC Merced 1.
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
Adapted from Discrete Math
Predicates and Quantifiers
Chapter 1: The Foundations: Logic and Proofs
Discrete Mathematics Goals of a Discrete Mathematics Learn how to think mathematically 1. Mathematical Reasoning Foundation for discussions of methods.
CSci 2011 Discrete Mathematics Lecture 3 CSci 2011.
Logical Equivalence & Predicate Logic
CSCI 115 Chapter 2 Logic. CSCI 115 §2.1 Propositions and Logical Operations.
MATH 213 A – Discrete Mathematics for Computer Science Dr. (Mr.) Bancroft.
Discrete Mathematics and Its Applications
Mathematical Structures A collection of objects with operations defined on them and the accompanying properties form a mathematical structure or system.
CS 103 Discrete Structures Lecture 05
Fall 2002CMSC Discrete Structures1 Let’s get started with... Logic !
Chapter 1, Part II: Predicate Logic With Question/Answer Animations.
Chapter 1, Part II: Predicate Logic With Question/Answer Animations.
Fundamentals of Logic 1. What is a valid argument or proof? 2. Study system of logic 3. In proving theorems or solving problems, creativity and insight.
Math 51/COEN 19 Day 3, 1.4 Quantifiers 1. 3 Predicates A lot like functions that return booleans Let P(x) denote x
Hazırlayan DISCRETE COMPUTATIONAL STRUCTURES Propositional Logic PROF. DR. YUSUF OYSAL.
Section 1.2: Propositional Equivalences In the process of reasoning, we often replace a known statement with an equivalent statement that more closely.
1 Sections 1.3 and 1.4 Predicates & Quantifiers. 2 Propositional Functions In a mathematical assertion, such as x < 3, there are two parts: –the subject,
Chapter 2 Logic 2.1 Statements 2.2 The Negation of a Statement 2.3 The Disjunction and Conjunction of Statements 2.4 The Implication 2.5 More on Implications.
Chapter 1: The Foundations: Logic and Proofs
Chapter 1: The Foundations: Logic and Proofs
1 Georgia Tech, IIC, GVU, 2006 MAGIC Lab Rossignac Lecture 02: QUANTIFIERS Sections 1.3 and 1.4 Jarek Rossignac CS1050:
Lecture Predicates and Quantifiers 1.4 Nested Quantifiers.
Discrete Mathematics CS 2610 August 22, Agenda Last class Propositional logic Logical equivalences This week Predicate logic & rules of inference.
Fall 2008/2009 I. Arwa Linjawi & I. Asma’a Ashenkity 1 The Foundations: Logic and Proofs Predicates and Quantifiers.
Discrete Structures – CNS 2300
Chapter 2 Symbolic Logic. Section 2-1 Truth, Equivalence and Implication.
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.
CSNB143 – Discrete Structure Topic 4 – Logic. Learning Outcomes Students should be able to define statement. Students should be able to identify connectives.
Predicates and Quantifiers Dr. Yasir Ali. 1.Predicates 2.Quantifiers a.Universal Quantifiers b.Existential Quantifiers 3.Negation of Quantifiers 4.Universal.
Predicate Logic One step stronger than propositional logic Copyright © Curt Hill.
Discrete Mathematics Mathematical reasoning: think logically; know how to prove Combinatorial analysis: know how to count Discrete structures: represent.
Section 1.5 and 1.6 Predicates and Quantifiers. Vocabulary Predicate Domain Universal Quantifier Existential Quantifier Counterexample Free variable Bound.
PREDICATES AND QUANTIFIERS COSC-1321 Discrete Structures 1.
Mathematics for Comter I Lecture 3: Logic (2) Propositional Equivalences Predicates and Quantifiers.
 To combine propositions using connectives  To construct the truth table of a given compound proposition  To define de Morgan Law for logic  To define.
Section 1.4. Propositional Functions Propositional functions become propositions (and have truth values) when their variables are each replaced by a value.
Introduction to Predicates and Quantified Statements I Lecture 9 Section 2.1 Wed, Jan 31, 2007.
Discrete Mathematical Structures: Theory and Applications 1 Logic: Learning Objectives  Learn about statements (propositions)  Learn how to use logical.
1 Section 7.1 First-Order Predicate Calculus Predicate calculus studies the internal structure of sentences where subjects are applied to predicates existentially.
Propositional Logic. Assignment Write any five rules each from two games which you like by using propositional logic notations.
Introduction to Discrete Mathematics Discrete Mathematics: is the part of mathematics devoted to the study of discrete objects. Discrete Mathematics is.
Chapter 1 Logic and proofs
رياضيات متقطعة لعلوم الحاسب MATH 226. Chapter 1 Predicates and Quantifiers 1.4.
Logic Hubert Chan [O1 Abstract Concepts] [O2 Proof Techniques]
CSE15 Discrete Mathematics 01/23/17
Logic Hubert Chan [O1 Abstract Concepts] [O2 Proof Techniques]
CMSC Discrete Structures
Chapter 1 The Foundations: Logic and Proofs
CS201: Data Structures and Discrete Mathematics I
CS 220: Discrete Structures and their Applications
CHAPTER 1: LOGICS AND PROOF
Discrete Mathematics Lecture 4 & 5: Predicate and Quantifier
Discrete Mathematics Lecture 3: Predicate and Quantifier
Discrete Mathematics CMP-200 Propositional Equivalences, Predicates & Quantifiers, Negating Quantified Statements Abdul Hameed
Discrete Mathematics Lecture 4 & 5: Predicate and Quantifier
Predicates and Quantifiers
CS201: Data Structures and Discrete Mathematics I
Presentation transcript:

CSE115/ENGR160 Discrete Mathematics 01/20/11 Ming-Hsuan Yang UC Merced 1

Propositional equivalences Replace a statement with another statement with the same truth value For efficiency (speed-up) or implementation purpose (e.g., circuit design) 2

Tautology and contradiction 3 A compound proposition: Tautology: always true Contradiction: always false Contingency: neither a tautology nor a contradiction

Logical equivalence p ≡ q (p q): the compound propositions p and q are logically equivalent if p ↔ q is a tautology Can use truth table to determine whether two propositions are equivalent or not 4

Example 5

6 pqp→q┐p˅q TTTT TFFF FTTT FFTT

Example 7

8

De Morgan’s laws 9

Example Express the negation of “Heather will go to the concert or Steve will go to the concert” Negation: Heather will not go to the concert AND Steve will not go to the concert. 10

De Morgan’s law: general form The first example above is known as the De Morgan’s law 11

Logical equivalences 12

13

14

Constructing new logical equivalences Show ┐ (p → q) ≡ p ˄ ┐ q ┐ (p → q) ≡ ┐(┐p ˅ q) ≡ ┐(┐p) ˄ ┐q ≡ p ˄ ┐q 15

Constructing new logical equivalences Show ┐ (p ˅ (┐ p ˄ q) ) ≡ ┐ p ˄ ┐ q ┐ (p ˅ (┐ p ˄ q) ) ≡ ┐ p ˄ ┐(┐ p ˄ q) ≡ ┐ p ˄ (┐(┐ p) ˅ ┐q) ≡ ┐ p ˄ (p ˅ ┐q) ≡ (┐ p ˄ p ) ˅ (┐ p ˄ ┐q) ≡ F ˅ (┐ p ˄ ┐q) ≡ ┐ p ˄ ┐q 16

Limitations of proposition logic Proposition logic cannot adequately express the meaning of statements Suppose we know “Every computer connected to the university network is functioning property” No rules of propositional logic allow us to conclude “MATH3 is functioning property” where MATH3 is one of the computers connected to the university network 17

Example Cannot use the rules of propositional logic to conclude from “CS2 is under attack by an intruder” where CS2 is a computer on the university network to conclude the truth “There is a computer on the university network that is under attack by an intruder” 18

Predicate logic/calculus Can be used to express the meaning of a wide range of statements Allow us to reason and explore relationship between objects Predicates: statements involving variables, e.g., “x > 3”, “x=y+3”, “x+y=z”, “computer x is under attack by an intruder”, “computer x is functioning property” 19

Example: x > 3 The variable x is the subject of the statement Predicate “is greater than 3” refers to a property that the subject of the statement can have Can denote the statement by p(x) where p denotes the predicate “is greater than 3” and x is the variable p(x): also called the value of the propositional function p at x Once a value is assigned to the variable x, p(x) becomes a proposition and has a truth value 20

Example Let p(x) denote the statement “x > 3” – p(4): setting x=4, thus p(4) is true – p(2): setting x=2, thus p(2) is false Let a(x) denote the statement “computer x is under attack by an intruder”. Suppose that only CS2 and MATH1 are currently under attack – a(CS1)? : false – a(CS2)? : true – a(MATH1)?: true 21

N-ary Predicate A statement involving n variables, x 1, x 2, …, x n, can be denoted by p(x 1, x 2, …, x n ) p(x 1, x 2, …, x n ) is the value of the propositional function p at the n-tuple (x 1, x 2, …, x n ) p is also called n-ary predicate 22

Quantifiers Express the extent to which a predicate is true In English, all, some, many, none, few Focus on two types: – Universal: a predicate is true for every element under consideration – Existential: a predicate is true for there is one or more elements under consideration Predicate calculus: the area of logic that deals with predicates and quantifiers 23

Universal quantifier “p(x) for all values of x in the domain” Read it as “for all x p(x)” or “for every x p(x)” A statement is false if and only if p(x) is not always true An element for which p(x) is false is called a counterexample of A single counterexample is all we need to establish that is not true 24

Example Let p(x) be the statement “x+1>x”. What is the truth value of ? – Implicitly assume the domain of a predicate is not empty – Best to avoid “for any x” as it is ambiguous to whether it means “every” or “some” Let q(x) be the statement “x<2”. What is the truth value of where the domain consists of all real numbers? 25

Example Let p(x) be “x 2 >0”. To show that the statement is false where the domain consists of all integers – Show a counterexample with x=0 When all the elements can be listed, e.g., x 1, x 2, …, x n, it follows that the universal quantification is the same as the conjunction p(x 1 ) ˄p(x 2 ) ˄…˄ p(x n ) 26

Example What is the truth value of where p(x) is the statement “x 2 < 10” and the domain consists of positive integers not exceeding 4? is the same as p(1)˄p(2)˄p(3)˄p(4) 27

Existential quantification “There exists an element x in the domain such that p(x) (is true)” Denote that as where is the existential quantifier In English, “for some”, “for at least one”, or “there is” Read as “There is an x such that p(x)”, “There is at least one x such that p(x)”, or “For some x, p(x)” 28

Example Let p(x) be the statement “x>3”. Is true for the domain of all real numbers? Let q(x) be the statement “x=x+1”. Is true for the domain of all real numbers? When all elements of the domain can be listed,, e.g., x 1, x 2, …, x n, it follows that the existential quantification is the same as disjunction p(x 1 ) ˅p(x 2 ) ˅ … ˅ p(x n ) 29

Example What is the truth value of where p(x) is the statement “x 2 > 10” and the domain consists of positive integers not exceeding 4? is the same as p(1) ˅p(2) ˅p(3) ˅ p(4) 30

Uniqueness quantifier There exists a unique x such that p(x) is true “There is exactly one”, “There is one and only one” 31

Quantifiers with restricted domains What do the following statements mean for the domain of real numbers? 32 Be careful about → and ˄ in these statements

Precedence of quantifiers have higher precedence than all logical operators from propositional calculus 33

Binding variables 34 When a quantifier is used on the variable x, this occurrence of variable is bound If a variable is not bound, then it is free All variables occur in propositional function of predicate calculus must be bound or set to a particular value to turn it into a proposition The part of a logical expression to which a quantifier is applied is the scope of this quantifier

Example 35 What are the scope of these expressions? Are all the variables bound?