2.5 Quantum Monte Carlo methods for electrons
2.5.4 Path sampling: the bounce algorithm
To sample the paths in the PIMC method we adopted the bisection construction, that allows to efficiently reconstruct portions of the single particle paths among two fixed extremes. Conventionally this construction is not used in the RQMC, in part for historical reasons, since the PIMC and the RQMC methods have been developed independently. Moreover in the RQMC scheme we are dealing with open paths, then the “reptile” motion we will describe in this section is in some sense more natural to apply. Finally, in the CEIMC scheme it is more efficient to move all electrons at
once10 and in this case a reptation algorithm allows to keep a good acceptance rate of moves compared to a global bisection algorithm.
Let P be a sequence of M +1 points in the electronic configuration space, i.e. a set of 3N (M + 1) coordinates representing a path of total lenght M τ : P = {r0, · · · , rM}.
The probability distribution of the paths π(P) can be obtained from the expression (2.131) of the generating function, using the form (2.139) for the matrix elements ρ(r, r0; t) π(P) = |ψT(r0)ψT(rM)| e− PM i=1L(ri,ri−1;τ )e−τ h PM −1 i=1 EL(ri)+EL(r0)+EL(rM )2 i (2.150) with L given by (2.140).
In the original RQMC implementation the path sampling is performed as follows. Starting from a given many body path a new path can be obtained by adding a segment of time length τ to one of the two ends of the original path and, consequently, by deleting the opposite end of the path in order to keep constant the number of beads in the chain. First of all it is then necessary to decide which one of the two ends will be the growing end and this is done by choosing at random between the two, with probability 1/2: let us indicate with rh the growing end and with rt the
opposite extreme of the path. Then, a new point of the path is sampled from a gaussian distribution centered at a distance 2λτ F (rh) from rh, which comes from
the term e−PMi=1L(ri,ri−1;τ ) in (2.150). Let us also introduce a variable d representing
the growth direction. Since there exist only two possible growth directions, d can assume only two values: by convention, let us choose d = +1 when rh = rM and
d = −1 when rh= r0. The proposed configuration is accepted or rejected according
to a standard Metropolis rule
αd(P → P0) = min 1,π(P 0)t −d(P0 → P) π(P)td(P → P0) (2.151) where the acceptance probability αd and the transition probability td both depends
on the growth direction, while the path probability π(P) is independent of d. The resulting evolution of the path is something similar to a snake motion, and for that reason the algorithm is called reptation; chosen the motion direction, the ends of the path, rh and rt, are also called the head and the tail of the reptile,
respectively. After the acceptance step, the procedure is repeated, starting by the sampling of the moving end.
Proceeding as described however, the electronic configurational space may be sampled inefficiently. This algorithm is in fact characterized by a large autocorrelation time - defined as the number of MC steps required to obtain two uncorrelated configurations - which scales as the square of the beads number M divided by the acceptance rate11. Moreover persistent configurations may occasionally appear: since
10
The reason of this choice is related to the form of the trial wave function, used to represent the electronic state, which contains a Slater determinant of single particle orbitals. Inside the determinants the electronic coordinates are not mutually independent, due to the application of a coordinate transformation, the backflow transformation, used to improve the wave function. As a consequence, also in the case of a single electronic move an entire determinant must be recomputed: since this operation has a computational cost that scales with the cube of the number of particles, it is preferable to adopt global electronic moves.
11
Intuitively, we can estimate the autocorrelation time of the reptation algorithm by noticing that, if the motion direction would always remain unchanged and all the moves were accepted, a
the moving direction of the polymer can change frequently, the polymer can simply oscillate back and forth without really explore the space. In CEIMC, in which the electronic ground state calculation must be repeated at each protonic move, these features make the standard reptation algorithm undesirable.
The reptation algorithm can be improved using a slightly different approach. Instead of sampling at random the head of the reptile each time we perform a move, the motion direction d is chosen only at the beginning of the simulation and retained until the move is rejected. After any rejection the motion direction of the reptile is inverted. This algorithm to sample the path configurational space is known as bounce algorithm [91]. Although this scheme does not satisfy the detailed balance, it is possible to prove that it samples the right limiting distribution. To demonstrate that, following [91], let us add to the 3N (M + 1) dimensional path space the additional variable d, representing the direction of motion of the path, which can assume only two values, +1 and −1. We can also define in this extended space the path transition probability A(r, d → r0, d0) = αd(r → r0)td(r0 → r). Since the algorithm represents
a Markov process in the extended space, under the assumptions of ergodicity and irreducibility, it admits a unique stationary distribution Π(P, d) that satisfies
Π(P0, d0) =X
P
X
d
Π(P, d)A(P, d → P0, d0) (2.152) We need to show that, with the transition probability of the bounce algorithm, our path distribution π(P) independent of the coordinate d is a solution of this equation. Let us first notice that in the bounce algorithm if the move is discarded the moving direction is inverted and hence A(P0, d0 → P0, d0) = 0 and A(P0, d0 → P0, −d0) = 1. On the other hand, if the move is accepted, the growth direction remain unchanged and hence A(P0, d0→ P, −d0) = 0 for any P0 6= P. With these observations we are
able to eliminate the sum over d in the previous equation, that becomes Π(P0, d0) = Π(P0, −d0)A(P0, −d0 → P0, d0)+ X
P6=P0
Π(P, d0)A(P, d0 → P0, d0) (2.153) By substituting our distribution π(P), independent of the direction d, to the generic probability distribution in the extended space Π(P, d) the (2.153) can be rewritten as π(P0) = π(P0)A(P0, −d0 → P0, d0) + X P6=P0 π(P)A(P, d0 → P0, d0) = π(P0) " A(P0, −d0 → P0, d0) +X P A(P0, −d0→ P, −d0) # (2.154) where in the last line we used the detailed balance condition π(P)A(P, d0 → P0, d0) = π(P0)A(P0, −d0 → P, −d0). The transition probabilities are normalized, hence terms
in square bracket sum to 1: this proves that equation (2.152) is identically satisfied by the path distribution π(P0) for each P0, and, as a consequence, that the bounce algorithm samples correctly the paths.
completely new polymer, of zero overlap with the original, is sampled after a number of steps equal to the lenght M of the polymer. Due to the rejections the correlation time is increased of a factor equal to the acceptance rate Ntot/Nacc. The sampling of the growth direction after each move gives