Discrete Structures CMSC 2123 Introduction EXAMPLE 1 EXAMPLE 2 Lecture 5 1.5 Nested Quantifiers Express βπ₯π₯βπ¦π¦(π₯π₯ + π¦π¦ = 0) without the existential quantifier. Solution: βπ₯π₯βπ¦π¦(π₯π₯ + π¦π¦ = 0) is the same as βπ₯π₯π₯π₯(π₯π₯) where ππ(π₯π₯) is βπ¦π¦π¦π¦(π₯π₯, π¦π¦) and ππ(π₯π₯, π¦π¦) = π₯π₯ + π¦π¦ = 0 Translate βπ₯π₯βπ¦π¦((π₯π₯ > 0) β§ (π¦π¦ < 0) β π₯π₯π₯π₯ < 0)) into English. Solution: This statement says that for every real number x and for every real number y, if π₯π₯ > 0 and π¦π¦ < 0, then π₯π₯π₯π₯ < 0. That is, this statement says that for real numbers x and y, if x is positive and y is negative, then xy is negative. The can be stated more succinctly as βThe product of a positive real number and a negative real number is always a negative real number. The Order of Quantifiers EXAMPLE 3 Let ππ(π₯π₯, π¦π¦) be the statement βπ₯π₯ + π¦π¦ = π¦π¦ + π₯π₯. " What are the truth values of the quantifications βπ₯π₯βπ¦π¦π¦π¦(π₯π₯, π¦π¦) and βπ¦π¦βπ₯π₯π₯π₯(π₯π₯, π¦π¦) where the domain for all variables consists of all real numbers. Solution: The quantification βπ₯π₯βπ¦π¦π¦π¦(π₯π₯, π¦π¦) denotes the proposition βFor all real numbers x, for all real numbers y, π₯π₯ + π¦π¦ = π¦π¦ + π₯π₯.β Because ππ(π₯π₯, π¦π¦) is true for all real numbers x and y (it is the commutative law for addition which is an axiom for the real numbers), the proposition βπ₯π₯βπ¦π¦π¦π¦(π₯π₯, π¦π¦) is true. Note that the statement βπ¦π¦βπ₯π₯π₯π₯(π₯π₯, π¦π¦) says βFor all real numbers y, for all real numbers x, π₯π₯ + π¦π¦ = π¦π¦ + π₯π₯.β This has the same meaning as the statement βFor all real numbers x, for all real numbers y, π₯π₯ + π¦π¦ = π¦π¦ + π₯π₯.β That is, βπ₯π₯βπ¦π¦π¦π¦(π₯π₯, π¦π¦) and βπ¦π¦βπ₯π₯π₯π₯(π₯π₯, π¦π¦) have the same meaning, and both are true. This illustrates the principle that the order of nested universal quantifiers in a statement without other quantifiers can be changed without changing the meaning of the quantified statement. 1 Discrete Structures CMSC 2123 EXAMPLE 4 Lecture 5 1.5 Nested Quantifiers Let ππ(π₯π₯, π¦π¦) denote βπ₯π₯ + π¦π¦ = 0.β What are the truth values of the quantifications βπ¦π¦βπ₯π₯π₯π₯(π₯π₯, π¦π¦), where the domain for all variables consists of all real numbers. Solution: The quantification βπ¦π¦βπ₯π₯π₯π₯(π₯π₯, π¦π¦) denotes the proposition βThere is a real number y such that for every real number x, ππ(π₯π₯, π¦π¦).β No matter what value of y is chosen, there is only one value of x for which π₯π₯ + π¦π¦ = 0. Because there is no real number y such that π₯π₯ + π¦π¦ = 0 for all real numbers x, the statement βπ¦π¦βπ₯π₯π₯π₯(π₯π₯, π¦π¦) is false. The quantification βπ₯π₯βπ¦π¦π¦π¦(π₯π₯, π¦π¦) denotes the proposition βFor every real number x there is a real number y such that ππ(π₯π₯, π¦π¦).β Given a real number x, there is a real number y such that π₯π₯ + π¦π¦ = 0; namely, π¦π¦ = βπ₯π₯. Hence, the statement βπ₯π₯βπ¦π¦π¦π¦(π₯π₯, π¦π¦) is true. Example 4 illustrates that the order in which quantifiers appear makes a difference. The statements βπ¦π¦βπ₯π₯π₯π₯(π₯π₯, π¦π¦) and βπ₯π₯βπ¦π¦π¦π¦(π₯π₯, π¦π¦) are not logically equivalent. The statement βπ¦π¦βπ₯π₯π₯π₯(π₯π₯, π¦π¦) is true if and only if there is a y that makes ππ(π₯π₯, π¦π¦) true for every x. So, for this statement to be true, there must be a particular value of y for which ππ(π₯π₯, π¦π¦) is true regardless of the choice of x. On the other hand, βπ₯π₯βπ¦π¦π¦π¦(π₯π₯, π¦π¦) is true if and only if for every value of x there is a value of y for which ππ(π₯π₯, π¦π¦) is true. So, for this statement to be true, no matter which x you choose, there must be a value of y (possibly depending of the x you choose) for which ππ(π₯π₯, π¦π¦) is true. In other words, in the second case, y can depend on x, whereas in the first case y is a constant independent of x. From these observations it follows that if βπ¦π¦βπ₯π₯π₯π₯(π₯π₯, π¦π¦) is true, then βπ₯π₯βπ¦π¦π¦π¦(π₯π₯, π¦π¦) must also be true. However, if βπ₯π₯βπ¦π¦π¦π¦(π₯π₯, π¦π¦) is true, it is not necessary for βπ¦π¦βπ₯π₯π₯π₯(π₯π₯, π¦π¦) to be true. 2 Discrete Structures CMSC 2123 Lecture 5 1.5 Nested Quantifiers TABLE 1 Quantifications of Two Variables. Statement When True? βπ₯π₯βπ¦π¦π¦π¦(π₯π₯, π¦π¦) ππ(π₯π₯, π¦π¦) is true for every pair x, y. βπ¦π¦βπ₯π₯π₯π₯(π₯π₯, π¦π¦) βπ₯π₯βπ¦π¦π¦π¦(π₯π₯, π¦π¦) For every π₯π₯ there is a π¦π¦ for which ππ(π₯π₯, π¦π¦) is true. βπ₯π₯βπ¦π¦π¦π¦(π₯π₯, π¦π¦) There is an x for which ππ(π₯π₯, π¦π¦) is true for every y. βπ₯π₯βπ¦π¦π¦π¦(π₯π₯, π¦π¦) There is a pair π₯π₯, π¦π¦ for which βπ¦π¦βπ₯π₯π₯π₯(π₯π₯, π¦π¦) ππ(π₯π₯, π¦π¦) is true. EXAMPLE 5 When False? There is a pair x, y for which ππ(π₯π₯, π¦π¦) is false. There is an x such that ππ(π₯π₯, π¦π¦) is false for every y. For every x there is a y for which ππ(π₯π₯, π¦π¦) is false. ππ(π₯π₯, π¦π¦) is false for every pair π₯π₯, π¦π¦. Let ππ(π₯π₯, π¦π¦, π§π§) be the statement βπ₯π₯ + π¦π¦ = π§π§.β What are the truth values of the statements βπ₯π₯βπ¦π¦βπ§π§π§π§(π₯π₯, π¦π¦, π§π§) and βπ§π§βπ₯π₯βπ¦π¦π¦π¦(π₯π₯, π¦π¦, π§π§), where the domain of all variables consists of all real numbers? Solution: Suppose that π₯π₯ and π¦π¦ are assigned values. Then, there exists a real number π§π§ such that π₯π₯ + π¦π¦ = π§π§. Consequently, the quantification βπ₯π₯βπ¦π¦βπ§π§π§π§(π₯π₯, π¦π¦, π§π§) which is the statement βFor all real numbers x and for all real numbers y there is a real number z such that π₯π₯ + π¦π¦ = π§π§. " is true. The order of the quantification is important, because the quantification βπ§π§βπ₯π₯βπ¦π¦π¦π¦(π₯π₯, π¦π¦, π§π§) which is the statement βThere is a real number z such that for all real numbers x and for all real numbers y it is true that π₯π₯ + π¦π¦ = π§π§.β is false, because there is no value of z that satisfies the equation π₯π₯ + π¦π¦ = π§π§ for all values of x and y. 3 Discrete Structures CMSC 2123 Lecture 5 1.5 Nested Quantifiers Translating Mathematical Statements into Statements Involving Nested Quantifiers EXAMPLE 6 Translate the statement βThe sum of two positive integers is always positiveβ into a logical expression. Solution: 1. To translate this statement into a logical expression, we first rewrite it so that the implied quantifiers and a domain are shown. βFor every two integers, if these integers are both positive, then the sum of these integers is positive.β 2. Next, we introduce the variables x and y to obtain βFor all positive integers x and y, π₯π₯ + π¦π¦ is positive.β 3. We can express the foregoing as βπ₯π₯βπ¦π¦((π₯π₯ > 0) β§ (π¦π¦ > 0) β (π₯π₯ + π¦π¦ > 0)) where the domain for both variables consists of all integers. 4. Note that we could also translate this using the positive integers as the domain. Then the statement βThe sum of two positive integers is always positiveβ becomes βFor every two positive integers, the sum of these integers is positive. We can express this as βπ₯π₯βπ¦π¦(π₯π₯ + π¦π¦ > 0). 4 Discrete Structures CMSC 2123 Lecture 5 1.5 Nested Quantifiers Translating from Nested Quantifiers into English EXAMPLE 9 Translate the statement βπ₯π₯(πΆπΆ(π₯π₯) β¨ βπ¦π¦π¦π¦(π¦π¦) β§ πΉπΉ(π₯π₯, π¦π¦))) into English, where πΆπΆ(π₯π₯) is the βx has a computer,β πΉπΉ(π₯π₯, π¦π¦) is βx and y are friends,β and the domain for both x and y consists of all students in your school. Solution: The statement says that for every student x in your school, x has a computer or there is a student y such that y has a computer and x and y are friends. In other words, every student in your school has a computer or has a friend who has a computer. Translating English Sentences into Logical Expressions EXAMPLE 11 Express the statement βIf a person is female and is a parent, then this person is someoneβs motherβ as a logical expression involving predicates, quantifiers with a domain consisting of all people, and logical connectives. Solution: 1. πΉπΉ(π₯π₯) βx is female.β 2. ππ(π₯π₯) βx is a parent.β 3. ππ(π₯π₯, π¦π¦) βx is the mother of y.β βπ₯π₯(οΏ½πΉπΉ(π₯π₯) β§ ππ(π₯π₯)οΏ½ β βπ¦π¦π¦π¦(π₯π₯, π¦π¦)) or βπ₯π₯βπ¦π¦(οΏ½πΉπΉ(π₯π₯) β§ ππ(π₯π₯)οΏ½ β ππ(π₯π₯, π¦π¦)) EXAMPLE 13 Use quantifiers to express the statement βThere is a woman who has taken a flight on every airline in the world. Solution: Let ππ(π€π€, ππ) be βw has taken fβ and ππ(ππ, ππ) be βf is a flight on a.β We can express the statement as βπ€π€βππβππ(ππ(π€π€, ππ) β§ ππ(ππ, ππ)), where the domains of discourse for w, f, and a consist of all the women in the world, all airplane flights, and all airlines respectively. 5 Discrete Structures CMSC 2123 Lecture 5 1.5 Nested Quantifiers Negating Nested Quantifiers TABLE 2 De Morganβs Laws for Quantifiers (from section 1.3) Negation Equivalent Statement When Is Negation True? ¬βπ₯π₯π₯π₯(π₯π₯) βπ₯π₯¬ππ(π₯π₯) For every x, ππ(π₯π₯) is false ¬βπ₯π₯π₯π₯(π₯π₯) EXAMPLE 14 EXAMPLE 15 βπ₯π₯¬ππ(π₯π₯) There is an π₯π₯, for which ππ(π₯π₯) is false. When False? There is an π₯π₯, for which ππ(π₯π₯) is true. ππ(π₯π₯) is true for every x. Express the negation of the statement βπ₯π₯βπ¦π¦(π₯π₯π₯π₯ = 1) so that no negation precedes a quantifier. Solution: By successively applying De Morganβs laws for quantifiers in Table 2 of Section 1.3, we can move the negation in ¬βπ₯π₯βπ₯π₯(π₯π₯π₯π₯ = 1) inside all the quantifiers. We find that ¬βπ₯π₯βπ¦π¦(π₯π₯π₯π₯ = 1) is equivalent to βπ₯π₯¬βπ¦π¦(π₯π₯π₯π₯ = 1), which is equivalent to βπ₯π₯βπ¦π¦¬(π₯π₯π₯π₯ = 1). Because ¬(π₯π₯π₯π₯ = 1) can be expressed more simply as π₯π₯π₯π₯ β 1, we conclude that our negated statement can be expressed as βπ₯π₯βπ¦π¦(π₯π₯π₯π₯ β 1) Use quantifiers to express the statement that βThere does not exist a woman who has taken a flight on every airline in the world.β Solution: This statement is the negation of the statement βThere is a woman who has taken a flight on every airline in the world.β from Example 13. By Example 13, our statement can be expressed as ¬βπ€π€βππβπποΏ½ππ(π€π€, ππ) β§ ππ(ππ, ππ)οΏ½, where ππ(π€π€, ππ) be βw has taken fβ and ππ(ππ, ππ) be βf is a flight on a.β By successively applying De Morganβs laws for quantifiers in Table 2 of Section 1.3 to move the negation inside successive quantifiers and by applying De Morganβs low for negating a conjunction in the last step, we find that our statement is equivalent to each of the sequence of statements: Statement Justification Original statement ¬βπ€π€βππβπποΏ½ππ(π€π€, ππ) β§ ππ(ππ, ππ)οΏ½ Table 2 Section 1.3 ¬βπ₯π₯π₯π₯(π₯π₯) β‘ βπ₯π₯¬ππ(π₯π₯) βπ€π€¬βππβπποΏ½ππ(π€π€, ππ) β§ ππ(ππ, ππ)οΏ½ Table 2 Section 1.3 ¬βπ₯π₯π₯π₯(π₯π₯) β‘ βπ₯π₯¬ππ(π₯π₯) βπ€π€βππ¬βπποΏ½ππ(π€π€, ππ) β§ ππ(ππ, ππ)οΏ½ Table 2 Section 1.3 ¬βπ₯π₯π₯π₯(π₯π₯) β‘ βπ₯π₯¬ππ(π₯π₯) βπ€π€βππβππ¬οΏ½ππ(π€π€, ππ) β§ ππ(ππ, ππ)οΏ½ Table 2 Section 1.2 ¬(ππ β§ ππ) β‘ ¬ππ β¨ ¬ππ βπ€π€βππβπποΏ½¬ππ(π€π€, ππ) β¨ ¬ππ(ππ, ππ)οΏ½ This last statement states βFor every woman there is an airline such that for all flights, this woman has not taken that flight or that flight is not on this airline.β 6
© Copyright 2026 Paperzz