logical equivalence - jeremy9959.net

8
Logical Equivalence

Upload: others

Post on 13-Mar-2022

11 views

Category:

Documents


0 download

TRANSCRIPT

Logical Equivalence

Equivalence

Two statements P and Q are logically equivalent if P ≈∆ Q is

always true.For example, P =∆ Q and “Q or ≥ P” are logically equivalent.

To see this, look at the truth table for

(P =∆ Q) ≈∆ (≥ P ‚ Q).

We can write “=” instead of ≈∆ in these situations.

t

P I EE EC I

iii

i

Other ways of thinking about logical equivalence

Another way to think of logical equivalence is that two statements

made up of statements P, Q, R, . . . are logically equivalent if their

truth tables are the same.

If you getAPIA on the final Fist Aaaa

you will purs the coursebutyoudon'tpars

QfontIt as you Easy IIIA

Boolean Algebra

One can think of a kind of algebra made up of statements together

with operations And, Or, Not, implies, and so on. From this point

of view, two expressions made up of statements are “equal” or “the

same” if they are logically equivalent.

In fact this is called Boolean Algebra and is an important tool in

computer science.

P Q R statements

v A

Pvr rQ r 5

DeMorgan’s Laws

I NOT (P AND Q) is equivalent to ((NOT P) or (NOT Q))

I NOT (P OR Q) is equivalent to ((NOT P) and (NOT Q))

prod C PV Q

PAO CPAQ p Q punQPQ FTT T F F F

F T TT F F TF T F T T F T

F F F T T T TT A I

Pva l Ps Q

Contrapositive

(P =∆ Q) = (≥ Q =∆ ≥ P)

p a coarse Q p

t e 97477

If P then Q If Not On THEN NOT R

P Q P Q Q P Q PT T T F F T

T F F T F F

F T T F T T

F F T T T T

If it is raining then it is cloudy

If it is not cloudy then it is not raining

Associative Laws

P · (Q · R) = (P · Q) · Ra

PVCQUR fPVQ vR

our pre for AR MCQARP Q R T T TT T T T

T F FT T F F

FT F T FT F F F F

T T TO Fp

F T F F F i

F F T F F ei

F F F F F F F

Distributive Laws for AND over OR or OR over AND

P · (Q ‚ R) = ((P · Q) ‚ (P · R))c pv QAR Pva ACPERlX t

Px Qtr PxQ t PxR7

QUR PACQUR PAG PAR G vCMR cP Q R

T T T T TTTT r n F TTT F T Tr l

T F T T T F T T

T F F F F F F F

F T T T F F F F

F T F T F F F F

F FT T F F F F

F F F F F F F F