Get the latest tech news
Monte Carlo Crash Course: Sampling
- Continuous Probability - Exponentially Better Integration - Sampling - Coming Soon… Sampling In the previous chapter, we assumed that we can uniformly randomly sample our domain. However, it’s not obvious how to actually do so—in fact, how can a deterministic computer even generate random numbers?1 - Pseudo-Random Numbers - Uniform Rejection Sampling - Non-Uniform Rejection Sampling - Inversion Sampling - Changes of Coordinates Pseudo-Random Numbers Fortunately, Monte Carlo methods don’t need truly random numbers.2 Instead, we can use a pseudo-random number generator (PRNG).
PRNGs give us uniformly random scalars, but we ultimately want to sample complex, high-dimensional domains. Like we saw with Monte Carlo integration, rejection sampling can be straightforwardly extended to work with non-uniform distributions. That’s because transforming from polar to rectangular coordinates didn’t preserve area—smaller radii contain less area, yet we weighted all $$r$$ equally.
Or read this on Hacker News