now calculating pearson chi2 with a sum of 6 gaussians. Ran into regiter memory issues.