Control variates: Difference between revisions

and ''U'' follows a [[uniform distribution (continuous)|uniform distribution]] [0, 1].
Using a sample of size '''n''' denote the points in the sample as <math>u_1, \cdots, u_n</math>. Then the estimate is given by
:<math>I \approx \frac{1}{n} \sum_i f(u_i); </math>;
If we introduce <math>T=\int_0^1 1+x \, \mathrm{d}x. </math> as a control variate with a known expected value <math>\textrm{E}\left[T\left(U\right)\right]=\frac{3}{2} </math>
Using <math>n=1500</math> realizations and an estimated optimal coefficient <math> c^{\star} \approx 0.4773 </math> we obtain the following results
{| cellspacing="1" border="1"