In the context of this course, predicates are an opporunity to understand quantifiers and to practice negation of statements. We need some notation to do this, but remembering the notation beyond the course is not a goal. Be aware many textbooks use slightly different notation for these (e.g., using commas instead of \(\ni\) and \(\rightarrow\)).
In order to efficiently communicate logic statements we use predicates. These are simply functions with a codomain of βtrueβ and βfalse.β For example \(R(x)=x\) is red. Thus \(R(\)stop sign\()=\)true and \(R(\)Seawolf logo\()=\)false. More complicated statements can be expressed as well. The following example converts the statement β\(n\) is a positive, even numberβ into symbols using predicates.
For predicates we often ask the questions, βdoes any object satisfy the predicate (condition)β and βwhat is true of all objects that satisfy the predicate (condition).β The first we call existential and use the symbol \(\exists\) for βthere exists.β The second we call universal and use the symbol \(\forall\) for βfor all.β These two questions add quantifiers to logic. Another symbol used is \(\ni\) for βsuch that.β
Write the following statement using predicates and quantifiers. βAll computer science majors must take Introduction to Discrete Mathematics and Data Structures and Algorithms.β
One of the logical operations is negation. We can negate whole statements or parts of statements. A useful skill is to simplify the negation of a statement. This typically enables us to understand the meaning of the negation more easily and to optimize conditional statements.
First we define predicates for each part of the statement.
\begin{align*}
S(x) = \amp x \text{ owns a sail boat.}\\
C(x) = \amp x \text{ has a type rating for the Cessna Citation X.}\\
K(x) = \amp x \text{ likes to cook.}
\end{align*}
In addition to DeMorganβs Laws (negation of and and or), the negations of the two quantifiers are needed. The negation of for all and there exists statements can be recognized from examples. Try the ones below.
\begin{align*}
B(x) = \amp x \text{ is a bee.}\\
F(x) = \amp x \text{ is a flower.}\\
Y(x) = \amp x \text{ is yellow.}\\
L(x,y) = \amp x \text{ likes } y.
\end{align*}
\begin{align*}
U(x) = \amp x \text{ is a bear.}\\
B(x) = \amp x \text{ is a berry.}\\
R(x) = \amp x \text{ is red.}\\
L(x,y) = \amp x \text{ likes } y.
\end{align*}
If you wonder why DeMorganβs law was not applied in the first step, look at the first example. When the \(\exists\) (first clause) is negated, the exists statement becomes a for all statement and the negation is passed over the condition to the next clause. The negation changes exists/for all but does not change their condition.
Negate: \(\forall n \: C(n) \rightarrow \left( \exists m T(m) \ni \left[ R(n,m) \vee S(n,m) \right] \right). \) Meanings for the predicates are not required.
Negate: \(\forall x \: (A(x) \vee B(x)) \rightarrow \left( \exists y C(y) \ni \left[ D(x,y) \vee E(x,y) \right] \right). \) Meanings for the predicates are not required.
These demonstrate the full spectrum of what can happen and will require careful attention to grammar. Negate the following statements and re-write in English.
The following two statements are not logically equivalent. Demonstrate why by finding a case that is true for one statement but false for the other statement.