Download presentation
Presentation is loading. Please wait.
1
Discrete Mathematics Lecture # 2
2
Truth Table ~ p q ~ p (q ~ r) (pq) ~ (pq)
3
Truth Table Truth table for the statement form ~ p q
4
Truth Table Truth table for ~ p (q ~ r)
5
Truth Table Truth table for (pq) ~ (pq)
6
Exclusive OR When or is used in its exclusive sense, the statement “p or q” means “p or q but not both” or “p or q and not p and q” which translates into symbols as: p q p XOR q
7
Exclusive OR- Truth Table
p q pq pq ~ (pq) (pq) ~ (pq) T F
8
Double Negation ~(~p) p Same truth value
9
Examples Rewrite in a simpler form
“It is not true that I am not happy” Solution: Let p = “I am happy” then ~ p = “I am not happy” and ~(~ p) = “It is not true that I am not happy” Since ~ (~p) p Hence the given statement is equivalent to: “I am happy”
10
Examples ~ (pq) and ~p ~q are not logically equivalent
11
De Morgan’s Law The negation of an and statement is logically equivalent to the or statement in which each component is negated. Symbolically ~(p q) ~p ~q.
12
De Morgan’s Law The negation of an or statement is logically equivalent to the and statement in which each component is negated. Symbolically: ~(p q) ~p ~q
13
Proof ~(p q) ~p ~q Same truth values
14
Application Give negations for each of the following statements:
The fan is slow or it is very hot. Akram is unfit and Saleem is injured. Solution The fan is not slow and it is not very hot. Akram is not unfit or Saleem is not injured.
15
Inequalities & De Morgan’s Law
Use DeMorgan’s Laws to write the negation of -1 < x 4 for some particular real no. x -1 < x 4 means x > –1 and x 4 By DeMorgan’s Law, the negation is: x > –1 or x 4 Which is equivalent to: x –1 or x > 4
16
Exercise (p q) r p (q r)
Are the statements (pq)r and p (q r) logically equivalent?
17
Tautology A tautology is a statement form that is always true regardless of the truth values of the statement variables. A tautology is represented by the symbol “T”..
18
Example The statement form p ~ p is tautology p ~p t
19
Contradiction A contradiction is a statement form that is always false regardless of the truth values of the statement variables. A contradiction is represented by the symbol “c”.
20
Example p ~p c The statement form p ~ p is a contradiction. p ~ p
21
Exercise Use truth table to show that (p q) (~p (p ~q)) is a tautology. p Q p q ~ p ~ q p ~ q ~ p (p ~q) (p q) (~p (p ~q)) T F
22
Exercise Use truth table to show that (p ~q) (~pq) is a contradiction. p q ~q p~q ~p ~pq (p ~q) (~pq) T F
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.