Math review

Exponents

Logarithms

Definition: XA = B if and only if logXB = A

Logarithms used in this course will be to the base 2, unless otherwise specified

Theorem 1.1 (base change)

logA B = ( logC B ) / ( logC A ) for A,B,C > 0, A != 1

Can you prove this? (Hint: Use definition of log to derive this property)

Other easlily derived (and provable) properties

These can be shown for any base. Assume base 2, unless otherwise specified

Proof Techniques

Common proof techniques that will be used in data structure and algorithm analysis (and in CS, in general):

Proof by Induction

Given a statement or theorem to prove:

Proof by contradiction

To use this technique to prove a statement or theorem:

Proof by counterexample

This is the easiest way to prove a given assertion to be false.

Example 1 (induction)

Suppose we use the following definition of the Fibonnaci series: Prove the following (by induction):

(Solution in class)
 

Example 2 (counter-example)

Using the same Fibonnaci definition above, is this statement true or false? All we need is one counterexample to show the formula is false. (To be true, it must hold for all values of k).

Example 3 (contradiction)

Theorem: There are an infinite number of primes

Proof: