Welcome to Scribd, the world's digital library. Read, publish, and share books and documents. See more ➡
Standard view
Full view
of .
×
0 of .
Results for:
P. 1
Discrete Mathematics - W. Chen (1982) WW

Discrete Mathematics - W. Chen (1982) WW

Ratings: 0|Views: 69|Likes:

Availability:

See More
See less

09/14/2011

pdf

text

original

DISCRETE MATHEMATICS
W W L CHEN
c
W W L Chen, 1982.This work is available free, in the hope that it will be useful.Any part of this work may be reproduced or transmitted in any form or by any means, electronic or mechanical, includingphotocopying, recording, or any information storage and retrieval system, with or without permission from the author.
Chapter 1
LOGIC AND SETS
1.1. Sentences
In this section, we look at sentences, their truth or falsity, and ways of combining or connecting sentencesto produce new sentences.A sentence (or proposition) is an expression which is either true or false. The sentence “2 + 2 = 4”is true, while the sentence “
π
is rational” is false. It is, however, not the task of logic to decide whetherany particular sentence is true or false. In fact, there are many sentences whose truth or falsity nobodyhas yet managed to establish; for example, the famous Goldbach conjecture that “every even numbergreater than 2 is a sum of two primes”.There is a defect in our deﬁnition. It is sometimes very diﬃcult, under our deﬁnition, to determinewhether or not a given expression is a sentence. Consider, for example, the expression “I am telling alie”; am I?Since there are expressions which are sentences under our deﬁnition, we proceed to discuss ways of connecting sentences to form new sentences.Let
p
and
q
denote sentences.
Definition.
(CONJUNCTION) We say that the sentence
p
q
(
p
and
q
) is true if the two sentences
p
,
q
are both true, and is false otherwise.
Example 1.1.1.
The sentence “2 + 2 = 4 and 2 + 3 = 5” is true.
Example 1.1.2.
The sentence “2 + 2 = 4 and
π
is rational” is false.
Definition.
(DISJUNCTION) We say that the sentence
p
q
(
p
or
q
) is true if at least one of twosentences
p
,
q
is true, and is false otherwise.
Example 1.1.3.
The sentence “2 + 2 = 2 or 1 + 3 = 5” is false.
This chapter was ﬁrst used in lectures given by the author at Imperial College, University of London, in 1982.

12 W W L Chen : Discrete Mathematic
Example 1.1.4.
The sentence “2 + 2 = 4 or
π
is rational” is true.
Remark.
To prove that a sentence
p
q
is true, we may assume that the sentence
p
is false and usethis to deduce that the sentence
q
is true in this case. For if the sentence
p
is true, our argument isalready complete, never mind the truth or falsity of the sentence
q
.
Definition.
(NEGATION) We say that the sentence
p
(not
p
) is true if the sentence
p
is false, andis false if the sentence
p
is true.
Example 1.1.5.
The negation of the sentence “2 + 2 = 4” is the sentence “2 + 2
= 4”.
Example 1.1.6.
The negation of the sentence “
π
is rational” is the sentence “
π
is irrational”.
Definition.
(CONDITIONAL) We say that the sentence
p
q
(if
p
, then
q
) is true if the sentence
p
is false or if the sentence
q
is true or both, and is false otherwise.
Remark.
It is convenient to realize that the sentence
p
q
is false precisely when the sentence
p
istrue and the sentence
q
is false. To understand this, note that if we draw a false conclusion from a trueassumption, then our argument must be faulty. On the other hand, if our assumption is false or if ourconclusion is true, then our argument may still be acceptable.
Example 1.1.7.
The sentence “if 2+2 = 2, then 1+3 = 5” is true, because the sentence “2+2 = 2”is false.
Example 1.1.8.
The sentence “if 2 + 2 = 4, then
π
is rational” is false.
Example 1.1.9.
The sentence “if
π
is rational, then 2 + 2 = 4” is true.
Definition.
(DOUBLE CONDITIONAL) We say that the sentence
p
q
(
p
if and only if
q
) is trueif the two sentences
p
,
q
are both true or both false, and is false otherwise.
Example 1.1.10.
The sentence “2 + 2 = 4 if and only if
π
is irrational” is true.
Example 1.1.11.
The sentence “2 + 2
= 4 if and only if
π
is rational” is also true.If we use the letter
to denote “true” and the letter
to denote “false”, then the above ﬁvedeﬁnitions can be summarized in the following “truth table”:
p q p
q p
q p p
q p
qT T T T F T T F F T F F F T F T T T F F F F T T
Remark.
Note that in logic, “or” can mean “both”. If you ask a logician whether he likes tea or coﬀee,do not be surprised if he wants both!
Example 1.1.12.
The sentence (
p
q
)
(
p
q
) is true if exactly one of the two sentences
p
,
q
is true,and is false otherwise; we have the following “truth table”:
p q p
q p
q p
q
(
p
q
)
(
p
q
)
T T T T F T F F T T F T F T T F F F F T

