Variational Monte Carlo
Variational Monte Carlo (VMC) evaluates a trial wavefunction’s energy by sampling its squared modulus. It replaces a high-dimensional integral by local wavefunction ratios or derivatives. The variational upper bound applies to the exact expectation for the trial state; a finite noisy estimate can fall below the ground energy by chance.
Required background. Monte Carlo estimation and MCMC supply sampling controls. The variational principle supplies the energy bound; Rayleigh–Ritz explains its finite-basis implementation.
The local energy estimator
Section titled “The local energy estimator”For a normalizable trial state in the Hamiltonian’s domain, define
Then . Nodes have zero sampling probability but can produce large nearby local-energy fluctuations; smoothness, cusp conditions, and finite estimator variance must be checked.
For a discrete basis,
A sparse local Hamiltonian can make this sum inexpensive even when the Hilbert space is large. Evaluate logarithmic amplitudes and phases when direct wavefunction values underflow. Test the Hamiltonian row convention: complex conjugating the wrong index can give a plausible but incorrect real energy.
The oscillator Gaussian calculation
Section titled “The oscillator Gaussian calculation”Use and with . Differentiation gives
Since and ,
At , every local-energy sample equals : the exact eigenstate has zero local-energy variance. At , the mean is and the variance is . These exact values test the sampler, derivatives, and uncertainty estimate independently.
Zero full energy variance identifies an eigenstate, though not necessarily the lowest one. The sampled local-energy variance equals that full variance only if the sampling support captures the residual, as the discrete example below shows.
Energy gradients and optimization bias
Section titled “Energy gradients and optimization bias”For real parameters, let on the sampling support. When differentiating the expectation is justified and no contribution from outside that support is omitted, a useful gradient estimator is
It follows by differentiating the normalized expectation and using Hermiticity. Subtracting the mean energy acts as a covariance baseline. A stochastic-reconfiguration update additionally uses the covariance matrix of logarithmic derivatives as a metric, with regularization for nearly redundant directions.
The optimization sample is not a clean validation set. Repeatedly selecting the lowest noisy estimate introduces selection bias. After fixing the parameters, run independent production chains and report their energy and variance. When reusing samples across nearby parameters, monitor reweighting overlap.
Exact zeros in a discrete trial state
Section titled “Exact zeros in a discrete trial state”Sampling cannot visit configurations where vanishes exactly. In a finite orthonormal basis, let be normalized and . Splitting the squared residual into its components gives
The first term is the sampled variance, with the modulus appropriate for complex local energies. The second is absent from every sample. This is the sampling version of the distinction between a projected and full residual.
For a concrete check, take real , real , and a real dimensionless parameter :
At , only configuration zero is sampled, and its local energy is zero. Every local-energy sample therefore has zero variance, although and the full energy variance is . The energy mean itself remains correct: .
The same zero also defeats the support-only gradient estimator. Its covariance vanishes, but direct differentiation gives . The missing contribution comes from : changing the parameter opens an unsampled configuration. This support issue in variational forces is analyzed by Sinibaldi et al. (2023). Full support, or parameter derivatives that vanish outside a fixed support, avoids this particular missing-gradient term; other variance and convergence conditions still apply.
A symmetry-restricted support is legitimate when it is invariant under and the intended variations stay within it. Otherwise, test exact sums on a small system and use a sampling distribution and estimator that include the missing contributions. More samples from the same restricted distribution cannot recover them. Isolated measure-zero nodes in continuous configuration space are different: one must examine integrability and the operator domain, rather than assign them the discrete sum above.
A convergence record for a trial family
Section titled “A convergence record for a trial family”Separate sampling uncertainty, optimizer convergence, and ansatz limitation. Increase production length at fixed parameters; then vary optimization tolerances and starts; then enlarge the wavefunction family. A tiny standard error only addresses the first limit.
Complex states require phase-consistent ratios. Singular potentials require physically appropriate local behavior. Sampling only one disconnected nodal pocket can bias observables unless symmetry and weights justify the restriction.
Exercises
Section titled “Exercises”Minimize the Gaussian energy analytically and evaluate its curvature at the optimum.
Solution
vanishes at , and . For , . Energy errors are quadratic near the optimum, so a very accurate energy can coexist with visibly imperfect wavefunction parameters.
For the two-state example with , find both local energies. As , explain why zero sampled variance at does not follow by taking the limit of the full-support variance. How many independent draws are needed to have a reasonable chance of visiting configuration one?
Solution
The local energies are and , with . For every nonzero , both states are sampled and the local-energy variance equals the full energy variance. Its limit is : the rare state’s probability tends to zero while its squared local energy diverges. At exactly zero that state is excluded, so the sampled variance instead vanishes. The probability of no visits in independent draws is ; obtaining an order-one chance of a visit requires of order . Reliable error estimation generally needs many such visits, and Markov correlations can increase the cost.
References
Section titled “References”- Foulkes, W. M. C., Lubos Mitas, R. J. Needs, and G. Rajagopal, “Quantum Monte Carlo simulations of solids,” Reviews of Modern Physics 73, 33–83 (2001), doi:10.1103/RevModPhys.73.33 — variational and diffusion Monte Carlo with error analysis.
- Sinibaldi, Alessandro, Clemens Giuliani, Giuseppe Carleo, and Filippo Vicentini, “Unbiasing time-dependent Variational Monte Carlo by projected quantum evolution,” Quantum 7, 1131 (2023), doi:10.22331/q-2023-10-10-1131, arXiv:2305.14294 — support-dependent bias in stochastic variational forces, especially Section 2, equations (8)–(9).