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

Similar documents
Discrete Mathematical Structures. Chapter 1 The Foundation: Logic

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

Chapter 1, Section 1.1 Propositional Logic

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

Discrete Mathematics and Applications COT3100

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

CSC Discrete Math I, Spring Propositional Logic

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

Compound Propositions

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

Definition 2. Conjunction of p and q

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

Propositional logic ( ): Review from Mat 1348

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

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

Propositional Logic 1

CSE 240 Logic and Discrete Mathematics

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

DISCRETE MATHEMATICS BA202

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

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

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

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

The Foundations: Logic and Proofs. Part I

EECS 1028 M: Discrete Mathematics for Engineers

software design & management Gachon University Chulyun Kim

Section 1.1: Logical Form and Logical Equivalence

Logic and Proof. Aiichiro Nakano

Logic and Proofs. Jan COT3100: Applications of Discrete Structures Jan 2007

Today s Topic: Propositional Logic

The Logic of Compound Statements cont.

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

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

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

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

2/13/2012. Logic: Truth Tables. CS160 Rosen Chapter 1. Logic?

MAT2345 Discrete Math

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

Announcements CompSci 102 Discrete Math for Computer Science

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

DISCRETE STRUCTURES WEEK5 LECTURE1

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

Why Learning Logic? Logic. Propositional Logic. Compound Propositions

CHAPTER 1 - LOGIC OF COMPOUND STATEMENTS

LOGIC & PROPOSITIONAL EQUIVALENCE

Boolean Logic. CS 231 Dianna Xu

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

Discrete Structures for Computer Science

LOGIC CONNECTIVES. Students who have an ACT score of at least 30 OR a GPA of at least 3.5 can receive a college scholarship.

Propositional Languages

Discrete Mathematics and Its Applications

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

UNIT-I: Propositional Logic

1.3 Propositional Equivalences

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

ECOM Discrete Mathematics

Section 3.1 Statements, Negations, and Quantified Statements

ARTIFICIAL INTELLIGENCE

Introduction Propositional Logic. Discrete Mathematics Andrei Bulatov

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

The statement calculus and logic

Logic and Propositional Calculus

Formal Logic. Critical Thinking

PROPOSITIONAL CALCULUS

CSE 20 DISCRETE MATH. Fall

Chapter 1: Formal Logic

Foundation of proofs. Jim Hefferon.

Introduction to Sets and Logic (MATH 1190)

1.1 Language and Logic

Discrete Mathematics and Its Applications

Truth Tables for Arguments

GEOMETRY. Chapter 2: LOGIC. Name: Teacher: Pd:

CHAPTER 1. MATHEMATICAL LOGIC 1.1 Fundamentals of Mathematical Logic

Chapter 2: The Logic of Compound Statements

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

THE LOGIC OF COMPOUND STATEMENTS

Logical Operators. Conjunction Disjunction Negation Exclusive Or Implication Biconditional

Department of Computer Science & Software Engineering Comp232 Mathematics for Computer Science

Mathematical Logic Part One

Discrete Mathematics

ICS141: Discrete Mathematics for Computer Science I

CITS2211 Discrete Structures. Propositional Logic

10/5/2012. Logic? What is logic? Propositional Logic. Propositional Logic (Rosen, Chapter ) Logic is a truth-preserving system of inference

PHI Propositional Logic Lecture 2. Truth Tables

Discrete Structures of Computer Science Propositional Logic I

13.3 Truth Tables for the Conditional and the Biconditional

1.1 Language and Logic

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

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

CSCI Homework Set 1 Due: September 11, 2018 at the beginning of class

Computer Science 280 Spring 2002 Homework 2 Solutions by Omar Nayeem

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

Announcement. Homework 1

Propositional Equivalence

Math.3336: Discrete Mathematics. Propositional Equivalences

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

Chapter 5: Section 5-1 Mathematical Logic

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

Mathematical Logic Part One

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

