Asked By : 372
Answered By : Raphael
- The algorithm is a straight-forward implementation of equation (5) using memoisation.
- Equation (5) is correct, that is $A[i,j]$ is
the minimum cost triangulation of the polygon spanned by vertices $i,i+1,…,j$
as the author claims. They give a reasoning right there:
Formulating the subproblem this way we are enumerating all the possible diagonals such that the diagonals do not cross each other. Since we are only considering in clockwise directions, diagonals generated by the subproblems can not cross each other.
They argue that
- all feasible solutions are considered and
- all considered solutions are feasible.
If this is true, then choosing the minimum out all considered solutions is clearly the correct answer. Proving the bullets now needs insight into the problem, and the author gives the basic idea. In terms of an induction, what I sketch above amounts to the inductive step. The anchor is trivial and covered in the text. The induction hypothesis has to be phrased such that you know for $i,j$ fixed that all $A[i,k]$ and $A[k,j]$ for $k=i,dots,j$ are optimal.
Best Answer from StackOverflow
Question Source : http://cs.stackexchange.com/questions/11085