Discrete Mathematics and Applications COT3100

Size: px
Start display at page:

Download "Discrete Mathematics and Applications COT3100"

Transcription

1 Discrete Mathematics and Applications CO3100 Dr. Ungor Sources: Slides are based on Dr. G. Bebis material. uesday, January 7, 2014

2 oundations of Logic: Overview Propositional logic: (Sections ) Basic definitions. Equivalence rules & derivations. Predicate logic (Section 1.4) Predicates. Quantified predicate expressions. Equivalences & derivations. CO Dr. Ungor 2 uesday, January 7, 2014

3 Propositional Logic Propositional Logic is the logic of compound statements built from simpler statements using Boolean connectives. Applications: Design of digital electronic circuits. Expressing conditions in computer programs. Queries to databases & search engines. CO Dr. Ungor 3 uesday, January 7, 2014

4 Propositional Logic Propositional Logic is the logic of compound statements built from simpler statements using Boolean connectives. What are Propositions? What are Boolean connectors? CO Dr. Ungor uesday, January 7, 2014

5 Definition of a Proposition CO Dr. Ungor 5 uesday, January 7, 2014

6 Definition of a Proposition A proposition (p, q, r, ) is simply a statement (i.e., a declarative sentence) with a definite meaning, having a truth value thatʼs either true () or false () (never both, neither, or somewhere in between). CO Dr. Ungor 5 uesday, January 7, 2014

7 Definition of a Proposition A proposition (p, q, r, ) is simply a statement (i.e., a declarative sentence) with a definite meaning, having a truth value thatʼs either true () or false () (never both, neither, or somewhere in between). In probability theory, we assign degrees of certainty to propositions. or now: rue/alse only! CO Dr. Ungor 5 uesday, January 7, 2014

8 Examples of Propositions CO Dr. Ungor 6 uesday, January 7, 2014

9 Examples of Propositions It is raining. (Given a situation.) CO Dr. Ungor 6 uesday, January 7, 2014

10 Examples of Propositions It is raining. (Given a situation.) Beijing is the capital of China. CO Dr. Ungor 6 uesday, January 7, 2014

11 Examples of Propositions It is raining. (Given a situation.) Beijing is the capital of China = 5 CO Dr. Ungor 6 uesday, January 7, 2014

12 Examples of Propositions It is raining. (Given a situation.) Beijing is the capital of China = 5 he following are NO propositions: CO Dr. Ungor 6 uesday, January 7, 2014

13 Examples of Propositions It is raining. (Given a situation.) Beijing is the capital of China = 5 he following are NO propositions: Whoʼs there? (interrogative, question) CO Dr. Ungor 6 uesday, January 7, 2014

14 Examples of Propositions It is raining. (Given a situation.) Beijing is the capital of China = 5 he following are NO propositions: Whoʼs there? (interrogative, question) La la la la la. (meaningless interjection) CO Dr. Ungor 6 uesday, January 7, 2014

15 Examples of Propositions It is raining. (Given a situation.) Beijing is the capital of China = 5 he following are NO propositions: Whoʼs there? (interrogative, question) La la la la la. (meaningless interjection) Just do it! (imperative, command) CO Dr. Ungor 6 uesday, January 7, 2014

16 Examples of Propositions It is raining. (Given a situation.) Beijing is the capital of China = 5 he following are NO propositions: Whoʼs there? (interrogative, question) La la la la la. (meaningless interjection) Just do it! (imperative, command) Yeah, I sorta dunno, whatever... (vague) CO Dr. Ungor 6 uesday, January 7, 2014

17 Examples of Propositions It is raining. (Given a situation.) Beijing is the capital of China = 5 he following are NO propositions: uesday, January 7, 2014 Whoʼs there? (interrogative, question) La la la la la. (meaningless interjection) Just do it! (imperative, command) Yeah, I sorta dunno, whatever... (vague) CO Dr. Ungor (expression with a non-true/false value) 6

18 Boolean operators Negation (NO) Implication (I) Conjunction (AND) Disjunction (OR) Exclusive-Or (XOR) Bi-conditional (I) CO Dr. Ungor uesday, January 7, 2014

19 Operators / Connectives An operator or connective combines one or more operand expressions into a larger expression. (e.g., + in numeric exprs.) Unary operators take 1 operand (e.g., -3); binary operators take 2 operands (e.g., 3 4). Propositional or Boolean operators operate on propositions or truth values instead of on numbers. CO Dr. Ungor 8 uesday, January 7, 2014

20 he Negation Operator he unary negation operator (NO) transforms a prop. into its logical negation. Example: If p = I have brown hair., then p = I do not have brown hair. ruth table for NO: CO Dr. Ungor 9 uesday, January 7, 2014

21 he Conjunction Operator he binary conjunction operator (AND) combines two propositions to form their logical conjunction. E.g., If p= I will have salad for lunch. and q= I will have steak for dinner., then p q= I will have salad for lunch and I will have steak for dinner. CO Dr. Ungor 10 uesday, January 7, 2014

22 Conjunction ruth able CO Dr. Ungor 11 uesday, January 7, 2014

23 Conjunction ruth Note that a conjunction p 1 p 2 p n of n propositions will have 2 n rows in its truth table. able and operations together are universal, i.e., sufficient to express any truth table! CO Dr. Ungor 11 uesday, January 7, 2014

24 he Disjunction Operator he binary disjunction operator (OR) combines two propositions to form their logical disjunction. p= hat car has a bad engine. q= hat car has a bad carburetor. p q= Either that car has a bad engine, or that car has a bad carburetor. CO Dr. Ungor 12 uesday, January 7, 2014

25 Disjunction ruth able CO Dr. Ungor 13 uesday, January 7, 2014

26 Disjunction ruth Note that p q means that p is true, or q is true, or both are true! So this operation is also called inclusive or, because it includes the able possibility that both p and q are true. and together are also universal. CO Dr. Ungor 13 uesday, January 7, 2014

27 A Simple Exercise Let p= It rained last night, q= he sprinklers came on last night, r= he lawn was wet this morning. ranslate each of the following into English: p = r p = r p q = CO Dr. Ungor 14 uesday, January 7, 2014

28 A Simple Exercise Let p= It rained last night, q= he sprinklers came on last night, r= he lawn was wet this morning. ranslate each of the following into English: p = It didn t rain last night. r p = r p q = CO Dr. Ungor 14 uesday, January 7, 2014

29 A Simple Exercise Let p= It rained last night, q= he sprinklers came on last night, r= he lawn was wet this morning. ranslate each of the following into English: p = r p = r p q = CO Dr. Ungor 14 uesday, January 7, 2014

30 A Simple Exercise Let p= It rained last night, q= he sprinklers came on last night, r= he lawn was wet this morning. ranslate each of the following into English: p = r p = he lawn was wet this morning, and it didn t rain last night. r p q = CO Dr. Ungor 14 uesday, January 7, 2014

31 A Simple Exercise Let p= It rained last night, q= he sprinklers came on last night, r= he lawn was wet this morning. ranslate each of the following into English: p = r p = r p q = CO Dr. Ungor 14 uesday, January 7, 2014

32 A Simple Exercise Let p= It rained last night, q= he sprinklers came on last night, r= he lawn was wet this morning. ranslate each of the following into English: p = r p = r p q = CO Dr. Ungor Either the lawn wasn t wet this morning, or it rained last night, or the sprinklers came on last night. 14 uesday, January 7, 2014

33 he Exclusive Or Operator he binary exclusive-or operator (XOR) combines two propositions to form their logical exclusive or (exjunction?). p = I will earn an A in this course, q = I will drop this course, p q = I will either earn an A for this course, or I will drop it (but not both!) CO Dr. Ungor 15 uesday, January 7, 2014

34 Exclusive-Or ruth Note that p q means that p is true, or q is true, but not both! his operation is called exclusive or, able because it excludes the possibility that both p and q are true. and together are not universal. CO Dr. Ungor 16 uesday, January 7, 2014

35 Natural Language is Ambiguous Note that in English or is by itself ambiguous regarding the both case! Pat is a singer or Pat is a writer. - Pat is rich or Pat is poor. - Need context to disambiguate the meaning! or this class, assume or means inclusive. CO Dr. Ungor 17 uesday, January 7, 2014

36 Natural Language is Ambiguous Note that in English or is by itself ambiguous regarding the both case! Pat is a singer or Pat is a writer. - Pat is rich or Pat is poor. - Need context to disambiguate the meaning! or this class, assume or means inclusive. CO Dr. Ungor 17 uesday, January 7, 2014

