CS113 Chapters 1-14

Ace your homework & exams now with Quizwiz!

discrete time dynamical system

In a discrete time dynamical system, time is divided into discrete time intervals and the state of the system stays fixed within each time interval

arrow diagram

In an arrow diagram of a relation R on sets A and B, the elements of A are listed on the left, the elements of B are listed on the right, and there is an arrow from a∈A to b∈B if aRb.

hypothesis

In p → q, the proposition p is called the hypothesis

conclusion

In p → q, the proposition q is called the conclusion

inductive hypothesis

In the statement "S(k) implies S(k+1)" of the inductive step, the supposition that S(k) is true

self-loop

Indication that an element that is related to itself. Leaves the element and then turns around to point to itself again.

induction

Induction starts by showing that a theorem is true for k = 1.Then an inductive proof shows that for any k > 1, if the theorem is true for k - 1, then the theorem also holds for k.

Pseudocode for post-order traversal.

Post-order(v) For every child w of v: Post-order(w) End-for process(v) (the root would be the initial parameter)

Pseudocode for pre-order traversal.

Pre-order(v) process(v) For every child w of v: Pre-order(w) End-for (the initial parameter would be the root)

transitive

R is transitive if and only if for every three elements, x, y, z ∈ A, if xRy and yRz, then it must also be the case that xRz.

complement

S - E = compE p(compE) = 1 - p(E)

explicit formula

a formula showing how the value is determined by the index

ordered triple

(x, y, z)

biconditional operation

If p and q are propositions, the proposition "p if and only if q" is expressed with the biconditional operation and is denoted p ↔ q

converse

If p→q, then q → p is its converse

inverse

If p→q, then ¬p → ¬q is its inverse

contrapositive

If p→q, then ¬q → ¬p is its contrapositive

concatenation

If s and t are two strings, then the concatenation of s and t (denoted st) is the string obtained by putting s and t together.

self-loop

If the head and the tail of an edge are the same vertex, the edge is called a self-loop.

characteristic equation

If the number x satisfies the characteristic equation for a linear homogeneous recurrence relation, then xn satisfies the recurrence relation.

descendant

If u is an ancestor of v, then v is a descendant of u.

child

If v is the parent of vertex u, then u is a child of vertex v

Associative Laws

( p ∨ q ) ∨ r ≡ p ∨ ( q ∨ r ), and ( p ∧ q ) ∧ r ≡ p ∧ ( q ∧ r )

directed edge

(a, b)

Identity 11.2.2: Another identity from the Binomial Theorem.

(n 0)−(n 1)+(n 2)+⋯+(−1)^n (n n)=0

Theorem 11.2.3: Pascal's identity.

(n k) = (n−1 k−1) + (n−1 k)

Theorem 11.2.1: A simple combinatorial identity.

(n k)=(n (n−k))

permutation

(without the parameter r) is a sequence that contains each element of a finite set exactly once

ordered pair

(x, y)

modus tollens

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

Filling the rows of a truth table

1. Fill the rightmost column with alternating values 2. Fill the next rightmost column with groups of 2 Ts and Fs 3. Fill the next column alternates by 4's.

Finding the next r-subset in lexicographic order

1. Move from right to left until current number (curr) can be increased. 2. Increment curr by 1. 3. Fill in numbers after curr by adding +1 to the previous number.

Finding the next permutation in lexicographic order

1. Move from right to left until the current number (curr) is less than the one before. 2. Find smallest number after curr that is greater than curr (next). 3. Swap next and curr. 4. Reorder numbers after next in increasing order

Comparing two subsets according to lexicographic order

1. Order each set from greatest to smallest 2. Compare each set as sequences

Identity 11.2.1: An identity from the Binomial Theorem.

2^n = the sum from k = 0 to k = n of (n k)

Hasse diagram

A Hasse diagram, named after the 20th century German mathematician Helmut Hasse, is a useful way to depict a partial order on a finite set. For any x and y such that x ≠ y: If x ⪯ y, then make x appear lower in the diagram than y. If x ⪯ y and there is no z such that x ⪯ z and z ⪯ y, then draw a segment connecting x and y.

bit

A bit is a character in a binary string.

function

A function f that maps elements of a set X to elements of a set Y, is a subset of X × Y such that for every x ∈ X, there is exactly one y ∈ Y for which (x, y) ∈ f. f:X --> Y or f(x)=y X = Domain Y = Target / Co-Domain

well-defined

A function is well-defined if and only if it maps an element in the domain to exactly one element in the target

bijective function / bijection / one-to-one correspondence

A function which is classified as both one-to-one AND onto injective and surjective

Game trees

A game tree shows all possible playing strategies of both players in a game. Each vertex in the tree represents a configuration of the game as well as an indication of whose turn it is to play next. The root of the tree is the initial configuration of the game. The children of a configuration c are all the configurations that can be reached from c by a single move of the correct player. A configuration is a leaf vertex in the tree if the game is over.

subgraph

A graph H = (VH, EH) is a subgraph of a graph G = (VG, EG) if VH ⊆ VG and EH ⊆ EG.

quantified statement

A logical statement that includes a universal or existential quantifier

predicate

A logical statement whose truth value is a function of one or more variables

total order (partial order)

A partial order is a total order if every two elements in the domain are comparable.

partition

A partition of a set A is a set of non-empty subsets of A that are pairwise disjoint and whose union is A.

