Dynamic Programming is a technique used to solve problems by reducing difficult cases to simpler cases, recursively, until you reach a case simple enough to solve "by inspection". Therefore, there can only be a sensible DP approach to the n-puzzle problem if, at each stage, you can consider a move which reduces the complexity of the problem.
For instance, if the first "move" in a n-puzzle always made it into an "(n-1)-puzzle" (for some concrete definition of "move", and assuming an (n-1)-puzzle made sense), then you could apply DP, eventually solving the "1-puzzle", and composing back upwards to solve the n-puzzle.
I don't know of any such simplification process for the n-puzzle; and I can't think of one at the moment. However, that doesn't mean one doesn't exist.
发布评论
评论(1)
动态编程是一种用于解决问题的技术,它通过递归地将困难的情况简化为更简单的情况,直到达到足够简单的情况,可以“通过检查”解决。因此,如果在每个阶段都可以考虑采取降低问题复杂性的举措,那么对于 n-puzzle 问题,只能有一种合理的 DP 方法。
例如,如果 n-谜题中的第一个“移动”总是使其成为“(n-1)-谜题”(对于“移动”的某些具体定义,并假设 (n-1)-谜题有意义),然后你可以应用DP,最终解决“1-谜题”,并向上组合以解决n-谜题。
我不知道 n 谜题有任何这样的简化过程;我现在想不出一个。然而,这并不意味着不存在。
Dynamic Programming is a technique used to solve problems by reducing difficult cases to simpler cases, recursively, until you reach a case simple enough to solve "by inspection". Therefore, there can only be a sensible DP approach to the n-puzzle problem if, at each stage, you can consider a move which reduces the complexity of the problem.
For instance, if the first "move" in a n-puzzle always made it into an "(n-1)-puzzle" (for some concrete definition of "move", and assuming an (n-1)-puzzle made sense), then you could apply DP, eventually solving the "1-puzzle", and composing back upwards to solve the n-puzzle.
I don't know of any such simplification process for the n-puzzle; and I can't think of one at the moment. However, that doesn't mean one doesn't exist.