updated corr fcn calculation to sample from random gals