I'm a chemistry guy and in a program I wrote, I use a Metropolis acceptance criterion in order to determine whether my algorithm is allowed to go to a different part x' of the problem.
This is done like this: 1. Generate x'. 2. With probability min(1,P(x')/P(x)), the algorithm goes to x' and keeps on working begining from x', else it stays at x and keeps on working from x.
(Definition: P(x):= exp(-b*x), b and x are real numbers)
Neglecting inaccuracies in the description of the Mtropolis algorithm here, please assume that this will generate x which are distributed like P(X). IMPORTANT: It is not important for my algorithm, that the correct P(X) is generated, the Metropolis algorithm is only used to guide my algorithm through problem space.
Now by playing around I have seen that my algorithm is much more efficient in the follwing way: 1. Generate x'. 2. With probability min(1,P(x')/P(x)), the algorithm goes to x' and keeps on working begining from x'. If it is rejected, DON't keep on working at x, but go to step 1.
Although, for my issues, it is not important to know the distribution I am interested, whether it is possible to say, which distribution is generated. Maybe I can learn something from knowing the generated distribution.
To rephrase my problem: In order to generate real numbers in a set G that are distributed like P(x) do the following: 1) Generate x' 2) With probability min(1,P(x')/P(x)) go to x' and add x' to G , else add x to G. 3) Go to step 1).
However, I want to know: How are real number in a set G distributed, if one builds this set G as follows: 1) Generate x' 2) With probability min(1,P(x')/P(x)) go to x' and add x' to G, else go to step 1) . 3) Go to step 1).
Unfortunately I'm a chmistry guy, so I don't have the necessary background in statistics.
Thanks a lot.