Conditional Monte Carlo (source code)

= Conditional Monte Carlo

Replacing a simulated quantity $H$ by $E[H\mid\mathcal G]$ preserves its expectation and reduces variance by the <law of total variance>. This is <Rao-Blackwellization>. For a random sum, conditioning on the count and all but one summand replaces an event indicator by a <cumulative distribution function> evaluation. The resulting estimator needs that conditional expectation to be computable.