|
v2DM-DOCI
1.0
|
#include <LocalMinimizer.h>
Collaboration diagram for simanneal::LocalMinimizer:Public Member Functions | |
| LocalMinimizer (const CheMPS2::Hamiltonian &) | |
| LocalMinimizer (CheMPS2::Hamiltonian &&) | |
| virtual | ~LocalMinimizer () |
| int | Minimize (bool dist_choice=false, int start_iters=0) |
| double | get_energy () const |
| double | calc_new_energy () |
| double | calc_new_energy (const CheMPS2::Hamiltonian &) |
| void | calc_energy () |
| simanneal::UnitaryMatrix & | get_Optimal_Unitary () |
| CheMPS2::Hamiltonian & | getHam () const |
| OrbitalTransform & | getOrbitalTf () const |
| doci2DM::Method & | getMethod () const |
| void | UseBoundaryPoint () |
| void | UsePotentialReduction () |
| doci2DM::PotentialReduction & | getMethod_PR () const |
| doci2DM::BoundaryPoint & | getMethod_BP () const |
| std::vector< std::tuple< int, int, double, double > > | scan_orbitals () |
| double | get_conv_crit () const |
| void | set_conv_crit (double) |
| void | set_conv_steps (int) |
| int | choose_orbitalpair (std::vector< std::tuple< int, int, double, double >> &) |
| int | Minimize_noOpt (double stopcrit) |
| int | Minimize_hybrid () |
Private Attributes | |
| double | conv_crit |
| criteria for convergence of the minimizer More... | |
| double | energy |
| int | conv_steps |
| number of steps in convergence area More... | |
| std::unique_ptr< doci2DM::Method > | method |
| std::unique_ptr< CheMPS2::Hamiltonian > | ham |
| Holds the current hamiltonian. More... | |
| std::unique_ptr< simanneal::OrbitalTransform > | orbtrans |
| the actual orbital transform More... | |
| std::unique_ptr< simanneal::UnitaryMatrix > | opt_unitary |
| the current unitary More... | |
| std::mt19937 | mt |
| our pseudo-random generator More... | |
| std::vector< int > | allow_irreps |
| only rotation within these irreps (if not empty) More... | |
Definition at line 44 of file LocalMinimizer.h.
| simanneal::LocalMinimizer::LocalMinimizer | ( | const CheMPS2::Hamiltonian & | mol | ) |
| mol | the molecular data to use |
Definition at line 45 of file LocalMinimizer.cpp.
| simanneal::LocalMinimizer::LocalMinimizer | ( | CheMPS2::Hamiltonian && | mol | ) |
Definition at line 103 of file LocalMinimizer.cpp.
|
virtualdefault |
| void simanneal::LocalMinimizer::calc_energy | ( | ) |
Calculate the energy with the current molecular data
Definition at line 134 of file LocalMinimizer.cpp.
| double simanneal::LocalMinimizer::calc_new_energy | ( | ) |
Calculate the energy with the current molecular data
Definition at line 146 of file LocalMinimizer.cpp.
| double simanneal::LocalMinimizer::calc_new_energy | ( | const CheMPS2::Hamiltonian & | new_ham | ) |
Definition at line 156 of file LocalMinimizer.cpp.
| int simanneal::LocalMinimizer::choose_orbitalpair | ( | std::vector< std::tuple< int, int, double, double >> & | orbs | ) |
Choose a pair of orbitals to rotate over, according to the distribution of their relative energy change.
| orbs | the list returned by scan_orbitals() |
Definition at line 439 of file LocalMinimizer.cpp.
| double simanneal::LocalMinimizer::get_conv_crit | ( | ) | const |
Definition at line 418 of file LocalMinimizer.cpp.
| double simanneal::LocalMinimizer::get_energy | ( | ) | const |
Definition at line 125 of file LocalMinimizer.cpp.
| simanneal::UnitaryMatrix & simanneal::LocalMinimizer::get_Optimal_Unitary | ( | ) |
Definition at line 164 of file LocalMinimizer.cpp.
| CheMPS2::Hamiltonian & simanneal::LocalMinimizer::getHam | ( | ) | const |
Definition at line 169 of file LocalMinimizer.cpp.
| doci2DM::Method & simanneal::LocalMinimizer::getMethod | ( | ) | const |
Definition at line 179 of file LocalMinimizer.cpp.
| doci2DM::BoundaryPoint & simanneal::LocalMinimizer::getMethod_BP | ( | ) | const |
Return a reference to a BoundaryPoint object. Only works if the actual method is BoundaryPoint. You should always wrap this in a try/catch block and check for a std::bad_cast exception
Definition at line 203 of file LocalMinimizer.cpp.
| doci2DM::PotentialReduction & simanneal::LocalMinimizer::getMethod_PR | ( | ) | const |
Return a reference to a PotentialReduction object. Only works if the actual method is PotentialReduction. You should always wrap this in a try/catch block and check for a std::bad_cast exception
Definition at line 190 of file LocalMinimizer.cpp.
| simanneal::OrbitalTransform & simanneal::LocalMinimizer::getOrbitalTf | ( | ) | const |
Definition at line 174 of file LocalMinimizer.cpp.
| int simanneal::LocalMinimizer::Minimize | ( | bool | dist_choice = false, |
| int | start_iters = 0 |
||
| ) |
Do the local minimization
| dist_choice | if set to true, we use choose_orbitals to choose which pair of orbitals to use (instead of the lowest one) |
| start_iters | start number the iterations from this number (defaults to 0) |
Definition at line 275 of file LocalMinimizer.cpp.
Here is the call graph for this function:| int simanneal::LocalMinimizer::Minimize_hybrid | ( | ) |
Combine LocalMinimizer::Minimize and LocalMinimizer::Minimize_noOpt
Definition at line 544 of file LocalMinimizer.cpp.
| int simanneal::LocalMinimizer::Minimize_noOpt | ( | double | stopcrit | ) |
Definition at line 462 of file LocalMinimizer.cpp.
| std::vector< std::tuple< int, int, double, double > > simanneal::LocalMinimizer::scan_orbitals | ( | ) |
Definition at line 220 of file LocalMinimizer.cpp.
| void simanneal::LocalMinimizer::set_conv_crit | ( | double | crit | ) |
Definition at line 423 of file LocalMinimizer.cpp.
| void simanneal::LocalMinimizer::set_conv_steps | ( | int | steps | ) |
Definition at line 428 of file LocalMinimizer.cpp.
| void simanneal::LocalMinimizer::UseBoundaryPoint | ( | ) |
Definition at line 210 of file LocalMinimizer.cpp.
| void simanneal::LocalMinimizer::UsePotentialReduction | ( | ) |
Definition at line 215 of file LocalMinimizer.cpp.
|
private |
only rotation within these irreps (if not empty)
Definition at line 118 of file LocalMinimizer.h.
|
private |
criteria for convergence of the minimizer
Definition at line 96 of file LocalMinimizer.h.
|
private |
number of steps in convergence area
Definition at line 101 of file LocalMinimizer.h.
|
private |
Definition at line 98 of file LocalMinimizer.h.
|
private |
Holds the current hamiltonian.
Definition at line 106 of file LocalMinimizer.h.
|
private |
Definition at line 103 of file LocalMinimizer.h.
|
private |
our pseudo-random generator
Definition at line 115 of file LocalMinimizer.h.
|
private |
the current unitary
Definition at line 112 of file LocalMinimizer.h.
|
private |
the actual orbital transform
Definition at line 109 of file LocalMinimizer.h.