
Notes:
The problem is set up as minimization problem, called procrustes problem where we try to find the the rigid transformation that takes us iteratively closer to the correct position.
The algorithm operates on two point clouds and each point in the surface to be matched against the model needs a corresponding point in the other cloud. This correspondence is set up using precomputed distancemaps as LUT's to make it fast.