mse function

Computing the mean squared error