Escolar Documentos
Profissional Documentos
Cultura Documentos
p q (1)
is False when Both p and q are False; True otherwise
p q (2)
is True when Both p and q are True; False otherwise
p q (3)
is True when exactly one is True; False otherwise
p q (4)
Can be read as p only if q
is False when p is True and q is False; True otherwise
True when both p and q are True
True when p is False (q doesnt matter)
is False when p is True and q is False
if p is False, then q must be True
q unless p and p q have the same truth value
Assume
p q (5)
Converse q p
Contrapositive q p
Same truth value as p q
False only when p is False and q is True
Inverse p q
p q (6)
True when p and q have same truth value
1
True when p q is True and q p is True; False otherwise
Tautology is a proposition that is always True
Contradiction is a proposition that is always False
2 Logical Equivalencies
Identity Laws
p T p
p F p
Domination Laws
p T T
p F F
Idempotent
p p p
p p p
Commutative
p q q p
p q q p
Associative
(p q) r p (q r)
(p q) r p (q r)
Distribution
p (q r) (p q) (p r)
p (q r) (p q) (p r)
Absorption
p (p q) p
p (p q) p
Negation (Complement)
p p T
p p F
2.1 Logical Equivalencies With Conditional Statements
p q p q
p q q p
p q p q
p q p q
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
2.2 Logical Equivalencies with Biconditionals
p q (p q) (q p)
p q p q
p q (p q) (p q)
(p q) (p q)
2
2.3 De-Morgans Laws
(p q) p q
(p q) p q
3 Quantiers
3.1 Universal Quantier
(7)
It is read as For all. So x means For all x
The statement xP(x) is the same as the conjunction P(x
1
) P(x
2
)
P(x
n
).
Can be distributed over a conjunction (), but can not be distributed
over a disjunction().
Meaning x(P(x) Q(x)) xP(x) xQ(x))
3.2 Existential Quantier
(8)
It is read as There exists. So x means There exists an x
Similarly the statement xP(x) is the same as the disjunction P(x
1
)
P(x
2
) P(x
n
)
Can be distributed over a disjunction(), but can not be distributed
over a conjunction().
Meaning x(P(x) Q(x)) xP(x) xQ(x))
Statement When is it True? When is it False
xP(x) P(x) is True for all x There is an x for which P(x) is False
xP(x) There is an x for which P(x) is True P(x) is False for every x
4 Other Quantiers
4.1 Uniqueness Quantier
! (9)
Denoted by ! or
1
. !xP(x) states that There exists a unique x such that
P(x) is true.
3
4.2 Negating Quantied Expressions
De Morganss Laws for Quantiers
Negation Equivalent Statement When is Negation True? When False?
xP(x) xP(x) For every x, P(x) is False There is an x for which
P(x) is True
xP(x) xP(x) There is an x for which
P(x) is False
P(x) is True for every x.
5 Rules of Inference
Rule of Inference Tautology
p (p (p q)) q
p q
q
q (q (p q)) p
p q
p
p q ((p q) (q r)) (p r)
q r
p q
p q ((p q) p) q
p
q
p q (p q) p
p
p ((p) (q)) (p q)
q
p q
p q ((p q) (p r)) (q r)
p r
q r
6 Rules of Inference for Quantied Statements
Universal Instantiation is the rule of inference used to conclude that P(c)
is true where c is a particular member of the domain, given the premise
xP(x).
Universal Generalization is the rule of inference that states that xP(x) is
true, given the premise that P(c) is true for all elements c in the domain.
It is used when we show that xP(x) is true by taking an arbitrary element
c from the domain and showing that P(c) is true. The element c that we
select must be an arbitrary, and not a specic, element of the domain.
4
Existential Instantiation is the rule that allows us to conclude that there is
an element c in the domain for which P(c) is true if we know that xP(x)
is true. We cannot select an arbitrary value of c here, but it must be a c
for which P(c) is true.
Existential Generalization is the rule of inference that is used to conclude
that xP(x) is true when a particular element c with P(c) true is known.
That is if we know one element c in the domain for which P(c) is true,
then we know that xP(x) is true.
Rule of Inference Name
xP(x) Universal Instantiation
P(c)
P(c) for an arbitrary c Universal Generalization
P(x)
xP(x) Existential Instantiation
P(c) for some element c
P(c) for some element c Existential Generalization
xP(x)
7 Proofs
Common terminology
Theorem a statement that can be shown to be true
Proposition less important theorem.
Proof a valid argument that establishes the truth of a theorem.
Axioms statements that are used in a proof. They are assumed to be true.
Lemma less important theorem that is helpful in the proof of other results.
7.1 Types of Proofs
Direct Proof of a conditional statement p q
First step is the assumption that p is true.
Then use the rules of infrence to get to q must also be true.
With most direct proofs you will see that they are straightforward,
using a fairly obvious sequence of steps to get to the conclusion.
Proof by Contraposition Prove q p
They use the fact that p q is equivalent to its contrapositive q
p
So the hypothesis is that q is true
5
Then get to the conclusion that p is true as well using axioms, def-
initions, and previously proven theorems with the rules of inference
Proofs by Contradiction Prove p q
Suppose you want to prove the statement p is true, and we can nd
a contradiction q such that p q is true.
Because q is false, but p q is true, we can conclude that p is
false, which means that p is true.
Since r r is a contradiction, we can prove that p is true if we can
show that p (r r) is true from some proposition r
8 Sets, Functions, Sequences, and Sums
8.1 Sets
Notes
A set is an unordered collection of objects.
The objects in a set are called the elements or members of the set.
Normally lower case letters are used to denote the elements of a set.
The order in which the elements of a set are listed doesnt matter.
A special set that has no elements is called the Empty Set and is denoted
by
A set with one elements is called a Singleton Set
A common error is to confuse the empty set, with the singleton set,
The single element of the set is the empty set itself.
When we wish to emphasize that a set A is a subset of the set B but
that A ,= B, we write A B and say that A is a proper set of B. For
A B to be true, it must be the case that A B and there must exist
an element x of B that is not an element of A.
A way to show that two sets have the same elements is to show that each
set is a ubset of the other. So if we can show that if A and B are sets with
A B and B A then A = B.
The Power Set of a set S, has as its members all the subsets of S.
If a set has n elements then its power set has 2
n
elements
The order of elements in a collection is often important, since sets are
unorded, a derent structure is needed to represent ordered collections.
This is proveded by ordered n- tuples.
6
Two ordered n-tuples are equal if and only if each corresponding pair of
their elements is equal. So (a
1
, a
2
, . . . , a
n
) = (b
1
, b
2
, . . . , b
n
) if and only if
a
i
= b
i
Denitions
Two sets are equal if and only if they have the same elements. That is if A
and B are sets, then A and B are equal if and only if x(x A x B)
we write A = B if A and B are equal sets.
The set A is said to be a subset of B if and only if every element of A is
also an element of B. This is written by: A B.This s true only when
x(x A x B) is true.
Every nonempty set S is guaranteed to have at least two subsets, the
empty set and the set S itself.
For every set S the following is always true:
S
S S
A is the proper subset of B (A B) if: x(x A x B) x(x
B x / A)
Let S be a set. If there are exactly n distinct elements in S where n
is a nonnegative integer we say that S is a nite set and that n is the
cardinality of S. The cardinality of S is denoted by [S[
Given a set S, the Power Set of S is the set of all subsets of the set S.
The power set of S is denoted by P(S)
the ordered n-tuple (a
1
, a
2
, . . . , a
n
) is the ordered collection that has a
1
as its rst element and a
2
as its second element, . . . , and a
n
as its nth
element.
2-tuples are called ordered pairs.
Let A and B be sets. The Cartesian Product of A and B. denoted
AB is the set of all ordered pairs (a, b), where a A and b B. Hence,
AB = (a, b)[a A b B
A subset R of the Cartesian product AB is called a relation from the
set A to the set B. The elements of R are ordered pairs, where the rst
element belongs to A and the second to B.
Given a predicate P and a domian D, we dene the Truth Set of P to
be the set of elements x in D for which P(x) is true, and is denoted by
x D[P(x)
7
Set Notation with Quantiers If we restrict the domain of a quantied
statement explicitly by making use of a particular notion, for example x
S(P(x)) denotes the universal quantication of P(x) over all elements in the set
S, which is short hand for x(x S P(x)). Similarly x S(P(x)) denotes
the existential quantication of P(x) over all elements in S. Which is short
hand for x(x S P(x))
8.2 Set Operations
Notes
An element x belongs to the union of the sets A and B if and only if x
belongs to A or x belongs to B.
An element x belongs to the dierence of A and B if and only if x A
and x / B.
An element belongs to A if and only if x / A
Set identities can be proved using Membership Tables. We consider
each combination of sets that an element can belong to and verify that
elements in the same combination of sets belong to beth the sets in the
identity. To indicate that an element is in a set use the number 1, and
the number 0 when it is not a member.
We can extend the notation we have for unions and intersections to other
families of sets. Using the notation A
1
A
2
A
n
=
i=1
A
i
to denote
the union of the sets A
1
, A
2
, . . . , A
n
, . . . . . . .
For the intersection of theses sets: A
1
A
2
A
n
=
i=1
A
i
for the sets
A
1
, A
2
, . . . , A
n
, . . . . . .
8
Denitions
Let A and B be sets. The Union of the sets A and B, denoted by AB,
is the set that contains those elements that are either in A or in B, or
in both. Which is written by: A B = x[x A x B
Let A and B be sets. The Intersection of the sets A and B, denoted by
A B, is the set that conatins those elements that are in both A and B.
Which is written by: x[x A x B
Two sets are called disjoint if their intersection is the empty set.
the Principle of inclusion-exclusion is the generalization of [AB[ =
[A[ +[B[ [A B[ to unions of an arbitrary number of sets.
Let A and B be sets. The Dierence of the A and B, denoted by AB,
is the set containing those elements that are in A but not in B. The
dierence of A and B is also called the Complement of B with respect
to A. This tells us that AB = x[x A x / B
Once the universal set U has been specied the complement of a set can
be dened by the following:
Let U be the universal set. The Complement of the set A, denoted
by A is the Compliment of A with respect to U. In other words,
the compliment of the set A is U A
This is written by: A = x[x / A
The Union of a collection of sets is the set that contains those elements
that are members of at least one set in the collection. The notation:
A
1
A
2
A
n
=
n
i=1
A
i
is denoting the union of the sets A
1
, A
2
, . . . , A
n
.
the Intersection of a collection of sets is the set that contains those
elements that are member of all the sets in the collection. And is denoted
by: A
1
A
2
A
n
=
n
i=1
A
i
is denoting the intersection of the sets
A
1
, A
2
, . . . , A
n
.
9
Set Identities
Set Identities
Name Identity
Identity Laws
A = A
A U = A
Domination Laws
A U = U
A =
Idempotent
A A = A
A A = A
Complementation law (A) = A
Commutative
A B = B A
A B = B A
Associative
A (B C) = (A B) C
A (B C) = (A B) C
Distribution
A (B C) = (A B) (A C)
A (B C) = (A B) (A C)
De Morgans Laws
A B A B
A B = A B
Absorption
A (A B) = A
A (A B) = A
Complement
A A = U
A A =
8.3 Functions
Notes
If we assign to each element of a set a particular element of a second set,
it is called a Function.
Functions are sometimes called Mappings or Transformations.
A relation from A to B is just a subset of A B. A relation from A to
B that contains one, and only one, ordered pair (a, b) for every element
a A denes a function f from A to B. This function is dened by the
assignment f(a) = b where (a, b) is the unique ordered pair in the relation
that has a as its rst element.
When we dene a function we specify its domain, its codomain, and the
mapping of elements of the domain to elements in the codomain.
Two functions are equal when they have the same domain, codomain,
and map elements of their common domain to the same elements in their
common codomain.
The notation f(S) for the image of the set S under the function f is
potentially ambiguous. Here, f(S) denotes a set, and not the values of
the function f for the set S.
10
Some functions never assign the same value to two dierent elements.
These functions are said to be One-to-one.
A function f is one-to-one if and only if f(a) ,= f(b) whenever a ,= b.
This way of expressing that f is one-to-one is obtained by taking the
contrapositive of the implication in the denition.
We can express that f is one-to-one using quantiers as
ab(f(a) = f(b) a = b)
A function f is increasing if xy(x < y f(x) f(y)), strictly increas-
ing if xy(x < y f(x) < f(y)), decreasing if xy(x < y f(x)
f(y)) and strictly decreasing if xy(x < y f(x) > f(y))
A function that is either strictly increasing or strictly decreasing must
be one-to-one. However a function that is increasing, but not strictly,
decreasing, but not strictly, is not necessarily one-to-one.
For some functions the range and codomain are equal. That is, every
member of the codomain is the image of some element of the domain.
Functions with this property are called onto functions.
A function f is onto if yx(f(x) = y), where the domain of x is the do-
main of the function and the domain for y is the codomain of the function.
Consider a one-to-one correspondence f from the set A to the set B.
Because f is an onto function, every element of B is the image of some
element in A. Also since f is also a one-to-one function, every element
of B is the image of a unique element of A. Consequently, we can dene
a new function from B to A that reverses the correspondence given by f.
Do not confuse the function f
1
with the function 1/f, which is the func-
tion that assigns to each x in the domain the value 1/f(x). The latter
makes sense only when f(x) is a non-zero real number.
If a function f is not a one-to-one correspondence, we cant dene an
inverse function of f.
A one-to-one correspondence is called invertible because we can de-
ne an inverse of this function.
A function is not invertible it if is not a one-to-one correspondence,
because the inverse of such a function does not exist.
Sometimes we can restrict the domain or the codomain of a function, or
both, to obtain an invertible function.
f g is the function that assigns to the element a of A the element assigned
by f to g(a). That is to nd (f g)(a) we rst apply the function g to a
to obtain g(a) and then we apply the function f to result g(a).
11
The composition f g cant be dened unless the range of g is a subset of
the domain of f.
The commutative law does not hold for the composition of functions.
We can associate a set of pairs in A B to each function from A to B.
This set of pairs is called the graph of the function and is often displayed
pictorially to aid in understand the behavior of the function.
from the denition, the graph of a function f from A to B is the subset
of AB containing the ordered paris with the second entry equal to the
element of B assigned by f to the rst entry.
Let x be a real number. The oor function rounds x down to the closes
integer less that or equal to x.
Let x be a real number. The ceiling function rounds x up to the closes
integer great than or equal to x.
The oor function is often also called the greatest integer function.
and is often denoted by: [x]
Denitions
Let A and B be nonempty sets. A Function f from A to B is an assign-
ment of exactly one element of B to each element of A. We write f(a) = b
if b is the unique element of B assigned by the function f to the element
a of A. If f is a function from A to B we write f : A B.
If f is a function from A to B, we say that A is the domain of f and B
is the codomain of f. If f(a) = b, we say that b is the image of a and a
is a preimage if b. The Range of f is the set of all images of elements
of A. Also, if f is a function from A to B, we say that f maps A to B.
Let f
1
and f
2
be functions from A to R. Then f
1
+ f
2
and f
1
f
2
are also
functions from A to R dened by:
(f
1
+ f
2
)(x) = f
1
(x) + f
2
(x)
(f
1
f
2
)(x) = f
1
(x)f
2
(x)
Let f
1
and f
2
be functions from A to the set B and let S be a subset of A.
The Image of S under the function of f is the subset of B that consists
of the images of the elements of S. We denote the image of S by f(S), so:
f(S) = t[s S(t = f(s)) .
The short hand is written:
f(s)[s S
A function f is said to be one-to-one or injective if and only if f(a) =
f(b) implies that a = b for all a and b in the domain of f. A function is
said to be an injection if it is one-to-one.
12
A function f whose domain and codomain are subsets of the set of real
number is called increasing if f(x) f(y) and strictly increasing if
f(x) < f(y), whenever x < y and x and y are in the domain of f.
A function f whose domain and codomain are subsets of the set of real
number is called decreasing if f(x) f(y) and strictly decreasing if
f(x) > f(y), whenever x > y and x and y are in the domain of f.
A function f from A to B is called onto or surjective, if and only if for
every element b B there is an element a A with f(a) = b. A function
f is called surjection if it is onto.
The function f is a one-to-one correspondence or a bijection, if it is
both one-to-one and onto.
Let f be a one-to-one correspondence from the set A to the set B.
The inverse function of f is the function that assigns to an element b
belonging to B the unique element of a in A such that f(a) = b. The
inverse function of f is denoted by f
1
. Hence f
1
(b) = a when f(a) = b
Let g be a function from the set A to the set B and let f be a function
from the set B to the set C. The composition of the functions f and g,
denoted by f g is dened by
(f g)(a) = f(g(a))
Let f be a function from the set A to the set B. The graph of the function
f is the set of ordered pairs (a, b)[a A and f(a) = b
The oor function assigns to the real number x the largest integer that
is less than or equal to x. The value of the oor function at x is denoted
by: x|
The ceiling function assigns to the real number x the smallest integer
that is greater than or equal to x. The value of the ceiling function at
x is denoted by: ,x|
13
Properties of the Floor and Ceiling Functions
x| = n if and only if n x < n + 1
,x| = n if and only if n 1 < x n
x| = n if and only if x 1 < n x
,x| = n if and only if x n < x + 1
x 1 < x| x ,x| < x + 1
x| = ,x|
,x| = x|
x + n| = x| + n
,x + n| = ,x| + n
8.4 Sequences and Summations
Notes
When the elements of a set can be listed, the set is called countable.
A sequence is a discrete structure used to represent an ordered list.
The notation a
n
is used to describe a sequence.
a
n
represents an individual term of the sequence a
n
j=0
ar
j
=
ar
n+1
a
r1
if r ,= 1
(n + 1)a if r = 1
j=0
n
k
x
nj
y
j
=
n
0
x
n
+
n
1
x
n1
y +
n
2
x
n2
y
2
+ +
n
n 1
xy
n1
+
n
n
y
n
Pascals Identity. Let n and k be positive integers with n k Then
n + 1
k
n
k 1
n
k
.
Vandermondes Identity. Letm, n and r be nonnegative integers with
r not exceeding either m or n, then
m + n
r
=
r
k=0
m
r k
n
k
n + 1
r + 1
=
n
j=r
j
r
Corollaries
Let n be a nonnegative integer. Then
n
k=0
n
k
= 2
n
Let n be a postive integer. Then
n
k=0
(1)
k
n
k
= 0
Let n be a nonnegative integer. Then
n
k=0
2
k
n
k
= 3
n
If n is a nonnegative integer, then
2n
n
=
n
k=0
n
n k
n
k
=
n
k=0
n
k
2
23