permutation

A permutation of the set {1, 2, ..., n} is an ordered n-tuple in which each number in {1, 2, ..., n} appears exactly once

Nested quantifiers

A predicate that has more than one variable bound to a separate quantifier. ∀x ∀y M(x, y) ∃x ∀y M(x, y)

probability distribution

A probability distribution over the outcomes of an experiment with a countable sample space S is a function p from S to the set of real numbers in the interval from 0 to 1 with the property that the sum of the probabilities of every possible outcome is 1.

combinatorial proof

A proof that makes use of counting principles

preserved under isomorphism

A property is said to be preserved under isomorphism if whenever two graphs are isomorphic, one graph has the property if and only if the other graph also has the property. a) Total Degree b) Number of edges c) Number of vertices d) Number of vertices whose degree is an even number. e) Number of vertices whose degree is an odd number.

strict order

A relation R is a strict order if R is transitive and anti-reflexive. AT - Anti-Symmetric - Transitive

equivalence relation

A relation R is an equivalence relation if R is reflexive, symmetric, and transitive. - reflexive - symmetric - transitive

partial order

A relation R on a set A is a partial order if it is reflexive, transitive, and anti-symmetric. RAT - Reflexive - Anti-Symmetric - Transitive

anti-reflexive

A relation for which for EVERY x ∈ A, xRx is NOT true.

reflexive

A relation for which for EVERY x ∈ A, xRx is true.

anti-symmetric

A relation is anti-symmetric if for every pair of distinct elements in the domain one of the following situations holds: - xRy, but it is not true that yRx - yRx, but it is not true that xRy - Neither xRy nor yRx is true

symmetric

A relation is symmetric if for every pair of elements x and y in the domain, one of the following situations holds: - neither xRy nor yRx is true - xRy and yRx are both true

recurrence relation

A rule that defines a term An as a function of previous terms in the sequence

string

A sequence of characters

pairwise disjoint

A sequence of sets, A1, A2, ..., An, is pairwise disjoint if every pair of distinct sets in the sequence is disjoint Ex. Ai ∩ Aj = ∅ for any i and j in the range from 1 through n where i ≠ j

finite sequence

A sequence with a finite domain

infinite sequence

A sequence with an infinite domain

pairwise disjoint

A set of sets is pairwise disjoint if the intersection of any pair of the sets is empty.

connected

A set of vertices in a graph is said to be connected if every pair of vertices in the set is connected.

total order (strict order)

A strict order is a total order if every pair of elements is comparable.

n-bit string

A string of length n

balanced

A string of parentheses is balanced if the number of left parentheses is equal to the number of right parentheses

prefix

A string s is a prefix of another string t if all the characters in string s appear at the beginning of string t

event

A subset of the sample space

topological

A topological sort for a DAG is an ordering of the vertices that is consistent with the edges in the graph.

r-subset/r-combination

A unordered subset of size r

term

A value

neighbor

A vertex c is a neighbor of vertex b if and only if {b, c} is an edge.

isolated vertex

A vertex that is not connected with any other vertex

product rule

A way to count combinations which involves multiplying the cardinalities of sets

proper subset

A ⊂ B = A is a proper subset of B Every element in A is also an element in B. HOWEVER, there is at least one element in B which is not an element in A.

subset

A ⊆ B = A is a subset of B Every element in A is also an element in B If A ⊆ B and B ⊆ A, then A = B.

maximal (strict order)

An element x is a maximal element if there is no y such that x ≺ y. no arrows leave the element

maximal (partial order)

An element x is a maximal element if there is no y ≠ x such that x ⪯ y. there are no arrows leaving this element except the ones that point to themselves

minimal (strict order)

An element x is a minimal element if there is no y such that y ≺ x. no arrows point to the element

minimal (partial order)

An element x is a minimal element if there is no y ≠ x such that y ⪯ x. there are no arrows pointing to this element except the ones that come from themselves

vertex

An individual element of V a dot in a graph

uncountably infinite

An infinite set that is not countably infinite An infinite set in which there is NOT a one-to-one correspondence between the elements of the set and the integers.

k-edge-connected

An undirected graph G is k-edge-connected if it remains connected after any k - 1 edges are removed from the graph.

k-vertex-connected

An undirected graph G is k-vertex-connected if the graph contains at least k + 1 vertices and remains connected after any k - 1 vertices are removed from the graph.

Theorem 14.3.2: Number of leaves in a tree.

Any free tree with at least two vertices has at least two leaves. Proof. Find the longest path p in the tree. Let u and v be the first and last vertices in the path. Suppose u is not a degree 1 vertex. (The same argument will hold for v). Then there is an edge e that is incident to u and not part of the path p. If the other endpoint of e, that is not vertex u, is part of the path p, then the graph has a cycle and is not a tree. The path p can be extended by adding e along with the other endpoint of e. The fact that the path p can be extended contradicts the assumption that p was the longest path in the tree. We have shown that the two endpoints in the path p are both leaves. Therefore, the tree has at least two leaves. ■

Show that for every x in a recursively defined set P, x has a particular property

Base case: Show that every element in the basis satisfies the property. Inductive step: The recursive rules show how to construct larger elements in P using smaller elements from P. Assume the property holds for the smaller elements and prove that the property holds for the larger elements.

