Presentation is loading. Please wait.

Presentation is loading. Please wait.

Foundations of Discrete Mathematics Chapter 1 By Dr. Dalia M. Gil, Ph.D.

Similar presentations


Presentation on theme: "Foundations of Discrete Mathematics Chapter 1 By Dr. Dalia M. Gil, Ph.D."— Presentation transcript:

1 Foundations of Discrete Mathematics Chapter 1 By Dr. Dalia M. Gil, Ph.D.

2 Truth Tables  Statement means a statement of fact that is either true or false.  Let p and q be statements.

3 Truth Tables 1.The compound statements “p or q” is written (p q) “p and q” is written (p  q) 2. The truth values of these compound statements depend on those of p and q can be neatly summarized by tables called truth tables.

4 Truth Tables for (p  q) and (p  q) Possible values for p and q. The values for p and q- each either true (T) or false (F). p and q p or q

5 A Truth Table for the Implication p  q p  q is false if p is T (true) and q is F (false).

6 A Truth Table for the negation of p “¬p” if p is T (true) then ¬p is F (false).

7 A Truth Table for Compound Statements The first two columns and the last column are the most important.

8 A Truth Table for Double Implication p  q is true if both p and q are true or are false

9 A Truth Table for p  ¬(p  q) The procedure is to construct appropriate columns one by one until the answer is reached.

10 A Truth Table for p  ¬(p  q) First, obtain p  q

11 A Truth Table for p  ¬(p  q) Second, obtain ¬(p  q)

12 A Truth Table for p  ¬(p  q) Third, obtain p  ¬(p  q) from the first and the fourth columns

13 p  q  [((¬p)  r) (q  r)] There are three statements p, q, and r

14 p  q  [((¬p)  r) (q  r)] Obtain ¬p from p

15 p  q  [((¬p)  r) (q  r)] Obtain the compound statement (¬p)  r

16 p  q  [((¬p)  r) (q  r)] Obtain q  r

17 p  q  [((¬p)  r) (q  r)]  Obtain the compound statement ((¬p)  r) (q  r)

18 p  q  [((¬p)  r) (q  r)] Obtain the statement p  q

19 p  q  [((¬p)  r) (q  r)]  Obtain the compound statement p  q  [((¬p)  r) (q  r)]

20 p  q is false when the values of p, q are T, F. p  q  [((¬p)  r) (q  r)]

21 [p ((q (¬r))  s]  [(¬t) (s  r)]  Where p, q, r, and s are all true while t is false.  Obtain the statements (¬r), (q (¬r)), and (p ((q (¬r))  s)

22 [p ((q (¬r))  s]  [(¬t) (s  r)]  Obtain the statements (¬t), (s r), and (¬t)  (s  r)

23 [p ((q (¬r))  s]  [(¬t) (s  r)]  Obtain the compound statement [p ((q (¬r))  s]  [(¬t) (s  r)]

24 [p ((q (¬r))  s]  [(¬t) (s  r)]  True

25 Logical Equivalence  Two statements are logically equivalent if they have identical truth tables.

26 Logical Equivalence  A: p  (¬q) and B: ¬(p  q) are identical  A  B: A and B are logically equivalent.

27 Tautology  A tautology is a compound statement that is always true, regardless of the truth values assigned to its variables.  Let A: p  (¬q) and B: ¬(p  q) A and B are logically equivalent when A  B is a tautology.

28 Contradiction  A Contradiction is a compound statement that is always false.

29 Proposition 1.A proposition is a synonym for (mathematical) statement. 2.A proposition is a statement of fact that is either true or false.

30 Proposition  Let p and q be propositions.  The proposition “p and q,” or p  q, is true when both p and q are true, and false when one of p or q is false.  p  q is called the conjunction of p and q.

31 Proposition 1.Let p and q be propositions. 2.The propositions “p or q,” or p  q, is false when p and q are both false and true otherwise. 3.The proposition p  q is called the disjunction of p and q.

32 Some Basic Logical Equivalences 1.Idempotence: 1.(p  q)  p 2.(p  p)  p  denotes logical equivalence

33 Some Basic Logical Equivalences 2. Commutative: 1.(p  q)  (q  p) 2.(p  q)  (q  p)

34 Some Basic Logical Equivalences 3. Associativity: 1.((p  q)  r)  p  (q  r)) 2.((p  q)  r)  (p  (q  r))

35 Some Basic Logical Equivalences 4. Distributivity: 1.(p  (q  r))  ((p  q)  (p  r)) 2.(p  (q  r))  ((p  q)  (p  r))

36 Some Basic Logical Equivalences 5. Double Negation: 1.¬(¬p) p 6. De Morgan’s Laws: 1.¬(p  q)  ((¬p)  (¬q)) 2.¬(p  q)  ((¬p)  (¬q))

37 Some Basic Logical Equivalences  Any two tautologies are logically equivalent.  Any two contradictions are logically equivalent.  Letting 1 denote a tautology and 0 a contradiction.

38 Some Basic Logical Equivalences 7. 1.(p  1) 1 2.(p  1) p 8. 1.(p  0) p 2.(p  0) 0

39 Some Basic Logical Equivalences 9. 1.(p  (¬p)) 1 2.(p  (¬p)) 0 10. 1.(¬1)  0 2.(¬0)  1

40 Some Basic Logical Equivalences 11. (p  q)  [(¬q)  (¬p)] 12. (p  q)  [(¬p)  q] 13. (p  q)  [(p  q)  (q  p)]

41 Show that (¬p) (p  q) is a tautology Using property 12 (p  q)  [(¬p)  q]  [(¬(¬p)  ((¬p)  q)]  p  [(¬p)  q]  [p  (¬p)]  q 1  q 1 [(¬p) (p  q)]  [(¬p)  ((¬p)  q)]

42 Verify the idempotence property (p  p)  p

43 Verify the second distributive property (p  (q  r))  ((p  q)  (p  r))

44 Simplify the following statement [¬(p  q)]  [(¬p)  q]  [[(¬p)  (¬q)]  [(¬p)  q]]  by one of the laws of De Morgan using distributive law.

45 Simplify the following statement  [[(¬p)  (¬q)]  [(¬p)  q]]  (¬p)  [(¬q)  q]  (¬p)  1  ¬p so the given statement is logically equivalent simply to ¬p

46 Theorem 1.2.1 Suppose A and B are logically equivalent statements involving variables p 1, p 2 …, p n. Suppose that C 1, C 2,.., C n are statements. If, in A and B, we replace p 1 by C 1, p 2 by C 2, and so on until we replace p n by C n, then the resulting statements will still be logically equivalent.

47 Show that [(p  q)  ((q  (¬r))  (p  r))]  ¬[(¬p) (¬q)] Using one of the distributive laws, the left- hand side is logically equivalent to [(p  q)  (q  (¬r))]  [(p  q)  (p  r)]

48 Associativity and idempotence say that the first term here [(p  q)  (q  (¬r))] is logically equivalent to [p  (q  (q  (¬r)))]  [p  ((q  q)  (¬r)))]  [p  (q  (¬r))]  [(p  q)  (¬r)] [(p  q)  ((q  (¬r))  (p  r))]  ¬[(¬p) (¬q)]

49 [(q  p)  (p  r)]  [q  (p  (p  r))]  [q  ((p  p)  r)]  [q  (p  r)]  [(p  q)  r] [(p  q)  ((q  (¬r))  (p  r))]  ¬[(¬p) (¬q)] The second term [(p  q)  (p  r)] is logically equivalent to  [q  (p  r)]

50 [((p  q)  (¬ r)  ((p  q)  r) ]   [(p  q)  0]  p  q [(p  q)  ((q  (¬r))  (p  r))]  ¬[(¬p) (¬q)] The expression on he left-hand side of the statement is logically equivalent to  [(p  q)  (¬ r)  r)]

51 [((p  q)  (¬ r)  ((p  q)  q) ]  [(p  q)  0]  p  q [(p  q)  ((q  (¬r))  (p  r))]  ¬[(¬p) (¬q)] Logically equivalent to the right-hand side of the desired statement 

52 [(p  q)  ((q  (¬r))  (p  r))]  ¬[(¬p) (¬q)] De Morgan’s Laws: ¬(p  q)  ((¬p)  (¬q)) by double negation and one of the laws of De Morgan. p  q 

53  A theorem is a statement that can be shown to be true (theorems are sometimes called propositions, facts, or results.)  Proof is a sequence of statements that form an argument to demonstrate a theorem. Logical arguments

54  The statements used in a proof can include axioms or postulates.  They are the underlying assumptions about mathematical structures, the hypotheses of the theorem to be proved, and previously proved theorems. Logical arguments

55  The rules of inference, which are the means used to draw conclusions from other assertions, tie together the steps of a proof. Logical arguments

56  A lemma (plural lemmas or lemmata) is a simple theorem used in the proof of other theorems.  Complicated proofs are usually easier to understand when they are proved using a series of lemmas, where each lemma is proved individually. Logical arguments

57  A corollary is a proposition that can be established directly from a theorem that has been proved.  A conjecture is a statement whose truth value is unknown. When a proof of a conjecture is found, the conjecture becomes a theorem. Conjectures are shown to be false, so they are not theorem. Logical arguments

58  An argument is a finite collection of statements A 1, A 2, …, A n called premises (or hypotheses) followed by a statement B called the conclusion.  An argument is valid if, whenever A 1, A 2, …, A n are all true, then B is also true. An Argument

59 p  ¬q r  q ______ ¬q is valid Show that the argument  The solution requires the construction of a truth table

60 row 3 is the only row where the premises are all true. p  ¬q (T) r  q (T) r (T) p  ¬q r  q ______ ¬q

61 p  ¬q r  q ______ ¬q  The argument can be shown to be valid without the construction of a truth table.  Assume that all premises are true. r is true, r  q is also true, q must also be true.  Thus ¬q is false and, because p  (¬q) is true, p is false. Thus ¬p is true as desired.

62 If I like biology, then I will study it. Either I study biology or I fail the course. ___________________________________ If I fail the course, then I do not like biology Determine whether the following argument is valid.  Let p, q, and r be the statements.

63 p  q q  r _______ r  (¬p)  p: “I like biology,”  q: “I study biology,” and  r: “I fail the course.” Solution

64 The analysis by means a truth table 5 rows where the premises are all true.

65  An argument with premises A 1, A 2, …, A n and conclusion B is valid precisely when the compound statement A 1  A 2  …  A n B is a tautology. Theorem 1.3.2

66  Substitution: Assume that an argument with premises A 1, A 2, …, A n and conclusion B is valid and that all these statements involves variables p 1, p 2 …, p n. If p 1, p 2 …, p n are replaced by statements C 1, C 2, …, C n, the resulting argument is still valid. Theorem 1.3.3

67  Rules of inference provide the justification of the steps used to show that a conclusion follows logically from a set of hypotheses. Rules of Inference

68  The tautology (p  (p  q) )  q  is the basis of the rule of inference called modus ponens, or the law of detachment.  This tautology is written in the following way: Rules of Inference

69

70

71 P p  q ______ q The symbol denotes “therefore” Modus ponens states that if both an implication and its hypothesis are known to be true, then conclusion of this implication is true. Modus Ponens

72  “If it snows today, then will go skiing”  The hypothesis, “it is snowing today”, is true,  then by modus ponens, it follows that the conclusion of this implication “we will go skiing,” is true. Example

73  “If n is greater than 3, then n 2 is greater than 9” is true.  Consequently, if n is greater than 3, then by modus ponens, it follows that n 2 is greater than 9. Example

74  State which rule of inference is the basis of the following argument:  “it is below freezing now. Therefore, it is either below freezing or raining now.”  Solution: Let p and q be propositions. Example

75 p: “It is below freezing now,” q: “It is raining now.” Then this argument is of the form p ______  p  q  This argument uses the addition rule. Solution

76  State which rule of inference is the basis of the following argument: “It is below freezing and raining now. Therefore, it is below freezing now.”  Solution: Let p and q be propositions. Example

77 p: “It is below freezing now” q: “It is raining now.” This argument is of the form p  q ______  p  This argument uses the simplification rule. Solution

78 (p  q)  (s  t) [¬((¬s)  (¬t))] [(¬r)  q] _______________________________________________ (p  q) (r  q) Show that the following argument is valid

79 (p  q)  (s  t) [¬((¬s)  (¬t))] [(¬r)  q] ___________________________ (p  q) (r  q) One of De Morgan and the principle of double negation tell us that [¬((¬s)  (¬t))]  [(¬(¬s))  (¬(¬t))]  (s  t)

80 (p  q)  (s  t) [¬((¬s)  (¬t))] [(¬r)  q] ___________________________ (p  q) (r  q) Property 12 of logical equivalence says that [(¬r)  q] (r  q) (p  q (s  t) (s  t) (r  q) _______________________ (p  q) (r  q) The chain rule now tells us that our argument is valid.

81 Determine the validity of the following argument If I study, then I will pass. If I do not go to a movie, then I will study. I failed ___________________________________ Therefore, I went to a movie.

82 Let p, q, and r be the statements  p: “I study,”  q: “I pass,” and  r: “I go to a movie.” p  q (¬r)  q ¬q __________ r

83 Let p, q, and r be the statements  The first two premises imply the truth of (¬r)  q by the chain rule.  Since (¬r)  q and ¬q imply ¬ (¬r) by modus tollens  The validity of the argument follows by the principle of double negation: ¬ (¬r)  r p  q (¬r)  q ¬q __________ r

84 Topics covered  Truth Tables.  The Algebra of Propositions. Basic logical equivalences  Logical Arguments. Rules of inference

85 Reference  “Discrete Mathematics with Graph Theory”, Third Edition, E. Goodaire and Michael Parmenter, Pearson Prentice Hall, 2006. pp 19-37.


Download ppt "Foundations of Discrete Mathematics Chapter 1 By Dr. Dalia M. Gil, Ph.D."

Similar presentations


Ads by Google