Uni20
Asynchronous tensor and runtime library.
Loading...
Searching...
No Matches
Classes | Namespaces | Typedefs | Enumerations | Functions
two_site_dmrg.hpp File Reference

Performs directional finite-chain two-site DMRG updates. More...

#include <uni20/async/debug_scheduler.hpp>
#include <uni20/common/performance_measurements.hpp>
#include <uni20/core/math.hpp>
#include <uni20/core/numeric_limits.hpp>
#include <uni20/core/scalar_concepts.hpp>
#include <uni20/krylov/block_tensor_vector.hpp>
#include <uni20/symmetry/block_tensor_contract.hpp>
#include <uni20/tensor_network/dmrg_lanczos.hpp>
#include <uni20/tensor_network/environment_cache.hpp>
#include <uni20/tensor_network/two_site_effective_hamiltonian.hpp>
#include <uni20/tensor_network/two_site_split.hpp>
#include <algorithm>
#include <cmath>
#include <concepts>
#include <cstddef>
#include <functional>
#include <optional>
#include <stdexcept>
#include <string_view>
#include <type_traits>
#include <utility>
#include <vector>
Include dependency graph for two_site_dmrg.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  uni20::tensor_network::TwoSiteDmrgOptions< Real >
 Numerical policies for one finite-chain two-site DMRG update. More...
 
struct  uni20::tensor_network::TwoSiteDmrgRunOptions< Real >
 Policies for an alternating finite-chain two-site DMRG run. More...
 
struct  uni20::tensor_network::TwoSiteDmrgRunResult< Real >
 Result of an alternating finite-chain two-site DMRG run. More...
 
struct  uni20::tensor_network::TwoSiteDmrgStepResult< Real, InstalledBond >
 Diagnostics and selected bond data from one DMRG bond update. More...
 
struct  uni20::tensor_network::TwoSiteDmrgSweepSummary< Real >
 Aggregate diagnostics for one completed directional DMRG sweep. More...
 

Namespaces

namespace  uni20
 
namespace  uni20::tensor_network
 

Typedefs

using uni20::tensor_network::DetailedTwoSiteDmrgPerformanceMeasurements = performance::DetailedMeasurements< TwoSiteDmrgPerformanceEvent, static_cast< std::size_t >(TwoSiteDmrgPerformanceEvent::count)>
 Detailed DMRG measurements including per-sector block-SVD batch timings.
 
using uni20::tensor_network::TwoSiteDmrgPerformanceMeasurements = performance::DurationMeasurements< TwoSiteDmrgPerformanceEvent, static_cast< std::size_t >(TwoSiteDmrgPerformanceEvent::count)>
 Coarse inclusive wall-duration measurements for two-site DMRG phases.
 

Enumerations

enum class  uni20::tensor_network::TwoSiteDmrgPerformanceEvent {
  uni20::tensor_network::run , uni20::tensor_network::sweep , uni20::tensor_network::bond_update , uni20::tensor_network::center_construction ,
  uni20::tensor_network::local_eigensolver , uni20::tensor_network::effective_hamiltonian_application , uni20::tensor_network::krylov_vector_allocation , uni20::tensor_network::krylov_vector_update ,
  uni20::tensor_network::krylov_reduction , uni20::tensor_network::block_svd , uni20::tensor_network::svd_sector_batch , uni20::tensor_network::state_selection ,
  uni20::tensor_network::factor_materialization , uni20::tensor_network::environment_update , uni20::tensor_network::count
}
 Stable phase identifiers for two-site DMRG performance measurements. More...
 

Functions

template<class MpsChain , class MpoChain , SparseBlockStorage EnvironmentStorage, class Measurements , BlockTensorStorage CenterStorage = typename MpsChain::storage_policy>
requires detail::TwoSiteCenterStorageFor<CenterStorage, typename MpsChain::value_type> && performance::DurationMeasurementPolicy<Measurements, TwoSiteDmrgPerformanceEvent>
auto uni20::tensor_network::optimize_two_site_dmrg_bond (MpsChain &mps, MpoChain const &mpo, MpoEnvironmentCache< MpsChain, MpoChain, EnvironmentStorage > &cache, std::size_t first_site, MpsSweepDirection direction, TwoSiteDmrgOptions< make_real_t< typename MpsChain::value_type > > const &options, Measurements &measurements, CenterStorage center_storage={})
 Optimize and replace one adjacent MPS pair with a measured ground-state DMRG step.
 