Show that for every properly nested set of parentheses (every x in P), x is balanced (left[x] = right[x])

Basis: Show that () is balanced Inductive step: Case 1: Assume u is balanced, Prove that (u) is balanced. Case 2: Assume u and v are balanced, Prove that uv is balanced

cycle

Cn is called a cycle on n vertices. The edges connect the vertices in a ring. Cn is well defined only for n ≥ 3.

Theorem 11.3.2: The generalized pigeonhole principle.

Consider a function whose domain has at least n elements and whose target has k elements, for n and k positive integers. Then there is an element y in the target such that f maps at least ⌈n/k⌉ elements in the domain to y. Proof. First we prove that there is an element in the target y such that the number of elements in the domain which f maps to y is greater than or equal to n/k. Proof by contradiction. Suppose that f maps less than n/k elements of the domain to each element in the target. Since there are k elements in the target, the total number of elements in the domain must be less than (n/k)k = n, which contradicts the fact that there are n elements in the domain. Therefore, we can conclude that there is an element in the target to which f maps at least n/k elements. The number of elements that map to any element in the target must be an integer. ⌈n/k⌉ is defined to be the smallest integer that is at least n/k, so it follows that there must be an element in the target to which f maps at least ⌈n/k⌉ elements. ■

Theorem 9.8.2: Equivalence relations define a partition.

Consider an equivalence relation over a set A. The set of all distinct equivalence classes defines a partition of A. The term "distinct" means that if there are two equal equivalence classes [a] = [b], the set [a] is only included once.

Theorem 13.3.1: Vertex degree preserved under isomorphism.

Consider two graphs, G and G'. Let f be an isomorphism from G to G'. For each vertex v in G, the degree of vertex v in G is equal to the degree of vertex f(v) in G'.

Theorem 5.3.1: Explicit formula for a sequence defined by a recurrence relation.

Define the sequence {gn} as: - g0 = 1.gn = 3· - gn-1 + 2n, for any n ≥ 1. Then for any n ≥ 0, gn = 5/2 ⋅ 3^n − n − 3/2

Theorem 5.3.2: Explicit formula for a sequence defined by a recurrence relation.

Define the sequence {hn} as: - h0 = 7 - hn = (hn-1 )^3, for any n ≥ 1 Then for any n ≥ 0, hn=7(3n)

n-dimensional hypercube

Denoted Qn,. Has 2^n vertices. Each vertex is labeled with an n-bit string. Two vertices are connected by an edge if their corresponding labels differ by only one bit.

Discrete probability

Discrete probability is concerned with experiments in which the sample space is a finite or countably infinite set.

linear homogeneous

Each number in a sequence defined by a linear homogeneous recurrence relation is a linear combination of numbers that occur earlier in the sequence

tail / head

Edge (u, v) The vertex u is the tail and vertex v is the head.

ancestor

Every vertex along the path from v to the root

solving a recurrence relation

Finding an explicit formula for a recursively defined sequence

matrix representation

For a graph with n vertices, the matrix representation is an n x n matrix whose entries are all either 0 or 1, indicating whether or not each edge is present. If the matrix is labeled M, then Mi,j denotes the entry in row i and column j. For a matrix representation, the vertices of the graph are labeled with integers in the range from 1 to n. The matrix representation of an undirected graph is symmetric about the diagonal.

range

For function f: X → Y, an element y is in the range of f if and only if there is an x ∈ X such that (x, y) ∈ f. Expressed in set notation: Range of f = { y: (x, y) ∈ f, for some x ∈ X }

one-to-one / injective

For the function f: X → Y, f(x1) ≠ f(x2). That is, f maps different elements in X to different elements in Y.

onto / surjective

For the function f: X → Y, the range of f is equal to the target Y. That is, for every y ∈ Y, there is an x ∈ X such that f(x) = y

Generating permutations

GenLexPermutations(n) Initialize P = (1, 2, ..., n - 1, n) Output P While P ≠ (n, n - 1, ..., 2, 1), P = NextPerm(P) Output P The algorithm GenLexPermutations(n) takes as input a natural number n and outputs all the permutations of {1, 2, ..., n} in lexicographic order. GenLexPermutations starts with the first permutation in lexicographic order and keeps generating the next permutation until the last permutation is reached. The algorithm NextPerm(P) (described below) takes as input a permutation P and returns the smallest permutation that is larger than P.

Generating r-subsets of a set

GenLexSubsets(r, n) Initialize S = {1, 2, ..., r-1, r} Output S While S ≠ {n-r+1, ..., n-1, n}, S = NextSubset(n, S) Output S The algorithm GenLexSubsets(r, n) starts with the first r-subset in lexicographic order and keeps generating the next r-subset until the last r-subset is reached. The algorithm NextSubset(n, S) (described below) takes as input an r-subset S and natural number n and returns the smallest r-subset of {1, 2, ..., n} that is larger than S.

equivalence class

If A is the domain of an equivalence relation and a ∈ A, then [a] is defined to be the set of all x ∈ A such that a~x. The set [a] is called an equivalence class. a~b is read "a is equivalent to b".

Theorem 12.3.1: Complement and conditional probability.

If E and F are both events in the same sample space S, then the probability of E and the probability of E still sum to 1, even when conditioned on the event F. p(E | F) + p(compE | F) = 1

transitive closure of G