37 Natural Language is Ambiguous Note that in English or is by itself ambiguous regarding the both case! Pat is a singer or Pat is a writer. - Pat is rich or Pat is poor. - Need context to disambiguate the meaning! or this class, assume or means inclusive. CO Dr. Ungor 17 uesday, January 7, 2014

38 he Implication Operator he implication p q states that p implies q. It is ALSE only in the case that p is RUE but q is ALSE. e.g., p= I am elected. q= axes will be lowered. p q = If I am elected, then taxes will be lowered (else it could go either way) CO Dr. Ungor 18 uesday, January 7, 2014

39 he Implication Operator erminology for the structure of implication p q p: Hypothesis (antecedent or premise) q: Conclusion (consequence) CO Dr. Ungor 19 uesday, January 7, 2014

40 Implication ruth able CO Dr. Ungor 20 uesday, January 7, 2014

41 Implication ruth able p q is false only when p is true but q is not true. CO Dr. Ungor 20 uesday, January 7, 2014

42 Implication ruth able p q is false only when p is true but q is not true. p q does not imply that p causes q! CO Dr. Ungor 20 uesday, January 7, 2014

43 Implication ruth able p q is false only when p is true but q is not true. p q does not imply that p causes q! p q does not imply that p or q are ever true! CO Dr. Ungor 20 uesday, January 7, 2014

44 Implication ruth able p q is false only when p is true but q is not true. p q does not imply that p causes q! p q does not imply that p or q are ever true! E.g. (1=0) pigs can fly is RUE! CO Dr. Ungor 20 uesday, January 7, 2014

45 Examples of Implications If this lecture ends, then the sun will rise tomorrow. rue or alse? If Monday is a day of the week, then I am a not teacher. rue or alse? If 1+1=6, then George passed the exam. rue or alse? If the moon is made of green cheese, then I am richer than Bill Gates. rue or alse? CO Dr. Ungor 21 uesday, January 7, 2014

46 Examples of Implications If this lecture ends, then the sun will rise tomorrow. rue or alse? If Monday is a day of the week, then I am a not teacher. rue or alse? If 1+1=6, then George passed the exam. rue or alse? If the moon is made of green cheese, then I am richer than Bill Gates. rue or alse? CO Dr. Ungor 21 uesday, January 7, 2014

47 Examples of Implications If this lecture ends, then the sun will rise tomorrow. rue or alse? If Monday is a day of the week, then I am a not teacher. rue or alse? If 1+1=6, then George passed the exam. rue or alse? If the moon is made of green cheese, then I am richer than Bill Gates. rue or alse? CO Dr. Ungor 21 uesday, January 7, 2014

48 Examples of Implications If this lecture ends, then the sun will rise tomorrow. rue or alse? If Monday is a day of the week, then I am a not teacher. rue or alse? If 1+1=6, then George passed the exam. rue or alse? If the moon is made of green cheese, then I am richer than Bill Gates. rue or alse? CO Dr. Ungor 21 uesday, January 7, 2014

49 Examples of Implications If this lecture ends, then the sun will rise tomorrow. rue or alse? If Monday is a day of the week, then I am a not teacher. rue or alse? If 1+1=6, then George passed the exam. rue or alse? If the moon is made of green cheese, then I am richer than Bill Gates. rue or alse? CO Dr. Ungor 21 uesday, January 7, 2014

50 Inverse, Converse, Contrapositive Some terminology: he inverse of p q is: p q he converse of p q is: q p. he contrapositive of p q is: q p. CO Dr. Ungor 22 uesday, January 7, 2014

51 Inverse, Converse, Contrapositive Some terminology: he inverse of p q is: p q he converse of p q is: q p. he contrapositive of p q is: q p. One of these has the same meaning (same truth table) as p q. Can you figure out which? CO Dr. Ungor 22 uesday, January 7, 2014

52 Inverse, Converse, Contrapositive Some terminology: he inverse of p q is: p q he converse of p q is: q p. he contrapositive of p q is: q p. One of these has the same meaning (same truth table) as p q. Can you figure out which? CO Dr. Ungor Contrapositive 22 uesday, January 7, 2014

53 How do we know for sure? Proving the equivalence of p q and its contrapositive using truth tables: CO Dr. Ungor 23 uesday, January 7, 2014

54 he biconditional operator CO Dr. Ungor 24 uesday, January 7, 2014

55 he biconditional operator he biconditional p q states that p is true if and only if (I) q is true. CO Dr. Ungor 24 uesday, January 7, 2014

56 he biconditional operator he biconditional p q states that p is true if and only if (I) q is true. It is RUE only when both p q and q p are RUE. CO Dr. Ungor 24 uesday, January 7, 2014

57 he biconditional operator he biconditional p q states that p is true if and only if (I) q is true. It is RUE only when both p q and q p are RUE. p = It is raining. CO Dr. Ungor 24 uesday, January 7, 2014

58 he biconditional operator he biconditional p q states that p is true if and only if (I) q is true. It is RUE only when both p q and q p are RUE. p = It is raining. q = he home team wins. CO Dr. Ungor 24 uesday, January 7, 2014

59 he biconditional operator he biconditional p q states that p is true if and only if (I) q is true. It is RUE only when both p q and q p are RUE. p = It is raining. q = he home team wins. p q = If and only if it is raining, the home team wins. CO Dr. Ungor 24 uesday, January 7, 2014

60 Biconditional ruth able CO Dr. Ungor 25 uesday, January 7, 2014

61 Biconditional ruth able p q means that p and q have the same truth value. CO Dr. Ungor 25 uesday, January 7, 2014

62 Biconditional ruth able p q means that p and q have the same truth value. Note this truth table is the exact opposite of ʼs! CO Dr. Ungor 25 uesday, January 7, 2014

63 Biconditional ruth able p q means that p and q have the same truth value. Note this truth table is the exact opposite of ʼs! p q means (p q) CO Dr. Ungor 25 uesday, January 7, 2014

64 Biconditional ruth able p q means that p and q have the same truth value. Note this truth table is the exact opposite of ʼs! p q means (p q) p q does not imply p and q are true, or cause each other. CO Dr. Ungor 25 uesday, January 7, 2014

65 Boolean Operations Summary We have seen 1 unary operator and 5 binary operators. CO Dr. Ungor 26 uesday, January 7, 2014

66 Precedence of Logical Operators Operator Precedence CO Dr. Ungor 27 uesday, January 7, 2014

67 Nested Propositional Expressions Use parentheses to group sub-expressions: I just saw my old friend, and either heʼs grown or Iʼve shrunk. = f (g s) (f g) s would mean something different f g s would be ambiguous By convention, takes precedence over both and. s f means ( s) f, not (s f) CO Dr. Ungor 28 uesday, January 7, 2014

68 Some Alternative Notations CO Dr. Ungor 29 uesday, January 7, 2014

69 Bits and Bit Operations A bit is a binary (base 2) digit: 0 or 1. By convention: 1 represents true ; Bits may be used to represent truth values. 0 represents false. Boolean algebra is like ordinary algebra except that variables stand for bits, + means or, and multiplication means and. CO Dr. Ungor 30 uesday, January 7, 2014

70 Bit Strings A Bit string of length n is an ordered series or sequence of n 0 bits. By convention, bit strings are written left to right: e.g. the first bit of is 1. When a bit string represents a base-2 number, by convention the first bit is the most significant bit. Ex =8+4+1=13. CO Dr. Ungor 31 uesday, January 7, 2014

71 Bitwise Operations Boolean operations can be extended to operate on bit strings as well as single bits. E.g.: Bit-wise OR Bit-wise AND Bit-wise XOR CO Dr. Ungor 32 uesday, January 7, 2014

72 Propositional Equivalences CO Dr. Entezari uesday, January 7, 2014

73 Propositional Equivalence wo syntactically (i.e., textually) different compound propositions may be semantically identical (i.e., have the same meaning). We call them equivalent. NEX: Learn about various equivalence rules or laws. Learn how to prove equivalences using symbolic derivations. CO Dr. Ungor 34 uesday, January 7, 2014

74 autologies and Contradictions CO Dr. Ungor 35 uesday, January 7, 2014

75 autologies and Contradictions A tautology is a compound proposition that is true no matter what the truth values of its atomic propositions are! CO Dr. Ungor 35 uesday, January 7, 2014

76 autologies and Contradictions A tautology is a compound proposition that is true no matter what the truth values of its atomic propositions are! Ex. p p [What is its truth table?] CO Dr. Ungor 35 uesday, January 7, 2014

77 autologies and Contradictions A tautology is a compound proposition that is true no matter what the truth values of its atomic propositions are! Ex. p p [What is its truth table?] A contradiction is a comp. prop. that is false no matter what! Ex. p p [ruth table?] CO Dr. Ungor 35 uesday, January 7, 2014

78 autologies and Contradictions A tautology is a compound proposition that is true no matter what the truth values of its atomic propositions are! Ex. p p [What is its truth table?] A contradiction is a comp. prop. that is false no matter what! Ex. p p [ruth table?] Other comp. props. are contingencies. CO Dr. Ungor 35 uesday, January 7, 2014

79 Proving Equivalences CO Dr. Ungor 36 uesday, January 7, 2014

80 Proving Equivalences Compound propositions P and Q are logically equivalent to each other I P and Q contain the same truth values as each other in all rows of their truth tables. CO Dr. Ungor 36 uesday, January 7, 2014

81 Proving Equivalences Compound propositions P and Q are logically equivalent to each other I P and Q contain the same truth values as each other in all rows of their truth tables. Compound proposition P is logically equivalent to compound proposition Q, written P Q, I the compound proposition P Q is a tautology. CO Dr. Ungor 36 uesday, January 7, 2014

82 Proving Equivalence via ruth ables P Q Ex. Prove that } } p q ( p q). Ex Ex. Prove that p q ( p q). Ex. Prove that p q ( p q).. Prove thex. Prove that pq ( p q). at p q ( p q). CO Dr. Ungor 37 uesday, January 7, 2014

83 Proving Equivalence via ruth ables P Q Ex. Prove that } } p q ( p q). Ex Ex. Prove that p q ( p q). Ex. Prove that p q ( p q).. Prove thex. Prove that pq ( p q). at p q ( p q). CO Dr. Ungor 37 uesday, January 7, 2014

84 Proving Equivalence via ruth ables P Q Ex. Prove that } } p q ( p q). Ex Ex. Prove that p q ( p q). Ex. Prove that p q ( p q).. Prove thex. Prove that pq ( p q). at p q ( p q). CO Dr. Ungor 37 uesday, January 7, 2014

85 Proving Equivalence via ruth ables P Q Ex. Prove that } } p q ( p q). Ex Ex. Prove that p q ( p q). Ex. Prove that p q ( p q).. Prove thex. Prove that pq ( p q). at p q ( p q). CO Dr. Ungor 37 uesday, January 7, 2014

86 Proving Equivalence via ruth ables P Q Ex. Prove that } } p q ( p q). Ex Ex. Prove that p q ( p q). Ex. Prove that p q ( p q).. Prove thex. Prove that pq ( p q). at p q ( p q). CO Dr. Ungor 37 uesday, January 7, 2014

87 Proving Equivalence via ruth ables P Q Ex. Prove that } } p q ( p q). Ex Ex. Prove that p q ( p q). Ex. Prove that p q ( p q).. Prove thex. Prove that pq ( p q). at p q ( p q). CO Dr. Ungor 37 uesday, January 7, 2014

88 Proving Equivalence via ruth ables P Q Ex. Prove that } } p q ( p q). Ex Ex. Prove that p q ( p q). Ex. Prove that p q ( p q).. Prove thex. Prove that pq ( p q). at p q ( p q). CO Dr. Ungor 37 uesday, January 7, 2014

89 Proving Equivalence via ruth ables P Q Ex. Prove that } } p q ( p q). Ex Ex. Prove that p q ( p q). Ex. Prove that p q ( p q).. Prove thex. Prove that pq ( p q). at p q ( p q). CO Dr. Ungor 37 uesday, January 7, 2014

90 Proving Equivalence via ruth ables P Q Ex. Prove that } } p q ( p q). Ex Ex. Prove that p q ( p q). Ex. Prove that p q ( p q).. Prove thex. Prove that pq ( p q). at p q ( p q). CO Dr. Ungor 37 uesday, January 7, 2014

91 Proving Equivalence via ruth ables P Q Ex. Prove that } } p q ( p q). Ex Ex. Prove that p q ( p q). Ex. Prove that p q ( p q).. Prove thex. Prove that pq ( p q). at p q ( p q). CO Dr. Ungor 37 uesday, January 7, 2014

92 Proving Equivalence via ruth ables P Q Ex. Prove that } } p q ( p q). Ex Ex. Prove that p q ( p q). Ex. Prove that p q ( p q).. Prove thex. Prove that pq ( p q). at p q ( p q). CO Dr. Ungor 37 uesday, January 7, 2014

93 Proving Equivalence via ruth ables P Q Ex. Prove that } } p q ( p q). Ex Ex. Prove that p q ( p q). Ex. Prove that p q ( p q).. Prove thex. Prove that pq ( p q). at p q ( p q). CO Dr. Ungor 37 uesday, January 7, 2014

94 Proving Equivalence via ruth ables P Q Ex. Prove that } } p q ( p q). Ex Ex. Prove that p q ( p q). Ex. Prove that p q ( p q).. Prove thex. Prove that pq ( p q). at p q ( p q). CO Dr. Ungor 37 uesday, January 7, 2014

95 Proving Equivalence via ruth ables P Q Ex. Prove that } } p q ( p q). Ex Ex. Prove that p q ( p q). Ex. Prove that p q ( p q).. Prove thex. Prove that pq ( p q). at p q ( p q). CO Dr. Ungor 37 uesday, January 7, 2014

96 Proving Equivalence via ruth ables P Q Ex. Prove that } } p q ( p q). Ex Ex. Prove that p q ( p q). Ex. Prove that p q ( p q).. Prove thex. Prove that pq ( p q). at p q ( p q). CO Dr. Ungor 37 uesday, January 7, 2014

97 Proving Equivalence via ruth ables P Q Ex. Prove that } } p q ( p q). Ex Ex. Prove that p q ( p q). Ex. Prove that p q ( p q).. Prove thex. Prove that pq ( p q). at p q ( p q). CO Dr. Ungor 37 uesday, January 7, 2014

98 Proving Equivalence via ruth ables P Q Ex. Prove that } } p q ( p q). Ex Ex. Prove that p q ( p q). Ex. Prove that p q ( p q).. Prove thex. Prove that pq ( p q). at p q ( p q). CO Dr. Ungor 37 uesday, January 7, 2014

99 Proving Equivalence via ruth ables P Q Ex. Prove that } } p q ( p q). Ex Ex. Prove that p q ( p q). Ex. Prove that p q ( p q).. Prove thex. Prove that pq ( p q). at p q ( p q). CO Dr. Ungor 37 uesday, January 7, 2014

100 Proving Equivalence via ruth ables P Q Ex. Prove that } } p q ( p q). Ex Ex. Prove that p q ( p q). Ex. Prove that p q ( p q).. Prove thex. Prove that pq ( p q). at p q ( p q). CO Dr. Ungor 37 uesday, January 7, 2014

101 Proving Equivalence via ruth ables P Q Ex. Prove that } } p q ( p q). Ex Ex. Prove that p q ( p q). Ex. Prove that p q ( p q).. Prove thex. Prove that pq ( p q). at p q ( p q). CO Dr. Ungor 37 uesday, January 7, 2014

102 Proving Equivalence via ruth ables P Q Ex. Prove that } } p q ( p q). Ex Ex. Prove that p q ( p q). Ex. Prove that p q ( p q).. Prove thex. Prove that pq ( p q). at p q ( p q). CO Dr. Ungor 37 uesday, January 7, 2014

103 Proving Equivalence via ruth ables P Q Ex. Prove that } } p q ( p q). Ex Ex. Prove that p q ( p q). Ex. Prove that p q ( p q).. Prove thex. Prove that pq ( p q). at p q ( p q). CO Dr. Ungor 37 uesday, January 7, 2014

104 Proving Equivalence via ruth ables P Q Ex. Prove that } } p q ( p q). Ex Ex. Prove that p q ( p q). Ex. Prove that p q ( p q).. Prove thex. Prove that pq ( p q). at p q ( p q). CO Dr. Ungor 37 uesday, January 7, 2014

105 Equivalence Laws hese are similar to the arithmetic identities you may have learned in algebra, but for propositional equivalences instead. hey provide a pattern or template that can be used to match much more complicated propositions and to find equivalences for them. CO Dr. Ungor 38 uesday, January 7, 2014

106 Equivalence Laws - Examples Identity: p p p p Domination: p p Idempotent: p p p p p p Double negation: p p Commutative: p q q p p q q p Associative: (p q) r p (q r) (p q) r p (q r) CO Dr. Ungor 39 uesday, January 7, 2014

107 More Equivalence Laws Distributive: p (q r) (p q) (p r) p (q r) (p q) (p r) De Morgan s: " (p q) p q " (p q) p q CO Dr. Ungor 40 uesday, January 7, 2014

108 More Equivalence Laws Absorption: " p (p q) p p (p q) p rivial tautology/contradiction: p p p p CO Dr. Ungor 41 uesday, January 7, 2014

109 Defining Operators via Equivalences Using equivalences, we can define operators in terms of other operators. Implication: p q p q Biconditional: p q (p q) (q p) p q (p q) Exclusive or: p q (p q) (p q) p q (p q) (q p) CO Dr. Ungor 42 uesday, January 7, 2014

110 An Example Problem CO Dr. Ungor 43 uesday, January 7, 2014

111 An Example Problem Check using a symbolic derivation whether (p q) (p r) p q r. CO Dr. Ungor 43 uesday, January 7, 2014

112 An Example Problem Check using a symbolic derivation whether (p q) (p r) p q r. (p q) (p r) CO Dr. Ungor 43 uesday, January 7, 2014

113 An Example Problem Check using a symbolic derivation whether (p q) (p r) p q r. (p q) (p r) [Expand definition of ] (p q) (p r) CO Dr. Ungor 43 uesday, January 7, 2014

114 An Example Problem Check using a symbolic derivation whether (p q) (p r) p q r. (p q) (p r) [Expand definition of ] (p q) (p r) [Defn. of ] (p q) ((p r) (p r)) CO Dr. Ungor 43 uesday, January 7, 2014

115 An Example Problem Check using a symbolic derivation whether (p q) (p r) p q r. (p q) (p r) [Expand definition of ] (p q) (p r) [Defn. of ] (p q) ((p r) (p r)) [DeMorganʼs Law] CO Dr. Ungor 43 uesday, January 7, 2014

116 An Example Problem Check using a symbolic derivation whether (p q) (p r) p q r. (p q) (p r) [Expand definition of ] (p q) (p r) [Defn. of ] (p q) ((p r) (p r)) [DeMorganʼs Law] ( p q) ((p r) (p r)) CO Dr. Ungor 43 uesday, January 7, 2014

117 An Example Problem Check using a symbolic derivation whether (p q) (p r) p q r. (p q) (p r) [Expand definition of ] (p q) (p r) [Defn. of ] (p q) ((p r) (p r)) [DeMorganʼs Law] ( p q) ((p r) (p r)) CO Dr. Ungor 43 uesday, January 7, 2014

118 Example Continued... CO Dr. Ungor 44 uesday, January 7, 2014

119 Example Continued... ( p q) ((p r) (p r)) [ commutes] CO Dr. Ungor 44 uesday, January 7, 2014

120 Example Continued... ( p q) ((p r) (p r)) [ commutes] (q p) ((p r) (p r)) [ associative] CO Dr. Ungor 44 uesday, January 7, 2014

121 Example Continued... ( p q) ((p r) (p r)) [ commutes] (q p) ((p r) (p r)) [ associative] q ( p ((p r) (p r))) [distrib. over ] CO Dr. Ungor 44 uesday, January 7, 2014

