Mixer¶
full name: tenpy.algorithms.dmrg.Mixer
parent module:
tenpy.algorithms.dmrg
type: class
Inheritance Diagram

Methods
|
|
|
Perturb the wave function and perform an SVD with truncation. |
|
Update the amplitude, possibly disable the mixer. |
Class Attributes and Properties
how many sites the theta in perturb_svd should have |
- class tenpy.algorithms.dmrg.Mixer(options, sweep_activated)[source]¶
Bases:
object
Base class of a general Mixer.
Since DMRG performs only local updates of the state, it can get stuck in “local minima”, in particular if the Hamiltonian is long-range – which is the case if one maps a 2D system (“infinite cylinder”) to 1D – or if one wants to do single-site updates. The idea of the mixer is to perturb the state with the terms of the Hamiltonian which have contributions in both the “left” and “right” side of the system. In that way, it adds fluctuation of the quantum numbers and non-zero contributions of the long-range terms - leading to a significantly improved convergence of DMRG.
The strength of the perturbation is given by the amplitude of the mixer. A good strategy is to choose an initially significant amplitude and let it decay until the perturbation becomes completely irrelevant and the mixer gets disabled.
This original idea of the mixer was introduced in [white2005], implemented as
DensityMatrixMixer
. More recently, [hubig2015] discussed the mixer and provided an improved version based on an svd, which turns out to give the same results up to numerical errors; it’s implemented as theSubspaceExpansion
.- Parameters
Options
- config Mixer¶
option summary Initial strength of the mixer. (Should be sufficiently smaller than 1.)
To slowly turn off the mixer, we divide `amplitude` by `decay` [...]
We disable the mixer completely after this number of sweeps.
- option amplitude: float¶
Initial strength of the mixer. (Should be sufficiently smaller than 1.)
- option decay: float¶
To slowly turn off the mixer, we divide amplitude by decay after each sweep. (Should be >= 1.)
- option disable_after: int¶
We disable the mixer completely after this number of sweeps.
- amplitude¶
Current amplitude for mixing. Singular values are perturbed on that order of magnitude.
- Type
- disable_after¶
The number of sweeps after which the mixer should be disabled, relative to disable_after. Note that DMRG might repeatedly activate the mixer if you gradually increase chi with a :cfg:configoption`DMRGEngine.chi_list`.
- Type
- update_sites = 2¶
how many sites the theta in perturb_svd should have
- perturb_svd(engine, theta, i0, update_LP, update_RP)[source]¶
Perturb the wave function and perform an SVD with truncation.
The call structure is slightly different depending on
update_sites
; seeSubspaceExpansion.perturb_svd()
andDensityMatrixMixer.perturb_svd()
.