If G is a directed graph, then G+ is called the transitive closure of G. G+ is the union of all powers of G from G1 to Gk where k is the number of vertices in G.

Theorem 11.3.1: The pigeonhole principle.

If a function f has a domain of size at least n+1 and a target of size at most n, where n is a positive integer, then there are two elements in the domain that map to the same element in the target (i.e., the function is not one-to-one). Proof. Proof by contradictions. Assume that the hypothesis is true and that the negation of the conclusion is also true. Then no two elements in the domain map to the same element in the target and thus each element in the domain maps to a different element in the target. Since there are n+1 different elements in the domain they map to n+1 different elements in the target, which contradicts the hypothesis that there are n element in the target. Therefore, there must be at least two elements in the domain that f maps to the same element in the target. ■

Theorem 6.3.1: Solutions to linear homogeneous recurrence relations.

If gn and hn satisfy a linear homogeneous recurrence relation then so does fn = s·gn + t·hn for any real numbers s and t.

complete graph

Kn is called the complete graph on n vertices. Kn has an edge between every pair of vertices. Kn,m has n+m vertices. The vertices are divided into two sets: one with m vertices and one set with n vertices. There are no edges between vertices in the same set, but there is an edge between every vertex in one set and every vertex in the other set.

clique

Kn is sometimes called a clique of size n or an n-clique.

Theorem 7.2.1: Cardinality of a power set.

Let A be a finite set of cardinality n. Then the cardinality of the power set of A is 2^n, or |P(A)|=2^n.

Isomorphic graphs

Let G = (V, E) and G'=(V',E'). G and G' are isomorphic if there is a bijection f: V → V' such that for every pair of vertices x, y ∈ V, {x, y} ∈ E if and only if {f(x), f(y)} ∈ E'. The function f is called an isomorphism from G to G'.

Theorem 9.7.1: Directed acyclic graphs and strict orders.

Let G be a directed graph. G has no positive length cycles if and only if G+ is a strict order.

Theorem 9.5.1: The Graph Power Theorem.

Let G be a directed graph. Let u and v be any two vertices in G. There is an edge from u to v in Gk if and only if there is a walk of length k from u to v in G.

Theorem 13.5.1: Upper bound for vertex and edge connectivity.

Let G be an undirected graph. Denote the minimum degree of any vertex in G by δ(G). Then: κ(G)≤δ(G) and λ(G)≤δ(G)

Theorem 13.1.1: Number of edges and total degree.

Let G=(V, E) be an undirected graph. Then twice the number of edges is equal to the total degree.

Theorem 5.2.1: Number of vertices in a perfect binary tree.

Let T be a perfect binary tree. Then the number of vertices in T is 2k - 1 for some positive integer k.

Theorem 14.1.1: Unique paths in trees.

Let T be a tree and let u and v be two vertices in T. There is exactly one path between u and v.

Theorem 14.3.3: Number of edges in a tree.