122 Example Continued... ( p q) ((p r) (p r)) [ commutes] (q p) ((p r) (p r)) [ associative] q ( p ((p r) (p r))) [distrib. over ] q ((( p (p r)) ( p (p r))) CO Dr. Ungor 44 uesday, January 7, 2014

123 Example Continued... ( p q) ((p r) (p r)) [ commutes] (q p) ((p r) (p r)) [ associative] q ( p ((p r) (p r))) [distrib. over ] q ((( p (p r)) ( p (p r))) [assoc.] q ((( p p) r) ( p (p r))) CO Dr. Ungor 44 uesday, January 7, 2014

124 Example Continued... ( p q) ((p r) (p r)) [ commutes] (q p) ((p r) (p r)) [ associative] q ( p ((p r) (p r))) [distrib. over ] q ((( p (p r)) ( p (p r))) [assoc.] q ((( p p) r) ( p (p r))) [trivial taut.] q (( r) ( p (p r))) CO Dr. Ungor 44 uesday, January 7, 2014

125 Example Continued... ( p q) ((p r) (p r)) [ commutes] (q p) ((p r) (p r)) [ associative] q ( p ((p r) (p r))) [distrib. over ] q ((( p (p r)) ( p (p r))) [assoc.] q ((( p p) r) ( p (p r))) [trivial taut.] q (( r) ( p (p r))) [domination] q ( ( p (p r))) CO Dr. Ungor 44 uesday, January 7, 2014

126 CO Dr. Ungor Example Continued... ( p q) ((p r) (p r)) [ commutes] (q p) ((p r) (p r)) [ associative] q ( p ((p r) (p r))) [distrib. over ] q ((( p (p r)) ( p (p r))) [assoc.] q ((( p p) r) ( p (p r))) [trivial taut.] q (( r) ( p (p r))) [domination] q ( ( p (p r))) [identity] uesday, January 7, 2014 q ( p (p r)) cont. 44

127 End of Long Example CO Dr. Ungor 45 uesday, January 7, 2014

128 q ( p (p r)) End of Long Example CO Dr. Ungor 45 uesday, January 7, 2014

129 End of Long Example q ( p (p r)) [DeMorganʼs] q ( p ( p r)) CO Dr. Ungor 45 uesday, January 7, 2014

130 End of Long Example q ( p (p r)) [DeMorganʼs] q ( p ( p r)) [Assoc.] q (( p p) r) CO Dr. Ungor 45 uesday, January 7, 2014

131 End of Long Example q ( p (p r)) [DeMorganʼs] q ( p ( p r)) [Assoc.] q (( p p) r) [Idempotent] q ( p r) CO Dr. Ungor 45 uesday, January 7, 2014

132 End of Long Example q ( p (p r)) [DeMorganʼs] q ( p ( p r)) [Assoc.] q (( p p) r) [Idempotent] q ( p r) [Assoc.] (q p) r CO Dr. Ungor 45 uesday, January 7, 2014

133 End of Long Example q ( p (p r)) [DeMorganʼs] q ( p ( p r)) [Assoc.] q (( p p) r) [Idempotent] q ( p r) [Assoc.] (q p) r [Commut.] p q r CO Dr. Ungor 45 uesday, January 7, 2014

134 End of Long Example q ( p (p r)) [DeMorganʼs] q ( p ( p r)) [Assoc.] q (( p p) r) [Idempotent] q ( p r) [Assoc.] (q p) r [Commut.] p q r Q.E.D. (quod erat demonstrandum) CO Dr. Ungor 45 uesday, January 7, 2014

Propositional logic ( ): Review from Mat 1348

Propositional logic ( ): Review from Mat 1348 CSI 2101 / Winter 2008: Discrete Structures. Propositional logic ( 1.1-1.2): Review from Mat 1348 Dr. Nejib Zaguia - Winter 2008 1 Propositional logic: Review Mathematical Logic is a tool for working with

More information

ICS141: Discrete Mathematics for Computer Science I

ICS141: Discrete Mathematics for Computer Science I ICS141: Discrete Mathematics for Computer Science I Dept. Information & Computer Sci., Originals slides by Dr. Baek and Dr. Still, adapted by J. Stelovsky Based on slides Dr. M. P. Frank and Dr. J.L. Gross

More information

ARTIFICIAL INTELLIGENCE

ARTIFICIAL INTELLIGENCE ARTIFICIAL INTELLIGENCE LECTURE # 03 Artificial Intelligence 2012 Lecture 03 Delivered By Zahid Iqbal 1 Review of Last Lecture Artificial Intelligence 2012 Lecture 03 Delivered By Zahid Iqbal 2 Today s

More information

Discrete Mathematical Structures. Chapter 1 The Foundation: Logic

Discrete Mathematical Structures. Chapter 1 The Foundation: Logic Discrete Mathematical Structures Chapter 1 he oundation: Logic 1 Lecture Overview 1.1 Propositional Logic 1.2 Propositional Equivalences 1.3 Quantifiers l l l l l Statement Logical Connectives Conjunction

More information

The Fundamentals of Logic. Foundations of Logic. Foundations of Logic. CMSC 302 Propositional Logic. In Rosen, ~98 slides, ~3 lectures

The Fundamentals of Logic. Foundations of Logic. Foundations of Logic. CMSC 302 Propositional Logic. In Rosen, ~98 slides, ~3 lectures VCU, Department of Computer Science CMSC 302 Propositional Logic Vojislav Kecman The Fundamentals of Logic In Rosen, 1.1-1.4 ~98 slides, ~3 lectures All the PPT slides are based on MP Franck s and H Bingöl

More information

CS100: DISCRETE STRUCTURES. Lecture 5: Logic (Ch1)

CS100: DISCRETE STRUCTURES. Lecture 5: Logic (Ch1) CS100: DISCREE SRUCURES Lecture 5: Logic (Ch1) Lecture Overview 2 Statement Logical Connectives Conjunction Disjunction Propositions Conditional Bio-conditional Converse Inverse Contrapositive Laws of

More information

CSC Discrete Math I, Spring Propositional Logic

CSC Discrete Math I, Spring Propositional Logic CSC 125 - Discrete Math I, Spring 2017 Propositional Logic Propositions A proposition is a declarative sentence that is either true or false Propositional Variables A propositional variable (p, q, r, s,...)

More information

Chapter Summary. Propositional Logic. Predicate Logic. Proofs. The Language of Propositions (1.1) Applications (1.2) Logical Equivalences (1.

Chapter Summary. Propositional Logic. Predicate Logic. Proofs. The Language of Propositions (1.1) Applications (1.2) Logical Equivalences (1. Chapter 1 Chapter Summary Propositional Logic The Language of Propositions (1.1) Applications (1.2) Logical Equivalences (1.3) Predicate Logic The Language of Quantifiers (1.4) Logical Equivalences (1.4)

More information

Proposition/Statement. Boolean Logic. Boolean variables. Logical operators: And. Logical operators: Not 9/3/13. Introduction to Logical Operators

Proposition/Statement. Boolean Logic. Boolean variables. Logical operators: And. Logical operators: Not 9/3/13. Introduction to Logical Operators Proposition/Statement Boolean Logic CS 231 Dianna Xu A proposition is either true or false but not both he sky is blue Lisa is a Math major x == y Not propositions: Are you Bob? x := 7 1 2 Boolean variables

More information

Chapter 1, Part I: Propositional Logic. With Question/Answer Animations

Chapter 1, Part I: Propositional Logic. With Question/Answer Animations Chapter 1, Part I: Propositional Logic With Question/Answer Animations Chapter Summary Propositional Logic The Language of Propositions Applications Logical Equivalences Predicate Logic The Language of

More information

Compound Propositions

Compound Propositions Discrete Structures Compound Propositions Producing new propositions from existing propositions. Logical Operators or Connectives 1. Not 2. And 3. Or 4. Exclusive or 5. Implication 6. Biconditional Truth

More information

Lecture 2. Logic Compound Statements Conditional Statements Valid & Invalid Arguments Digital Logic Circuits. Reading (Epp s textbook)

Lecture 2. Logic Compound Statements Conditional Statements Valid & Invalid Arguments Digital Logic Circuits. Reading (Epp s textbook) Lecture 2 Logic Compound Statements Conditional Statements Valid & Invalid Arguments Digital Logic Circuits Reading (Epp s textbook) 2.1-2.4 1 Logic Logic is a system based on statements. A statement (or

More information

Example. Logic. Logical Statements. Outline of logic topics. Logical Connectives. Logical Connectives

Example. Logic. Logical Statements. Outline of logic topics. Logical Connectives. Logical Connectives Logic Logic is study of abstract reasoning, specifically, concerned with whether reasoning is correct. Logic focuses on relationship among statements as opposed to the content of any particular statement.

More information

Sec$on Summary. Propositions Connectives. Truth Tables. Negation Conjunction Disjunction Implication; contrapositive, inverse, converse Biconditional

Sec$on Summary. Propositions Connectives. Truth Tables. Negation Conjunction Disjunction Implication; contrapositive, inverse, converse Biconditional Section 1.1 Sec$on Summary Propositions Connectives Negation Conjunction Disjunction Implication; contrapositive, inverse, converse Biconditional ruth ables 2 Proposi$ons A proposition is a declarative

More information

Definition 2. Conjunction of p and q

Definition 2. Conjunction of p and q Proposition Propositional Logic CPSC 2070 Discrete Structures Rosen (6 th Ed.) 1.1, 1.2 A proposition is a statement that is either true or false, but not both. Clemson will defeat Georgia in football

More information

Propositional Logic. Propositional Equivalences. Agenda. Yutaka HATA, IEEE Fellow. Ch1.1 Propositional Logic. Ch1.2 Propositional Equivalences

Propositional Logic. Propositional Equivalences. Agenda. Yutaka HATA, IEEE Fellow. Ch1.1 Propositional Logic. Ch1.2 Propositional Equivalences Discrete Mathematic Chapter 1: Logic and Proof 1.1 Propositional Logic 1.2 Propositional Equivalences Yutaka HAA, IEEE ellow University of Hyogo, JAPAN his material was made by Dr. Patrick Chan School

More information

Chapter 1, Section 1.1 Propositional Logic

Chapter 1, Section 1.1 Propositional Logic Discrete Structures Chapter 1, Section 1.1 Propositional Logic These class notes are based on material from our textbook, Discrete Mathematics and Its Applications, 6 th ed., by Kenneth H. Rosen, published

More information

Chapter 1, Part I: Propositional Logic. With Question/Answer Animations

Chapter 1, Part I: Propositional Logic. With Question/Answer Animations Chapter 1, Part I: Propositional Logic With Question/Answer Animations Chapter Summary! Propositional Logic! The Language of Propositions! Applications! Logical Equivalences! Predicate Logic! The Language

More information

2/2/2018. CS 103 Discrete Structures. Chapter 1. Propositional Logic. Chapter 1.1. Propositional Logic

2/2/2018. CS 103 Discrete Structures. Chapter 1. Propositional Logic. Chapter 1.1. Propositional Logic CS 103 Discrete Structures Chapter 1 Propositional Logic Chapter 1.1 Propositional Logic 1 1.1 Propositional Logic Definition: A proposition :is a declarative sentence (that is, a sentence that declares

More information

Bits and Bit Operations. Today s topics

Bits and Bit Operations. Today s topics oday s topics Bits and Bit Operations opic #2 Bits Boolean algebra preview Propositional equivalences Predicate logic Reading: Sections 1.2-1.4 Slides taken from Prof. Michael rank A bit is a binary nary

More information

Boolean Logic. CS 231 Dianna Xu

Boolean Logic. CS 231 Dianna Xu Boolean Logic CS 231 Dianna Xu 1 Proposition/Statement A proposition is either true or false but not both The sky is blue Lisa is a Math major x == y Not propositions: Are you Bob? x := 7 2 Boolean variables

More information

1 Propositional Logic

1 Propositional Logic 1 Propositional Logic Required reading: Foundations of Computation. Sections 1.1 and 1.2. 1. Introduction to Logic a. Logical consequences. If you know all humans are mortal, and you know that you are

More information

ICS141: Discrete Mathematics for Computer Science I

ICS141: Discrete Mathematics for Computer Science I ICS141: Discrete Mathematics for Computer Science I Dept. Information & Computer Sci., Originals slides by Dr. Baek and Dr. Still, adapted by J. Stelovsky Based on slides Dr. M. P. Frank and Dr. J.L. Gross

More information

Propositional Logic 1

Propositional Logic 1 Propositional Logic 1 Section Summary Propositions Connectives Negation Conjunction Disjunction Implication; contrapositive, inverse, converse Biconditional Truth Tables 2 Propositions A proposition is

More information

Discrete Mathematics and Its Applications

Discrete Mathematics and Its Applications Discrete Mathematics and Its Applications Lecture 1: Proposition logic MING GAO DASE @ ECNU (for course related communications) mgao@dase.ecnu.edu.cn Sep. 12, 2017 Outline 1 Propositions 2 Connectives

More information

An Introduction to Logic 1.1 ~ 1.4 6/21/04 ~ 6/23/04

An Introduction to Logic 1.1 ~ 1.4 6/21/04 ~ 6/23/04 An Introduction to Logic 1.1 ~ 1.4 6/21/04 ~ 6/23/04 1 A Taste of Logic Logic puzzles (1) Knights and Knaves Knights: always tell the truth Knaves: always lie You encounter two people A and B. A says:

More information

Section 1.1 Propositional Logic. proposition : true = T (or 1) or false = F (or 0) (binary logic) the moon is made of green cheese

Section 1.1 Propositional Logic. proposition : true = T (or 1) or false = F (or 0) (binary logic) the moon is made of green cheese Section 1.1 Propositional Logic proposition : true = T (or 1) or false = F (or 0) (binary logic) the moon is made of green cheese go to town! X - imperative What time is it? X - interrogative propositional

More information

A statement is a sentence that is definitely either true or false but not both.

A statement is a sentence that is definitely either true or false but not both. 5 Logic In this part of the course we consider logic. Logic is used in many places in computer science including digital circuit design, relational databases, automata theory and computability, and artificial

More information

DISCRETE STRUCTURES WEEK5 LECTURE1

DISCRETE STRUCTURES WEEK5 LECTURE1 DISCRETE STRUCTURES WEEK5 LECTURE1 Let s get started with... Logic! Spring 2010 CPCS 222 - Discrete Structures 2 Logic Crucial for mathematical reasoning Important for program design Used for designing

More information

Logic. Logic is a discipline that studies the principles and methods used in correct reasoning. It includes:

Logic. Logic is a discipline that studies the principles and methods used in correct reasoning. It includes: Logic Logic is a discipline that studies the principles and methods used in correct reasoning It includes: A formal language for expressing statements. An inference mechanism (a collection of rules) to

More information

Discrete Structures of Computer Science Propositional Logic I

Discrete Structures of Computer Science Propositional Logic I Discrete Structures of Computer Science Propositional Logic I Gazihan Alankuş (Based on original slides by Brahim Hnich) July 26, 2012 1 Use of Logic 2 Statements 3 Logic Connectives 4 Truth Tables Use

More information

Propositional Equivalence

Propositional Equivalence Propositional Equivalence Tautologies and contradictions A compound proposition that is always true, regardless of the truth values of the individual propositions involved, is called a tautology. Example:

More information

Mathematical Logic Part One

Mathematical Logic Part One Mathematical Logic Part One Question: How do we formalize the definitions and reasoning we use in our proofs? Where We're Going Propositional Logic (oday) Basic logical connectives. ruth tables. Logical

More information

Overview. 1. Introduction to Propositional Logic. 2. Operations on Propositions. 3. Truth Tables. 4. Translating Sentences into Logical Expressions

Overview. 1. Introduction to Propositional Logic. 2. Operations on Propositions. 3. Truth Tables. 4. Translating Sentences into Logical Expressions Note 01 Propositional Logic 1 / 10-1 Overview 1. Introduction to Propositional Logic 2. Operations on Propositions 3. Truth Tables 4. Translating Sentences into Logical Expressions 5. Preview: Propositional

More information

Propositional Logic. Spring Propositional Logic Spring / 32

Propositional Logic. Spring Propositional Logic Spring / 32 Propositional Logic Spring 2016 Propositional Logic Spring 2016 1 / 32 Introduction Learning Outcomes for this Presentation Learning Outcomes... At the conclusion of this session, we will Define the elements

More information

Introduction. Applications of discrete mathematics:

Introduction. Applications of discrete mathematics: Introduction Applications of discrete mathematics: Formal Languages (computer languages) Compiler Design Data Structures Computability Automata Theory Algorithm Design Relational Database Theory Complexity

More information

software design & management Gachon University Chulyun Kim

software design & management Gachon University Chulyun Kim Gachon University Chulyun Kim 2 Outline Propositional Logic Propositional Equivalences Predicates and Quantifiers Nested Quantifiers Rules of Inference Introduction to Proofs 3 1.1 Propositional Logic

More information

HW1 graded review form? HW2 released CSE 20 DISCRETE MATH. Fall

HW1 graded review form? HW2 released CSE 20 DISCRETE MATH. Fall CSE 20 HW1 graded review form? HW2 released DISCRETE MATH Fall 2017 http://cseweb.ucsd.edu/classes/fa17/cse20-ab/ Today's learning goals Translate sentences from English to propositional logic using appropriate

More information

Truth-Functional Logic

Truth-Functional Logic Truth-Functional Logic Syntax Every atomic sentence (A, B, C, ) is a sentence and are sentences With ϕ a sentence, the negation ϕ is a sentence With ϕ and ψ sentences, the conjunction ϕ ψ is a sentence

More information

Discrete Structures & Algorithms. Propositional Logic EECE 320 // UBC

Discrete Structures & Algorithms. Propositional Logic EECE 320 // UBC Discrete Structures & Algorithms Propositional Logic EECE 320 // UBC 1 Review of last lecture Pancake sorting A problem with many applications Bracketing (bounding a function) Proving bounds for pancake

More information

Announcements. CS311H: Discrete Mathematics. Propositional Logic II. Inverse of an Implication. Converse of a Implication

Announcements. CS311H: Discrete Mathematics. Propositional Logic II. Inverse of an Implication. Converse of a Implication Announcements CS311H: Discrete Mathematics Propositional Logic II Instructor: Işıl Dillig First homework assignment out today! Due in one week, i.e., before lecture next Wed 09/13 Remember: Due before

More information

Note: The area of logic that deals with propositions is called the propositional calculus or propositional logic.

Note: The area of logic that deals with propositions is called the propositional calculus or propositional logic. Ch. 1.1 Logic Logic 1 Def. A Proposition is a statement that is either true or false. Example 1: Which of the following are propositions? Statement Proposition (yes or no) UHD is a University 1 + 3 = 0

More information

1 The Foundations. 1.1 Logic. A proposition is a declarative sentence that is either true or false, but not both.

1 The Foundations. 1.1 Logic. A proposition is a declarative sentence that is either true or false, but not both. he oundations. Logic Propositions are building blocks of logic. A proposition is a declarative sentence that is either true or false, but not both. Example. Declarative sentences.. Ottawa is the capital

More information

Section 1.1: Logical Form and Logical Equivalence

Section 1.1: Logical Form and Logical Equivalence Section 1.1: Logical Form and Logical Equivalence An argument is a sequence of statements aimed at demonstrating the truth of an assertion. The assertion at the end of an argument is called the conclusion,

More information

UNIT-I: Propositional Logic

UNIT-I: Propositional Logic 1. Introduction to Logic: UNIT-I: Propositional Logic Logic: logic comprises a (formal) language for making statements about objects and reasoning about properties of these objects. Statements in a logical

More information

2. The Logic of Compound Statements Summary. Aaron Tan August 2017

2. The Logic of Compound Statements Summary. Aaron Tan August 2017 2. The Logic of Compound Statements Summary Aaron Tan 21 25 August 2017 1 2. The Logic of Compound Statements 2.1 Logical Form and Logical Equivalence Statements; Compound Statements; Statement Form (Propositional

More information

The Foundations: Logic and Proofs. Part I

The Foundations: Logic and Proofs. Part I The Foundations: Logic and Proofs Part I Chapter Summary Propositional Logic n The Language of Propositions n Applications n Logical Equivalences Predicate Logic n The Language of Quantifiers n Logical

More information

Announcements. CS243: Discrete Structures. Propositional Logic II. Review. Operator Precedence. Operator Precedence, cont. Operator Precedence Example

Announcements. CS243: Discrete Structures. Propositional Logic II. Review. Operator Precedence. Operator Precedence, cont. Operator Precedence Example Announcements CS243: Discrete Structures Propositional Logic II Işıl Dillig First homework assignment out today! Due in one week, i.e., before lecture next Tuesday 09/11 Weilin s Tuesday office hours are

More information

Equivalence and Implication

Equivalence and Implication Equivalence and Alice E. Fischer CSCI 1166 Discrete Mathematics for Computing February 7 8, 2018 Alice E. Fischer Laws of Logic... 1/33 1 Logical Equivalence Contradictions and Tautologies 2 3 4 Necessary

More information

Functions. Lecture 4: Truth functions, evaluating compound statements. Arithmetic Functions. x y x+y

Functions. Lecture 4: Truth functions, evaluating compound statements. Arithmetic Functions. x y x+y Lecture 4: ruth functions, evaluating compound statements 1. unctions, arithmetic functions, and truth functions 2. Definitions of truth functions unctions A function is something that takes inputs and

More information

EECS 1028 M: Discrete Mathematics for Engineers

EECS 1028 M: Discrete Mathematics for Engineers EECS 1028 M: Discrete Mathematics for Engineers Suprakash Datta Office: LAS 3043 Course page: http://www.eecs.yorku.ca/course/1028 Also on Moodle S. Datta (York Univ.) EECS 1028 W 18 1 / 26 Why Study Logic?

More information

Introduction Propositional Logic. Discrete Mathematics Andrei Bulatov

Introduction Propositional Logic. Discrete Mathematics Andrei Bulatov Introduction Propositional Logic Discrete Mathematics Andrei Bulatov Discrete Mathematics Propositional Logic 2-2 What is Logic? Computer science is a mere continuation of logic by other means Georg Gottlob

More information

Logic as a Tool Chapter 1: Understanding Propositional Logic 1.1 Propositions and logical connectives. Truth tables and tautologies

Logic as a Tool Chapter 1: Understanding Propositional Logic 1.1 Propositions and logical connectives. Truth tables and tautologies Logic as a Tool Chapter 1: Understanding Propositional Logic 1.1 Propositions and logical connectives. Truth tables and tautologies Valentin Stockholm University September 2016 Propositions Proposition:

More information

Discrete Structures for Computer Science

Discrete Structures for Computer Science Discrete Structures for Computer Science William Garrison bill@cs.pitt.edu 6311 Sennott Square Lecture #2: Propositional Logic Based on materials developed by Dr. Adam Lee Today s Topic: Propositional

More information

Propositional Logic. Fall () Propositional Logic Fall / 30

Propositional Logic. Fall () Propositional Logic Fall / 30 Propositional Logic Fall 2013 () Propositional Logic Fall 2013 1 / 30 1 Introduction Learning Outcomes for this Presentation 2 Definitions Statements Logical connectives Interpretations, contexts,... Logically

More information

13.3 Truth Tables for the Conditional and the Biconditional

13.3 Truth Tables for the Conditional and the Biconditional ruthablesconditionalbiconditional.nb 1 13.3 ruth ables for the Conditional and the Biconditional Conditional Earlier, we mentioned that the statement preceding the conditional symbol is called the antecedent

More information

Today s Topic: Propositional Logic

Today s Topic: Propositional Logic Today s Topic: Propositional Logic What is a proposition? Logical connectives and truth tables Translating between English and propositional logic Logic is the basis of all mathematical and analytical

More information

Logic Overview, I. and T T T T F F F T F F F F

Logic Overview, I. and T T T T F F F T F F F F Logic Overview, I DEFINITIONS A statement (proposition) is a declarative sentence that can be assigned a truth value T or F, but not both. Statements are denoted by letters p, q, r, s,... The 5 basic logical

More information

3/29/2017. Logic. Propositions and logical operations. Main concepts: propositions truth values propositional variables logical operations

3/29/2017. Logic. Propositions and logical operations. Main concepts: propositions truth values propositional variables logical operations Logic Propositions and logical operations Main concepts: propositions truth values propositional variables logical operations 1 Propositions and logical operations A proposition is the most basic element

More information

AMTH140 Lecture 8. Symbolic Logic

AMTH140 Lecture 8. Symbolic Logic AMTH140 Lecture 8 Slide 1 Symbolic Logic March 10, 2006 Reading: Lecture Notes 6.2, 6.3; Epp 1.1, 1.2 Logical Connectives Let p and q denote propositions, then: 1. p q is conjunction of p and q, meaning

More information

Artificial Intelligence Knowledge Representation I

Artificial Intelligence Knowledge Representation I Artificial Intelligence Knowledge Representation I Agents that reason logically knowledge-based approach implement agents that know about their world and reason about possible courses of action needs to

More information

n logical not (negation) n logical or (disjunction) n logical and (conjunction) n logical exclusive or n logical implication (conditional)

n logical not (negation) n logical or (disjunction) n logical and (conjunction) n logical exclusive or n logical implication (conditional) Discrete Math Review Discrete Math Review (Rosen, Chapter 1.1 1.6) TOPICS Propositional Logic Logical Operators Truth Tables Implication Logical Equivalence Inference Rules What you should know about propositional

More information

CHAPTER 1. MATHEMATICAL LOGIC 1.1 Fundamentals of Mathematical Logic

CHAPTER 1. MATHEMATICAL LOGIC 1.1 Fundamentals of Mathematical Logic CHAPER 1 MAHEMAICAL LOGIC 1.1 undamentals of Mathematical Logic Logic is commonly known as the science of reasoning. Some of the reasons to study logic are the following: At the hardware level the design

More information

Section 3.1. Statements and Logical Connectives. Copyright 2013, 2010, 2007, Pearson, Education, Inc.

Section 3.1. Statements and Logical Connectives. Copyright 2013, 2010, 2007, Pearson, Education, Inc. Section 3.1 Statements and Logical Connectives What You Will Learn Statements, quantifiers, and compound statements Statements involving the words not, and, or, if then, and if and only if 3.1-2 HISORY

More information

1.1 Language and Logic

1.1 Language and Logic c Oksana Shatalov, Fall 2017 1 1.1 Language and Logic Mathematical Statements DEFINITION 1. A proposition is any declarative sentence (i.e. it has both a subject and a verb) that is either true or false,

More information

CSE 20 DISCRETE MATH. Fall

CSE 20 DISCRETE MATH. Fall CSE 20 DISCRETE MATH Fall 2017 http://cseweb.ucsd.edu/classes/fa17/cse20-ab/ Today's learning goals Describe and use algorithms for integer operations based on their expansions Relate algorithms for integer

More information

Logic and Proof. Aiichiro Nakano

Logic and Proof. Aiichiro Nakano Logic and Proof Aiichiro Nakano Collaboratory for Advanced Computing & Simulations Department of Computer Science Department of Physics & Astronomy Department of Chemical Engineering & Materials Science

More information

CSE 240 Logic and Discrete Mathematics

CSE 240 Logic and Discrete Mathematics CSE 240 Logic and Discrete Mathematics Instructor: odd Sproull Department of Computer Science and Engineering Washington University in St. Louis 1Extensible - CSE 240 Logic Networking and Discrete Platform

More information

MAT2345 Discrete Math

MAT2345 Discrete Math Fall 2013 General Syllabus Schedule (note exam dates) Homework, Worksheets, Quizzes, and possibly Programs & Reports Academic Integrity Do Your Own Work Course Web Site: www.eiu.edu/~mathcs Course Overview

More information

Unit 1. Propositional Logic Reading do all quick-checks Propositional Logic: Ch. 2.intro, 2.2, 2.3, 2.4. Review 2.9

Unit 1. Propositional Logic Reading do all quick-checks Propositional Logic: Ch. 2.intro, 2.2, 2.3, 2.4. Review 2.9 Unit 1. Propositional Logic Reading do all quick-checks Propositional Logic: Ch. 2.intro, 2.2, 2.3, 2.4. Review 2.9 Typeset September 23, 2005 1 Statements or propositions Defn: A statement is an assertion

More information

PROPOSITIONAL CALCULUS

PROPOSITIONAL CALCULUS PROPOSITIONAL CALCULUS A proposition is a complete declarative sentence that is either TRUE (truth value T or 1) or FALSE (truth value F or 0), but not both. These are not propositions! Connectives and

More information

CSCE 222 Discrete Structures for Computing. Propositional Logic. Dr. Hyunyoung Lee. !!!!!! Based on slides by Andreas Klappenecker

CSCE 222 Discrete Structures for Computing. Propositional Logic. Dr. Hyunyoung Lee. !!!!!! Based on slides by Andreas Klappenecker CSCE 222 Discrete Structures for Computing Propositional Logic Dr. Hyunyoung Lee Based on slides by Andreas Klappenecker 1 Propositions A proposition is a declarative sentence that is either true or false

More information

THE LOGIC OF COMPOUND STATEMENTS

THE LOGIC OF COMPOUND STATEMENTS THE LOGIC OF COMPOUND STATEMENTS All dogs have four legs. All tables have four legs. Therefore, all dogs are tables LOGIC Logic is a science of the necessary laws of thought, without which no employment

More information

Why Learning Logic? Logic. Propositional Logic. Compound Propositions

Why Learning Logic? Logic. Propositional Logic. Compound Propositions Logic Objectives Propositions and compound propositions Negation, conjunction, disjunction, and exclusive or Implication and biconditional Logic equivalence and satisfiability Application of propositional

More information

Chapter 1: The Logic of Compound Statements. January 7, 2008

Chapter 1: The Logic of Compound Statements. January 7, 2008 Chapter 1: The Logic of Compound Statements January 7, 2008 Outline 1 1.1 Logical Form and Logical Equivalence 2 1.2 Conditional Statements 3 1.3 Valid and Invalid Arguments Central notion of deductive

More information

What is Logic? Introduction to Logic. Simple Statements. Which one is statement?

What is Logic? Introduction to Logic. Simple Statements. Which one is statement? What is Logic? Introduction to Logic Peter Lo Logic is the study of reasoning It is specifically concerned with whether reasoning is correct Logic is also known as Propositional Calculus CS218 Peter Lo

More information

1.1 Language and Logic

1.1 Language and Logic c Oksana Shatalov, Spring 2018 1 1.1 Language and Logic Mathematical Statements DEFINITION 1. A proposition is any declarative sentence (i.e. it has both a subject and a verb) that is either true or false,

More information

Introduction to Decision Sciences Lecture 2

Introduction to Decision Sciences Lecture 2 Introduction to Decision Sciences Lecture 2 Andrew Nobel August 24, 2017 Compound Proposition A compound proposition is a combination of propositions using the basic operations. For example (p q) ( p)

More information

LING 106. Knowledge of Meaning Lecture 3-1 Yimei Xiang Feb 6, Propositional logic

LING 106. Knowledge of Meaning Lecture 3-1 Yimei Xiang Feb 6, Propositional logic LING 106. Knowledge of Meaning Lecture 3-1 Yimei Xiang Feb 6, 2016 Propositional logic 1 Vocabulary of propositional logic Vocabulary (1) a. Propositional letters: p, q, r, s, t, p 1, q 1,..., p 2, q 2,...

More information

Overview. Knowledge-Based Agents. Introduction. COMP219: Artificial Intelligence. Lecture 19: Logic for KR

Overview. Knowledge-Based Agents. Introduction. COMP219: Artificial Intelligence. Lecture 19: Logic for KR COMP219: Artificial Intelligence Lecture 19: Logic for KR Last time Expert Systems and Ontologies oday Logic as a knowledge representation scheme Propositional Logic Syntax Semantics Proof theory Natural

More information

CSE 311: Foundations of Computing. Lecture 2: More Logic, Equivalence & Digital Circuits

CSE 311: Foundations of Computing. Lecture 2: More Logic, Equivalence & Digital Circuits CSE 311: Foundations of Computing Lecture 2: More Logic, Equivalence & Digital Circuits Last class: Some Connectives & Truth Tables Negation (not) p p T F F T Disjunction (or) p q p q T T T T F T F T T

More information

Propositional Logic Basics Propositional Equivalences Normal forms Boolean functions and digital circuits. Propositional Logic.

Propositional Logic Basics Propositional Equivalences Normal forms Boolean functions and digital circuits. Propositional Logic. Propositional Logic Winter 2012 Propositional Logic: Section 1.1 Proposition A proposition is a declarative sentence that is either true or false. Which ones of the following sentences are propositions?

More information

Topic 1: Propositional logic

Topic 1: Propositional logic Topic 1: Propositional logic Guy McCusker 1 1 University of Bath Logic! This lecture is about the simplest kind of mathematical logic: propositional calculus. We discuss propositions, which are statements

More information

Mathematical Logic Part One

Mathematical Logic Part One Mathematical Logic Part One An Important Question How do we formalize the logic we've been using in our proofs? Where We're Going Propositional Logic (oday) Basic logical connectives. ruth tables. Logical

More information

PHI Propositional Logic Lecture 2. Truth Tables

PHI Propositional Logic Lecture 2. Truth Tables PHI 103 - Propositional Logic Lecture 2 ruth ables ruth ables Part 1 - ruth unctions for Logical Operators ruth unction - the truth-value of any compound proposition determined solely by the truth-value

More information

DISCRETE MATHEMATICS BA202

DISCRETE MATHEMATICS BA202 TOPIC 1 BASIC LOGIC This topic deals with propositional logic, logical connectives and truth tables and validity. Predicate logic, universal and existential quantification are discussed 1.1 PROPOSITION

More information

Propositional Languages

Propositional Languages Propositional Logic Propositional Languages A propositional signature is a set/sequence of primitive symbols, called proposition constants. Given a propositional signature, a propositional sentence is

More information

THE LOGIC OF COMPOUND STATEMENTS

THE LOGIC OF COMPOUND STATEMENTS CHAPTER 2 THE LOGIC OF COMPOUND STATEMENTS Copyright Cengage Learning. All rights reserved. SECTION 2.1 Logical Form and Logical Equivalence Copyright Cengage Learning. All rights reserved. Logical Form

More information

CHAPTER 1 - LOGIC OF COMPOUND STATEMENTS

CHAPTER 1 - LOGIC OF COMPOUND STATEMENTS CHAPTER 1 - LOGIC OF COMPOUND STATEMENTS 1.1 - Logical Form and Logical Equivalence Definition. A statement or proposition is a sentence that is either true or false, but not both. ex. 1 + 2 = 3 IS a statement

More information

Discrete Mathematics

Discrete Mathematics Discrete Mathematics Discrete mathematics is devoted to the study of discrete or distinct unconnected objects. Classical mathematics deals with functions on real numbers. Real numbers form a continuous

More information

Mathematical Logic Part One

Mathematical Logic Part One Mathematical Logic Part One Announcements Problem Session tonight from 7:00 7:50 in 380-380X. Optional, but highly recommended! Problem Set 3 Checkpoint due right now. 2 Handouts Problem Set 3 Checkpoint

More information

Logic. Def. A Proposition is a statement that is either true or false.

Logic. Def. A Proposition is a statement that is either true or false. Logic Logic 1 Def. A Proposition is a statement that is either true or false. Examples: Which of the following are propositions? Statement Proposition (yes or no) If yes, then determine if it is true or

More information

We last time we began introducing equivalency laws.

We last time we began introducing equivalency laws. Monday, January 14 MAD2104 Discrete Math 1 Course website: www/mathfsuedu/~wooland/mad2104 Today we will continue in Course Notes Chapter 22 We last time we began introducing equivalency laws Today we

More information

Logic and Proofs. (A brief summary)

Logic and Proofs. (A brief summary) Logic and Proofs (A brief summary) Why Study Logic: To learn to prove claims/statements rigorously To be able to judge better the soundness and consistency of (others ) arguments To gain the foundations

More information

Logic. Definition [1] A logic is a formal language that comes with rules for deducing the truth of one proposition from the truth of another.

Logic. Definition [1] A logic is a formal language that comes with rules for deducing the truth of one proposition from the truth of another. Math 0413 Appendix A.0 Logic Definition [1] A logic is a formal language that comes with rules for deducing the truth of one proposition from the truth of another. This type of logic is called propositional.

More information

Logic and Propositional Calculus

Logic and Propositional Calculus CHAPTER 4 Logic and Propositional Calculus 4.1 INTRODUCTION Many algorithms and proofs use logical expressions such as: IF p THEN q or If p 1 AND p 2, THEN q 1 OR q 2 Therefore it is necessary to know

More information

Introduction to Sets and Logic (MATH 1190)

Introduction to Sets and Logic (MATH 1190) Introduction to Sets Logic () Instructor: Email: shenlili@yorku.ca Department of Mathematics Statistics York University Sept 18, 2014 Outline 1 2 Tautologies Definition A tautology is a compound proposition

More information

LOGIC & PROPOSITIONAL EQUIVALENCE

LOGIC & PROPOSITIONAL EQUIVALENCE KS091201 MATEMATIKA DISKRIT (DISCRETE MATHEMATICS ) LOGIC & PROPOSITIONAL EQUIVALENCE Discrete Math Team 2 -- KS091201 MD W-02 Outline Logic Proposition Propositional Variables Logical Operators Presedence

More information

It is not the case that ϕ. p = It is not the case that it is snowing = It is not. r = It is not the case that Mary will go to the party =

It is not the case that ϕ. p = It is not the case that it is snowing = It is not. r = It is not the case that Mary will go to the party = Introduction to Propositional Logic Propositional Logic (PL) is a logical system that is built around the two values TRUE and FALSE, called the TRUTH VALUES. true = 1; false = 0 1. Syntax of Propositional

More information

Propositions. Frequently, we will use the word statement instead of proposition.

Propositions. Frequently, we will use the word statement instead of proposition. Propositional Logic Propositions A proposition is a declaration of fact that is either true or false, but not both. Examples and non-examples: One plus two equals four (proposition) Mozart is the greatest

More information