Calculate mean and variance of exponential (#872)