This renders a cost matrix as a 3D terrain and finds the cheapest path across it: starting at the row you pick, moving one column at a time, free to step to the row above or below at each step. The highlighted path is the minimum-cost route, found with dynamic programming. Drag to rotate, scroll to zoom.
Row the path starts from, on the left edge of the grid.
\(f(x, y)\)
\(x\)
\(y\)
Total cost: 0