Chapter 1 : Logic and Sets 1
1.2. Tautologies and Logical Equivalence
Definition.
A tautology is a sentence which is true on logical ground only.
Example 1.2.1.
The sentences (
p
(
q
r
))
((
p
q
)
r
) and (
p
q
)
(
q
p
) are both tautologies.This enables us to generalize the deﬁnition of conjunction to more than two sentences, and write, forexample,
p
q
r
without causing any ambiguity.
Example 1.2.2.
The sentences (
p
(
q
r
))
((
p
q
)
r
) and (
p
q
)
(
q
p
) are both tautologies.This enables us to generalize the deﬁnition of disjunction to more than two sentences, and write, forexample,
p
q
r
without causing any ambiguity.
Example 1.2.3.
The sentence
p
p
is a tautology.
Example 1.2.4.
The sentence (
p
q
)
(
q
p
) is a tautology.
Example 1.2.5.
The sentence (
p
q
)
(
p
q
) is a tautology.
Example 1.2.6.
The sentence (
p
q
)
((
p
q
)
(
p
q
)) is a tautology; we have the following “truthtable”:
p q p
q
(
p
q
) (
p
q
)
(
p
q
) (
p
q
)
((
p
q
)
(
p
q
))
T T T F F T F F T T F T F T T F F T F F
The following are tautologies which are commonly used. Let
p
,
q
and
r
denote sentences.
DISTRIBUTIVE LAW.
The following sentences are tautologies:(a)
(
p
(
q
r
))
((
p
q
)
(
p
r
))
;(b)
(
p
(
q
r
))
((
p
q
)
(
p
r
))
.
DE MORGAN LAW.
The following sentences are tautologies:(a)
(
p
q
)
(
p
q
)
;(b)
(
p
q
)
(
p
q
)
.
INFERENCE LAW.
The following sentences are tautologies:(a)
(MODUS PONENS) (
p
(
p
q
))
q
;(b)
(MODUS TOLLENS) ((
p
q
)
q
)
p
;(c)
(LAW OF SYLLOGISM) ((
p
q
)
(
q
r
))
(
p
r
)
.
These tautologies can all be demonstrated by truth tables. However, let us try to prove the ﬁrstDistributive law here.Suppose ﬁrst of all that the sentence
p
(
q
r
) is true. Then the two sentences
p
,
q
r
are bothtrue. Since the sentence
q
r
is true, at least one of the two sentences
q
,
r
is true. Without loss of generality, assume that the sentence
q
is true. Then the sentence
p
q
is true. It follows that the sentence(
p
q
)
(
p
r
) is true.Suppose now that the sentence (
p
q
)
(
p
r
) is true. Then at least one of the two sentences (
p
q
),(
p
r
) is true. Without loss of generality, assume that the sentence
p
q
is true. Then the two sentences
p
,
q
are both true. It follows that the sentence
q
r
is true, and so the sentence
p
(
q
r
) is true.It now follows that the two sentences
p
(
q
r
) and (
p
q
)
(
p
r
) are either both true orboth false, as the truth of one implies the truth of the other. It follows that the double conditional(
p
(
q
r
))
((
p
q
)
(
p
r
)) is a tautology.