Introduction - If you have any usage issues, please Google them yourself
Using matlab to calculate the Mahalanobis distance for the image, Matlab for beginner students will help, Including the generalized cross-correlation function GCC time delay estimation.