# Why does the Wang-Landau algorithm converge?

This algorithm visits every energy state an equal amount of times, and with every visit is also multiplies the density of states by a certain factor f. So how does the density of states get bigger for more probable values? This part is key to understanding the algorithm but I just can't get the hang of it...

Visiting the energy states an equal number of times is the eventual aim of the method, not the starting point. To begin with, the algorithm doesn't visit the energy states with equal probability. It is the adjustment of the estimated density of states that pushes the simulation towards that goal. Initially we don't know what the actual density of states function is.

The acceptance criterion for moves is based on the ratio of the (current estimates of) the densities of states for the initial state's energy and the trial state's energy. Initially these estimates are all set equal to each other; if we did not adjust them, the system would simply spend all its time in the energies with the highest (actual) density of states. Multiplying the current estimate, at the current energy, by a factor $$f$$ greater than 1 is the way of making the simulation less likely to visit that energy in the future. The final result is uniform sampling of energies, produced by (usually) a very strongly varying density of states, proportional to the exponential of the entropy $$S(E)/k_B$$ (in Boltzmann units).

It has been described (in a cartoonish way) as clambering around a rough terrain, in which it is difficult to climb out of the holes, but dropping a rock everywhere you go. At the start, most of the time is spent near the bottoms of the holes. Eventually you end up filling up the holes with rocks, and making the terrain more level.

There is a completely different question about the convergence of Wang-Landau, which is how rapidly you reduce the multiplying factor $$f$$ towards unity. This is a little more subtle. I think it's generally understood that the original proposal (simulating until a predetermined measure of flatness of the "visits" histogram has been achieved, then starting again with a fresh histogram, the multiplying factor $$f$$ being reduced by, say, $$f\rightarrow\sqrt{f}$$, so as to continue refining the weights) is too aggressive and does not in general converge. This is called a "saturation error". But I don't think that's the question you are asking.