Sunteți pe pagina 1din 13

LECTURE # 2

STATEMENT FORM

A statement form or propositional form is an expression made up of


statement variables (such as p, q, and r) and logical connectives (such as ~,
,and ) that becomes a statement when actual statements are substituted
for the component statement variable.

TRUTH TABLE FOR A STATEMENT FORM

1. Note the distinct statement variables (such as p, q, r, …) in the


statement form.
2. Write all possible combinations of truth values for the statement
variables. Remember that for n statements variables there are 2n
possible combinations of truth values.
3. Write the truth values for the expression within the innermost
parentheses (expression evaluated left to right), and then within the
next innermost parentheses and so forth, until the complete
expression is evaluated.
Let p and q are the statements then
Negation ~p
is negation of the statement p.
Conjunction pq
is the “and “of the two statements p and q
Disjunction pq
is the “or” of the two statements p and q.
Now we will made some truth tables for practice

1
EXAMPLE
Write truth table for the statement form ~ p  q

p q ~p ~pq
T T F F
T F F F
F T T T
F F T F

Here in order to complete this table we first fill the column for ~p
and from the definition of negation you know that it is false where p is true
and false where p is true.
Then we fill the column for ~ p  q and you know that conjunction of two
statements is true omly when both the statements are true. So ~ p  q is true
only where ~ p and q both have truth values T,which is third row . Hence we
have T in the column of ~ p  q in the third row and write down F in all other
entries.
EXAMPLE
Construct truth table for ~ p  (q  ~ r)

p q r ~r q~r ~p ~ p  (q  ~ r)
T T T F T F F
T T F T T F F
T F T F F F F
T F F T T F F
F T T F T T T
F T F T T T T
F F T F F T F 2
F F F T T T T
EXAMPLE

Truth table for (pq)  ~ (pq)

p q pq pq ~ (pq) (pq)  ~ (pq)


T T T T F F
T F T F T T
F T T F T T
F F F F T F

LOGICAL EQUIVALENCE

Two statement forms are called logically equivalent if, and only if, they
have identical truth values for all possible truth values for their statement
variables.
The logical equivalence of statement forms P and Q is denoted by writing
P  Q.

EXAMPLE
Double Negative Property ~(~p)  p

p ~p ~(~p)
T F T
F T F

Same Truth Values


3
So by the logical equivalence we have ~(~p)  p
EXERCISE

Rewrite in a simpler form:


“It is not true that I am not happy”
Solution:
Let p = “I am happy”
then ~ p = “I am not happy”
and ~(~ p) = “It is not true that I am not happy”
Since ~(~p)  p
Hence the given statement is equivalent to: “I am happy”
The above example shows that using logic we can show that complicated
statements are simple

EXAMPLE

~(pq) and ~p  ~q are not logically equivalent

p q ~p ~q pq ~(pq) ~p  ~q
T T F F T F F
T F F T F T F
F T T F F T F
F F T T F T T

Note that the entries in the last two columns are the same . Hence
the statements forms are logically equivalent that is
~(pq) and ~p  ~q are not logically equivalent
4
DE MORGAN’S LAWS

1) The negation of an and statement is logically equivalent to the or


statement in which each component is negated.
Symbolically ~(p  q)  ~p  ~q.
2) The negation of an or statement is logically equivalent to the and
statement in which each component is negated.
Symbolically: ~(p  q)  ~p  ~q.
Now we will prove the part one of the Demorgan`s Law by using truth
table, you should remember whenever two expressions are logically
equivalent. The first part of the Law is

~(p  q)  ~p  ~q

p q ~p ~q pq ~(p  q) ~p  ~q

T T F F T F F
T F F T T F F
F T T F T F F
F F T T F T T

APPLYING
DE MORGAN’S LAWS

Give negations for each of the following statements:


a. The fan is slow or it is very hot.
b. Akram is unfit and Saleem is injured.
Solution
a. The fan is not slow and it is not very hot.
b. Akram is not unfit or Saleem is not injured.
5
INEQUALITIES AND DEMORGAN’S LAWS

Use DeMorgan’s Laws to write the negation of


-1 < x  4
For some particular real number x
-1 < x  4 means x > –1 and x  4
By DeMorgan’s Law, the negation is:
x > –1 or x  4
Which is equivalent to: x  –1 or x > 4
EXERCISE

Are the statements (p  q)  r and p  ( q  r ) logically equivalent?

p q r pq qr (p  q)  r p  (q  r)
T T T T T T T
T T F T F F F
T F T F F F F
T F F F F F F
F T T F T F F
F T F F F F F
F F T F F F F
F F F F F F F

Since the last two column have the same entries in the columns so we have
their corresponding statement forms are equivalent. That is

(p  q)  r  p  (q  r )
Which is known as the Associative Law for Conjunction.
6
EXERCISE

Are the statements (pq)r and p (q  r) logically equivalent?


In order to prove or disprove the logical equivalence we will make
truth table and if the columns for the given statement forms are not
identical then they are not logical equivalent.

p q r pq (p  q)  r (q  r) p (q  r)

T T T T T T T
T T F T T T T
T F T F T T T
T F F F F F F
F T T F T T F
F T F F F T F
F F T F T T F
F F F F F F F

Now it is clear from above table that the entries of the given
statement forms are not identical so the statement forms are not
logically equivalent.
TAUTOLOGY
A tautology is a statement form that is always true regardless of the truth
values of the statement variables.
A tautology is represented by the symbol “t”.
So if we have to prove that a given statement form is TAUTOLOGY we
will make the truth table for the statement from and if in the column of the
given statement form all the entries are T ,then we say that statement form is
7
tautology.
EXAMPLE: The statement form p  ~ p is tautology.

p ~p p~p
T F T
F T T

Since we have T in the last column so we have p  ~p  t

CONTRADICTION

A contradiction is a statement form that is always false regardless of the


truth values of the statement variables.
A contradiction is represented by the symbol “c”.
So if we have to prove that a given statement form is CONTRADICTION
we will make the truth table for the statement form and if in the column of
the given statement form all the entries are F ,then we say that statement
form is contradiction.
EXAMPLE:
The statement form p  ~ p is a contradiction.

p ~p p~p

T F F
F T F

Since in the last column in the truth table we have F in all the entries
so is a contradiction p  ~p c
8
REMARKS

– Most statements are neither tautologies nor contradictions.


– The negation of a tautology is a contradiction and vice versa.
– In common usage we sometimes say that two statement are
contradictory.
By this we mean that their conjunction is a contradiction: they cannot
both be true.

LOGICAL EQUIVALENCE INVOLVING TAUTOLOGY

1. Show that p  t  p

p t pt

T T T

F T F

Since in the above table the entries in the first and last columns are
identical so we have the corresponding statement forms are Logically
equivalent that is
ptp

9
LOGICAL EQUIVALENCE INVOLVING CONTRADICTION

Show that pc  c

p c pc

T F F
F F F

Same truth values in the indicated columns so pc  c


EXERCISE
Use truth table to show that (p  q) (~p (p  ~q)) is a tautology.
SOLUTION
Since we have to show that the given statement form is
Tautology so the column of the above proposition in the truth table will
have all entries as T.
As clear from the table below

p q pq ~p ~q p~q ~ p (p  ~q) (p  q) 


(~p  (p  ~q))
T T T F F F F T
T F F F T T T T
F T F T F F T T

F F F T T F T T

10
Hence (p  q) (~p (p  ~q))  t
EXERCISE

Use truth table to show that (p  ~q) (~pq) is a contradiction.


SOLUTION
Since we have to show that the given statement form is
Contradiction so its column in the truth table will have all entries
as F. As clear from the table below
p q ~q p~q ~p ~pq (p  ~q) (~pq)
T T F F F T F
T F T T F F F
F T F F T T F
F F T F T T F

USAGE OF “OR” IN ENGLISH

In English language the word or is sometimes used in an inclusive sense (p


or q or both).
Example I shall buy a pen or a book.
In the above statement, if you buy a pen or a book in both cases the
statement is true and if you buy both pen and book then statement is again
true. Thus we say in the above statement we use or in inclusive sense.
The word or is sometimes used in an exclusive sense (p or q but not both).
As in the below statement
Example Tomorrow at 9, I’ll be in Lahore or Islamabad.
Now in above statement we are using or in exclusive sense because both the
statements are true then we have F for the statement.
While defining a disjunction the word or is used in its inclusive sense. Thus
the symbol  means the “inclusive or” 11
EXCLUSIVE OR

When or is used in its exclusive sense, The statement “p or q” means “p or q


but not both” or “p or q and not p and q” which translates into symbols as:
(p q)  ~(p  q)
Which is abbreviated as:
pq
or p XOR q

TRUTH TABLE FOR EXCLUSIVE OR

p q pq pq ~ (pq) (pq)  ~ (pq)

T T T T F F
T F T F T T
F T T F T T
F F F F T F

Note:
Basically
p  q ≡ (p q)~p  q)
≡ [p  ~q) ~p] [(p  ~q)  q]
≡ (p q) p q)
≡ (p q) p ~q)
12
REASONING EXERCISES

1. If two propositions are logically equivalent, what can be said about


their truth tables?
2. If a proposition is neither a tautology nor a contradiction, what can
be said about its truth table?
3. Can a statement with a single variable p be a tautology or a
contradiction? Explain.
4. If A and B are two (possibly compound statements) such that A B
is a contradiction, what can you say about A and B?
5. If A and B are two (possibly compound statements) such that AB
is a tautology, what can you say about A and B?
6. If two statements are logically equivalent to each other, then they
must either be tautologies or contradictions. Is it correct?

13

S-ar putea să vă placă și