Let T be a tree with n vertices and m edges, then m = n - 1. Proof. The proof is by induction on the number of vertices. The base case is where n = 1. If T has one vertex, then it is has no edges. Then m = 0 = n - 1. For the inductive step, assume the theorem holds for trees with n-1 vertices and prove that it holds for trees with n vertices. Consider an arbitrary tree T with n vertices. Since n ≥ 2, by the previous theorem, the tree has at least two leaves. Let v be one of the leaves. Remove v from T along with the edge e incident to v. The resulting graph (call it T') is also a tree and has n-1 vertices. By the induction hypothesis, The number of edges in T' is (n - 1) - 1 = n - 2. T has exactly one more edge than T', because only edge e was removed from T to get T'. Therefore the number of edges in T is n - 2 + 1 = n - 1.■

binary relation

Mathematically, a binary relation between two sets A and B is a subset R of A×B. For a∈A and b∈B, the fact that (a,b)∈R is denoted by aRb.

Algorithm to generate the next r-subset in lexicographic order

NextSubset(n, {s1, s2, ..., sr}) Let k be the largest index such that sk < n - r + k If no such k exists then {s1, s2, ..., sr} is the last r-subset of {1, 2, ..., n}. sk := sk + 1 For j = k+1 to r sj := sj-1+1 Return( {s1, s2, ..., sr} )

power set

P(A) = power set of A = the set of all subsets of A Ex. A = { 1, 2, 3 } P(A) = {∅, { 1 }, { 2 }, { 3 }, { 1, 2 }, { 1, 3 }, { 2, 3 }, { 1, 2, 3 }}

directed acyclic graph / DAG

a directed graph that has no positive length cycles. A positive length cycle is a cycle with one or more edges.

The following statements describes the inductive step in a proof that proves a theorem about a graph by induction on the number of vertices

Start with a graph and remove a vertex. Assume that the theorem holds for the graph with the vertex removed and prove that the theorem holds for the graph when the vertex is put back in.

Theorem 12.4.1: Bayes' Theorem.

Suppose that F and X are events from a common sample space and p(F) ≠ 0 and p(X) ≠ 0. Then p(F|X) = ( p(X|F)p(F) ) / ( p(X|F)p(F) + p(X|compF)p(compF) )

Theorem 11.3.3: Converse of the generalized pigeonhole principle.

Suppose that a function f maps a set of n elements to a target set with k elements, where n and k are positive integers. In order to guarantee that there is an element y in the target to which f maps at least b elements from the domain, then n must be at least k(b - 1) + 1. Proof. If n ≤ k(b -1), then it is possible that f maps b -1 element to each y in the target set, which means that there is not necessarily an element y in the target to which f maps at least b items. ■

number of edges in a forest

Suppose that there is a forest with n vertices and c connected components. The number of edges in the forest as a function of n and c is: n-c

k-to-1 rule

Suppose there is a k-to-1 correspondence from a finite set A to a finite set B. Then |B| = |A|/k.

cardinality

The cardinality of a finite set A, denoted by |A|, is the number of elements in A

ceiling function

The ceiling function rounds a real number to the nearest integer in the upward direction. Ex. ⌈4.32⌉ = 5

binomial coefficients

The coefficients in the expansion of (a + b)^n for positive integer n are called binomial coefficients.

composition

The composition of relations R and S on set A is another relation on A, denoted S ο R. The pair (a, c) ∈ S ο R if and only if there is a b ∈ A such that (a, b) ∈ R and (b, c) ∈ S.

conditional probability

The conditional probability of E given F is p(E|F) = p(E∩F) / p(F)

golden ratio

The constant ϕ=(1+sqrt5)/2 The golden ratio describes certain proportions found in natural objects and has been used for thousands of years in man made structures in art and architecture.

Theorem 13.3.2: Degree sequence preserved under isomorphism.

The degree sequence of a graph is preserved under isomorphism.

difference

The difference between two sets A and B = A - B = the set of elements that are in A but not in B

partially ordered set / poset

The domain along with a partial order defined on it is denoted (A, ⪯)

incident

The edge {b, e} is incident to vertices b and e.

general solution

The expression denoting the infinite set of solutions to a recurrence relation without initial values

floor function

The floor function maps a real number to the nearest integer in the downward direction Ex. ⌊4.32⌋ = 4

k-to-1 correspondence

The function f:X→Y is a k-to-1 correspondence if for every y ∈ Y, there are exactly k different x ∈ X such that f(x) = y.

identity function

The function that always maps a set onto itself and maps every element onto itself Ex. The identity function on A, denoted IA: A → A, is defined as IA(a) = a, for all a ∈ A. Let f: A → B be a bijection. Then f^-1 ο f = IA and f ο f^-1 = IB.

power of G

The graph Gk is defined to be the directed graph whose edge set is Ek and is called the kth power of G.

intersection

The intersection of A and B = A ∩ B = the set of all elements that are elements of both A AND B.

elements

The objects in a set

uniform distribution

The probability distribution in which every outcome has the same probability. For every event E, p(E) = |E| / |S|

probability of event E

The probability of outcome s is p(s). If E ⊆ S is an event, then the probability of event E is the sum of the probabilities of all outcomes in E

composition

The process of applying a function to the result of another function f and g are two functions, where f: X → Y and g: Y → Z. The composition of g with f, denoted g ο f, is the function (g ο f): X → Z, such that for all x ∈ X, (g ο f)(x) = g(f(x)).

transitive closure of R

The relation R+ is called the transitive closure of R and is the smallest relation that is both transitive and includes all the pairs from R.

sample space

The set of all possible outcomes

alphabet

The set of characters used in a set of strings

symmetric difference

The symmetric difference between two sets, A and B = A ⊕ B = the set of elements that are a member of exactly one of A and B, but NOT both

union

The union of two sets A and B = A ∪ B = the set of all elements that are elements of A OR B

Theorem 14.3.1: Unique paths in trees.

There is a unique path between every pair of vertices in a tree. Proof. A tree is defined to be a connected graph with no cycles. Because every tree is connected, there is at least one path between every pair of vertices. It remains to establish that there is at most one path between every pair of vertices. The proof is by contrapositive. We assume that there is a pair of vertices u and v such that there are two distinct paths between u and v and then show that the graph must have a cycle (and therefore can not be a tree). Let p and p' be the two distinct paths between u and v. Find the first place where the two paths differ. Let x be the vertex just before the point where the two paths diverge. Follow path p until it hits a vertex y that is also contained in p'. (Both paths end up at v, so there has to be a point where the two paths come together). The portion of the path p between x and y and the portion of the path p' between x and y form a cycle. ■

Universal quantifier (∀)

Turns a predicate into a proposition by proposing that for every instance in a domain, there's a resolution

existential quantifier (∃)

Turns a predicate into a proposition by proposing that there is at least one element in the domain that has a resolution for the statement.

logically equivalent

Two compound propositions are said to be logically equivalent if they have the same truth value regardless of the truth values of their individual propositions, denoted by ≡.

comparable / incomparable (partial order)

Two elements of a partially ordered set, x and y, are said to be comparable if x ⪯ y or y ⪯ x. Otherwise they are said to be incomparable.

comparable / incomparable (strict order)

Two elements, x and y, are said to be comparable if x ≺ y or y ≺ x. Otherwise, the elements are said to be incomparable.

independent

Two events are independent if conditioning on one event does not change the probability of the other event. Let E and F be two events in the same sample space. The following three conditions are equivalent: a) p(E|F) = p(E∩F) / p(F) = p(E) b) p(E∩F) = p(E) ⋅ p(F) c) p(F|E) = p(E∩F) / p(E) = p(F) If the three conditions hold, then events E and F are independent.

mutually exclusive

