next up previous
Next: Up: Previous:

Proving Greedy Algorithms Optimal

Need to prove 1) optimal substructure and 2) greedy choice property.

The proof of 2 typically involves:

a.
Consider globally-optimal solution.
b.
Show greedy choice at first step reduces problem to the same but smaller problem.
Greedy choice must be
  • Part of an optimal solution, and
  • Can be made first
c.
Use induction to show greedy choice is best at each step (i.e., optimal substructure)


next up previous
Next: Up: Previous: