CSCE 222 Exam 1

Pataasin ang iyong marka sa homework at exams ngayon gamit ang Quizwiz!

Sequence

A _____ is a function from a subset of the integers to a set S.

Reflexivity in a digraph

A loop must be present at all vertices in the graph.

Uniqueness Proofs ∃x∀yP(y) ↔ (y=x)

Exactly one element satisfies P(x) ∀yP(y) → (y=x) ∃x∀yP(x) ∧ (P(y) → (y=x)) ∃x∀yP(y) ↔ (y=x)

Roster Method (set notation)

S = {1, 2, 3, 4}

Index of summation

What does i represent?

Existential Quantifier

∃xP(x) - P(x) holds for some x in the domain D

Express x ≠ 9 using interval notation

(-∞, 9) ∪ (9, ∞)

g: A → B, f: B → C, f ∘ g: A → C

(f ∘ g)(x) = f(g(x))

Prove that √2 is irrational using Proof by Contradiction

(∃p, q((q ≠ 0) ∧ (r = p/q))) → r is rational. A real number which is not rational is irrational. Suppose √2 is rational. Then, there exist integers a, b such that b ≠ 0 and √2 = a/b where a,b have no common factors. (√2 )^2 = (a/b)^2 2 = a^2/b^2 2b^2 = a^2, thus a is even 2b^2 = (2k)^2 b^2 = 2k^2, thus b is even. If both are even, then they share a common factor. This contradicts the assumption that √2 is rational. Therefore, √2 is NOT rational. ☐

Set Difference (set operations) A - B

A - B = {x | x ∈ A ∧ x ∉ B} Ex. {8,6,7,5,3,0,9} - {0,2,4,6,8} = {3,5,7}

Arithmetic Progression

A ___ ____ is a sequence of the form a, a+d, a+2d, where the initial term a and the common difference d are real numbers.

Geometric Progression

A ___ ____ is a sequence of the form a, ar, ar^2, ar^2... where the initial term a and the common ration r are real numbers.

Binary Relation

A ____ R from a set A to a set B is a subset R ⊆ A x B Ex. Let A = {0,1,2} and B = {a,b} Ex. {(0,a), (0,b), (1,a), (2,b)} is a relation from A to B.

Function

A ____ from A to B is an assignment of exactly one element of B to each element of A Ex. f(a) = b

Binary Relation on a Set

A _____ R on a set A is a subset of A x A or a relation from A to A Ex. Suppose that A = {a,b,c}. Then R = {(a,a), (a,b), (a,c)} is a relation on A.

Partition

A _____ of a set S is a collection of disjoint nonempty subsets of S that have S as their union. In other words, the collection of subsets Ai forms a ____ of S if and only if

Predicate

A function P from a set D to the set Prop of propositions is a _____.

One Way Functions

A function that is easy to compute on every input but hard to invert.

f: A → B

A is the domain of f B is the codomain of f f(a) = b is the image of a a is the preimage of f(a) = b {x | x = f(a) for a ∈ A} is the range of f

{∅}

A non-empty singleton set

Transitive Relation

A relation R on a set A is called _____ if whenever (a,b) ∈ R and (b,c) ∈ R, then (a,c) ∈ R for all a,b,c ∈ A. ∀x∀y∀z[(x,y) ∈ R ∧ (y,z) ∈ R → (x,z) ∈ R)

Antisymmetric Relation

A relation R on a set A such that for all a,b ∈ A if (a,b) ∈ R and (b,a) ∈ R, then a = b is called _____. ∀x∀y[(x,y) ∈ R ∧ (y,x) ∈ R → x=y)

Partial Ordering

A relation R on a set S is called a ____ _____ if it is reflexive, antisymmetric, and transitive.

Equivalence Relations

A relation that is reflexive, symmetric and transitive.

Solution of a recurrence relation

A sequence is called a ______ if its terms satisfy the recurrence relation.

Theorem

A statement that can be shown to be true ex. If x, y are odd integers, the x • y is odd

Relation from A to B

A subset of a Cartesian product

Proof

A valid argument that establishes the truth of a theorem ex. Let x, y be odd integers. Then, ∃a x = 2a + 1 ∃b x = 2b + 1 x • y = (2a + 1)(2b + 1) x • y = 4ab + 2a + 2b + 1 x • y = 2(2ab + a + b) + 1 ∴ x • y is odd ☐