Two events are mutually exclusive if the two events are disjoint (i.e., the intersection of the two events is empty). It follows from the definition of the probability of an event that if E1 and E2 are mutually exclusive, then: p( E1 ∪ E2 ) = p(E1) + p(E2)

equal

Two functions, f and g, are equal if f and g have the same domain and target, and f(x) = g(x) for every element x in the domain. view_list

Non- Isomorphic

Two graphs cannot be isomorphic if they don't: a) Have the same number of vertices and edges b) Have the same degree sequence

disjoint

Two sets, A and B, are said to be disjoint if their intersection is empty A ∩ B = ∅

siblings

Two vertices are siblings if they have the same parent

endpoints

Vertices b and e are the endpoints of edge {b, e}.

cycle

a CIRCUIT of length at least 1 in which no vertex occurs more than once, except the first and last vertices which are the same. - closed walk - unique edges - unique vertices

circuit

a CLOSED WALK in which no edge occurs more than once - closed walk - unique edges

path

a TRAIL in which no vertex occurs more than once - open walk - unique vertices - unique edges

cycle

a circuit of length at least 1 in which no vertex occurs more than once, except the first and last vertices which are the same - closed walk - unique edges - unique vertices

circuit

a closed walk in which no edge occurs more than once - closed walk - unique edges

partition

a collection of non-empty subsets of A such that each element of A is in exactly one of the subsets

set

a collection of objects

logical operation

a combination of propositions using a particular composition rule

contradiction

a compound proposition that is always false

tautology

a compound proposition that is always true

inverse

a function f that maps set S to set T is a function g that maps T to S such that for every s ∈ S and every t ∈ T, f(s) = t, if and only if g(t) = s. If a function f has an inverse, it is denoted by f-1

simple graph

a graph that does not have parallel edges or self-loops

forest

a graph that has no cycles and that is not necessarily connected.

edge

a line connecting two vertices

degree sequence

a list of the degrees of all of the vertices in non-increasing order.

roster notation

a list of the elements enclosed in curly braces with the individual elements separated by commas Order does not matter Ex. A = { 2, 4, 6, 10 } = { 10, 6, 4, 2 }

connected component

a maximal set of vertices that is connected. The word "maximal" means that if any vertex is added to a connected component, then the set of vertices will no longer be connected.

directed graph / digraph

a pair (V, E). V is a set of vertices, and E, a set of directed edges, is a subset of V × V.

disconnected graph

a pair of vertices in the graph is disconnected

experiment

a procedure that results in one out of a number of possible outcomes

compound proposition

a proposition created by connecting individual propositions with logical operations

matrix representation

a rectangular array of numbers with |A| rows and |B| columns.

walk

a sequence of alternating vertices and edges that starts and ends with a vertex <v1, v2, ... , vn-1, vn>

walk

a sequence of alternating vertices and edges that starts and ends with a vertex.

argument

a sequence of propositions p1 p2 p3 ... pn ------------------- therefore, C

r-permutation

a sequence of r items with no repetitions, all taken from the same set

arithmetic sequence

a sequence of real numbers where each term after the initial term is found by taking the previous term and adding a fixed number called the common difference

geometric sequence

a sequence of real numbers where each term after the initial term is found by taking the previous term and multiplying by a fixed number called the common ratio

logical proof

a sequence of steps, each of which consists of a proposition and a justification

alphabet

a set of characters

universal set

a set that contains all elements mentioned in a particular context.

infinite set

a set that is not finite

empty set / null set

a set with no elements ( ∅ )

vertex

a single point

sequence

a special type of function in which the domain is a set of consecutive integers

Proposition

a statement that is either true or false

binary string

a string whose alphabet is {0, 1}.

binary relation on a set A

a subset of A x A. The set A is called the domain of the binary relation.

dynamical system

a system that changes over time

truth table

a table showing the truth value of a compound proposition for every possible combination of truth values for the variables contained in the compound proposition

identity

a theorem stating that two mathematical expressions are equal.

path

a trail in which no vertex occurs more than once. - open walk - unique vertices - unique edges

Structural induction

a type of induction used to prove theorems about recursively defined sets that follows the structure of the recursive definition

Truth values

a value indicating whether a proposition is actually true or false

element

a value that can be plugged in for a variable x

bound variable

a variable that is bound to a quantifier i.e. The variable x in the statement ∀x P(x)

free variable

a variable that is free to take on any value in the domain. i.e. variable x in the predicate P(x)

post-order traversal

a vertex is visited after its descendants

pre-order traversal

a vertex is visited before its descendants

leaf

a vertex which has no children

closed walk

a walk in which the first and last vertices ARE the same.

open walk

a walk in which the first and last vertices are NOT the same.

Lexicographic order

a way of ordering n-tuples in which two n-tuples are compared according to the first entry where they differ.

sum rule

a way to count combinations which involves the addition of the cardinalities of sets

d-regular graph

all the vertices have degree d

regular graph

all the vertices have the same degree

trail

an OPEN WALK in which no edge occurs more than once. - open walk - unique edges

self-loop

an edge between a vertex and itself

counterexample

an element in the domain for which the predicate is false. i.e. For example, consider the statement ∀x (x2 > x), in which the domain is the set of positive integers. When x = 1, then x2 = x and the statement x2 > x is not true. Therefore x = 1 is a counterexample that shows the statement "∀x (x2 > x)" is false.

conditional statement

an english version of a conditional proposition. i.e. "If there is a traffic jam today, then I will be late for work"

set identity

an equation involving sets that is true regardless of the contents of the sets in the expression

ordered n-tuple

an ordered list of n items where n ≥ 4

permutation with repetition

an ordering of a set of items in which some of the items may be identical to each other

tree

an undirected graph that is connected and has no cycles

conditional proposition

compound proposition that uses a conditional operation

mutually independent

conditioning on ANY one event does not change the probability of any OTHER event. Events A1, ..., An in sample space S are mutually independent if the probability of the intersection of any subset of the events is equal to the product of the probabilities of the events in the subset. In particular, if A1, ..., An are mutually independent, then p(A1 ∩ A2 ∩ ... ∩ An) = p(A1) · p(A2) ... p(An)

conditional operation

denoted with the symbol →. The proposition p → q is read "if p then q". It is false if p is true and q is false, otherwise it is true.

adjacency list representation

each vertex has a list of all its neighbors

inductive step

establishes that if the theorem is true for k, then the theorem also holds for k + 1

base case

establishes that the theorem is true for the first value in the sequence

Fibonacci sequence

f(0) = 0 f(1) = 1 f(n) = f(n-1) + f(n-2) for n≥2

initial term

first value

common difference

fixed difference between values of a sequence

common ratio

fixed ratio between values in a sequence

arrow diagram

for a function f, the elements of the domain X are listed on the left and the elements of the target Y are listed on the right

increasing

for every two consecutive indices, k and k + 1, in the domain, ak < ak+1

decreasing

for every two consecutive indices, k and k + 1, in the domain, ak > ak+1

non-decreasing

for every two consecutive indices, k and k + 1, in the domain, ak ≤ ak+1

non-increasing

for every two consecutive indices, k and k + 1, in the domain, ak ≥ ak+1

pigeonhole principle

if n+1 pigeons are placed in n boxes, then there must be at least one box with more than one pigeon.

principle of mathematical induction

if the base case (for n = 1) is true and inductive step is true, then the theorem holds for all positive integers Let S(n) be a statement parameterized by a positive integer n. Then S(n) is true for all positive integers n, if: 1. Base case: S(1) is true . 2. Inductive step: For all k ∈ Z+, S(k) implies S(k+1)

valid argument

if the conclusion is true when all the hypotheses are true

identity

if the equation holds for all values for which the expressions in the equation are well defined

bijection rule

if there is a bijection from one set to another then the two sets have the same cardinality

generalized product rule

in selecting an item from a set, if the number of choices at each step does not depend on previous choices made, then the number of items in the set is the product of the number of choices in each step.

inverse of a function

inverse of f = f^-1 = { (y, x) : (x, y) ∈ f } where f is a bijection

Counting by complement

is a technique for counting the number of elements in a set S that have a property by counting the total number of elements in S and subtracting the number of elements in S that do not have the property

level

its distance from the root

final term

last value

Parallel edges

multiple edges between the same pair of vertices

free tree

no particular organization of the vertices and edges

arbitrary element

no special properties

bijection

one to one and onto

exclusive or

only evaluates to True if and only if one of the two propositions are true, not both. Denoted by ⊕

trail

open walk in which no edge occurs more than once. - open walk - unique edges

negation

operation that reverses the truth value of the proposition, i.e. ¬p and is read as "not p"

addition

p ---- p v q

modus ponens

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

Conjunction

p q --- p ^ q

simplification

p ^ q ------ p

disjunctive syllogism

p v q ~p ----- q

resolution

p v q ~p v r ------- q v r

Conditional identities

p → q ≡ ¬p ∨ q, and p ↔ q ≡ ( p → q ) ∧ ( q → p )

Domination laws

p ∧ F ≡ F, and p ∨ T ≡ T

conjunction

p ∧ q, read "p and q". if p is true and q is true, then the truth value is true. It is false if p, q, or both are false.

Complement laws

p ∧ ¬p ≡ F ¬T ≡ F, and p ∨ ¬p ≡ T ¬F ≡ T

Distributive laws

p ∨ ( q ∧ r ) ≡ ( p ∨ q ) ∧ ( p ∨ r ), and p ∧ ( q ∨ r ) ≡ ( p ∧ q ) ∨ ( p ∧ r )

Absorption laws

p ∨ (p ∧ q) ≡ p, and p ∧ (p ∨ q) ≡ p

Identity laws

p ∨ F ≡ p, and p ∧ T ≡ p

Idempotent Laws

p ∨ p ≡ p, and p ∧ p ≡ p

Commutative laws

p ∨ q ≡ q ∨ p, and p ∧ q ≡ q ∧ p

disjunction

p ∨ q, read "p or q". the proposition is true if either p or q is true, and is false only if both p and q are false.

Inclusion-Exclusion principle

p(E1∪E2) = p(E1) + p(E2) − p(E1∩E2) (given that E1 and E2 are not mutually exclusive)

hypothetical syllogism

p-> q q-> r ------ p->r

initial index

placement first value

final index

placement of last value

index

placement order

finite graph

the vertex set is finite.

homogeneous

there are no additional terms in the expression for fn besides the ones that refer to earlier numbers in the sequence

countably infinite

there is a one-to-one correspondence between the elements of the set and the integers.

adjacent vertices