Transcription:

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 of Computer Science and Engineering South China University of echnology Agenda Ch1.1 Propositional Logic Proposition Propositional Operator Compound Proposition Applications Ch1.2 Propositional Equivalences Logical Equivalences Using De Morgan's Laws Constructing New Logical Equivalences Chapter 1.1 & 1.2 2

Warm Up John is a cop. John knows first aid. herefore, all cops know first aid Chapter 1.1 & 1.2 3 Warm Up Human walks by two legs. Human is mammal. Mammal walks by two legs. Chapter 1.1 & 1.2 4

Warm Up he clock alarm of my iphone does not work today. he clock alarm of iphone does not work on 1-1-2011. So, today is 1-1-2011 Chapter 1.1 & 1.2 5 Warm Up Some students work hard to study. Some students fail in examination. So, some work hard students fail in examination. Chapter 1.1 & 1.2 6

Small Quiz Next few pages contain 4 questions Write down the answer of each question on a paper Remember No Discussion Do not modify answers you written down Chapter 1.1 & 1.2 7 Small Quiz: Question 1 According to the law, only a person who is elder than 21-year-old can have alcoholic drink You are a police. Which person(s) you need to check? Drink ea Drink Beer 23-year-old 19-year-old Chapter 1.1 & 1.2 8

Small Quiz: Question 2 According to a policy of a company, if someone surf the Internet longer than 2 hours, he/she has to earn more than 300k You are the boss of this company. Which staff(s) you need to check? 1h Surfing 3h Surfing Earned 200k Earned 400k Chapter 1.1 & 1.2 9 Small Quiz: Question 3 A company publishes a desk Each card has two sides: a character and a number If one side of a card is a vowel, the number on the other side should be even number You are a QC staff. Which card(s) you need to check? E 4 7 Chapter 1.1 & 1.2 10

Small Quiz: Question 4 A company publishes another desk: each card has two sides: a shape and a color If one side of a card is a circle, the color on the other side should be yellow You are a QC staff. Which card(s) you need to check? Chapter 1.1 & 1.2 11 Small Game: Answer Q1: Only a person who is elder than 21-year-old can have alcoholic drink Q2: If someone surf the Internet longer than 2 hours, he/she has to earn more than 300k Q3: If one side of a card is a vowel, the number on the other side is even number ea Beer 23 19 1h 3h 200k 400k E 4 7 Q4: If one side of a card is a circle, the color on the other side is yellow Chapter 1.1 & 1.2 12

Introduction In this chapter, we will explain how to make up a correct mathematical argument prove the arguments Chapter 1.1 & 1.2 13 Propositions Proposition (also called statement) is a declarative sentence (declares a fact) that is either true or false, but not both ruth value of a proposition is either rue/alse (/) to indicate its correctness Example: Keep quite 1 hour has 50 minutes 1 + 1 = 3 x + 2 = 4 alse Not declarative alse Can be either true or false Can be turned into proposition when x is defined Chapter 1.1 & 1.2 14

Propositions Proposition Variable is letters denote propositions Conventional letters are p,q,r,s, P,Q, Example: r : Peter is a boy Proposition Logic is the area of logic that deals with propositions Logic Operators NO AND OR XOR If then (Conditional Statement ) If and Only If (Biconditional Statement) Chapter 1.1 & 1.2 15 Proposition Logic Negation Operator (Not) Definition Let p be a proposition Negation of p is the statement It is not the case that p Notation: p, ~p, p Read as not p ruth value Opposite of the truth value of p Example: p: you are a student p: You are not a student Chapter 1.1 & 1.2 16

Proposition Logic Conjunction Operator (AND) Definition Let p and q be propositions Conjunction of p and q is p andq Notation: p q points up like an A, which means ND ruth value rue when both p and q are true alse otherwise Example: p: Peter likes to play, q: Peter likes to read p q: Peter likes to play and Peter likes to read Chapter 1.1 & 1.2 17 Proposition Logic Disjunction Operator (OR) Definition Let p and q be propositions Disjunction of p and q is p orq Notation: p q points up like an r, means O ruth value alse when both p and q are false rue otherwise Example: p: Peter likes to play, q: Peter likes to read p q: Peter likes to play or Peter likes to read Chapter 1.1 & 1.2 18

Proposition Logic Disjunction Operator (OR) In English, ORhas more than one meanings Example: Jackie is a singer ORJackie is an actor Either one or both (inclusive) Disjunction operation (OR, ) Jackie is a man ORJackie is a woman Either one but no both (exclusive) Exclusive OR operation( ) Chapter 1.1 & 1.2 19 Proposition Logic Exclusive OR Operator (XOR) Definition Let pand qbe propositions Notation: p q, p q, p +q ruth value rue whenexactly one ofpandqistrue alse otherwise Example: p: You can have a tea, q: You can have a coffee p q: You can have a tea ora coffee, but not both (exclusive or) Chapter 1.1 & 1.2 20

Small Exercise Given p: oday is riday q: It is raining today What is? p oday is not riday Which is correct? Why? omorrow is Wednesday Yesterday is riday oday is not Monday hey provide more information than p p q oday is riday and it is raining today p q oday is riday or it is raining today p q Either today is riday or it is raining today, but not both Chapter 1.1 & 1.2 21 Small Exercise Given p: x > 50 q: x < 100 What is? p p q p q p q x 50 x 100 or x 50 100 > x > 50 x can be any number Both qand pis Only qis Only pis qis pis 50 100 Chapter 1.1 & 1.2 22

Proposition Logic ruth able ruth able displays the relationships between the truth values of propositions Example: ruth able of Negation Operation P P Operand Column Result Column Chapter 1.1 & 1.2 23 Proposition Logic ruth able NO AND OR XOR p q p p q p q p q Chapter 1.1 & 1.2 24

Proposition Logic Conditional Statement (imply) Definition Let pand qbe propositions Conditionalstatement is if p, then q Notation: p q p is called the hypothesis(or antecedent or premise) q is called the conclusion(or consequence) ruth value alsewhen pistrue and qisfalse rue otherwise Example p q p q p: you work hard, q: you will pass this subject p q: If you work hard, then you will pass this subject Chapter 1.1 & 1.2 25 Proposition Logic Conditional Statement (imply) Example: p: You give me twenty dollars q: We are the best friends What is p q? If you give me twenty dollars, then we are the best friends Assume p q is true, what does you do not give me twenty dollars ( p) mean? Does it mean We are not the best friend ( p q)? Chapter 1.1 & 1.2 26

Proposition Logic Conditional Statement (imply) Example: Given p q If it rains, the floor is wet Situation 1 ( p q) If it does not rain, the floor is not wet Situation 2 (q p) If the floor is wet, it rains Situation 3 ( q p) p q and its Contrapositive are equivalent Converse and Inverse are equivalent Inverse Converse Contrapositive If the floor is not wet, it does not rain Chapter 1.1 & 1.2 27 Proposition Logic: Conditional Statement Necessary Condition o say that pis anecessary conditionfor q, it is impossible to have q without p Example Breathing is necessary condition for human life You cannot find a non-breathing human who is alive aking a flight is not necessary condition to go to Beijing You can go to Beijing by train, bus Chapter 1.1 & 1.2 28

Proposition Logic: Conditional Statement Sufficient Condition o say that pis asufficientconditionfor q, the presence of p guarantees the presence of q Example Being divisible by 4 is sufficient for being an even number Working hard is not sufficient for having a good examination result Chapter 1.1 & 1.2 29 Proposition Logic: Conditional Statement Necessary / Sufficient Condition Relation between conditional statement and necessary / sufficient condition Necessary Condition E.g. Breathing is necessary condition for human life P is necessary P Q condition of Q Sufficient Condition E.g. Being divisible by 4 is sufficient for being an even number P Q P is sufficient condition of Q p q p q p q is equivalent to: p is sufficient condition of q q is necessary condition of p Chapter 1.1 & 1.2 30

Proposition Logic Conditional Statement (imply) Other equivalent forms for P Q: Pis a sufficient condition for Q Qis a necessary condition for P Pimplies Q If P, then Q If P, Q Qif P Qwhenever P Ponly if Q P cannot be true when Q is not true Q is necessary condition for P Chapter 1.1 & 1.2 31 Proposition Logic Conditional Statement (imply) Remark: No causalityis implied in P Q P may not cause Q or example: If I have more money than Bill Gates, then a rabbit lives on the moon Chapter 1.1 & 1.2 32

Proposition Logic Conditional Statement (imply) Example: A mother tells her child that If you finish your homework, then you can eat the ice-cream What does it mean? Case 1 (p q) Homework is finished, p q p q you can eat the ice-cream Homework is not finished, you can/cannot eat the ice-cream Case 2 Homework is finished, you can eat the ice-cream Homework is not finished, you cannot eat the ice-cream Chapter 1.1 & 1.2 33 Proposition Logic Biconditional Statement (equivalent) Definition Let pand qbe propositions Biconditional statement is p if and only if q (iff) Notation: p q, p =q, p q Also called bi-implications, equivalence Equivalent to(p q) (q p) ruth value ruewhen pand qhave thesame truth values alseotherwise p q p q Chapter 1.1 & 1.2 34

Proposition Logic Biconditional Statement (equivalent) Example: p: You take the flight q: you buy a ticket What is p q? You take the flight if and only if you buy a ticket No ticket, no flight No flight, no ticket Chapter 1.1 & 1.2 35 Proposition Logic: Conditional Statement Necessary / Sufficient Condition p is necessarybut notsufficientfor q q p p is sufficientbut not necessaryfor q p q p is both necessary and sufficientfor q q p p q p q q is also both necessary and sufficientfor p Chapter 1.1 & 1.2 36

Proposition Logic Remarks: In ordinary speech, words like or and if-then may have multiple meanings In this technical subject, we assume that or means inclusive or ( ) if-then means implication ( ) Chapter 1.1 & 1.2 37 Proposition Logic Summary ormal Name Nickname Symbol Negation Operator NO Conjunction Operator AND Disjunction Operator OR Exclusive-OR Operator XOR Conditional Statement Imply Biconditional Statement Equivalent Chapter 1.1 & 1.2 38

Proposition Logic Summary p q p p q p q p q p q p q Chapter 1.1 & 1.2 39 Compound Proposition Compound Propositions are formed from existing propositions using proposition logical operators Example: Beijing is the capital of China and 1+1=2 How can we determine the truth values of the complicated compound propositions involving any number of propositional variables? Example: What is the truth value for every situations? p q s q p Chapter 1.1 & 1.2 40

Compound Proposition Precedence of Logical Operator Precedence Operator 1 NO 2 AND 3 OR XOR 4 Imply 5 Equivalent Example: p q r p (q r) (p q) r s f ( s) f (s f) a f b (a f) b a (f b) Chapter 1.1 & 1.2 41 Compound Proposition Example: 1. p q s q p 2. p ( q) s q p 3. p ( q) (s q) p 4. p ( q) ((s q) p) 5. (p ( q)) ((s q) p) Precedence Operator 1 2 3 4 5 herefore, p q s q p is equal to (p ( q)) ((s q) p) Chapter 1.1 & 1.2 42

Compound Proposition ruth tables can be used to determine the truth values of the complicated compound propositions Algorithm: 1. Write down all the combinations of the compositional variables 2. ind the truth value of each compound expression that occurs in the compound proposition according to the operator precedence Chapter 1.1 & 1.2 43 Compound Proposition Example: (p q) (s q) p 1 2 3 4 5 p q s Chapter 1.1 & 1.2 44

Compound Proposition Example: (p q) (s q) p 1 2 3 4 5 p q s Chapter 1.1 & 1.2 45 Compound Proposition Example: (p q) (s q) p 1 2 3 4 5 p q s q Chapter 1.1 & 1.2 46

Compound Proposition Example: (p q) (s q) p 1 2 3 4 5 p q s q s q Chapter 1.1 & 1.2 47 Compound Proposition Example: (p q) (s q) p 1 2 3 4 5 p q s q s q (s q) p Chapter 1.1 & 1.2 48

Compound Proposition Example: (p q) (s q) p 1 2 3 4 5 p q s q s q (s q) p p q Chapter 1.1 & 1.2 49 Compound Proposition Example: (p q) (s q) p 1 2 3 4 5 p q s q s q (s q) p p q (p q) (s q) p Chapter 1.1 & 1.2 50

Small Exercise Write down the truth table for the following compound statement: p r q p r p q p p q p q p q p q p q 1 2 3 4 5 Chapter 1.1 & 1.2 51 Small Exercise p r q p r (p (r q)) (p ( r)) 1 2 3 4 5 p q r r r q p (r q) p ( r) (p (r q)) (p ( r)) Chapter 1.1 & 1.2 52

ranslating English Sentences Human language is often ambiguous ranslating human language into compound propositions (logical expression) removes the ambiguity Chapter 1.1 & 1.2 53 ranslating English Sentences Algorithm: 1. Remove the connective operators 2. Let a variable for each complete concept 3. Use the operators to connect the variables 4. Adding brackets in suitable positions will be helpful Example: p: You can access the Internet from campus q: You are a computer science major s: You are a freshman You can access the Internet from campus only if you are a computer science major or you are not a freshman p ( q s) Chapter 1.1 & 1.2 54

Applications System Specifications Specifications are the essential part of the system and software engineering Specifications should be consistent, otherwise, no way to develop a system that satisfies all specifications Consistence means all specifications can be true Chapter 1.1 & 1.2 55 Applications System Specifications Example: here are three specifications for a particular system, are they consistent? he diagnostic message is stored in the buffer or it is retransmitted. he diagnostic message is not stored in the buffer. If the diagnostic message is stored in the buffer, then it is retransmitted. Chapter 1.1 & 1.2 56

Applications System Specifications he diagnostic message is stored in the buffer or it is retransmitted. he diagnostic message is not stored in the buffer. 1. Remove the connective operators 2. Let a variable for each complete concept 3. Use the operators to connect the variables 4. Adding brackets in suitable positions will be helpful If the diagnostic message is stored in the buffer, then it is retransmitted. P Q P P Q P: he diagnostic message is stored in the buffer Q: he diagnostic message is retransmitted hese specifications are consistent P Q P Q P P Q (P Q) ( P) (P Q) Chapter 1.1 & 1.2 57 Applications Logic and Bit Operations Information stored in a computer is represented by bits E.g. A = 0100 0001 Bit = Binary Digit, i.e. 0 or 1 ( or ) Logic connectives can be used as bit operation Bitwise OR ( ) the OR of the corresponding bits in the two strings Bitwise AND ( ) the AND of the corresponding bits in the two strings Bitwise XOR ( ) the XOR of the corresponding bits in the two strings Chapter 1.1 & 1.2 58

Applications Logic and Bit Operations Example: A B Bit-wise OR Bit-wise AND Bit-wise XOR 1011 0110 0001 1101 1011 1111 0001 0100 1010 1011 Chapter 1.1 & 1.2 59 Applications Logic Puzzles Puzzles that can be solved using logical reasoning are known as logic puzzles Can be solved by using rules of logic Example: here are two kinds of peopleon an island Batman: Always tell the truth Joker: Always lie One day, you encounter two peoples A and B. A says B is a Batman B says he two of us are opposite types What are A and B? Chapter 1.1 & 1.2 60

Applications Logic Puzzles Batman: Always tell the truth Joker: P Q Always lie A says B is a Batman B says he two of us are opposite types A B P Q 61 Chapter 1.1 & 1.2 ypes of Proposition autology A compound proposition which is always true Example: P P P P P P Contradiction A compound proposition which is always false Example: P P P P P P Contingency A compound proposition which is neither a tautology nor a contradiction P P P P (P P) Example: P (P P) Chapter 1.1 & 1.2 62