Cartesian Products

A x B = {(a,b) | a ∈ A ∧ b ∈ B}

Set Intersection (set operations) A ∩ B

A ∩ B = {x| x ∈ A ∧ x ∈ B} Ex. {1,2,3} ∩ {3,4} = {3}

Set Union (set operations) A ∪ B

A ∪ B = {x| x ∈ A ∨ x ∈ B} Ex. {1,2,3} ∪ {3,4} = {1,2,3,4}

Valid Arguments

An argument in propositional logic is a sequence of propositions that end with a proposition called conclusion. The argument is valid if the conclusion follows from the preceding statements (premises). In other words, in a valid argument it is impossible that all premises are true but the conclusion is false.

Loop

An edge of the form (a,a)

Recurrence Relation

An equation that expresses a subset n in terms of one or more of the previous terms of the sequence.

Without Loss of Generality (wlog)

Assert that the proof for one case can be reapplied with only straightforward changes to prove other specified cases.

How many relations are there on a set A?

Because a relation on A is the same thing as a subset of A x A, we count the subsets of A x A. Since A x A has n^2 elements when A has n elements and a set with m elements has 2^m subsets, there are 2^|A|^2 subsets of A x A. Therefore, there are 2^|A|^2 relations on a set A.

Bijective (Properties of functions)

Both one to one AND onto If f: A → B is _____, then there exists f^-1: B → A, the inverse function

Perform proof by cases on if n is an integer, then n^2 ≥ n

Case n ≥ 1: n • n ≥ 1 • n n^2 ≥ n Case n ≤ 1: n^2 ≥ n, since n^2 is positive and n is negative Case n = 0: 0^2 ≥ 0 The claim holds in all cases ☐

Logic to sets - ¬p

Complement P

Digraphs

Consists of a set V of vertices (or nodes) together with a set E of ordered pairs of elements of V called edges (or arcs). The vertex a is called the initial vertex of the edge (a,b) and the vertex b is called the terminal vertex of this edge.

Denotes the relation in any poset.

{x ∈ ℝ | x ≠ 9}

Express x ≠ 9 using set builder

Counterexamples

Find counterexample x that satisfies the negation of whatever you are solving for. ex. Show that not every positive integer is the sum of the squares of 2 integers. Proof: Counterexample is 3

Iteration (technique for solving recurrence relations)

Forward: Work forward from the initial term until a pattern emerges. Then guess the form of the solution. Backward: Work backward from a subset n towards a0 until a pattern emerges. Then guess the form of the solution.

Transitivity in a digraph

If (x,y) and (y,z) are edges, then so is (x,z).

Symmetry in a digraph

If (x,y) is an edge, then so is (y,x).

Antisymmetry in a digraph

If (x,y) with x ≠ y is an edge, then (y,x) is not an edge.

Show that R is an equivalence relation when R is the relation on the set of strings of English letters such that aRb iff l(a) = l(b), where l(x) is the length of the string x.

Must show that all properties of an equivalence relation hold. Reflexivity: Because l(a) = l(a), it follows that aRa for all strings a. Symmetry: Suppose that aRb. Since l(a) = l(b), l(b) = l(a) also holds and bRa. Transitivity: Suppose that aRb and bRc. Since l(a) = l(b), and l(b) = l(c), l(a) = l(c) also holds and aRc.

Is "divides" an equivalence relation?

No, because it is not symmetric. Symmetry counterexample: 2 divides 4, but 4 does not divide 2. Hence, the relation is not symmetric.

If f: ℝ → ℝ, f(x) = 2x^2 - 5, is f one-to-one? Onto?

Not one-to-one because f(x) ≠ f(-x) Not onto because ¬∃xf(x) < -5

Logic to sets - p ↔ q

P = Q

Logic to sets - p ∧ q

P ∩ Q

Logic to sets - p ∨ q

P ∪ Q

Logic to sets - p → q

P ⊆ Q

Universal Generalization (Quantified Statements)

P(a) for an arbitrary a ------------------ ∴∀xP(x)

Existential Generalization (Quantified Statements)

P(a) for some a ------------------ ∴∃xP(x)

(0 + 1)^3 ≥ 3^0 = 1 ≥ 1 (1 + 1)^3 ≥ 3^1 = 8 ≥ 3 (2 + 1)^3 ≥ 3^2 = 27 ≥ 9 (3 + 1)^3 ≥ 3^3 = 64 ≥ 27 (4 + 1)^3 ≥ 3^4 = 125 ≥ 81 ☐

Perform exhaustive proof on (n+1)^3 ≥ 3^n for n ∈ {0,1,2,3,4}

Prove using wlog of this theorem: Let x,y be integers. If xy and x+y are both even, then x and y are both even.

Proof Use contraposition ((x is odd) ∨ (y is odd)) → ((xy is odd) ∨ (x+y is odd)) Assume (x is odd) ∨ (y is odd) Wlog, assume x is odd. Case y even: x + y = (odd) + (even) = odd Case y odd: xy = (odd)(odd) = odd ∴ ((x is odd) ∨ (y is odd)) → ((xy is odd) ∨ (x+y is odd)) ☐ Follows that ((xy is even) ∧ (x+y is even)) → ((x is even) ∧ (y is even))

Proof by Cases

Prove for every case in the theorem

Exhaustive Proofs

Prove for every element in the domain (Must prove every case)

Direct Proof

Prove p → q, ∀x(P(x) → Q(x)) by assuming that p is true and using the rules of inference to show that q must also be true

Symmetric Relation

R is ____ iff (b,a) ∈ R whenever (a,b) ∈ R for all a,b ∈ A. ∀x∀y[(x,y) ∈ R → (y,x) ∈ R]

Reflexive Relation

R is _____ iff (a,a) ∈ R for every element a ∈ A. ∀x(x, x) ∈ R

Show that the inclusion relation (⊆) is a partial ordering on P(s), the power set of a set S.

Reflexivity: A ⊆ A always. Antisymmetry: If A and B are sets with A ⊆ B and B ⊆ A, then A = B. Transitivity: If A ⊆ B and B ⊆ C, then A ⊆ C.

Show that the "divides" relation is a partial ordering on the set of integers.

Reflexivity: a divides a for all integers a. Antisymmetry: If a and b are positive integers such that a divides b and b divides a, then a = b. Transitivity: Suppose that a divides b and b divides c. Then there are positive integers k and l such that b = ak and c = bl. Hence c = a(kl), so a divides c.

Set Builder

S = {x | x is a positive integer less than 5} S = {x | x ∈ ℤ+ ∧ x<5}

Let R be an equivalence relation on a set S. Then, the equivalence classes of R form a partition of S. Conversely, given a partition {Ai | i ∈ I} of the set S, there is an equivalence relation R that has the sets Ai, i ∈ I, as its equivalence classes. Prove.

Second part of the theorem - assume that {Ai | i ∈ I} is a partition of S. Let R be the relation on S consisting of the pairs (x, y) where x and y belong to the same subset Ai in the partition. We must show that R satisfies the properties of an equivalence relation. Reflexivity: For every a ∈ S, (a,a) ∈ R because a is in the same subset as itself. Symmetry: If (a,b) ∈ R, then b and a are in the same subset of the partition, so (b,a) ∈ R. Transitivity: If (a,b) ∈ R and (b,c) ∈ R, then a and b are in the same subset of the partition, as are b and c. Since the subsets are disjoint and b belongs to both, the two subsets of the partition must be identical. Therefore, (a,c) ∈ R since an and c belong to the same subset of the partition.

ℕ = {[0,] 1,2, 3...}

Set of natural numbers

ℚ = {p/q | p,q ∈ ℤ, q ≠ 0}

Set of rational numbers

Set Notation

Sets: an unordered collection of objects ("members", "elements") - a ∈ S "a is a member of S", "a is an element of S" - a ∉ S "a is NOT a member of S", "a is NOT an element of S"

Interval Notation

Shortcuts for sets containing numbers [,] mean inclusive - Closed interval (,) means exclusive - Open interval

Proofs of equivalence : p ↔ q

