◆ apply_op_orthogonalise_fit() [1/2]

template<typename Iterator = State*>
std::tuple<State, SRDef> syten::MPS::apply_op_orthogonalise_fit ( State const &  in,
Operator const &  op,
Truncation const &  trunc,
SRDef  desired_change,
Index  max_exp_sweeps = 12,
Index  max_opt_sweeps = 2,
State  res = State(),
Iterator  first = nullptr,
Iterator  last = nullptr 

Applies the operator op to the state in while orthogonalising the result against states [first, last) and truncating with trunc.

inthe initial state \( |\psi \rangle \) as a MPS::State
opthe operator \( \hat O \)
trunca truncation specification
desired_changesweeps are considered converged if the total change during a sweep is below this.
max_exp_sweepsmaximal number of full (back&forth) expansion sweeps
max_opt_sweepsmaximal number of full (back&forth) optimisation sweeps
resinput guess state to use as initial state
firstiterator to the first element of the orthogonalised set \( \{ | v_i \rangle \}_{i=\mathtt{first}}^{\mathtt{last-1}} \)
lastiterator to the one-past-the-end element of the orthogonalised set \( \{ | v_i \rangle \}_{i=\mathtt{first}}^{\mathtt{last-1}} \)
\( \hat O | \psi \rangle \) orthogonalised against all \( \{ | v_i \rangle \}_i \) and an error estimate (NAN as the error is not calculated at the moment)
A subspace expansion method is employed during the initial sweeps to increase the bond dimensions of the state. In our experience, the sweeps converge very quickly if a large expansion blocksize is allowed, but the computational effort also skyrockets then. As a compromise, the maximal blocksize is increased in increments of five during each sweep which should allow for an appropriate increase in the bond dimension while not handicapping the method in situations where the bond dimension hardly grows.
The parameters first and last are optional and can be left off. No orthogonalisation will occur in this case.

References syten::abs(), syten::Timer::add(), std::vector< T >::back(), syten::Tensor< rank >::begin(), syten::conj(), std::distance(), distance(), syten::Timer::end(), syten::Tensor< rank >::end(), expand_to_left(), expand_to_right(), syten::genFuse(), syten::genIONode(), syten::genSplit(), syten::MPS::State::leftnorm(), syten::MPS::State::lIdx, syten::MPS::Operator::lIdx, syten::MPS::State::lInt, syten::logGD(), syten::logTV(), std::make_tuple(), syten::Timer::middle(), std::move(), mps_mpo_ctr_ctr(), mps_mpo_mps_ctr_left(), mps_mpo_mps_ctr_right(), norm(), syten::orthogonalise_solve_svd(), std::vector< T >::pop_back(), std::vector< T >::push_back(), syten::MPS::State::rIdx, syten::MPS::Operator::rIdx, syten::MPS::State::rInt, syten::MPS::State::size(), syten::Timer::start(), syten::to_string_rd(), syten::MPS::State::uIdx, syten::MPS::State::uInt, and syten::underThreshold().

Referenced by apply_op_itrunc_fit(), syten::MPS::SwappableTEBD::exponentiate_and_multiply(), and syten::Pyten::init_mps().

+ Here is the call graph for this function:
+ Here is the caller graph for this function: