  We propose a new method for shape recognition and retrieval based on dynamic
programming. Our approach uses the dynamic programming algorithm to compute the
optimal score and to find the optimal alignment between two strings. First,
each contour of shape is represented by a set of points. After alignment and
matching between two shapes, the contours are transformed into a string of
symbols and numbers. Finally we find the best alignment of two complete strings
and compute the optimal cost of similarity. In general, dynamic programming has
two phases: the forward phase and the backward phase. In the forward phase, we
compute the optimal cost for each subproblem. In the backward phase, we
reconstruct the solution that gives the optimal cost. Our algorithm is tested
in a database that contains various shapes such as MPEG-7.