Show p → q and q → p p: n is even q: n^2 is even p → q Assume n is even. n = 2k n^2 = (2k)^2 = 4k^2 = 2(2k^2) ☐ q → p Use contrapositive: ¬p → ¬q Assume n is odd n = 2k+ 1 n^2 = (2k+1)^2 = 4k^2 + 4k + 1 = 2(2k^2 + 2k) + 1 ∴ p ↔ q ☐

Reflexivity: a ≥ a for every integer a. Antisymmetry: If a ≥ b and b ≥ a, then a = b. Transitivity: If a ≥ b and b ≥ c, then a ≥ c.

Show that the "greater than or equal" relation (≥) is a partial ordering on the set of integers.

Total function

Special case of partial function Ex. f is undefined for A - D, D is the domain of definition of f. If D = A, then f is a total function.

Lexicographical Order

Specifying that (a1, a2) is less than (b1, b2) if a1 ≺1 b1 or (a1 = b1 and a2 ≺2 b2).

Proof Strategies: Forward

Start with premises, plug and chug to the conclusion (direct proof) Start with negation of conclusion, plug and chug to negation of premises (indirect proof)

Compositon

Suppose R1 is a relation from a set A to a set B, and R2 is a relation from B to a set C. Then, the ____ R2 ∘ R1 of R2 with R1, is a relation from A to C where if (x,y) is a member of R1 and (y,z) is a member of R2, then (x,z) is a member of R2 ∘ R1

Prove ∀x(P(x)⋀Q(x)) ≡ ∀xP(x) ⋀∀xQ(x)

Suppose ∀x(P(x)⋀Q(x)) is true. Then for all a in the domain P(a) ⋀ Q(a) is true. Hence, both P(a) is true and Q(a) is true. Since P(a) is true for all a in the domain, ∀xP(x) is true. Since Q(a) is true for all a in the domain, ∀xQ(x) is true. Hence ∀xP(x) ⋀∀xQ(x) is true.

Venn Diagram

The diagram used where a rectangle is represents U, geometric shapes inside to represent sets, and points to represent particular elements.

Comparable

The elements of a and b of a poset (S,≼) are ___ if either a ≼ b or b ≼ a.

∅ = { }

The empty set

Set size

The number of distinct elements in the set. Ex: |S| = n, n ≥ 0, n is finite "Cardinality"

Domain

The set D is the _____ of P

Power set

The set of all subsets of a set ℘(S) Ex: S = {1,2,3} ℘(S) = {∅, {1}, {2}, {3}, {1,2}, {1,3}, {2,3}, {1,2,3}}

The set of complex numbers

ℤ = {..., -2, -1, 0, 1, 2, ...}, ℤ+ and ℤ-

The set of integers Set of positive integers Set of negative integers

ℝ, ℝ+ and ℝ-

The set of real numbers Set of positive reals Set of negative reals

U

The universal set (set of discourse)

(x + y ≥ 2) ∧ ¬((x ≥ 1) ∨ (y ≥ 1)) (Proof by contradiction) (x + y ≥ 2) ∧ ((x < 1) ∨ (y < 1)) x + y < 1 + 1 x + y < 2 contradicts x + y ≥ 2 ∴ ¬¬((x + y ≥ 2) → ((x ≥ 1) ∨ (y ≥ 1))) ☐

Theorem: If x + y ≥ 2, then x ≥ 1 or y ≥ 1 Proof: Assume ¬((x + y ≥ 2) → ((x ≥ 1) ∨ (y ≥ 1)))

Indirect Proofs - Proof by Contradiction

Trying to prove p - Prove by showing ¬p → (r ∧ ¬r) Thus ¬p = F ⇒ p = T

Logical Equivalence

Two statements involving quantifiers and predicates are logically equivalent iff they have the same truth values no matter which predicates are substituted into the statements and no matter which domain is used.

{3x | x is an integer and 0 ≤ x ≤ 4}

Use set builder notation to describe the set {0,3,4,6,12}

Closed formula

Used to solve a recurrence relation for the terms of the sequence. Does not involve previous terms of the sequence.

Let R be an equivalence relation on a set A. These statements for elements a and b of A are equivalent. i) aRb ii) [a] = [b] iii) [a] ∩ [b] ≠ ∅ Prove.

