6/14/2006

Citations from Corman's "Algorithms" textbook:

Dynamic Programming, like the Divide-and-Conquer methods, solves problems by combining the solutions to subproblems.

  • Divide-and-conquer algorithms partition the problem into independent subproblems, solve the subproblems recursively, and then combine their solutions to solve the original problem.
  • In contract, dynamic programming is applicable when the subproblems are not independent, that is, when subproblems share subsubproblems.
    • In this context, a divide-and-conquer algorithm does more work than necessary, repeatedly solving the common subsubproblems.
    • A dynamic-programming algorithm solves every subsubproblem just once and then saves its answer in a table, thereby avoiding the work of recomputing the answer every time the subsubproblem is encountered.
The development of a dynamic programming algorithm can be broken into a sequence of four steps.
  1. Characterize the structure of an optimal solution.
  2. Recursively define the value of an optimal solution.
  3. Compute the value of an optimal solution in a bottom-up fashion.
  4. Construct an optimal solution from computed information.

0 Comments:

Post a Comment

Subscribe to Post Comments [Atom]

<< Home