






Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
Material Type: Notes; Class: Data Structures and Algorithms; Subject: Computer Science and Engineering ; University: University of Nebraska - Lincoln; Term: Unknown 1989;
Typology: Study notes
1 / 10
This page cannot be seen from the preview
Don't miss anything!







http://www.cse.unl.edu/~goddard/Courses/CSCE310J
-^
Most of slides for this lecture are based on slides createdby Dr. Ben Choi, Louisiana Technical University.
-^
I have modified them and added new slides
“for all x”
∀
x P(x) is true iff P(x) is true for
all
x
universal quantifier (universe of discourse)
I
“there exist x”
∃
x P(x) is true iff P(x) is true for
some
value
of x^ •
existential quantifier
I
∀
x A(x) is logically equivalent to
¬ ∃
x(
¬
A(x))
I
∃
x A(x) is logically equivalent to
¬∀
x(
¬
A(x))
I
∀
x (A(x)
⇒
B(x))
“For all x such that if A(x) holds then B(x) holds”
Counterexample^ to prove
∀
x (A(x)
⇒
B(x)) is false, we show
some
object x
for which A(x) is true and B(x) is false.^ •
x (A(x)
B(x)))
x (A(x)
B(x))
I
Contraposition^ to prove A
⇒
B, we show (
¬
B)
⇒
(
¬
A)
I
Contradiction^ to prove A
⇒
B, we assume
¬
B and then prove B.
B) is false
I
Assuming (A
∧ ¬
B) is true,
and discover a
contradiction
(such as A
∧ ¬
A),
then conclude (A
∧ ¬
B) is false, and so A
⇒
B.
A rule of inference is a
general pattern
that allows us to
draw some new conclusion from a set of given statements.^ •
If we know {…} then we can conclude {…}
I
If {B and (B
⇒
C)} then {C}
modus ponens
I
If {A
⇒
B and B
⇒
C} then {A
⇒
C}
syllogism
I
If {B
⇒
C and
¬
B
⇒
C} then {C}
rule of cases
1.^
Closure: •^
if x, y
∈
B and z = x + y then z
∈
B
-^
if x, y
∈
B and z = x · y then z
∈
B
2.^
Identity and Zero elements: •^
for + designated by 0: x + 0 = x
-^
for · designated by 1: x · 1 = x
3.^
Commutative: •^
x + y = y + x
-^
x · y = y · x
4.^
Distributive: •^
x · (y + z) = (x · y) + (x · z)
-^
x + (y · z) = (x + y) · (x + z)
5.^
Complement: for everyelement x
B, there exits an
element x’
B s.t.
-^
x + x’ = 1, x · x’ = 0
6.^
There are at least two distinctelements in B
A set B and two binary operators + “or,
∨
”, · “and,
∧
”
creates a Boolean Algebra iff Huntington’s Postulates hold:
I
Prove [B
∧
(B
⇒
C)]
⇒
C
Proof: [B
True (
tautology
I
Direct Proof: