Building a recognizer that could handle such unconstrained gesture would be a substantial undertaking and an important research contribution in its own right.
the precise definition of a recurrence relation for m[i, j] and a proof of correctness will be described in a future publication.