Compute value of $\pi$ up to 8 digits I am quite lost on how approximate the value of $\pi$ up to 8 digits with a confidence of 99% using Monte Carlo. I think this requires a large number of trials but how can I know how many trials?
I know that a 99% confidence interval is 3 standard deviations away from the mean in a normal distribution. From the central limit theorem the standard deviation of the sample mean (or standard error) is proportional to the standard deviation of the population $\sigma_{\bar X} = \frac{\sigma}{\sqrt{n}}$
So I have something that relates the size of the sample (i.e. number of trials) with the standard deviation, but then I don't know how to proceed from here. How does the "8 digit precision" comes into play?
UPDATE
Ok I think I am close to understand it. From CLT we have $\displaystyle \sigma_{M} = \frac{\sigma}{\sqrt{N}}$ so in this case $\sigma = \sqrt{p(1-p)}$ therfore $\displaystyle \sigma_{M} = \frac{\sqrt{p(1-p)}}{\sqrt{N}}$
Then from the Bernoulli distribution, $\displaystyle \mu = p = \frac{\pi}{4}$ therefore
$$\sigma_{M}=\frac{\sqrt{\pi(4-\pi)}}{\sqrt{N}}$$ but what would be the value of $\sigma_{M}$? and then I have $\pi$ in the formula but is the thing I am trying to approximate so how does this work? and still missing the role of the 8 digit precision.

Basically, it is about the standard deviation of the Binomial distribution (a single independent experiment is called Bernoulli experiment, with a mean of p and the variance of p-p^2). For B(n,p), the variance is np(1-p), the standard deviation is  $$ \sqrt{p(1-p)/n} $$
In our case of Monte Carlo simulation, p = pi/4
Lastly, we need to time 4 to get pi. So $4*\sqrt{p*(1-p)/n}=1.642*\sqrt{1/n}<10^{-8}$, get n> 2.7e16
