Analysis_and_Application_of_Dynamic_Programming
Analysis_and_Application_of_Dynamic_Programming
1. Introduction
The dynamic programming method is a method to solve the multi-stage decision-making optimal
solution problem. It is not as "dynamic" as the name suggests. In the process of solving a practical
problem, it divides the big problem into small problems and defines the initial state. The current sub-
problem can be solved by the previous sub-problem. The focus and difficulty of solving this problem
is the connection between the current sub-problem and the previous sub-problem, that is, the state
transition equation. After finding the state transition equation, the solution of the sub-problem is
sought step by step from the bottom to the top of the initial state of the problem, so as to solve the final
big problem.
Content from this work may be used under the terms of the Creative Commons Attribution 3.0 licence. Any further distribution
of this work must maintain attribution to the author(s) and the title of the work, journal citation and DOI.
Published under licence by IOP Publishing Ltd 1
2021 International Conference on Advances in Optics and Computational Sciences IOP Publishing
Journal of Physics: Conference Series 1865 (2021) 042023 doi:10.1088/1742-6596/1865/4/042023
In general, in the process of thinking about the problem, our thinking should be top-down. To solve
the original problem, we need to solve the problem of the previous stage of the original problem, and
there are multiple states in the previous stage. The choice of, all may constitute the solution of the
original problem, which needs to be judged by the transfer equation, and these states are determined
by the last stage... loop this process until the initial state. But in the process of calculation, its process
is bottom-up. Starting from the initial state, the solution of each state of the first stage is calculated,
and then the states of the next stage can be solved from these solutions until the solution of the last
stage is completed.
4. Application
2
2021 International Conference on Advances in Optics and Computational Sciences IOP Publishing
Journal of Physics: Conference Series 1865 (2021) 042023 doi:10.1088/1742-6596/1865/4/042023
programming. Now we come to think about whether it is optimal to use dynamic programming to
solve this problem. Suppose this problem has n stages, and each stage has m states. When m is equal
to 1, this problem is suitable to be solved by recursion; if the optimal state of each stage is derived
from the optimal state of the previous stage, then this problem is suitable to be solved by the greedy
method; if each stage the optimal state of is derived from some state in a previous stage, then this
problem is suitable to be solved by dynamic programming.
After determining that this problem is suitable for solving by dynamic programming, the problem
is divided into multiple stages according to the characteristics of the problem. When the problem
develops to a certain stage, we need to use different states to represent the objective situation of the
problem at this time, and then What we need to find is the relationship between a certain state in a
certain stage and the state of the previous stage, that is, to find the transition equation. Before that, we
need to ensure that the choice of state has no aftereffect and find the initial state. Finally, find the
optimal solution at each stage according to the transfer equation, and finally find the optimal solution
at the final stage, that is, find the solution to the original problem.
5. Conclusions
The key point of the dynamic programming method is to find the transfer equation, and this transfer
equation is equivalent to the recursive formula in the recursive solution method. This article
systematically introduces the basic ideas, problem-solving steps and application examples of the
dynamic programming method, and specifically expounds the similarities and differences between the
dynamic programming method and other algorithms and their conversion relations. Through the
comparison with other algorithms, the essence of dynamic programming is analyzed and considered:
use the solved problems to solve new problems.
3
2021 International Conference on Advances in Optics and Computational Sciences IOP Publishing
Journal of Physics: Conference Series 1865 (2021) 042023 doi:10.1088/1742-6596/1865/4/042023
References
[1] Anany Levitin. Design and analysis of algorithms reconsidered. 2000, 32(1): 16-20.
[2] Pferschy Ulrich, Scatamacchia Rosario. Improved dynamic programming and approximation
results for the knapsack problem with setups. 2018, 25(2): 667-682.
[3] Dereventsov A. V, Temlyakov V. N. A unified way of analyzing some greedy algorithms. 2019,
227(12): 49-64.