|
META TOPICPARENT |
name="DuckyHomework" |
Ducky notes for CS 500 Midterm
The midterm is 20% of the grade. |
|
- use random permutation in backwards error analysis
- Rabin's approach to closest pair: take random sample, use that to calc guess of delta
- Polynomial multiplication and convolution
|
|
> > |
- partition-select -- divide into > and < some partition; look at expected number of steps in each phase, calc expected number of steps in each phase
- sample-select -- compute a sample whose size s-hat = (size s)^.75 = n^.75; look at k/n^.25 +/- n^.5
- interval scheduling:
- greedy earliest termination time works for lowest idle time
- interval coloring problem: use earliest start, use smallest color unused by neighbors
|
|
Readings: |
|
- understand = / = tree
- |p[i] - p[j]| : |p[k]-p[l]| with pairwise comparisons
- be able to write the linear median-finding algo
|
|
< < |
- review problem 3 on HW1 (2005.09.22p4) -- maybe do it for practice
|
> > |
-
review problem 3 on HW1 (2005.09.22p4) -- maybe do it for practice
|
|
On cheat sheet: |
|
- sterling's law
- some series
- some derivatives?
|
|
> > |
- some probability, including Chebyshev
|
|
- exponentiation/log rules
- (n/2)^(n/2) < n! < n^n
|
|
< < |
- use equivalence classes to help figure probabilities or to figure binary decision tree
|
|
- c[k] = sum(a[i]*b[j]) for all i and all j such that i+j = k.
- the key observation from Karatsuba
|
|
> > |
- sizes of things on binary tree
- if n' <= n^.75, can sort in linear time (why?)
- consider adding all of 2005.10.04 p4/5
- harmonic series: sum over n of 1/i = lg n + O(1)
- order stats for various sorts, including heap
|
|
At some point write up heuristics:
- divide and conquer
- look at tree of problem for intuition about running time
- if having trouble analyzing probabilities going forward, try going backwards
- randomization makes it harder for an adversary to be evil
|
|
> > |
- for partitioned things, figure the probability that something is < 3/4 original
- use equivalence classes to help figure probabilities or to figure binary decision tree
From wikipedia:
In general, greedy algorithms have five pillars:
- A candidate set, from which a solution is created
- A selection function, which chooses the best candidate to be added to the solution
- A feasibility function, that is used to determine if a candidate can be used to contribute to a solution
- An objective function, which assigns a value to a solution, or a partial solution, and
- A solution function, which will indicate when we have discovered a complete solution
|
| |