I would like to compute the expectation value $\langle O \rangle = \sum_x P(x) O(x)$ of some random variable over an extremely large sample space that I cannot simply exhaustively go through. Usually I would use Metropolis Monte Carlo for this, but for this particular example I already know the exact normalized probability $P(x)$ with which each sample $x$ occurs.
How can I leverage this? Does this simply mean I do not need to wait for equilibration of my Markov Chain? I feel like knowing the normalization should allow me to use a much more efficient algorithm/method here. Ideally I would like to directly generate samples $x_i$ according to the distribution of $P(x)$ and then compute $1/N \sum_{i=1}^N O(x_i)$ but I do not see an easy way of doing this, apart from MCMC which does not utilise the full information I have available.
Thank you!