Nesting Quantifiers And Their Manipulation Copyright © 2007-2014 Curt Hill.

Slides:



Advertisements
Similar presentations
Nested Quantifiers Section 1.4.
Advertisements

1.3 Predicates and Quantifiers
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.
CS 285- Discrete Mathematics
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 
1.3 FRACTIONS REVIEW Variables-letters that represent numbers
Nested Quantifiers Goals: Explain how to work with nested quantifiers
1.2 – Open Sentences and Graphs
Nested Loops. Nesting Control Structures One if statement inside another one An if statement inside a loop A loop inside an if statement Control structures.
Predicates and Quantifiers
Lecture 8 Introduction to Logic CSCI – 1900 Mathematics for Computer Science Fall 2014 Bill Pine.
Copyright © 2010 Pearson Education, Inc
CSci 2011 Discrete Mathematics Lecture 3 CSci 2011.
The Foundations: Logic and Proofs
Copyright © Curt Hill Rules of Inference What is a valid argument?
Matrices Square is Good! Copyright © 2014 Curt Hill.
Relations and Functions Another Foundational Concept Copyright © 2014 – Curt Hill.
Objectives: To evaluate and simplify algebraic expressions.
While Loops CMSC 201. Overview Today we will learn about: Looping Structures While loops.
Nested Quantifiers. 2 Nested Iteration Let the domain be {1, 2, …, 10}. Let P(x, y) denote x > y.  x,  y, P(x, y) means  x, (  y, P(x, y) ) Is the.
Chapter 1, Part II: Predicate Logic With Question/Answer Animations.
PART TWO PREDICATE LOGIC. Chapter Seven Predicate Logic Symbolization.
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.
Copyright © Curt Hill Languages and Grammars This is not English Class. But there is a resemblance.
Chapter 1, Part II: Predicate Logic With Question/Answer Animations.
Chapter 1: The Foundations: Logic and Proofs 1.1 Propositional Logic 1.2 Propositional Equivalences 1.3 Predicates and Quantifiers 1.4 Nested Quantifiers.
Statements with Multiple Quantifiers. When a statement contains more than one quantifier, we imagine the actions suggested by the quantifiers as being.
Copyright © 2014 Curt Hill Sets Introduction to Set Theory.
Copyright © Curt Hill Quantifiers. Copyright © Curt Hill Introduction What we have seen is called propositional logic It includes.
Multiplication of Real Numbers Section 2.5. Multiplying Rules 1) If the numbers have the same signs then the answer is positive. (-7) (-4) = 28 2) If.
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,
1 Introduction to Abstract Mathematics Predicate Logic Instructor: Hayk Melikya Purpose of Section: To introduce predicate logic (or.
1 Georgia Tech, IIC, GVU, 2006 MAGIC Lab Rossignac Lecture 02: QUANTIFIERS Sections 1.3 and 1.4 Jarek Rossignac CS1050:
Lecture 7 – Jan 28, Chapter 2 The Logic of Quantified Statements.
COMP 170 L2 L08: Quantifiers. COMP 170 L2 Outline l Quantifiers: Motivation and Concepts l Quantifiers: Notations and Meaning l Saying things with Quantified.
Slide Copyright © 2008 Pearson Education, Inc. Publishing as Pearson Addison-Wesley A set of equations is called a system of equations. The solution.
Copyright © Curt Hill Proofs An Introduction.
Predicates and Quantifiers Dr. Yasir Ali. 1.Predicates 2.Quantifiers a.Universal Quantifiers b.Existential Quantifiers 3.Negation of Quantifiers 4.Universal.
Propositional Equivalence A needed step towards proofs Copyright © 2014 Curt Hill.
Predicate Logic One step stronger than propositional logic Copyright © Curt Hill.
Copyright © Curt Hill Axiomatic Approach Some needed groundwork.
MTH 070 Elementary Algebra Chapter 2 Equations and Inequalities in One Variable with Applications 2.4 – Linear Inequalities Copyright © 2010 by Ron Wallace,
1 Logic Our ability to state invariants, record preconditions and post- conditions, and the ability to reason about a formal model depend on the logic.
1.4 Properties of Real Numbers ( )
Statements Containing Multiple Quantifiers Lecture 11 Section 2.3 Mon, Feb 5, 2007.
Copyright Curt Hill The Assignment Operator and Statement The Most Common Statement you will use.
Solve 7n – 2 = 5n + 6. Example 1: Solving Equations with Variables on Both Sides To collect the variable terms on one side, subtract 5n from both sides.
PREDICATES AND QUANTIFIERS COSC-1321 Discrete Structures 1.
Mathematics for Comter I Lecture 3: Logic (2) Propositional Equivalences Predicates and Quantifiers.
Section 1.5. Section Summary Nested Quantifiers Order of Quantifiers Translating from Nested Quantifiers into English Translating Mathematical Statements.
Loops CMSC 201. Overview Today we will learn about: Looping Structures While loops For Loops.
Introduction to Predicates and Quantified Statements I Lecture 9 Section 2.1 Wed, Jan 31, 2007.
Propositional Logic. Assignment Write any five rules each from two games which you like by using propositional logic notations.
Nested Quantifiers Goals: Explain how to work with nested quantifiers
Chapter 1 The Foundations: Logic and Proofs
The Foundations: Logic and Proofs
The C++ IF Statement Part 2 Copyright © Curt Hill
Nested Quantifiers Nested quantifiers are often necessary to express the meaning of sentences in English as well as important concepts in computer science.
Chapter 8: More on the Repetition Structure
(1.4) An Introduction to Logic
Introduction to Predicates and Quantified Statements I
Control Structure Testing
Lecture 1.3: Predicate Logic
ICS 253: Discrete Structures I
Properties of Definite Integrals
Predicates and Quantifiers
Lecture 1.3: Predicate Logic
Presentation transcript:

Nesting Quantifiers And Their Manipulation Copyright © Curt Hill

Introduction The larger view is that a quantified expression is just a predicate –It must have a true or false value –Even if we do not know what it is Then it only makes sense that we may have a quantified expression within a quantified expression Copyright © Curt Hill

Commutativity Consider the statement of commutativity  i  j (i + j = j + i) –We have a second universal quantifier nested within the first The book prefers that notation, but I prefer:  i,j (i + j = j + i) –Where the quantifier has multiple dummies, all of which may range independently Copyright © Curt Hill

Associativity of Addition Use:  i  j  k (i + (j + k) = (i + j) + k) Or  i,j,k (i + (j + k) = (i + j) + k) Copyright © Curt Hill

Mixed The multiple quantifiers is required when they are different What does this mean?  i  j (i < j) How is this different from?  j  i (i < j) One of these is true and the other false Copyright © Curt Hill

Prime Definition Again This time with nested quantifiers prime(n) =  i    1 < i < n   j  I (j=n  i) Negation of an existential gives a universal so: prime(n) =  i    1 < i < n  j  I (j  n  i ) Copyright © Curt Hill

Scope Expression  i (pred1(i)   k pred2(i,k)) There are two bound variables i is known in entire range k is known only in second quantifier As far as the universal quantifier is concerned i is a free variable Both may be used in the second quantifier This may cause a problem if they use the same names Copyright © Curt Hill

Looping A quantifier has much in common with programming language loops with a few exceptions –They are often infinite –Since  and  are commutative the order does not matter This gives us a way to think about them Nested quantifiers then become nested loops Copyright © Curt Hill

Order If the two quantifiers are the same then we may reverse their order: (  i  j i + j = j + i) = (  j  i i + j = j + i) This is not generally true if there is a combination of universal and existential The inner quantifier is chosen after the outer  x (  y x+y = 0)   y (  x x+y = 0) –What do these two mean? –Which is true? Copyright © Curt Hill

Audience Participation For each of the following: –Is it true? –What does it mean? –Assume Reals if no type is given  x (  y x<y)  y (  x x<y)  i   (  j   i=j 2 )  i   (  j   j=i 2 ) Copyright © Curt Hill

Negation What happens when we negate an expression with nested quantifiers? We know how to negate a quantifier We just apply this from the outside in Recall  x (  y x+y = 0) This means that there exists a single real number that may be added to any real and the result is zero –We also know that this is false –Multiplication has a zero, not addition Copyright © Curt Hill

Negating  x (  y x+y = 0) Start with applying a single negation:   x (  y x+y = 0) Negation of an existential is a universal with negated predicate  x (   y x+y = 0) Negate again  x (  y x+y  0) Compare this with the more interesting:  y (  x x+y = 0) Copyright © Curt Hill

Summary We now know something about nesting quantifiers Translation these to and from English uses the same skills we used before and practice Interchanging nested quantifiers does not usually give us either the same or opposite results Copyright © Curt Hill

Exercises Rosen 1.5 Problems: 5, 9, 15, 21, 25, 31, 37, 43 Copyright © Curt Hill