Learn to Use ITensor

main / classes / sweeps

Sweeps

The Sweeps class makes it easy to specify the "accuracy parameters" used when doing DMRG calculations. After setting the number of sweeps in the constructor, you can set parameters such as the truncation error cutoff to use for each sweep by providing the cutoffs in a comma-separated list.

Synopsis

auto sweeps = Sweeps(5); //do 5 sweeps

//set max "m" or bond dimension for each sweep
sweeps.maxm() = 10,20,40,80,160;
//set truncation error cutoff for each sweep
sweeps.cutoff() = 1E-5,1E-8,1E-10;

//if fewer parameters are given than number of
//sweeps (as above) then the last value is used
//for all remaining sweeps.

Names and meaning of "accuracy parameters"

Constructors

Comma-separated list input methods

For the following methods, the returned type is a "SweepSetter" object which collects numbers in a comma-separated list, then provides these numbers to the associated Sweeps object.

If fewer values are provided than the number of sweeps, the last value will be used for all remaining sweeps.

Other methods


Back to Classes
Back to Main