ypes of Proposition Example Are they autology, Contradiction or Contingency? P P P P P P P Q P Q (P Q) Q autology Contradiction autology Contingency Contingency Contradiction Chapter 1.1 & 1.2 63 Logically Equivalence An importanttype of step used in a mathematical argument is the replacement of a statement with another statementwith the same truth value We would like to discuss about the equivalences of arguments Chapter 1.1 & 1.2 64

Logically Equivalence Definition wo propositions Pand Qare logically equivalentif P Qis a tautology Notation: P Q or P Q Chapter 1.1 & 1.2 65 Logically Equivalence ruth able can be used to testif compositions are logically equivalent Example: if p q and p q are logically equivalent? p q ~p q p q p q p q Chapter 1.1 & 1.2 66

Logically Equivalence Example: Show p (q r) (p q) (p r) p q r q r p (q r) p q p r (p q) (p r) Chapter 1.1 & 1.2 67 Logically Equivalence Characteristic of ruth able Assume nis the number of variables, Raw of tables = 2 n E.g. 20 variables, 2 20 = 1048576 Not efficient Besides the ruth able, we will introduce a series of logical equivalences p q p p q s p q s Chapter 1.1 & 1.2 68

Logically Equivalence Example: Show (p q) (p r) p (q r) (p q) (p r) ( p q) ( p r) ( p p) (q r) p (q r) p (q r) Logical Equivalences P Q P Q P P P P (Q R) (P Q) R p q r q r p (q r) p q p r (p q) (p r) Chapter 1.1 & 1.2 69 Important Equivalences Identify Laws p p p p p p p p Domination Laws p p p p p p Chapter 1.1 & 1.2 70

Important Equivalences Idempotent Laws p p p p p p p p p p p p Double Negation Law ( p) p p p ( p) Chapter 1.1 & 1.2 71 Important Equivalences Negation Laws p p p p p p p p p p p p Chapter 1.1 & 1.2 72

Important Equivalences Commutative Laws p q q p p q q p p q q p q p p q q p q p Chapter 1.1 & 1.2 73 Important Equivalences Associative Laws p (q r) (p q) r p (q r) (p q) r p q r q r p (q r) p q (p q) r p q r q r p (q r) p q (p q) r Chapter 1.1 & 1.2 74

Important Equivalences Distributive Laws p (q r) p (q r) (p q) (p r) (p q) (p r) p q r q r p (q r) p q p r (p q) (p r) p q r q r p (q r) p q p r (p q) (p r) Chapter 1.1 & 1.2 75 Important Equivalences How about p (p q)? (p p) (p q) p (p q) p (p q)? (p p) (p q) p (p q) Distributive Laws p (q r) (p q) (p r) p (q r) (p q) (p r) Chapter 1.1 & 1.2 76

Important Equivalences Absorption Laws p q p q p (p q) p (p q) p (p q) p p p q p q p (p q) Chapter 1.1 & 1.2 77 Important Equivalences De Morgan s Laws (p q)? p q (p q)? p q p q p q (p q) p q p q p q p q (p q) p q p q Chapter 1.1 & 1.2 78

Recall, De Morgan s Laws Important Equivalences (p q) p q De Morgan s Laws Extension (p 1 p 2... p n )? Assume q= p 2... p n (p 1 p 2... p n ) = (p 1 q) According to De Morgan s Law... (p I q)= p 1 q= p 1 (p 2... p n ) Chapter 1.1 & 1.2 79 Recall, De Morgan s Laws Important Equivalences Assume s = p 3... p n (p 2 p 3... p n ) = (p 2 s) According to De Morgan s Law (p 2 s) = p 1 s = p 2 (p 3... p n ) herefore, (p q) p q (p 1 p 2... p n ) = p 1 p 2 p n Chapter 1.1 & 1.2 80