template<class MpsChain , class MpoChain , SparseBlockStorage EnvironmentStorage, BlockTensorStorage CenterStorage = typename MpsChain::storage_policy>
requires detail::TwoSiteCenterStorageFor<CenterStorage, typename MpsChain::value_type>
auto uni20::tensor_network::optimize_two_site_dmrg_bond (MpsChain &mps, MpoChain const &mpo, MpoEnvironmentCache< MpsChain, MpoChain, EnvironmentStorage > &cache, std::size_t first_site, MpsSweepDirection direction, TwoSiteDmrgOptions< make_real_t< typename MpsChain::value_type > > const &options={}, CenterStorage center_storage={})
 Optimize and replace one adjacent MPS pair without performance measurements.
 
template<class MpsChain , class MpoChain , SparseBlockStorage EnvironmentStorage, class Measurements , BlockTensorStorage CenterStorage = typename MpsChain::storage_policy>
requires detail::TwoSiteCenterStorageFor<CenterStorage, typename MpsChain::value_type> && performance::DurationMeasurementPolicy<Measurements, TwoSiteDmrgPerformanceEvent>
auto uni20::tensor_network::run_two_site_dmrg (MpsChain &mps, MpoChain const &mpo, MpoEnvironmentCache< MpsChain, MpoChain, EnvironmentStorage > &cache, TwoSiteDmrgRunOptions< make_real_t< typename MpsChain::value_type > > const &options, Measurements &measurements, CenterStorage center_storage={})
 Run measured alternating directional sweeps until terminal-energy convergence.
 
template<class MpsChain , class MpoChain , SparseBlockStorage EnvironmentStorage, BlockTensorStorage CenterStorage = typename MpsChain::storage_policy>
requires detail::TwoSiteCenterStorageFor<CenterStorage, typename MpsChain::value_type>
auto uni20::tensor_network::run_two_site_dmrg (MpsChain &mps, MpoChain const &mpo, MpoEnvironmentCache< MpsChain, MpoChain, EnvironmentStorage > &cache, TwoSiteDmrgRunOptions< make_real_t< typename MpsChain::value_type > > const &options={}, CenterStorage center_storage={})
 Run alternating directional sweeps without performance measurements.
 
template<class MpsChain , class MpoChain , SparseBlockStorage EnvironmentStorage, class Measurements , BlockTensorStorage CenterStorage = typename MpsChain::storage_policy>
requires detail::TwoSiteCenterStorageFor<CenterStorage, typename MpsChain::value_type> && performance::DurationMeasurementPolicy<Measurements, TwoSiteDmrgPerformanceEvent>
auto uni20::tensor_network::sweep_two_site_dmrg (MpsChain &mps, MpoChain const &mpo, MpoEnvironmentCache< MpsChain, MpoChain, EnvironmentStorage > &cache, MpsSweepDirection direction, TwoSiteDmrgOptions< make_real_t< typename MpsChain::value_type > > const &options, Measurements &measurements, CenterStorage center_storage={})
 Traverse every adjacent bond once in one measured two-site DMRG direction.
 
template<class MpsChain , class MpoChain , SparseBlockStorage EnvironmentStorage, BlockTensorStorage CenterStorage = typename MpsChain::storage_policy>
requires detail::TwoSiteCenterStorageFor<CenterStorage, typename MpsChain::value_type>
auto uni20::tensor_network::sweep_two_site_dmrg (MpsChain &mps, MpoChain const &mpo, MpoEnvironmentCache< MpsChain, MpoChain, EnvironmentStorage > &cache, MpsSweepDirection direction, TwoSiteDmrgOptions< make_real_t< typename MpsChain::value_type > > const &options={}, CenterStorage center_storage={})
 Traverse every adjacent bond once without performance measurements.
 
constexpr auto uni20::tensor_network::two_site_dmrg_performance_event_name (TwoSiteDmrgPerformanceEvent event) noexcept -> std::string_view
 Return the stable display name of one DMRG performance event.
 

Detailed Description

Performs directional finite-chain two-site DMRG updates.