has interviewed four witnesses to a crime.
From the stories of the witnesses the
detective has concluded that if the butler
is telling the truth then so is the cook; the
cook and the gardener cannot both be
telling the truth; the gardener and the
handyman

values before we run the program. So, for
this precondition we can use the
predicate P (x, y), where P (x, y) is the
statement x = a and y = b, where a and b
are the values of x and y before we run the
program. Because we want to verify that
the program s

an inventor, a lifelong student of medicine,
a book reviewer, a dramatist and an actor,
a short story writer, a phenomenologist, a
logician, and a metaphysician. He is noted
as the preeminent system-building
philosopher competent and productive in
logic,

notation p q denotes that p and q are
logically equivalent. Remark: The symbol
is not a logical connective, and p q is
not a compound proposition but rather is
the statement that p q is a tautology.
The symbol is sometimes used instead
of to denote logic

often more efficient not to, as Example 9
demonstrates. EXAMPLE 9 Determine
whether each of the compound
propositions (p q) (q r) (r
p), (p q r) (p q r), and (p
q) (q r) (r p) (p q r)
(p q r) is satisfiable. Solution:
Instead of using truth table to so

q) and p q agree for all possible
combinations of the truth values ofp and
q, it follows that (p q) (p q)is a
tautology and that these compound
propositions are logically equivalent.
TABLE 3 Truth Tables for (p q) and p
q. p q p q (p q) p q p q T T
TFF

honest or corrupt. Suppose you know that
at least one of the Freedonian senators is
honest and that, given any two
Freedonian senators, at least one is
corrupt. Based on these facts, can you
determine how many Freedonian
senators are honest and how many a

q) by the first De Morgan law (p p)
(q q) by the associative and
commutative laws for disjunction T T
by Example 1 and the commutative law
for disjunction T by the domination law
Propositional Satisfiability A
compound proposition issatisfiable if
there

branch leads to the ruins you want to
visit; the other branch leads deep into the
jungle. A villager is standing at the fork in
the road. What one question can you ask
the villager to determine which branch to
take? 16. An explorer is captured by a
group

also states that he P1: 1/1 P2: 1/2 QC:
1/1 T1: 2 CH01-7T Rosen-2311T
MHIA017-Rosen-v5.cls May 13, 2011
15:27 24 1 / The Foundations: Logic and
Proofs saw both Smith and Jones with
Cooper the day of the killing and that
either Smith or Jones must have kil

Steve will go to the concert. Then
Heather will go to the concert or Steve
will go to the concert can be represented
by r s. By the second of De Morgans
laws, (r s) is equivalent to r s.
Consequently, we can express the
negation of our original statement

solved by finding an assignment of truth
values to the 729 propositions p(i, j, n)
with i, j , and n each ranging from 1 to 9
that makes the conjunction of all these
compound propositions true. After listing
these assertions, we will explain how to
constr

designer. The basic ideas of Sudoku date
back even further; puzzles printed in
French newspapers in the 1890s were
quite similar, but not identical, to modern
Sudoku. Sudoku puzzles designed for
entertainment have two additional
important properties. Firs

equivalences, using one of the
equivalences in Table 6 at a time, starting
with (p q) and ending with p q. We
have the following equivalences. (p q)
(p q) by Example 3 (p) q by
the second De Morgan law p q by the
double negation law EXAMPLE 7 Show
that (

propositions are equivalent for each
additional propositional variable, so that
16 rows are needed to establish the
logical equivalence of two compound
propositions involving four propositional
variables, and so on. In general, 2n rows
are required if a c

assignment of truth values to p, q, and r
makes (p q) (q r) (r p) (p
q r) (p q r) true. Hence, it is
unsatisfiable. AUGUSTA ADA,
COUNTESS OF LOVELACE (18151852)
Augusta Ada was the only child from the
marriage of the famous poet Lord Byron
and Lady Byron

will attend only if Kanti will be there, and
Kanti will not attend unless Jasmine also
does.Which combinations of these three
friends can you invite so as not to make
someone unhappy? Exercises 1923
relate to inhabitants of the island of
knights and knave

proposition that is always true and F
denotes the compound proposition that is
always TABLE 6 Logical Equivalences.
Equivalence Name p T p Identity laws
p F p p T T Domination laws p F
F p p p Idempotent laws p p p
(p) p Double negation law p q q
p Comm

integrated circuit design, computer
networking, and genetics, can be modeled
in terms of propositional satisfiability.
Although most of these applications are
beyond the scope of this book, we will
study one application here. In particular,
we will show h

how the solution of a given 4 4 Sudoku
puzzle can be found by solving a
satisfiability problem. 64. Construct a
compound proposition that asserts that
every cell of a 9 9 Sudoku puzzle
contains at least one number. 65. Explain
the steps in the constructio

remember to change the logical
connective after you negate. us how to
negate conjunctions and how to negate
disjunctions. In particular, the equivalence
(p q) p q tells us that the
negation of a disjunction is formed by
taking the conjunction of the negat

statement x is greater than 3 has two
parts. The first part, the variable x, is the
subject of the statement. The second part
the predicate, is greater than 3
refers to a property that the subject of the
statement can have. We can denote the
statement x i

will use the term compound proposition
to refer to an expression formed from
propositional variables using logical
operators, such as p q. We begin our
discussion with a classification of
compound propositions according to their
possible truth values. DEF

held until forced to resign in 1891 when
he disagreed with the direction taken by
the Surveys new administration. While
making his living from work in the
physical sciences, Peirce developed a
hierarchy of sciences, with mathematics
at the top rung, in wh

PRECONDITIONS AND POSTCONDITIONS
Predicates are also used to establish the
correctness of computer programs, that is,
to show that computer programs always
produce the desired output when given
valid input. (Note that unless the
correctness of a computer

we can let R(x, y, z) denote the statement
`x + y = z. When values are assigned to
the variables x, y, and z, this statement has
a truth value. EXAMPLE 5 What are the
truth values of the propositions R(1, 2, 3)
and R(0, 0, 1)? Solution: The proposition
R(

setting x = CS1 in the statement
Computer x is under attack by an
intruder. Because CS1 is not on the list of
computers currently under attack, we
conclude that A(CS1) is false. Similarly,
because CS2 and MATH1 are on the list of
computers under attack, w

each pair contains compound
propositions that are duals of each other.
39. Why are the duals of two
equivalent compound propositions also
equivalent, where these compound
propositions contain only the operators
, , and ? 40. Find a compound
proposition in

Engine. In 1838 Augusta Ada married
Lord King, later elevated to Earl of
Lovelace. Together they had three
children. Augusta Ada continued her
mathematical studies after her marriage.
Charles Babbage had continued work on
his Analytic Engine and lectured

extent to which a predicate is true over a
range of elements. In English, the words
all, some, many, none, and few are used in
quantifications. We will focus on two
types of quantification here: universal
quantification, which tells us that a
predicate is