Important Equivalences De Morgan s Laws Extension herefore, (p q) p q (p 1 p 2... p n ) = p 1 p 2 p n Similarly, (p q) p q (p 1 p 2... p n ) = p 1 p 2 p n Chapter 1.1 & 1.2 81 Identify Laws Domination Laws Idempotent Laws Double Negation Law Commutative Laws Associative Laws p p p p p p p p p p p p ( p) p p q q p p q q p p (q r) (p q) r p (q r) (p q) r Distributive Laws p (q r) (p q) (p r) p (q r) (p q) (p r) De Morgan s Laws (p q) p q (p q) p q Absorption Laws Negation Laws p (p q) p p (p q) p p p p p Chapter 1.1 & 1.2 82

Some Important Equivalences Important equivalences about Implication P Q Q P Q You only need to memorize this P Q Q P P Q P Q P Q (P Q) (P Q) P Q (P Q) (P R) P (Q R) (P R) (Q R) (P Q) R (P Q) (P R) P (Q R) (P R) (Q R) (P Q) R Chapter 1.1 & 1.2 83 P Q Q P Let P = S and Q = P Q P Q ** ( S) Substitution S Double Negation Law S ** Q P Substitution (P Q) P Q (P Q) ( P Q) ** P Q De Morgan s Laws P Q P Q Let P = S P Q S Q Substitution S Q ** P Q Substitution P Q (P Q) P Q ( P Q) De Morgan s Laws (P Q) ** **P Q P Q Chapter 1.1 & 1.2 84

(P Q) (P R) P (Q R) (P R) (Q R) (P Q) R (P Q) (P R) ( P Q) ( P R) P (Q R) Distributive Laws P (Q R) ** (P R) (Q R) ** ( P R) ( Q R) ** ( P Q) R Distributive Laws (P Q) R De Morgan slaws (P Q) R ** (P Q) (P R) P (Q R) (P R) (Q R) (P Q) R (P Q) (P R) ( P Q) ( P R) ** ( P R) ( Q R) ** P P (Q R) Associative Laws ( P Q) R R Associative Laws P (Q R) P (Q R) ** **P Q P Q Idempotent Laws (P R) (Q R) ( P Q) R Idempotent Laws (P Q) R De Morgan s Laws (P Q) R ** Chapter 1.1 & 1.2 85 Some Important Equivalences Important equivalences about if and only if: P Q Q (P Q) (Q P) You only need to memorize this P Q (P Q) ( P Q) P Q P Q (P Q) P Q P Q (P Q) (Q P) ( P Q) ( Q P) **P Q P Q Chapter 1.1 & 1.2 86

Some Important Equivalences P Q (P Q) ( P Q) P Q ** P Q P Q ## P Q (P Q) (Q P) ( P Q) ( Q P) ( P Q) ( Q P) ## (( P Q) Q) (( P Q) P) Distributive Laws (( P Q) (Q Q)) (( P P) (Q P)) Distributive Laws (( P Q) ) ( (Q P)) Negation Laws ( P Q) (Q P) Identify Laws Chapter 1.1 & 1.2 87 Some Important Equivalences P Q P Q Let P= S and Q= P Q ** P Q P Q ## P Q (P Q) (Q P) ( P Q) ( Q P) ( P Q) ( Q P) ## (S ) ( S) Substitution S ## P Q Substitution Chapter 1.1 & 1.2 88

Some Important Equivalences (P Q) P Q (P Q) (( P Q) ( Q P)) ## ( P Q) ( Q P) (P Q) (Q P) ((P Q) Q) ((P Q) P) ((P Q) ( Q Q)) ((P P) ( Q P)) (P Q) ( Q P) (P Q) ( Q P) P Q ## De Morgan s Laws De Morgan s Laws Identify Laws ** P Q P Q ## P Q (P Q) (Q P) ( P Q) ( Q P) Distributive Laws Negation Laws Distributive Laws Chapter 1.1 & 1.2 89 End of 1.1 and 1.2 Chapter 1.1 & 1.2 90