there is an edge between the two vertices

tree traversal

to process the information stored in the vertices by systematically visiting each vertex

Universal generalization

replace an element of the domain with a quantified variable c is an arbitrary element P(c) ------------------------- ∴ ∀x P(x)

existential generalization

replace an element of the domain with a quantified variable c is an element (arbitrary or particular) P(c) --------------------- ∴ ∃x P(x)

universal instantiation

replace quantified variable with an element from the domain c is an element (arbitrary or particular) ∀x P(x) ---------------- ∴ P(c) Sam is a student in the class. Every student in the class completed the assignment. Therefore, Sam completed his assignment.

existential instantiation

replace quantified variable with an element from the domain ∃x P(x) --------- ∴ (c is a particular element) ∧ P(c) There is an integer that is equal to its square. Therefore, c^2 = c, for some integer c.

outcomes

result of an experiment

inclusive or

same operation as the disjunction, evaluating true if either proposition is true.

finite set

set that is either empty or whose elements can be numbered 1 through n for some positive integer n.

root

top-most vertex in a rooted tree

particular element

specific properties that are not shared by all the elements in the domain.

set builder notation

specifying that the set includes all elements in a larger set that also satisfy certain conditions. Ex. Given set S, A = { x ∈ S : P(x) }

Cartesian product

the Cartesian product of A and B = A x B = the set of all ordered pairs in which the first entry is in A and the second entry is in B A x B = { (a, b) : a ∈ A and b ∈ B }

prefix code

the code for one character can not be a prefix of the code for another character

undirected graph

the edges are unordered pairs of vertices, which is useful for modeling relationships that are symmetric.

open walk

the first and last vertices are not the same

closed walk

the first and last vertices are the same

parent

the first vertex after v encountered along the path from v to the root

form

the form of an argument is the conversion from english propositions to variable based propositions i.e. From It is raining today If it is raining today, I will not ride my bike to school ------------------------------------------------------ I will not ride my bike to school To p p -> q ------------ q

height

the highest level of any vertex

edge connectivity

the largest k such that the graph is k-edge-connected. The edge connectivity of a graph G is denoted λ(G). the minimum number of edges whose removal disconnects the graph into more than one connected component.

vertex connectivity

the largest k such that the graph is k-vertex-connected. the minimum number of vertices whose removal disconnects the graph into more than one connected component.

variable length codes

the number of bits for each character can vary. As opposed to ASCII codes which translate binary strings into characters with a fixed length code, these allow for more space-efficient encodings. Trees are a convenient way to represent variable length codes for translating between text and binary.

length

the number of characters in the string.

distance between two vertices in an undirected graph

the number of edges in the shortest path between the two vertices

length of a walk

the number of edges in the walk.

in-degree

the number of edges pointing into it.

out-degree

the number of edges pointing out of it.

degree

the number of neighbors it has

complement

the set of all elements in U that are not elements of A Ex. U = {1, 2, 3, 4} A = {1, 2} compA = {3, 4}

Z

the set of all integers. (..., -2, -1, 0, 1, 2, ...)

domain

the set of all possible values for the variable

N

the set of natural numbers, which includes all integers greater than or equal to 0. (0, 1, 2, ...)

Q

the set of rational numbers, which includes all real numbers that can be expressed as a/b, where a and b are integers and b ≠ 0. (0, 1/2, 5.23, -5/3)

R

the set of real numbers. (0, 1/2, 5.23, -5/3, π, sqrt2)

Logic

the study of formal reasoning

total degree

the sum of the degrees of all of the vertices.

subtree

the tree consisting of v and all v's descendants

empty string

the unique string whose length is 0 and is usually denoted by the symbol λ.

rooted tree

vertices are organized according to their distance from the root

invalid argument

when there is at least one hypothesis or the final conclusion that is false

undirected edge

{a, b}

De Morgan's Laws

¬( p ∨ q ) ≡ ¬p ∧ ¬q, and ¬( p ∧ q ) ≡ ¬p ∨ ¬q

De Morgan's laws

¬(p ∨ q) ≡ (¬p ∧ ¬q), ¬(p ∧ q) ≡ (¬p ∨ ¬q)

Double negation law

¬¬p ≡ p

DeMorgan's Law for Quantified Statements

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

DeMorgan's Laws for nested quantified statements

¬∀x ∀y P(x, y) ≡ ∃x ∃y ¬P(x, y) ¬∀x ∃y P(x, y) ≡ ∃x ∀y ¬P(x, y) ¬∃x ∀y P(x, y) ≡ ∀x ∃y ¬P(x, y) ¬∃x ∃y P(x, y) ≡ ∀x ∀y ¬P(x, y)

universally quantified statement

∀x P(x), "For every x, P(x)"

existentially quantified statement

∃x P(x), "there exists an x for which P(x)"


Related study sets

Biliary Tree, Liver pathology, liver pathology

View Set

Intro to Coding - Testing and Fixing Code

View Set

Patho Unit 1: Introduction to Patho

View Set

APR Exam Practice Questions Set 01

View Set

Comprehensive AANP Review (LEIK/Barkley/Fitzgerald) pt. 4* (women,pregnancy,childbirth/peds)

View Set

PrepU chapter 10; Patients With Chest and Lower Respiratory Tract Disorders

View Set

Micro: CH13 Costs of Production - Practice problems

View Set