We show that (i) implies (ii). Assume that aRb. Now supposed that c ∈ [a]. Then aRc. Because aRb and R is symmetric, bRa. Because R is transitive and bRa and aRc, it follows that bRc. Hence, c ∈ [b]. Therefore, [a] ⊆ [b]. Since [a] ⊆ [b] and [b] ⊆ [a], we have shown that [a] = [b].

Bijective

What type of map is this?

Backward Reasoning

What type of reasoning is this?

Incomparable

When a and b are elements of S so that neither a ≼ b nor b ≼ a.

Leveraging proof by cases

When you can't consider every case all at once When there's no obvious way to start, but extra information in each case helps

Proof Strategies: Backward

Work backwards from the conclusion to find the correct steps for a direct proof

Let m be an integer with m > 1. Show that the relation R = {(a,b) | a ≡ b (mod m)} is an equivalence relation on the set of integers.

a ≡ b (mod m) means a % m = b % m where % is the modulus operator (computes remainder of a/b) Reflexivity: a % m = a % m is true. Symmetry: if a % m = b % m, then b % m = a % m is true. Transitivity: if a % m = b % m and b % m = c% m, then a % m = c % m is true.

If R is a reflexive relation

all the elements on the diagonal of MR are equal to 1.

Equivalence Class

e set of all elements that are related to an element of A is called the ______ ____ of a.

XOR, A ⊕ B

elements in A, or in B, but not in both

Partial function

f: A → B, An assignment to each element in a subset of A (domain of definition of f) to a unique element in B.

R is an antisymmetric relation

iff mij = 0 or mji = 0 when i ≠ j.

R is a symmetric relation

iff mij = 1 whenever mji = 1.

Lower limit

m

Upper limit

n

Modus Ponens (Rules of Inference)

p p -> q ------ ∴ q

Simplification (Rules of Inference)

p ∧ q ------ ∴ p

List the members of the set {x | x^2 = 2}

{ -√2, √2}

Let A be the set of all airlines and B be the set of all US cities. What is the Cartesian product A x B^2?

{(a,b,c) | a is an airline, b is a US city, and c is a US city}

List the members of the set {x | x is the square of an integer and x < 100}

{0,1,4,9,16,25,36,49,64,81}

Use set builder notation to describe the set {-3,-2,-1,0,1,2,3}

{x | x is an integer and |x| ≤ 3}

Principle of inclusion-exclusion

|A ∪ B| = |A| + |B| - A ∩ B|

Modus Tollens (Rules of Inference)

¬q p -> q ------ ∴ ¬p

Prove ¬∀xP(x) → Q(x)) ≡ ∃x(P(x) ∧¬Q(x))

¬∀xP(x) → Q(x)) ≡ ∃x¬(P(x) → Q(x)) ≡ ∃x¬(¬P(x) ∨ Q(x)) ≡ ∃x(¬¬P(x) ∧ ¬Q(x)) ≡ ∃x(P(x) ∧ ¬Q(x))

De Morgan's Laws

¬∀xP(x) ≡ ∃x¬P(x) and ¬∃xP(x) ≡ ∀x¬P(x)

One-to-one (injective) (Properties of functions)

∀a∀b((f(a) = f(b)) → a = b)

Universal Modus Ponens (Combining universal instantiation and modus ponens)

∀x(P(x) → Q(x)) P(a) where a is in the domain -------------- ∴Q(a)

Universal Instantiation (Quantified Statements)

∀xP(x) ----- ∴ P(a)

Universal Quantifier

∀xP(x) - P(x) holds for all x in D

Onto (surjective) (Properties of functions)

∀y∃xf(x) = y

Existential Instantiation (Quantified Statements)

∃xP(x) ------ ∴ P(a) for some a

Existence Proofs

∃xP(x) To show than an object exists. Constructive proof: find a witness Nonconstructive: shown without witness Ex. Show that there exists some integer that is expressible as the sum of 2 cubes in 2 different ways - Constructive proof: 1729 = 10^3 + 9^3 = 12^3 + 1^3


Kaugnay na mga set ng pag-aaral

Economic Foundation of Cooperatives

View Set

Intg Bus Policy & Strategy- Quiz Questions CH8-12

View Set

BCN #4 Sports Head and Neck Injury - Penney 5.2

View Set