Full Doxygen Index¶
-
class
AbstractNode¶ This is an abstract node in the tree of a TTBasis.
Public Functions
-
AbstractNode()¶
-
virtual
~AbstractNode()¶
-
virtual size_t
nTotalNodes() const = 0¶
-
virtual size_t
nNodes() const = 0¶
-
virtual size_t
nLeaves() const = 0¶
-
virtual AbstractNode *
nextNode() = 0¶
-
virtual AbstractNode *
nextSCFNode(AbstractNode *in) = 0¶
-
virtual AbstractNode *
nextNodeManthe() = 0¶
-
virtual void
info(ostream &os) const = 0¶
-
virtual void
write(ostream &os) const = 0¶
-
virtual int
type() const = 0¶
-
virtual void
setParent(AbstractNode *Up) = 0¶
-
virtual void
update(const NodePosition &p) = 0¶
-
-
class
ActiveCounter: public NodeAttribute<vector<size_t>>¶ - #include <ActiveCounter.h>
Counts how many nodes are active per summand in a SOP.
Public Functions
-
ActiveCounter()¶
-
~ActiveCounter()¶
-
void
initialize(SparseMatrixTreescd &hmats, SparseMatrixTreescd &hcons, const SOPcd &S, const Tree &tree)¶
-
-
class
BlockTree¶ Public Functions
-
BlockTree()¶
-
~BlockTree()¶
-
void
initialize(const Tree &tree, const Range &range, const vector<Labels> &leaf_labels, size_t max_dim)¶
-
BlockTensor
bottomBlockTensor(const Labels &labels)¶
-
size_t
nNeighbors(const Node &node, int hole)¶ 1: 01, 10, | 00 00 | 01, 10 2: 11 | 00 (2+0) 00 | 11 (0+2) 01, 10 | 01, 10 (1+1)
-
BlockTensor
randomBlockTensor(const Node &node, int hole, const Range &range, const Tree &tree)¶
-
-
template<class
Q, classT, typenameU>
classBS_integrator¶ - #include <BS_integrator.h>
This is a Bulirsch-Stoer Integrator.
The design of this class is loosely related to the implementation of a numerical recipes book.
-
class
CDVR¶ Public Functions
-
~CDVR()¶
-
void
Update(const Wavefunction &Psi, const PotentialOperator &V, const Tree &tree, size_t part = 0, bool out = false, ostream &os = cout)¶
-
Tensorcd
apply(Tensorcd Phi, const SpectralDecompositioncd &rho_x, const Node &node) const¶
-
Tensorcd
applySym(Tensorcd Phi, const SpectralDecompositioncd &rho_x, const Node &node) const¶
-
void
update(SymTensorTree &Psi, const PotentialOperator &V, const Tree &tree, size_t part = 0, bool out = false, ostream &os = std::cout)¶
Private Members
-
TensorTreecd
Vnode_¶
-
MatrixTreed
Vedge_¶
-
DeltaVTree
deltaV_¶
-
TensorTreecd
Cdown_¶
-
TensorTreecd
Cup_¶
-
WorkMemorycd
mem_¶
-
-
class
CMFIntegrator¶ - #include <CMFIntegrator.h>
The constant mean-field integrator for solving the mctdh-EOM.
In the CMF-Integrator the mctdh-Matrices are assumed to be constant for a given time to propagate a Wavefunction.
Public Functions
-
CMFIntegrator(const Hamiltonian &H, const Tree &tree, const Tree &cdvrtree, complex<double> phase)¶
-
CMFIntegrator(const Hamiltonian &H, const Tree &tree, complex<double> phase)¶
-
~CMFIntegrator()¶
-
void
Integrate(IntegratorVariables &ivars, ostream &os = cout)¶
-
double
Error(const Wavefunction &Psi, const Wavefunction &Chi, const MatrixTreecd &rho, const Tree &tree) const¶
-
void
Output(double time, const Wavefunction &Psi, const Wavefunction &Psistart, const Hamiltonian &H, const Tree &tree, ostream &os)¶
Private Functions
-
void
CMFstep(Wavefunction &Psi, double time, double timeend, double accuracy_leaf, const Tree &tree)¶
Private Members
-
ofstream
cdvr_file_¶
-
size_t
cdvr_nr_¶
-
HamiltonianRepresentation
matrices_¶
-
vector<bs_integrator>
bs_integrators_¶
-
vector<double>
dt_bs_¶
-
vector<LayerInterface>
interfaces_¶
-
double
tconst_¶
-
double
max_increase_¶
-
-
template<typename
T= size_t>
classConfiguration: public vector<T>¶ Public Types
-
template<>
usingBase= vector<T>¶
-
template<>
-
template<typename
T= size_t>
classConfigurationTensor: public vector<Configuration<T>>¶ Public Types
-
template<>
usingBase= vector<Configuration<T>>¶
Public Functions
-
ConfigurationTensor()¶
-
~ConfigurationTensor()¶
-
ConfigurationTensor(size_t len)¶
-
ConfigurationTensor(const initializer_list<Configuration<T>> &list)¶
-
ConfigurationTensor(const initializer_list<initializer_list<T>> &list)¶
-
bool
operator==(const ConfigurationTensor &r) const¶
-
ConfigurationTensor
operator+(const ConfigurationTensor &r) const¶
-
ConfigurationTensor
operator*(const ConfigurationTensor &r) const¶
-
template<>
-
template<typename
T= size_t>
classConfigurationTree¶ -
Public Members
-
NodeAttribute<ConfigurationTensor<T>>
up_¶
-
NodeAttribute<ConfigurationTensor<T>>
down_¶
-
NodeAttribute<Configuration<T>>
idx_up_¶
-
NodeAttribute<Configuration<T>>
idx_down_¶
-
NodeAttribute<ConfigurationTensor<T>>
-
class
CoordinateTransformation¶
-
class
DeltaMemory¶
-
class
DeltaOperator¶ Public Functions
-
DeltaOperator(const Tensorcd &Phi, const vector<SparseMatrixTreecd> &Hmats, const vector<SparseMatrixTreecd> &Holes, const SOPcd &sop, const Node &node)¶
-
~DeltaOperator()¶
-
size_t
dim1() const¶
-
size_t
dim2() const¶
-
-
class
DeltaVTree: public NodeAttribute<Tensorcd>¶
-
class
DVRBasis: public LeafInterface¶ Subclassed by HO_Basis, LegendrePolynomials
-
class
Edge¶
-
class
EntropyTree: public NodeAttribute<double>¶ Public Functions
-
EntropyTree()¶
-
~EntropyTree()¶
-
void
calculate(const TensorTreecd &Psi, const Tree &tree)¶
-
void
perplexity(const TensorTreecd &Psi, const Tree &tree, size_t power = 1)¶
-
-
class
FFT¶
-
class
FFTCooleyTukey¶
-
class
FFTGrid: public LeafInterface¶
-
struct
Fidelity¶ - #include <TreeApplyOperator.h>
The mlmcApply namespace contains functions that can be used to apply operators on a wavefunction.
The namespace provides a method for applying SOPcd operators on wavefunctions that scales quadratically with respect to the number of summands. Furthermore, some functions are used by other classes that allow to apply SOPcd operators on wavefunctions.
The present scheme for applying operators is described in Ref. [1]
[1] R. Ellerbrock, T. J. Martínez, to be submitted (2019)
Public Functions
-
void
append(double f)¶ simple tracker for fidelity
-
void
calculate(const TensorTreecd &Psi, const TensorTreecd &Psilast, const SOPcd &u, const Tree &tree, WorkMemorycd *mem)¶
-
void
print(ostream &os = cout) const¶
-
void
write(const string &name = "fidelity.dat", const string &header = "")¶
-
void
-
class
FortranOperator: public LeafOperator<complex<double>>¶ Public Functions
-
FortranOperator()¶
-
~FortranOperator()¶
-
void
Initialize(int part_, int mode_, int dim_, FortranSystemH SystemH_)¶
-
void
apply(const LeafInterface &grid, Tensorcd &hAcoeff, const Tensorcd &Acoeff) const¶
-
-
class
FortranSOP: public SumOfProductsOperator<complex<double>>¶ Public Functions
-
FortranSOP()¶
-
~FortranSOP()¶
-
Wavefunction
ApplyFlux(const Wavefunction &Psi, const Tree &tree)¶
-
Wavefunction
ApplyDividingSurface(const Wavefunction &Psi, const Tree &tree)¶
-
-
class
Hamiltonian: public SumOfProductsOperator<complex<double>>¶
-
class
HamiltonianRepresentation¶ Public Functions
-
HamiltonianRepresentation(const Hamiltonian &H, const Tree &tree, const Tree &cdvrtree, bool tail = true)¶
-
HamiltonianRepresentation(const Hamiltonian &H, const Tree &tree)¶
-
void
initializeDense(const Hamiltonian &H, const Tree &tree)¶
-
~HamiltonianRepresentation()¶
-
void
build(const Hamiltonian &H, const Wavefunction &Psi, const Tree &tree, double time)¶
-
void
buildUp(const Hamiltonian &H, const Wavefunction &Psi, const Node &node, double time)¶
-
void
buildDown(const Hamiltonian &H, const Wavefunction &Psi, const Node &node, double time)¶
-
void
buildSCF(const Hamiltonian &H, const Wavefunction &Psi, const Tree &tree, double time)¶
-
void
buildSCF(const Hamiltonian &H, const Wavefunction &Psi, const Node &node, const Node &next, double time)¶
-
void
buildUpCorrection(const Hamiltonian &H, const Wavefunction &Psi, const Node &node)¶
-
void
buildDownCorrection(const Hamiltonian &H, const Wavefunction &Psi, const Node &node)¶
-
void
buildCorrection(const Hamiltonian &H, const Wavefunction &Psi, const Tree &tree)¶
Public Members
-
int
counter_= 0¶
-
MatrixTreecd
rho_¶
-
SpectralDecompositionTreecd
rho_decomposition_¶
-
MatrixTreecd
rho_inverse_¶
-
SparseMatrixTreescd
hMats_¶
-
SparseMatrixTreescd
hContractions_¶
-
bool
corrections_¶
-
SparseMatrixTreecd
hCorr_¶ decides whether corrections are turned on or off
-
SparseMatrixTreecd
hConCorr_¶ correction term for hMats
-
ActiveCounter
nActives_¶ correction term for hCon
-
WorkMemorycd
mem_¶
-
-
class
IntegratorInterface¶ Public Functions
-
IntegratorInterface(const Hamiltonian &H, const Tree &tree, complex<double> phase = 1.)¶
-
~IntegratorInterface()¶
-
Wavefunction
Derivative(double t, const Wavefunction &Psi)¶
-
-
struct
IntegratorVariables¶ Public Functions
-
IntegratorVariables(double time_now_, double time_end_, double dt_, double out_, double accuracy_root_, double accuracy_leaf_, Wavefunction &Psi_, const Hamiltonian &h_, const Tree &tree_, const Tree &cdvrtree_, string ofname_, string ifname_, bool append, bool cmf_bottom = true, bool cmf_upper = true, bool cmf_top = true)¶
-
-
struct
KrylovSpace¶ Public Functions
-
KrylovSpace(const TensorShape &shape, size_t size)¶
-
KrylovSpace(vector<Tensorcd> space, SpectralDecompositioncd spectrum)¶
-
-
class
LabelDimensionTree¶ Public Functions
-
LabelDimensionTree()¶
-
~LabelDimensionTree()¶
-
LabelDimension
createDimension(const NodeAttribute<Labels> &labels, size_t nbox, size_t max_dim, const Node &node)¶
-
-
class
LabelTree¶
-
template<class
A, typenamek>
classLanzcos¶
-
class
LayerInterface¶ Public Functions
-
LayerInterface(const Hamiltonian &H, const HamiltonianRepresentation &hRep, const Node &node, complex<double> propagation_phase)¶
-
~LayerInterface()¶
Public Members
-
complex<double>
propagation_phase_¶
-
-
class
Leaf¶ - #include <Leaf.h>
This class represents the leaf in the tree of a TTBasis.
The leafs represent the lowest layer (even below the bottomlayer) in a tree of a TTBasis. Leaves contain abstract class pointers to PrimitiveBasis which provides the interface to the problem under consideration.
-
template<typename
T>
classLeafFunction¶ - #include <LeafFunction.h>
This class allows to use functions as LeafOperators.
-
template<typename
T>
classLeafMatrix¶ - #include <LeafMatrix.h>
This class allows to create LeafOperators from (factor) Matrices.
-
template<typename
T>
classLeafOperator¶ - #include <LeafOperator.h>
This class represents a single particle operator acting on a single leaf.
Subclassed by FortranOperator
-
class
LinearizedLeaves¶ - #include <LinearizedLeaves.h>
The class holds a vector of references to the leaves in the TTBasis.
-
template<typename
T>
classMatrix This class represents a Matrix.
This is a simple Matrix-class. The functions that are implemented are specially suited for QuantumDynamics simulations.
Usage:
Matrixcd M(dim1, dim2); Matrixcd A(M); A = M * (A + M);
Bracket Operators
Group of functions for accessing Matrix elements
-
T &
operator()(const size_t i, const size_t j) const¶ Two-indexed accessor.
- Return
Value
- Parameters
i: Rowj: Column
-
T &
operator()(const size_t i, const size_t j)¶ Two-indexed accessor.
- Return
Value
- Parameters
i: Rowj: Column
-
T &
operator[](const size_t idx) const¶ Compound-index accessor.
- Return
Value
- Parameters
idx: Compound index
-
T &
operator[](const size_t idx)¶ Compound-index accessor.
- Return
Value
- Parameters
idx: Compound index
Arithmetic Operators
Group of functions and operator overloadings for performing arithmetic operations on Matrices
-
Matrix<T> &
operator+=(const Matrix<T> &B)¶ In-place elementwise matrix addition.
-
Matrix<T> &
operator-=(const Matrix<T> &B)¶ In-place elementwise matrix subtraction.
-
Matrix<T> &
operator*=(T coeff)¶ In-place elementwise scalar matrix multiplication.
- Return
Scaled Matrix
- Parameters
coeff: Scalar
-
Matrix<T> &
operator/=(T coeff)¶ In-place elementwise scalar matrix division.
- Return
Scaled Matrix
- Parameters
coeff: Scalar
-
bool
operator==(const Matrix<T> &A) const¶ Matrix equality.
- Return
True if precisely equal, False otherwise
- Parameters
A: Test Matrix
-
bool
operator!=(const Matrix<T> &A) const¶ Matrix inequality.
- Return
True if not precisely equal, False otherwise
- Parameters
A: Test Matrix
-
template<typename
U>
Matrixoperator*(const U sca, const Matrix &B)¶ Scalar elementwise multiplication.
Math Operators
Group of functions for common Matrix mathematical operations
-
double
frobeniusNorm() const¶ - Return
Frobenius norm
-
T
trace() const¶ - Return
trace of matrix
-
Matrix<T>
adjoint() const¶ - Return
Adjoint of matrix
-
Matrix<T>
conjugate() const¶ - Return
conjugate of matrix
-
Matrix<T>
transpose() const¶ - Return
Transposed matrix
-
void
rDiag(Matrix<double> &Transformation, Vector<double> &ev) const¶ Diagonalization of a real Matrix.
Uses Eigen to diagonalize the Matrix. Phases eigenvectors s.t. first element is always positive.
-
SpectralDecompositiond
rDiag() const¶ Diagonalization of a real Matrix.
Exactly like
Matrix::rDiag(Matrixd&, Vectord&)but returns copies instead of pass by reference- Return
Eigenvectors/value as a pair of <Matrixd, Vectord>
-
void
cDiag(Matrix<complex<double>> &Transformation, Vector<double> &ev) const¶ Diagonalization of a complex Matrix.
Uses Eigen to diagonalize the Matrix. Phases eigenvectors s.t. first element is always positive.
-
SpectralDecompositioncd
cDiag() const¶ Diagonalization of a complex Matrix.
Exactly like
Matrix::cDiag(Matrixcd&, Vectord&)but returns copies instead of pass by reference- Return
Eigenvectors/value as a pair of <Matrixcd, Vectord>
I/O Operators
Group of functions for input and output
-
void
print(ostream &os = cout) const¶
-
void
write(const string &filename) const¶
-
void
write(ostream &os) const¶
-
void
read(const string &filename)¶
-
void
read(istream &os)¶
Public Functions
-
Matrix()¶ Zero constructor equivalent to Matrix(1,1);.
-
Matrix(size_t dim1, size_t dim2)¶ Zero constructor.
- Parameters
dim1: size of first dimensiondim2: size of second dimension
-
Matrix(size_t dim1, size_t dim2, T *ptr, bool ownership, bool InitZero)¶ Zero constructor.
- Parameters
dim1: size of first dimensiondim2: size of second dimensionptr: pointer to pre-allocated memoryownership: if true, matrix will take care of deallocationInitZero: if true, set entries to zero
-
Matrix(istream &is)¶ Constructor from input stream.
- Parameters
is: Input stream passed to read()
-
Matrix(const string &filename)¶ Constructor from file.
- Parameters
filename: File to load and pass to read()
-
Matrix<T> &
operator=(const Matrix &other)¶ Copy assignment constructor.
- Return
Copied matrix
- Parameters
other: Matrix to copy
-
Matrix<T> &
operator=(Matrix &&other)¶ Move assignment constructor.
-
~Matrix()¶ Destructor.
-
T &
-
class
MatrixTensorTree: public pair<TensorTreecd, MatrixTreecd>, public pair<Wavefunction, MatrixTreecd>¶ Public Functions
-
MatrixTensorTree()¶
-
MatrixTensorTree(const Wavefunction &Psi, const Tree &tree, bool orthogonal)¶
-
void
initialize(const Wavefunction &Psi, const Tree &tree, bool orthogonal)¶ All-normalized wavefunction representation with A’s and B_inv’s.
-
const TensorTreecd &
nodes() const¶
-
TensorTreecd &
nodes()¶
-
const MatrixTreecd &
edges() const¶
-
MatrixTreecd &
edges()¶
-
const TensorTreecd &
DensityWeighted() const¶
-
void
buildNodes(TensorTreecd Psi, const Tree &tree)¶
-
TensorTreecd
topDownNormalized(const Tree &tree) const¶
-
TensorTreecd
bottomUpNormalized(const Tree &tree) const¶
-
MatrixTensorTree()
-
MatrixTensorTree(const TensorTreecd &Psi, const Tree &tree, bool orthogonal)¶
-
void
initialize(TensorTreecd Psi, const Tree &tree)¶ All-normalized wavefunction representation with A’s and B_inv’s.
-
const TensorTreecd &
nodes() const
-
TensorTreecd &
nodes()
-
const MatrixTreecd &
edges() const
-
MatrixTreecd &
edges()
-
const TensorTreecd &
densityWeighted() const¶
-
void
buildNodes(const TensorTreecd &Psi, const Tree &tree)¶
-
void
buildEdges(const Tree &tree)
-
void
buildFromWeighted(const Tree &tree)
-
TensorTreecd
topDownNormalized(const Tree &tree) const
-
TensorTreecd
bottomUpNormalized(const Tree &tree) const
-
-
template<typename
T>
classMatrixTree¶
-
template<typename
T>
classMatrixTree
-
class
MultiIndex¶ Public Functions
-
MultiIndex(vector<size_t> &boundaries)¶
-
MultiIndex(size_t size, size_t length)¶
-
MultiIndex(const MultiIndex &multi)¶
-
void
Zero()¶
-
void
Max()¶
-
void
print() const¶
-
void
operator++(int a)¶
-
void
operator--(int a)¶
-
size_t
operator()(size_t a) const¶
-
size_t
operator[](size_t a) const¶
-
bool
Below() const¶
-
bool
After() const¶
-
MultiIndex
operator+(MultiIndex &multi)¶
-
void
Erase(size_t position)¶
-
void
Erase(size_t startPosition, size_t endPosition)¶
-
void
pop_back()¶
-
void
Replace(size_t position, size_t newBoundary)¶
-
size_t
Linearize()¶
-
size_t
FastLinearize()¶
-
size_t
Before(size_t a)¶
-
size_t
Active(size_t a)¶
-
size_t
After(size_t a)¶
-
size_t
DimTot() const¶
Protected Functions
-
void
calculateTotal()¶
-
-
template<typename
T>
classMultiLeafOperator¶ - #include <MultiLeafOperator.h>
A MultiLeafOperator (MLO) is a product of general single-particle operators.
A MultiLeafOperator is one summand in a SumofProducts operator. It can be applied to a TensorTree resulting in a wavefunction with a different bottomlayer-Tensors. The MLO is central for building hamiltonians.
Please note:
The recommended operator to build MLO is SPOf or SPOM (due to performance)
SPO initialization might be removed in the future
TensorTrees with different lower-node Tensors cannot (straightforwardly) be added without loss of information.
-
class
Node¶ - #include <Node.h>
This class manages a node in the tree-structured TTBasis representation.
The class holds the tensor-dimensions (TensorDim) at the current node and holds the connectivity to the parent & all child nodes (parent and child(s)). The node also knows wether it is a toplayer or bottomlayer-node. If the Node is a bottomlayer node, it holds a Leaf. Accessing Leaf or sublying Nodes (non-leaves) for incorrect nodes will stop the program. Please use the TTBasis iterator to swipe over all nodes in a TTBasis. The parent and child getters should only be used to access local connectivity.
-
template<class
A>
classNodeAttribute¶ - #include <NodeAttribute.h>
Base class for creating objects at every node in a tree.
For every node in a TTBasis, there is one corresponding Object of class A. Inherit from this class for fast prototyping. Make sure that attributes_ gets cleared and filled in a constructor. Automatically provides iterators and bracket operators for Node objects.
-
class
NodeContent¶
-
class
NodeOperator¶
-
class
NodePosition¶ - #include <NodePosition.h>
This class manages the position information in a tree, mainly for I/O purposes.
-
class
NodeSOP: public vector<NodeProductOperator>¶ Public Functions
-
NodeSOP()¶
-
~NodeSOP()¶
-
void
push_back(const NodeProductOperator &M, const complex<double> coeff)¶
-
complex<double>
Coeff(size_t part) const¶
Private Members
-
vector<complex<double>>
coeffs¶
-
-
class
Parameter¶ a leaf.
-
class
Potential¶
-
class
PotentialOperator¶ - #include <PotentialOperator.h>
This Operator tells if a potential operator is present.
This Operator marks a potential operator in a MultiLeafOperator.
This operator tells that a potential acts is present. It also manages the number of degrees of freedom used in the PES and the state_ used in the PES.
The class is only relevant when working with quadrature methods on tensor trees.
-
class
Range¶ - #include <U1Symmetry.h>
range of allowed labels, e.g. particle number <= 5 and >= 0
Public Functions
-
bool
isAllowed(size_t x) const¶
-
bool
-
template<class
Container, classModel, typenameU>
classRK_integrator¶ - #include <RungeKutta4.h>
This class performs a 4th order Runge-Kutta integration for a given Model, Container and Type.
- Template Parameters
Container: is a class holding all required memory to obtain the derivativesModel: is the object you want to integrate. E.g. a Tensor, a TensorTree, etc.U: is the underlying datatype, E.g. double, complex<double>, float, etc.
Public Functions
-
RK_integrator()¶
-
RK_integrator(size_t dim, const Model &empty)¶
-
~RK_integrator()¶
-
void
Integrate(Model &y, double &t, double tend, double &dt, double eps, function<void(Container&, double, Model&, const Model&)> ddx, function<double(Container&, Model&, Model&)> err, Container &I, )¶
-
void
step(U &t, Model &y, U dt, Container &I, function<void(Container&, double, Model&, const Model&)> ddx)¶ - Parameters
t: is current timey: is current Model (Tensor, TensorTree, …)dt: is stepsize in timeI: is the memory containerddx:container:
-
struct
SCF_parameters¶ Public Members
-
size_t
nIter= {20}¶
-
size_t
nKrylov= {5}¶ how many iterations
-
size_t
nITP= {0}¶ how large is the krylov space
-
double
beta= {1.}¶ how many steps of imaginary time propagation
-
size_t
output= {0}¶ how large should beta be?
-
double
conversion= {219474.6313705e0}¶ output wavefunction every iteration
-
TensorTreecd *
psi= {nullptr}¶
-
const Hamiltonian *
h= {nullptr}¶
-
size_t
-
class
SimultaneousDiagonalization¶ - #include <SimultaneousDiagonalization.h>
This class performs a simulatneous diagonalization.
Attempts to diagonalize a set of, potentially not commuting, matrices.
Protected Functions
-
template<typename
T>
classSOPMatrixTrees¶
-
template<typename
T>
classSOPVector¶ - #include <SOPVector.h>
Dressed up vector of SOPs.
-
template<typename
T>
classSparseMatrixTree: public SparseNodeAttribute<Matrix<T>>¶ Public Functions
Create HoleMatrixTree for a given tree-marker.
-
SparseMatrixTree(const MLO<T> &M, const Tree &tree, bool tail = true, bool inverse_tree = false)¶ Create HoleMatrixTree only for relevant nodes for a given Operator.
-
SparseMatrixTree(const vector<size_t> &targets, const Tree &tree, bool tail = true, bool inverse_tree = false)¶ Create HoleMatrixTree only for relevant nodes for a given Operator.
-
~SparseMatrixTree()¶
-
void
print(ostream &os = cout) const¶ I/O.
-
void
write(ostream &os) const¶
-
void
write(const string &filename) const¶
-
void
read(istream &is)¶
-
void
read(const string &filename)¶
-
template<typename
T>
classSparseTensorTree: public SparseNodeAttribute<Tensor<T>>¶ Public Functions
-
SparseTensorTree(const vector<size_t> &leaf_indices, const Tree &tree, bool tail = true, bool inverse_tree = false)¶ Create HoleMatrixTree only for relevant nodes for a given Operator.
-
~SparseTensorTree()¶
Private Members
-
T *
mem_¶
-
-
template<class
A>
classSparseTreeStructuredObject¶ - #include <SparseNodeAttribute.h>
This is a central base class for objects that are sparsely tree-structured.
This is a sparse version of the TreeStructuredObject. It provides a sparse handling for objects that are only present at some nodes.
-
template<typename
T>
classSpectralDecompositionTree: public NodeAttribute<SpectralDecomposition<T>>¶ Public Functions
-
SpectralDecompositionTree()¶
-
SpectralDecompositionTree(const MatrixTree<T> &H, const Tree &tree)¶
-
~SpectralDecompositionTree()¶
-
void
calculate(const MatrixTree<T> &H, const Tree &tree)¶
-
MatrixTree<T>
invert(const Tree &tree, double eps = 1e-7)¶
-
-
class
SpinGroup: public LeafInterface¶
-
template<typename
T>
classSumOfProductsOperator¶ - #include <SumOfProductsOperator.h>
This class represents a sum-of-products operator.
SOPs are sums of MultiParticleOperators. The class provides basic arithmetics that allows to perform high-level operations on operators.
-
class
SymMatrixTree: public pair<SparseMatrixTreecd, SparseMatrixTreecd>¶ Public Functions
-
SymMatrixTree(const SparseMatrixTreecd &A, const SparseMatrixTreecd &B)¶
-
const SparseMatrixTreecd &
up() const¶
-
SparseMatrixTreecd &
up()¶
-
const SparseMatrixTreecd &
down() const¶
-
SparseMatrixTreecd &
down()¶
-
-
class
SymTensorTree¶
-
class
SymXMatrixTrees¶
-
class
TDDVR¶ Public Functions
-
TDDVR(const Wavefunction &Psi, const Tree &tree)¶
-
void
GridTransformation(MatrixTensorTree &Psi, const Tree &tree, bool inverse = false) const¶
-
void
GridTransformation(SymTensorTree &Psi, const Tree &tree, bool inverse = false) const¶
-
void
update(const Wavefunction &Psi, const Tree &tree)¶
-
void
update(const SymTensorTree &Psi, const Tree &tree)¶
-
void
upTransformation(SymTensorTree &Psi, const Tree &tree, bool inverse) const¶
-
void
downTransformation(SymTensorTree &Psi, const Tree &tree, bool inverse) const¶
Public Members
-
MatrixTreecd
trafo_¶
-
MatrixTreecd
hole_trafo_¶
-
XMatrixTrees
Xs_¶
-
SymXMatrixTrees
symx_¶
-
SymMatrixTree
strafo_¶
-
SymTreeGrid
sgrids_¶
Private Functions
-
void
NodeTransformation(Wavefunction &Psi, const Tree &tree, bool inverse) const¶
-
void
EdgeTransformation(MatrixTreecd &B_inv, const Tree &tree, bool inverse) const¶
-
-
template<typename
T>
classTensor - #include <Tensor.h>
This class represents a set of mathematical Tensors of n-th order.
The class allows to handle arithmentic operations on Tensors like matrix-products, etc. The set of tensors can be interpreted simultaneously as a set of vectors and thus operations are available like orthogonalizations, Dot-products, etc. Superindex mappings are used frequently throughout the class functions.
Usage: TensorDim dim_({2, 3, 4}, 1); Tensorcd A(dim_);
-
class
TensorDim - #include <TensorShape.h>
This class manages the dimensions of a Tensor.
This class holds the tensor dimensions n=(n_1,…,n_order). It is a decorated vector of (unsigned) integers (the dimensions). The class, furthermore, manages contracted dimensions for quick reshapings.

Usage: TensorDim tdim({2, 3, 4});
-
class
TensorDimTree¶
-
template<typename
T>
classTensorOperatorRepresentation: public TensorTree<T>¶
-
template<typename
T>
classTensorTree¶ - #include <TensorTree.h>
This class represents tensor trees.
Usage: Tree tree = balancedTree(12, 2, 2); // Create Tensor with Zero-entry tensors at every node TensorTreecd Psi(tree); Psi.Write(“filename.dat”); TensorTreecd Chi(“filename.dat”);
Subclassed by TensorOperatorRepresentation< T >, TensorTreeOperator< T >
-
template<typename
T>
classTensorTreeOperator: public TensorTree<T>¶ Public Functions
-
TensorTreeOperator()¶
-
~TensorTreeOperator()¶
-
void
setLeafOperator(const LeafMatrix<T> &M, size_t operator_idx, const Node &node)¶
-
-
class
Tree¶ This class manages the tensor tree tree.
TensorTreeBasis (TTBasis) holds and manages the tree structure and holds tensor dimensions at every node. It provides iterators for swiping over every node in a tree. For a bottom-up swipe though the tree use the iterator; for a top-down swipe use a regular for loop and get Nodes via GetNode(i).
Usage: Tree tree(n_leaves dim_leaves, dim_nodes); // Create close to balanced tree for (const Node& node : tree) { // Do something - bottom-up swipe }
for (int i = tree.nNodes() - 1; i > 0; i) { const Node& node = tree.GetNode(i); // Do something - Top-child swipe } or for (auto it = tree.rbegin(); it != tree.rend(); it++) {
}
for (size_t l = 0; l < nLeaves; ++l) { const Leaf& leaf = GetLeaf(l); // Do something - for every leaf }
Public Functions
-
Tree()¶ Default constructor.
-
~Tree()¶ Default Destructor.
-
Tree(istream &is)¶ File constructor.
-
Tree(const string &filename)¶ Stream constructor.
-
void
read(istream &is)¶ read Basis from ASCII-file
I/O.
-
void
read(const string &filename)¶
-
void
write(ostream &os = cout) const¶ Write the tree to a stream in ASCII output.
-
void
info(ostream &os = cout) const¶ Print out tree information.
-
size_t
nTotalNodes() const¶ number of Nodes
-
size_t
nNodes() const¶ number of logical nodes
-
size_t
nLeaves() const¶ number of physical nodes
-
size_t
nStates() const¶ Number of states.
-
AbstractNode &
nextNode()¶ Return the reference to the next node. This routine is only used for initialization once. Please use the iterator, or mctdhNode(i) functions to address nodes!
-
void
reindexLeafModes(map<size_t, size_t> Map)¶ Assign new indices to leaves.
-
void
resetLeafModes()¶ Reset indices of leaves.
-
vector<reference_wrapper<Node>>::const_iterator
begin() const¶ Bottom-up iterator over all nodes in the mctdh-tree For top-up iteration examples refer to e.g. the density-matrix class.
-
vector<reference_wrapper<Node>>::const_iterator
end() const¶ Bottom-up const iterator over all nodes in the mctdh-tree For top-up iteration examples refer to e.g. the density-matrix class.
-
vector<reference_wrapper<Node>>::const_reverse_iterator
rbegin() const¶ Top-down iterator over all nodes in the mctdh-tree.
-
vector<reference_wrapper<Node>>::const_reverse_iterator
rend() const¶ Bottom-up const iterator over all nodes in the mctdh-tree.
-
bool
isWorking()¶ Check whether TensorTreeBasis is working correctly.
-
void
print(ostream &os = cout) const¶ Human readable output of the tree shape.
-
const LinearizedNodes &
nodes() const¶
-
vector<size_t>
rangeLeaves() const¶ return range of 1 to n_leaves
Protected Attributes
-
LinearizedLeaves
linearizedLeaves_¶ Reference block to physical coordinates.
-
LinearizedNodes
linearizedNodes_¶ Reference block to mctdh-nodes.
-
-
class
TreeGrids: public vector<SparseVectorTreed>¶
-
class
TreeMarker¶ - #include <SparseTree.h>
This class marks a subset of active Nodes in a tree.
The class is used to mark Nodes when working with sparseness in tree structure. Typically, nodes are marked by providing a list of active leaves. In this case, the TreeMarker searches for the Nodes connectinb the leaves and saving the corresponding Node pointers in a list. co_address stores the mapping of the global Node address in TTBasis to the sparse address.
-
class
TreeNode¶ Public Functions
-
TreeNode()¶ Rule of five-section (constructors & destructors)
A simple tree-node class.
-
TreeNode(size_t n)¶
-
TreeNode(NodeContent con)¶
-
~TreeNode()¶
-
size_t
size() const¶
-
size_t
Address() const¶
-
void
SetAddress(size_t addr)¶
-
bool
IsLeaf() const¶
-
bool
IsBottom() const¶
-
bool
IsRoot() const¶
-
size_t
Layer() const¶
-
void
SetPhysicalNodes(size_t &next)¶
-
void
UpdateTensorDim()¶
-
void
MakeRoot()¶
-
void
GenInput(ostream &os = cout) const¶
Public Members
-
NodeContent
content_¶
-
-
class
TreeSOP: public NodeAttribute<NodeSOPlist>¶ - #include <TreeSOP.h>
A Tree-structured Sum-of-Product (SOP) Operator.
Public Functions
-
TreeSOP()¶
-
~TreeSOP()¶
-
LeafOperatorLib &
leafOperatorLib(const Node &node)¶
-
const LeafOperatorLib &
leafOperatorLib(const Node &node) const¶
-
void
push_back(const LeafOperatorLib &lib, const vector<string> &names)¶
-
vector<vector<string>>
LeafOperatorLibNames() const¶
-
bool
empty() const¶
Private Functions
-
-
template<typename
T>
classTTOcontraction: public NodeAttribute<vector<Matrix<T>>>¶ Public Functions
-
TTOcontraction()¶
-
~TTOcontraction()¶
-
Tensor<T>
applyMatrices(Tensor<T> A, const vector<size_t> &ls, const TensorTreeOperator<T> &H, const TTOrepresentation<T> &Hrep, const Node &parent, int hole) const¶
-
void
calculateLayer(const Tensor<T> &Psi, const TensorTreeOperator<T> &H, const TTOrepresentation<T> &Hrep, const Tensor<T> &Chi, const Node &opnode)¶
-
void
calculate(const TensorTree<T> &Psi, const TensorTreeOperator<T> &H, const TTOrepresentation<T> &Hrep, const TensorTree<T> &Chi, const Tree &optree)¶
-
-
template<typename
T>
classTTOHoleTree: public NodeAttribute<Matrix<T>>¶
-
template<typename
T>
classTTOMatrixTree: public MatrixTree<T>¶ Public Functions
-
~TTOMatrixTree()¶
-
-
template<typename
T>
classTTOrepresentation: public NodeAttribute<vector<Matrix<T>>>¶ Public Functions
-
TTOrepresentation()¶
-
~TTOrepresentation()¶
-
Tensor<T>
applyMatrices(Tensor<T> A, const Tensor<T> &B, const vector<size_t> &ls, const Node &opnode, int hole) const¶
-
void
calculateLayer(const Tensor<T> &Psi, const TensorTreeOperator<T> &H, const Tensor<T> &Chi, const Node &opnode)¶
-
void
calculate(const TensorTree<T> &Psi, const TensorTreeOperator<T> &H, const TensorTree<T> &Chi, const Tree &optree)¶
-
-
template<typename
T>
classVector This class is a Vector represented in a basis.
The class is a simple version of a represented Vector. The class is suited for Quantum Dynamics simulations; it is not a generell purpose library class.
Public Functions
-
Vector()¶
-
Vector(size_t dim)¶ Constructors, Destructors, Asignment operators ~ Rule of Five ~
-
Vector(const string &filename)¶
-
Vector(istream &is)¶
-
Vector<T> &
operator=(const Vector &other)¶
-
Vector<T> &
operator=(Vector &&other)¶
-
~Vector()¶
-
void
write(const string &filename) const¶
-
void
write(ostream &os) const¶
-
void
read(const string &filename)¶
-
void
read(istream &is)¶
-
void
print(ostream &os = cout) const¶
-
T
operator()(size_t i) const¶
-
T &
operator()(size_t i)¶
-
T
operator[](size_t i) const¶
-
T &
operator[](size_t i)¶
-
Vector<T>
operator+=(Vector b)¶
-
Vector<T>
operator-=(Vector b)¶
-
Vector<T>
operator+(Vector b) const¶
-
Vector<T>
operator-(Vector b) const¶
-
T
operator*(Vector b) const¶
-
Vector<T> &
operator*=(T coeff)¶
-
Vector<T> &
operator/=(T coeff)¶
-
Vector<T>
operator*(T coeff) const¶
-
Vector<T>
operator/(T coeff) const¶
-
double
norm() const¶
-
void
zero()¶
-
size_t
dim() const¶
-
-
template<typename
T>
classWorkMemory¶
-
class
XMatrixTrees¶ Public Functions
-
~XMatrixTrees()¶
-
void
Update(const Wavefunction &Psi, const Tree &tree)¶
-
void
UnweightContractions(vector<SparseMatrixTreecd> &holes, const Wavefunction &Psi, const Tree &tree) const¶
-
Tensorcd
Optimize(const Tensorcd &Phi, const Matrixcd &rho, const Node &node, const Node &node_small) const¶
-
Wavefunction
Optimize(Wavefunction Psi, const MatrixTreecd &rho, const Tree &tree, const Tree &tree_small)¶
-
void
print() const¶
-
size_t
size() const¶
-
-
namespace
cdvr_functions¶ Functions
-
void
fillXNode(Vectord &X, vector<size_t> idx, const TreeGrids &grids, const TreeGrids &holegrids, const Node &node)¶
-
void
fillXEdge(Vectord &X, vector<size_t> idx, const TreeGrids &grids, const TreeGrids &holegrids, const Node &node)¶
-
void
calculateDeltaVs(DeltaVTree &deltaVs, const TensorTreecd &Cup, const TensorTreecd &Cdown, const TensorTreecd &Vnodes, const MatrixTreed &Vedges, const Tree &tree)¶
-
void
apply(Tensorcd &VPhi, const Tensorcd &Xi, const Tensorcd &V, const TensorTreecd &Cdown, const DeltaVTree &deltaVs, const Node &node, const WorkMemorycd &mem)¶
-
void
fillX(Vectord &X, size_t idx, const TreeGrids &grids, const Node &node)¶ Notes on notation: Cdown: Top-down normalized, reads C^{p(p k)} in equations Cup: Bottom-up normalized, reads C^{p(p 0)} in equations Fill a vector with grid points corresponding to intex “idx”.
- Parameters
X:idx:grids:node:
-
void
contractEF(Tensorcd &deltaV, const Tensorcd &E, const Tensorcd &F, const Node &node, size_t k)¶
-
void
deltaEdgeCorrection(Tensorcd &deltaV, const Tensorcd &Cup, const TensorTreecd &Cdown, const DeltaVTree &DeltaVs, const Node &node)¶
-
void
-
namespace
chrono¶
-
namespace
JacobiRotationFramework¶ This namespace contains functions for Jacobi rotations algorithms.
-
namespace
JordanWigner¶
-
namespace
OptimizeGrid¶
-
namespace
QM¶ Functions
-
constexpr complex<double> QM::im(0., 1.)
-
-
namespace
Random¶ Functions
-
template<typename
T, classLinearOperator, classMem>
Matrix<T>randomQ(const LinearOperator &A, size_t k_plus_p, mt19937 &gen, Mem *mem)¶ Create matrix Q as required by random algorithms in Ref. [1].
[1] SIAM Rev., 53(2), 217–288. (72 pages)
- Return
Random Matrix Q as required by Ref. [1].
- Template Parameters
Mem: container for memory attached to linear operator
- Parameters
A: the linear operator used for preconditioning the random matrixk_plus_p: dimension of the random space. Refers to notation in Ref. [1]
-
template<typename
T, classLinearOperator, classMem>
SpectralDecomposition<T>diagonalizeRandom(const LinearOperator &A, size_t rank, size_t pow, mt19937 &gen, Mem *mem = nullptr)¶
-
template<typename
T>
Matrix<T>randomGauss(size_t dim1, size_t dim2, mt19937 &gen)¶ Draw a random matrix from the gaussian unitary ensemble.
- Return
Matrix with random gaussian unitary entries.
- Template Parameters
T: base type
- Parameters
dim1: number of rows of the matrixdim2: number of columns of the matrixgen: random number generator
-
template<typename
-
namespace
RandomMatrices¶ Functions
-
SpectralDecompositioncd
diagonalizeRandom(const Matrixcd &A, size_t rank, size_t p, mt19937 &gen)¶ randomized Factorizations
-
Vectord
probabilitiyDist(const Matrixcd &A)¶ entropy & cross entropy
Probability distribution framework Take absolute square of diagonals(A)
-
vector<Vectorcd>
buildKrylovSpace(Vectorcd x, const Matrixcd &A, size_t dim_subspace)¶ Krylov subspace stuff.
-
SpectralDecompositioncd
gueDiag(size_t dim, mt19937 &gen)¶
-
SpectralDecompositiond
goeDiag(size_t dim, mt19937 &gen)¶
-
SpectralDecompositioncd
-
namespace
RungeKutta4¶
-
namespace
SparseMatrixTreeFunctions¶ This class provides functions to build SparseMatrixTrees.
SparseMatrixTrees typically appear when representing operators in a tensortree basis. Similar to MatrixTree, a SparseMatrixTree can be build bottom-up or top-down in a tree. A SparsematrixTree is build bottom-up if an operator is represented and top-down if the representation of the operator is represented.
-
namespace
std¶ Functions
-
bool
is_number(const std::string &s)¶ Check whether string is a natural number https://stackoverflow.com/questions/4654636/how-to-determine-if-a-string-is-a-number-with-c
-
bool
-
namespace
chrono¶
-
namespace
Tensor_Extension¶ Functions
-
template<typename
T>
Matrix<T>weightedOuterProduct(const Tensor<T> &A, const Tensor<T> &B, const Matrix<T> &M)¶
-
template<typename
T>
voidweightedOuterProductAdd(Matrix<T> &M, const Tensor<T> &A, const Tensor<T> &B, const Matrix<T> &rho)¶
-
template<typename
T>
Tensor<T>doubleHoleContraction(const Tensor<T> &A, const Tensor<T> &B, size_t k1, size_t k2)¶
-
void
shiftIndices(vector<size_t> &Ibreak, const TensorShape &shift, bool beforeLast, bool last)¶ Direct Sum + Product.
-
TensorShape
directSum(const TensorShape &A, const TensorShape &B, bool before, bool last)¶
-
template<typename
T>
Tensor<T>directSum(const Tensor<T> &A, const Tensor<T> &B, bool before, bool last)¶
-
template<typename
T>
voidgenerateNormal(T *A, size_t n, mt19937 &gen)¶ Random number routines for tensors.
Randomly occupy Tensors and Matrices
-
template<typename
T>
Matrix<T>oldStateAveragedHoleProduct(const Tensor<T> &A, const Tensor<T> &B, size_t k)¶
-
template<typename
T, typenameU>
Tensor<T>oldMultAB(const Matrix<U> &A, const Tensor<T> &B, size_t mode)¶
-
TensorShape
DirectProduct(const TensorShape &A, const TensorShape &B)¶
-
size_t
mergeIndex(size_t I, size_t J, const TensorShape &A, const TensorShape &B, const TensorShape &C)¶
-
template<typename
-
namespace
TreeFactory¶ Functions
-
vector<Node>
bottomlayerNodes(size_t num_leaves, size_t dim_leaves, size_t dim_nodes, size_t leaf_type)¶
-
Tree
balancedTree(size_t num_leaves, size_t dim_leaves = 2, size_t dim_nodes = 2, size_t dim_inc = 0, size_t leaf_type = 0, double omega = 1., double r0 = 0., double wfr0 = 1., double wfomega = 0.)¶
-
map<size_t, size_t>
leaves_staggered_integers(size_t num_integer, size_t num_bits)¶
-
vector<Node>
-
namespace
TreeFunctions¶ -
Functions
-
void
applyOperatorSCF(TensorTreecd &Psi, MatrixTreecd &rho, const SOPVectorcd &sop, const Tree &tree)¶
-
double
applyOperatorIteration(TensorTreecd &Psi, MatrixTreecd &rho, const SOPcd &sop, const Tree &tree)¶ apply a SOPcd operator onto a wavefunction (the sop operator is needed in its adjoint form as well)
-
void
applyOperatorIteration(TensorTreecd &HPsi, const TensorTreecd &Psi, MatrixTreecd &rho, SparseMatrixTreescd &Hmats, SparseMatrixTreescd &HHoles, const SOPcd &sop, const SparseTree &stree, const Tree &tree)¶
-
Tensorcd
applyOperatorLocal(const Tensorcd &Phi, const MatrixTreecd &rho, const SparseMatrixTreescd &mats, const SparseMatrixTreescd &holes, const SOPcd &sop, const Node &node)¶
-
double
fidelity(const TensorTreecd &Psi, const TensorTreecd &Psilast, const SparseMatrixTreescd &umat, const MatrixTreecd &rho, const SOPcd &u, const SparseTree &stree, const Tree &tree)¶
-
void
applyOperator(TensorTreecd &Psi, MatrixTreecd &rho, const SOPVectorcd &sop, const SOPVectorcd &sop_adj, const Tree &tree, Fidelity &f, mt19937 &gen)¶
-
void
applyOperator(TensorTreecd &Psi, MatrixTreecd &rho, const SOPcd &sop, const SOPcd &sop_adj, const Tree &tree, const Diagonalizer &par, WorkMemorycd *mem)¶ Routine for applying a SOPcd operator onto a wavefunction.
apply a SOPcd operator onto a wavefunction (the sop operator is needed in its adjoint form as well)
-
TensorTreecd
add(const vector<TensorTreecd> &Psis, const Tree &tree, double eps)¶ Contract multiple wavefunctions in a single wavefunction.
-
double
fidelity(const TensorTreecd &Psi, const TensorTreecd &Psilast, const SOPcd &u, const Tree &tree)¶
-
Tensorcd
occupyFromMatrix(const Matrixcd &ev, const TensorShape &tdim)¶ Occupy a Tensor from a matrix.
-
Tensorcd
multAdd(const vector<Tensorcd> &A, const vector<Matrixcd> &rho)¶ Perform a state-index matrix-tensor operators for a set of Tensors/Matrices and accumulate.
-
Tensorcd
applyLower(const Tensorcd &Phi, const SOPcd &sop, vector<SparseMatrixTreecd> &Hmats, const vector<SparseMatrixTreecd> &Holes, const Node &node, const Diagonalizer &par, WorkMemorycd *mem)¶ Solve equations for applying an operator for a lower node.
-
Tensorcd
applyTop(const Tensorcd &Acoeff, const vector<SparseMatrixTreecd> &Hmats, const SOPcd &sop, const Node &node)¶ Solve equations for applying an operator for the top node.
Build hole-matrices used for applying scheme.
-
Matrixcd
buildDeltaOperator(const vector<Tensorcd> &Phis, const SOPcd &sop, const vector<SparseMatrixTreecd> &Holes, const Node &node)¶ Build residual operator from a set of Tensors, hole-matrices and the SOPcd operator.
-
void
applyOperator(TensorTreecd &Psi, Tree &tree, const SOPVectorcd &sop, const SOPVectorcd &sop_adj, double eps, size_t max_spf, size_t n_plus)¶
-
void
applyOperator(TensorTreecd &Psi, Tree &tree, const SOPcd &sop, const SOPcd &sop_adj, double eps, size_t max_spf, size_t n_plus)¶
-
Tensorcd
applyLowerDynamic(Tensorcd Phi, const SOPcd &sop, vector<SparseMatrixTreecd> &Hmats, const vector<SparseMatrixTreecd> &Holes, Node &node, Node &parent, Tensorcd &upPhi, double eps, size_t max_spf, size_t n_plus)¶
-
void
Represent(SparseMatrixTreecd &mat, const MatrixTensorTree &Psi, const MLOcd &M, const Tree &tree)¶
-
void
Contraction(SparseMatrixTreecd &hole, const MatrixTensorTree &Psi, const SparseMatrixTreecd &mat, const SparseTree &marker, const Tree &tree)¶
-
void
Represent(SparseMatrixTreePaircd &mats, const MatrixTensorTree &Psi, const MLOcd &M, const Tree &tree)¶
-
void
Represent(SparseMatrixTreePairscd &matset, const MatrixTensorTree &Psi, const SOPcd &H, const Tree &tree)¶
-
Tensorcd
symApplyDown(const Tensorcd &Phi, const SparseMatrixTreecd &hHole, const Node &node)¶
-
Tensorcd
symApply(const Tensorcd &Phi, const SparseMatrixTreePaircd &mats, const MLOcd &M, const Node &node)¶
-
Tensorcd
symApply(Tensorcd Phi, const SparseMatrixTreePairscd &hMatSet, const SOPcd &H, const Node &node)¶
-
void
represent(SparseMatrixTreecd &mat, const MatrixTensorTree &Psi, const MLOcd &M, const Tree &tree)¶
-
void
contraction(SparseMatrixTreecd &hole, const MatrixTensorTree &Psi, const SparseMatrixTreecd &mat, const SparseTree &marker, const Tree &tree)¶
-
void
represent(SparseMatrixTreePaircd &mats, const MatrixTensorTree &Psi, const MLOcd &M, const Tree &tree)¶
-
void
represent(SparseMatrixTreePairscd &matset, const MatrixTensorTree &Psi, const SOPcd &H, const Tree &tree)¶
-
template<typename
T>
voiddotProductLocal(MatrixTree<T> &S, const Tensor<T> &Phi, Tensor<T> AChi, const Node &node)¶ General DotProduct for Tensor Trees.
-
template<typename
T>
voiddotProduct(MatrixTree<T> &S, const TensorTree<T> &Psi, const TensorTree<T> &Chi, const Tree &tree)¶
-
template<typename
T>
MatrixTree<T>dotProduct(const TensorTree<T> &Psi, const TensorTree<T> &Chi, const Tree &tree)¶
-
template<typename
T>
doubleresidual(const TensorTree<T> &Bra, const TensorTree<T> &Ket, const Tree &tree)¶
-
template<typename
T>
voidcontractionLocal(MatrixTree<T> &Rho, const Tensor<T> &Bra, Tensor<T> Ket, const Node &node, const MatrixTree<T> *S_opt)¶ General Contraction for Tensor Trees.
-
template<typename
T>
voidcontraction(MatrixTree<T> &Rho, const TensorTree<T> &Psi, const TensorTree<T> &Chi, const MatrixTree<T> &S, const Tree &tree)¶
-
template<typename
T>
MatrixTree<T>contraction(const TensorTree<T> &Psi, const TensorTree<T> &Chi, const MatrixTree<T> &S, const Tree &tree)¶
-
template<typename
T>
voidcontraction(MatrixTree<T> &Rho, const TensorTree<T> &Psi, const Tree &tree, bool orthogonal)¶
-
template<typename
T>
MatrixTree<T>contraction(const TensorTree<T> &Psi, const Tree &tree, bool orthogonal)¶
-
template<typename
T>
voidcontraction(MatrixTree<T> &Rho, const TensorTree<T> &Psi, const TensorTree<T> &Chi, const Tree &tree, const MatrixTree<T> *S_opt = nullptr)¶
-
template<typename
T>
Matrix<T>representUpper(const SparseMatrixTree<T> &hmat, const Tensor<T> &Bra, const Tensor<T> &Ket, const Node &node, WorkMemory<T> *mem)¶ Build SparseMatrixTree Bottom-parent (Forward)
-
template<typename
T>
voidrepresentLayer(SparseMatrixTree<T> &mats, const Tensor<T> &Bra, const Tensor<T> &Ket, const MLO<T> &M, const Node &node, WorkMemory<T> *mem)¶
-
template<typename
T>
voidrepresent(SparseMatrixTree<T> &hmat, const MLO<T> &M, const TensorTree<T> &Bra, const TensorTree<T> &Ket, const Tree &tree, WorkMemory<T> *mem = nullptr)¶
-
template<typename
T>
SparseMatrixTree<T>represent(const MLO<T> &M, const TensorTree<T> &Bra, const TensorTree<T> &Ket, const Tree &tree)¶
-
template<typename
T>
voidrepresent(SparseMatrixTree<T> &hmat, const MLO<T> &M, const TensorTree<T> &Psi, const Tree &tree)¶
-
template<typename
T>
SparseMatrixTree<T>represent(const MLO<T> &M, const TensorTree<T> &Psi, const Tree &tree)¶
-
template<typename
T>
voidrepresent(vector<SparseMatrixTree<T>> &Mats, const SOP<T> &sop, const TensorTree<T> &Bra, const TensorTree<T> &Ket, const Tree &tree)¶ === vector versions ===
-
template<typename
T>
voidrepresent(SOPMatrixTrees<T> &mats, const SOP<T> &sop, const TensorTree<T> &Bra, const TensorTree<T> &Ket, const Tree &tree)¶
-
template<typename
T>
voidcontractionLayer(SparseMatrixTree<T> &holes, const TensorTree<T> &Bra, const TensorTree<T> &Ket, const SparseMatrixTree<T> &mats, const MatrixTree<T> *rho, const SparseTree &stree, const Node &node, WorkMemory<T> *mem)¶ Build SparseMatrixTree Top-child (Backward) /////////////////////////////////////////////////////////////////////.
Low-level routine for calculating mean field matrices
-
template<typename
T>
voidcontraction(SparseMatrixTree<T> &holes, const TensorTree<T> &Bra, const TensorTree<T> &Ket, const SparseMatrixTree<T> &mats, const MatrixTree<T> *rho, const SparseTree &stree, const Tree &tree, WorkMemory<T> *mem = nullptr)¶
-
template<typename
T>
SparseMatrixTree<T>contraction(const TensorTree<T> &Psi, const SparseMatrixTree<T> &mats, const Tree &tree)¶ Build SparseMatrixTree Top-down (Backward)
-
template<typename
T>
voidcontraction(SparseMatrixTree<T> &holes, const TensorTree<T> &Bra, const TensorTree<T> &Ket, const SparseMatrixTree<T> &mats, const Tree &tree)¶
-
template<typename
T>
voidcontraction(SparseMatrixTree<T> &holes, const TensorTree<T> &Bra, const TensorTree<T> &Ket, const SparseMatrixTree<T> &mats, const MatrixTree<T> &rho, const SparseTree &marker, const Tree &tree)¶
-
template<typename
T>
voidcontraction(SparseMatrixTree<T> &holes, const TensorTree<T> &Bra, const TensorTree<T> &Ket, const SparseMatrixTree<T> &mats, const MatrixTree<T> &rho, const Tree &tree)¶
-
template<typename
T>
voidcontraction(SparseMatrixTree<T> &holes, const TensorTree<T> &Psi, const SparseMatrixTree<T> &mats, const Tree &tree)¶
-
template<typename
T>
voidcontraction(SparseMatrixTrees<T> &holes, const SparseMatrixTrees<T> &mat, const TensorTree<T> &Bra, const TensorTree<T> &Ket, const Tree &tree)¶
-
template<typename
T>
voidcontraction(SparseMatrixTrees<T> &holes, const TensorTree<T> &Bra, const TensorTree<T> &Ket, const SparseMatrixTrees<T> &mats, const MatrixTree<T> &rho, const Tree &tree)¶
-
template<typename
T>
voidcontraction(MatrixTree<T> &Rho, const TensorTree<T> &Psi, const SparseTree &stree, bool orthogonal = true)¶
-
template<typename
T>
Tensor<T>apply(const SparseMatrixTree<T> &mat, const Tensor<T> &Phi, const MLO<T> &M, const Node &node)¶ apply MatrixTree
apply factor matrices locally
-
template<typename
T>
voidapply(Tensor<T> &hPhi, const SparseMatrixTree<T> &mat, const SparseMatrixTree<T> *holes, const MatrixTree<T> *rho, Tensor<T> Phi, const SparseTree &stree, const Node &node, int skip, Tensor<T> *work = nullptr)¶ apply SparseMatrixTree to tensor tree
-
template<typename
T>
Tensor<T>apply(const SparseMatrixTree<T> &mat, const SparseMatrixTree<T> &holes, const MatrixTree<T> *rho, Tensor<T> Phi, const SparseTree &stree, const Node &node, int skip)¶
-
template<typename
T>
Tensor<T>applyUpper(const SparseMatrixTree<T> &mat, Tensor<T> Phi, const Node &node)¶
-
template<typename
T>
Tensor<T>applyHole(const SparseMatrixTree<T> &holes, Tensor<T> Phi, const Node &hole_node)¶
-
template<typename
T>
voidapply(Tensor<T> &hPhi, const SparseMatrixTree<T> &mat, const Tensor<T> &Phi, const MLO<T> &M, const Node &node)¶
-
template<typename
T>
Matrix<T>RepresentBottom(const Tensor<T> &Bra, const Tensor<T> &Ket, const MLO<T> &M, const Node &node, const Leaf &leaf, WorkMemory<T> *mem)¶
-
template<typename
T>
voidrepresent(SparseMatrixTrees<T> &Mats, const SOP<T> &sop, const TensorTree<T> &Bra, const TensorTree<T> &Ket, const Tree &tree)¶
-
template<typename
T>
voidcontraction(SparseMatrixTree<T> &holes, const TensorTree<T> &Bra, const TensorTree<T> &Ket, const SparseMatrixTree<T> &mats, const SparseTree &marker, const Tree &tree)¶
-
template<typename
T>
voidcontraction(vector<SparseMatrixTree<T>> &holes, const SparseMatrixTrees<T> &Mats, const TensorTree<T> &Bra, const TensorTree<T> &Ket, const Tree &tree)¶
-
void
contractionUp(MatrixTreecd &S, const SymTensorTree &Bra, const SymTensorTree &Ket, const Tree &tree)¶
-
void
contractionDown(MatrixTreecd &Sdown, const SymTensorTree &Bra, const SymTensorTree &Ket, const MatrixTreecd &S, const Tree &tree)¶
-
vector<double>
dotProduct(const SymTensorTree &Bra, SymTensorTree Ket, const Tree &tree)¶
-
void
symContractionLocal(SparseMatrixTreecd &hole, const Tensorcd &Bra, const Tensorcd &Ket, const SparseMatrixTreecd &mat, const Node &hchild)¶ Tree Functions.
-
void
symContraction(SparseMatrixTreecd &hole, const TensorTreecd &Bra, const TensorTreecd &Ket, const SparseMatrixTreecd &mat, const Tree &tree)¶
-
void
symRepresent(SymMatrixTree &mat, const SymTensorTree &Bra, const SymTensorTree &Ket, const MLOcd &M, const Tree &tree)¶
-
void
symRepresent(SymMatrixTrees &mats, const SymTensorTree &Bra, const SymTensorTree &Ket, const SOPcd &S, const Tree &tree)¶
-
void
ApplySCF(SymTensorTree &HPsi, SymMatrixTrees &mats, const SymTensorTree &Psi, const SOPcd &H, const Tree &tree, double eps, size_t max_iter, ostream *os = nullptr)¶
-
Tensorcd
symApply(const Tensorcd &Ket, const SymMatrixTree &mats, const MLOcd &M, const Node &node)¶
-
void
symApply(SymTensorTree &HPsi, const SymTensorTree &Psi, const SymMatrixTrees &hmats, const SOPcd &H, const Tree &tree)¶
-
void
symApply(Tensorcd &HPhi, const Tensorcd &Phi, const SymMatrixTrees &hmats, const SOPcd &H, const Node &node)¶
-
SymMatrixTree
weightedContraction(const SymTensorTree &Bra, const SymTensorTree &Ket, const Tree &tree)¶
-
MatrixTreecd
symDotProduct(const SymTensorTree &Bra, const SymTensorTree &Ket, const Tree &tree)¶
-
MatrixTreecd
mixedDotProduct(const TensorTreecd &Psi, const SymTensorTree &spsi, const Tree &tree)¶ dot product between tensor tree and sym. tensor tree
-
MatrixTreecd
mixedRho(const TensorTreecd &Psi, const SymTensorTree &spsi, const Tree &tree)¶ density matrices between tensor tree and sym. tensor tree
-
template<typename
T>
voidadjust(TensorTree<T> &Psi, Tree &tree, const SpectralDecompositionTree<T> &X, double eps)¶ Compress the TensorTree for a given accuracy.
-
template<typename
T>
voidadjust(TensorTree<T> &Psi, const Tree &newtree)¶
-
template<typename
T>
voidsum(TensorTree<T> &Psi, Tree &tree, const TensorTree<T> &Chi, bool sharedLeafs = true, bool sumToplayer = true)¶ Perform a (generalized) sum of tensor trees. By default, a regular sum will be performed.
-
template<typename
T>
voidproduct(TensorTree<T> &Psi, Tree &tree, const TensorTree<T> &Chi)¶ Perform a product of tensor trees.
-
template<typename
T>
voidAdjustNode(Tensor<T> &Phi, Tensor<T> &A, Node &node, Node &parent, const SpectralDecomposition<T> &x, double eps)¶
-
template<typename
T>
TensorTree<T>densityWeighting(TensorTree<T> Psi, const Tree &tree)¶
-
template<typename
T>
TensorTree<T>contractionNormalization(TensorTree<T> Psi, const Tree &tree, bool orthogonal = true)¶
-
template<typename
T>
voidtransform(TensorTree<T> &Chi, const TensorTree<T> &Psi, const MatrixTree<T> &M, const MatrixTree<T> &M_inv, const Tree &tree)¶
-
template<typename
T>
TensorTree<T>DotProductNormalization(TensorTree<T> Psi, const Tree &tree)¶
-
template<typename
T>
TensorTree<T>DirectionalInvarientRepresentation(TensorTree<T> Psi, const Tree &tree, bool orthogonal)¶
-
template<typename
T>
voidTransformEdgeDown(TensorTree<T> &Chi, const TensorTree<T> &Psi, const Matrix<T> &M, const Edge &e)¶
-
template<typename
T>
voidTransformEdgeUp(TensorTree<T> &Chi, const TensorTree<T> &Psi, const Matrix<T> &Mi, const Edge &e)¶
-
template<typename
T>
voidTransformEdge(TensorTree<T> &Chi, const TensorTree<T> &Psi, const Matrix<T> &M, const Matrix<T> &M_inv, const Edge &e)¶
-
Tensorcd
ApplyDelta(const Tensorcd &R, const vector<Tensorcd> &hPhi, const vector<SparseMatrixTreecd> &Holes, size_t npart, const Node &node)¶
-
void
ContractionLocal(SparseMatrixTreecd &hole, const Tensorcd &Phi, const SparseMatrixTreecd &mat, const Node &hchild)¶
-
template void TreeFunctions::dotProductLocal(MatrixTree< cd > & S, const Tensor < cd > & Bra, Tensor < cd > Ket, const Node & node)
-
template void TreeFunctions::dotProduct(MatrixTree< cd > & S, const TensorTree < cd > & Bra, const TensorTree < cd > & Ket, const Tree & tree)
-
template MatrixTree<cd> TreeFunctions::dotProduct(const TensorTree < cd > & Bra, const TensorTree < cd > & Ket, const Tree & tree)
-
template double TreeFunctions::residual(const TensorTree < cd > & Bra, const TensorTree < cd > & Ket, const Tree & tree)
-
template void TreeFunctions::contractionLocal(MatrixTree< cd > & Rho, const Tensor < cd > & Bra, Tensor < cd > Ket, const Node & node, const MatrixTree< cd > * S)
-
template void TreeFunctions::contraction(MatrixTree< cd > & Rho, const TensorTree < cd > & Bra, const TensorTree < cd > & Ket, const Tree & tree, const MatrixTree< cd > * S)
-
template void TreeFunctions::contraction(MatrixTree< cd > & Rho, const TensorTree < cd > & Bra, const TensorTree < cd > & Ket, const MatrixTree< cd > & S, const Tree & tree)
-
template void TreeFunctions::contraction(MatrixTree< cd > & Rho, const TensorTree < cd > & Psi, const Tree & tree, bool orthogonal)
-
template MatrixTree<cd> TreeFunctions::contraction(const TensorTree < cd > & Bra, const TensorTree < cd > & Ket, const MatrixTree< cd > & S, const Tree & tree)
-
template MatrixTree<cd> TreeFunctions::contraction(const TensorTree < cd > & Psi, const Tree & tree, bool orthogonal)
-
template void TreeFunctions::dotProductLocal< d >(MatrixTree< d > & S, const Tensor < d > & Bra, Tensor < d > Ket, const Node & node)
-
template void TreeFunctions::dotProduct< d >(MatrixTree< d > & S, const TensorTree < d > & Bra, const TensorTree < d > & Ket, const Tree & tree)
-
template MatrixTree<d> TreeFunctions::dotProduct(const TensorTree < d > & Bra, const TensorTree < d > & Ket, const Tree & tree)
-
template double TreeFunctions::residual(const TensorTree < d > & Bra, const TensorTree < d > & Ket, const Tree & tree)
-
template void TreeFunctions::contractionLocal(MatrixTree< d > & Rho, const Tensor < d > & Bra, Tensor < d > Ket, const Node & node, const MatrixTree< d > * S)
-
template void TreeFunctions::contraction(MatrixTree< d > & Rho, const TensorTree < d > & Bra, const TensorTree < d > & Ket, const Tree & tree, const MatrixTree< d > * S)
-
template void TreeFunctions::contraction(MatrixTree< d > & Rho, const TensorTree < d > & Bra, const TensorTree < d > & Ket, const MatrixTree< d > & S, const Tree & tree)
-
template void TreeFunctions::contraction(MatrixTree< d > & Rho, const TensorTree < d > & Psi, const Tree & tree, bool orthogonal)
-
template MatrixTree<d> TreeFunctions::contraction(const TensorTree < d > & Bra, const TensorTree < d > & Ket, const MatrixTree< d > & S, const Tree & tree)
-
template MatrixTree<d> TreeFunctions::contraction(const TensorTree < d > & Psi, const Tree & tree, bool orthogonal)
-
template void TreeFunctions::represent(SparseMatrixTree < cd > & hmat, const MLO < cd > & M, const TensorTree < cd > & Bra, const TensorTree < cd > & Ket, const Tree & tree, WorkMemory < cd > * mem)
-
template void TreeFunctions::represent(SparseMatrixTree < cd > & hmat, const MLO < cd > & M, const TensorTree < cd > & Psi, const Tree & tree)
-
template SparseMatrixTree<cd> TreeFunctions::represent(const MLO < cd > & M, const TensorTree < cd > & Bra, const TensorTree < cd > & Ket, const Tree & tree)
-
template SparseMatrixTree<cd> TreeFunctions::represent(const MLO < cd > & M, const TensorTree < cd > & Psi, const Tree & tree)
-
template void TreeFunctions::represent< cd >(SparseMatrixTrees< cd > & Mats, const SOP < cd > & sop, const TensorTree < cd > & Bra, const TensorTree < cd > & Ket, const Tree & tree)
-
template void TreeFunctions::represent(SOPMatrixTrees < cd > & mats, const SOP < cd > & sop, const TensorTree < cd > & Bra, const TensorTree < cd > & Ket, const Tree & tree)
-
template void TreeFunctions::representLayer(SparseMatrixTree < cd > & mats, const Tensor < cd > & Bra, const Tensor < cd > & Ket, const MLO < cd > & M, const Node & node, WorkMemory < cd > *)
-
template SparseMatrixTrees<cd> TreeFunctions::represent(const SOP < cd > & sop, const TensorTree < cd > & Bra, const TensorTree < cd > & Ket, shared_ptr< SparseTree > & stree, const Tree & tree, WorkMemorycd * mem)
-
template void TreeFunctions::contractionLayer(SparseMatrixTree < cd > & holes, const TensorTree < cd > & Bra, const TensorTree < cd > & Ket, const SparseMatrixTree < cd > & mats, const MatrixTree< cd > * rho, const SparseTree & stree, const Node & node, WorkMemory < cd > * mem)
-
template void TreeFunctions::contractionLayer(SparseMatrixTree < d > & holes, const TensorTree < d > & Bra, const TensorTree < d > & Ket, const SparseMatrixTree < d > & mats, const MatrixTree< d > * rho, const SparseTree & stree, const Node & node, WorkMemory < d > * mem)
-
template void TreeFunctions::contraction(SparseMatrixTree < cd > & holes, const TensorTree < cd > & Bra, const TensorTree < cd > & Ket, const SparseMatrixTree < cd > & mats, const MatrixTree< cd > * rho, const SparseTree & stree, const Tree & tree, WorkMemory < cd > * mem)
-
template void TreeFunctions::contraction(SparseMatrixTree < cd > & holes, const TensorTree < cd > & Bra, const TensorTree < cd > & Ket, const SparseMatrixTree < cd > & mats, const Tree & tree)
-
template void TreeFunctions::contraction(SparseMatrixTree < cd > & holes, const TensorTree < cd > & Psi, const SparseMatrixTree < cd > & mats, const Tree & tree)
-
template void TreeFunctions::contraction(vector< SparseMatrixTree < cd >> & holes, const SparseMatrixTrees< cd > & Mats, const TensorTree < cd > & Bra, const TensorTree < cd > & Ket, const Tree & tree)
-
template void TreeFunctions::contraction(SparseMatrixTree < cd > & holes, const TensorTree < cd > & Bra, const TensorTree < cd > & Ket, const SparseMatrixTree < cd > & mats, const MatrixTree< cd > & rho, const Tree & tree)
-
template void TreeFunctions::contraction(SparseMatrixTrees< cd > & holes, const TensorTree < cd > & Bra, const TensorTree < cd > & Ket, const SparseMatrixTrees< cd > & Mats, const MatrixTree< cd > & rho, const Tree & tree)
-
template SparseMatrixTree<cd> TreeFunctions::contraction(const TensorTree < cd > & Bra, const SparseMatrixTree < cd > & mats, const Tree & tree)
-
template vector<SparseMatrixTree<cd> > TreeFunctions::contraction(const TensorTree < cd > & Bra, const TensorTree < cd > & Ket, const vector< SparseMatrixTree < cd >> & mats, const MatrixTree< cd > & rho, shared_ptr< SparseTree > & stree, const Tree & tree)
-
template void TreeFunctions::contraction< cd >(MatrixTree< cd > & Rho, const TensorTree < cd > & Psi, const SparseTree & stree, bool orthogonal)
-
template Tensor<cd> TreeFunctions::apply(const SparseMatrixTree < cd > & mat, const Tensor < cd > & Phi, const MLO < cd > & M, const Node & node)
-
template void TreeFunctions::apply(Tensor < cd > & hPhi, const SparseMatrixTree < cd > & mat, const SparseMatrixTree < cd > * holes, const MatrixTree< cd > * rho, Tensor < cd > Phi, const SparseTree & stree, const Node & node, int skip, Tensor < cd > * mem)
-
template Tensor<cd> TreeFunctions::apply(const SparseMatrixTree < cd > & mat, const SparseMatrixTree < cd > & holes, const MatrixTree< cd > * rho, Tensor < cd > Phi, const SparseTree & stree, const Node & node, int skip)
-
template Tensor<cd> TreeFunctions::applyUpper(const SparseMatrixTree < cd > & mat, Tensor < cd > Phi, const Node & node)
-
template Tensor<cd> TreeFunctions::applyHole(const SparseMatrixTree < cd > & holes, Tensor < cd > Phi, const Node & hole_node)
-
template void TreeFunctions::represent(SparseMatrixTree < d > & hmat, const MLO < d > & M, const TensorTree < d > & Bra, const TensorTree < d > & Ket, const Tree & tree, WorkMemory < d > * mem)
-
template void TreeFunctions::represent(SparseMatrixTree < d > & hmat, const MLO < d > & M, const TensorTree < d > & Psi, const Tree & tree)
-
template SparseMatrixTree<d> TreeFunctions::represent(const MLO < d > & M, const TensorTree < d > & Bra, const TensorTree < d > & Ket, const Tree & tree)
-
template SparseMatrixTree<d> TreeFunctions::represent(const MLO < d > & M, const TensorTree < d > & Psi, const Tree & tree)
-
template void TreeFunctions::represent< d >(SparseMatrixTrees< d > & Mats, const SOP < d > & sop, const TensorTree < d > & Bra, const TensorTree < d > & Ket, const Tree & tree)
-
template void TreeFunctions::represent(SOPMatrixTrees < d > & mats, const SOP < d > & sop, const TensorTree < d > & Bra, const TensorTree < d > & Ket, const Tree & tree)
-
template void TreeFunctions::representLayer(SparseMatrixTree < d > & mats, const Tensor < d > & Bra, const Tensor < d > & Ket, const MLO < d > & M, const Node & node, WorkMemory < d > *)
-
template SparseMatrixTrees<d> TreeFunctions::represent(const SOP < d > & sop, const TensorTree < d > & Bra, const TensorTree < d > & Ket, shared_ptr< SparseTree > & stree, const Tree & tree, WorkMemory < d > * mem)
-
template void TreeFunctions::contraction(SparseMatrixTree < d > & holes, const TensorTree < d > & Bra, const TensorTree < d > & Ket, const SparseMatrixTree < d > & mats, const MatrixTree< d > * rho, const SparseTree & stree, const Tree & tree, WorkMemory < d > * mem)
-
template void TreeFunctions::contraction(SparseMatrixTree < d > & holes, const TensorTree < d > & Bra, const TensorTree < d > & Ket, const SparseMatrixTree < d > & mats, const Tree & tree)
-
template void TreeFunctions::contraction(SparseMatrixTree < d > & holes, const TensorTree < d > & Bra, const SparseMatrixTree < d > & mats, const Tree & tree)
-
template SparseMatrixTree<d> TreeFunctions::contraction(const TensorTree < d > & Bra, const SparseMatrixTree < d > & mats, const Tree & tree)
-
template void TreeFunctions::contraction(vector< SparseMatrixTree < d >> & holes, const SparseMatrixTrees< d > & Mats, const TensorTree < d > & Bra, const TensorTree < d > & Ket, const Tree & tree)
-
template vector<SparseMatrixTree<d> > TreeFunctions::contraction(const TensorTree < d > & Bra, const TensorTree < d > & Ket, const vector< SparseMatrixTree < d >> & mats, const MatrixTree< d > & rho, shared_ptr< SparseTree > & stree, const Tree & tree)
-
template void TreeFunctions::contraction< d >(MatrixTree< d > & Rho, const TensorTree < d > & Psi, const SparseTree & stree, bool orthogonal)
-
template Tensor<d> TreeFunctions::apply(const SparseMatrixTree < d > & mat, const Tensor < d > & Phi, const MLO < d > & M, const Node & node)
-
template void TreeFunctions::apply(Tensor < d > & hPhi, const SparseMatrixTree < d > & mat, const SparseMatrixTree < d > * holes, const MatrixTree< d > * rho, Tensor < d > Phi, const SparseTree & stree, const Node & node, int skip, Tensor < d > * work)
-
template Tensor<d> TreeFunctions::apply(const SparseMatrixTree < d > & mat, const SparseMatrixTree < d > & holes, const MatrixTree< d > * rho, Tensor < d > Phi, const SparseTree & stree, const Node & node, int skip)
-
template Tensor<d> TreeFunctions::applyUpper(const SparseMatrixTree < d > & mat, Tensor < d > Phi, const Node & node)
-
template Tensor<d> TreeFunctions::applyHole(const SparseMatrixTree < d > & holes, Tensor < d > Phi, const Node & hole_node)
-
void
contractionUpLocal(MatrixTreecd &S, const Tensorcd &Bra, Tensorcd Ket, const Node &node)¶ Tree Contractions.
-
void
contractionDownLocal(MatrixTreecd &Sdown, const Tensorcd &Bra, Tensorcd Ket, const MatrixTreecd &S, const Node &child)¶
-
Tensorcd
symApply(Tensorcd Ket, const MatrixTreecd &Sup, const MatrixTreecd &Sdown, const Node &node)¶
-
double
error(const vector<double> &vec)¶
-
void
iterate(SymTensorTree &HPsi, SymMatrixTrees &mats, const SymTensorTree &Psi, const SOPcd &H, const Tree &tree)¶ apply Operators
Idea:
always perform normalize up right before building up-/down-matrices
only perform once per operator to avoid multiple evaluations
weighted Tensors store the important information
allows to perform different ‘normalization’ for CDVR
this can incorporate finding optimized x-basis sets
- Parameters
HPsi:Psi:hmats:H:node:
-
Tensorcd
symApplyDownNew(const Tensorcd &Phi, const SparseMatrixTreecd &hHole, const Node &node)¶ apply Operators
-
template void TreeFunctions::transform(TensorTree < cd > & Chi, const TensorTree < cd > & Psi, const MatrixTree< cd > & M, const MatrixTree< cd > & M_inv, const Tree & tree)
-
template void TreeFunctions::transform(TensorTree < d > & Chi, const TensorTree < d > & Psi, const MatrixTree< d > & M, const MatrixTree< d > & M_inv, const Tree & tree)
-
template TensorTree<cd> TreeFunctions::contractionNormalization(TensorTree < cd > Psi, const Tree & tree, bool orthogonal)
-
template TensorTree<d> TreeFunctions::contractionNormalization(TensorTree < d > Psi, const Tree & tree, bool orthogonal)
-
template TensorTree<cd> TreeFunctions::DotProductNormalization(TensorTree < cd > Psi, const Tree & tree)
-
template TensorTree<d> TreeFunctions::DotProductNormalization(TensorTree < d > Psi, const Tree & tree)
-
void
-
namespace
TreeIO¶ Functions
-
void
status(size_t it, size_t max, size_t freq, size_t length)¶
-
void
statusTime(size_t it, size_t max, size_t freq, size_t length, chrono::high_resolution_clock::time_point &t1, chrono::high_resolution_clock::time_point &t2, chrono::microseconds &time)¶
-
void
output(const TensorTreecd &Psi, const Tree &tree, ostream &os = cout)¶
-
template<typename
T>
voidoutput2(const TensorTree<T> &Psi, const Tree &tree, ostream &os = cout)¶
-
template<typename
T>
voidoccupancy(const TensorTree<T> &Psi, const Tree &tree, ostream &os = cout)¶
-
template<typename
T>
voidleafs(const TensorTree<T> &Psi, const MatrixTree<T> &Rho, const Tree &tree, ostream &os = cout)¶
-
template<typename
T>
Matrix<T>leafDensity(const TensorTree<T> &Psi, const MatrixTree<T> &Rho, const Leaf &leaf, const Tree &tree)¶
-
template<typename
T>
Matrix<T>leafDensity(const TensorTree<T> &Psi, const SparseMatrixTree<T> &Rho, const Leaf &leaf, const Tree &tree)¶
-
template<typename
T>
voidentropyMap(const TensorTree<T> &Psi, const Tree &tree)¶
-
void
expectationValues(const TensorTreecd &Psi, const MatrixTreecd &rho, const Tree &tree, ostream &os)¶
-
void
-
namespace
WeightedSimultaneousDiagonalization¶ Perform matrix-weighted Joint Diagonalization.
Functions
-
void
calculate(vector<Matrixcd> &Xs, vector<Matrixcd> XXs, Matrixcd &W, Matrixcd &trafo, double eps)¶
-
void
weightedJacobiRotations(vector<Matrixcd> &Xs, vector<Matrixcd> &XXs, Matrixcd &W, Matrixcd &trafo)¶
-
int
calculateWeightedAngles(complex<double> &c, complex<double> &s, size_t i, size_t j, const vector<Matrixcd> &Xs, const vector<Matrixcd> &XXs, const Matrixcd &W)¶
-
double
weightedJacobiLoc(const vector<Matrixcd> &Xs, const vector<Matrixcd> &XXs, const Matrixcd &W, size_t p, size_t q, complex<double> c, complex<double> s)¶
-
void
weightedJacobiDerivatives(Vectord &grad, Matrixd &preHessian, complex<double> s_in, const vector<Matrixcd> &Xs, const vector<Matrixcd> &XXs, const Matrixcd &W, size_t p, size_t q, double delta)¶
-
void
-
file
ApplyFirstOrder.h - #include “TreeClasses/MatrixTreeFunctions.h”#include “TreeClasses/SparseMatrixTreeFunctions.h”#include “TreeOperators/SumOfProductsOperator.h”#include “TreeOperators/SOPVector.h”
Typedefs
-
typedef TensorTreecd
Wavefunction¶
-
typedef TensorTreecd
-
file
CMFIntegrator.h - #include “TreeClasses/HamiltonianRepresentation.h”#include “TreeClasses/LayerInterface.h”#include “TreeClasses/IntegratorVariables.h”#include “Util/BS_integrator.h”
Typedefs
-
typedef BS_integrator<LayerInterface&, Tensorcd, complex<double>>
bs_integrator¶
-
typedef BS_integrator<LayerInterface&, Tensorcd, complex<double>>
-
file
Eigenstates.h - #include “TreeClasses/HamiltonianRepresentation.h”#include “TreeClasses/IntegratorInterface.h”#include “TreeClasses/TreeIO.h”#include “Applications/CMFIntegrator.h”
Functions
-
Vectord
propagatorEnergies(const Wavefunction &Psi, const Tree &tree, double out)¶
-
Vectord
Eigenstate(Wavefunction &Psi, const Hamiltonian &H, const Tree &tree)¶
-
void
Status(const Vectord &eigenvalues, const Vectord &propergatorev, const Matrixcd &S, ostream &os)¶
-
void
Eigenstates(IntegratorVariables &ivar)¶
-
Vectord
-
file
SCF.h - #include “TreeShape/Tree.h”#include “TreeOperators/Hamiltonian.h”
-
file
TreeApplyOperator.h - #include “TreeClasses/MatrixTreeFunctions.h”#include “TreeClasses/SparseMatrixTreeFunctions.h”#include “TreeOperators/SumOfProductsOperator.h”#include “TreeOperators/SOPVector.h”
Typedefs
-
typedef TensorTreecd
Wavefunction
-
typedef TensorTreecd
-
file
TreeApplyOperatorDynamic.h - #include “TreeClasses/MatrixTreeFunctions.h”#include “TreeClasses/SparseMatrixTreeFunctions.h”#include “TreeOperators/SumOfProductsOperator.h”#include “TreeOperators/SOPVector.h”#include “Applications/TreeApplyOperator.h”
-
file
Matrix.h - #include “stdafx.h”#include <Eigen/Dense>#include “Vector.h”
Typedefs
-
typedef Matrix<complex<double>>
Matrixcd General typedef for complex matrices.
-
typedef Matrix<double>
Matrixd General typedef for real matrices.
-
using
SpectralDecomposition= pair<Matrix<T>, Vectord> General typedef for Matrix<T>, Vectord pairs.
-
typedef SpectralDecomposition<complex<double>>
SpectralDecompositioncd Specialization of SpectralDecomposition of Matrixcd.
-
typedef SpectralDecomposition<double>
SpectralDecompositiond Specialization of SpectralDecomposition of Matrixd.
Functions
-
template<typename
T>
Matrix<complex<double>>multATB(const Matrix<complex<double>> &A, const Matrix<T> &B)¶
-
template<typename
T>
Vector<T>operator*(const Matrix<T> &A, const Vector<T> &v)¶ operator overloadings
-
SpectralDecompositioncd
diagonalize(const Matrix<complex<double>> &A)¶ Diagonalization framework.
Diagonalize a complex double matrix
- Return
Decomposed matrix
- Parameters
A: Matrix to be diagonalized
-
void
diagonalize(SpectralDecompositioncd &S, const Matrix<complex<double>> &A)¶ Diagonalize a complex double martrix.
- Parameters
S: Decomposed matrix (call-by-reference)A: Matrix to be diagonalized
-
SpectralDecompositiond
diagonalize(const Matrix<double> &A)¶ Diagonalize a double matrix.
- Return
Decomposed matrix
- Parameters
A: Matrix to be diagonalized
-
void
diagonalize(SpectralDecompositiond &S, const Matrix<double> &A)¶ Diagonalize a double martrix.
- Parameters
S: Decomposed matrix (call-by-reference)A: Matrix to be diagonalized
-
template<typename
T>
pair<Matrix<T>, Vectord>diagonalize(const Matrix<T> &A)¶ Diagonalization routine for remaining types (Eigenvector always double; not generally applicable)
- Return
- Template Parameters
T:
- Parameters
A:
-
template<typename
T>
Matrix<T>toMatrix(const SpectralDecomposition<T> &X)¶ Construct matrix from its decomposition.
- Return
re-constructed matrix
- Parameters
X: Decomposed matrix
-
template<typename
T>
SpectralDecomposition<T>inverse(SpectralDecomposition<T> X, double eps = 1e-7)¶
-
template<typename
T>
SpectralDecomposition<T>sqrt(SpectralDecomposition<T> X)¶ Calculate squareroot of matrix (decomposed)
- Return
squareroot of matrix (decomposed)
- Parameters
X: Decomposed matrix
-
template<typename T>template Matrix< doub > identityMatrix(size_t dim) Create an identity matrix.
- Return
identity-matrix
- Template Parameters
T: Type of identity matrix
- Parameters
dim: dimension
-
typedef Matrix<complex<double>>
-
file
Matrix_Extension.h - #include “Matrix.h”
-
file
Matrix_Extension_Implementation.h - #include “Matrix_Extension.h”
-
file
Matrix_Implementation.h - #include “Matrix.h”
Functions
-
void
tmatvec_(double *C, double *B, double *mat, int *a, int *b, int *c, int *add)¶
-
void
trmatvec_(double *C, double *B, double *mat, int *a, int *b, int *c, int *add)¶
-
template<typename
T>
Matrix<complex<double>>multATB(const Matrix<complex<double>> &A, const Matrix<T> &B)
-
template<typename
T, typenameU>
Vector<U>operator*(const Matrix<T> &A, const Vector<U> &v)¶ operator overloadings
-
template<typename
T>
voiddiagonalize(Matrix<T> &trafo, Vector<double> &ev, const Matrix<T> &B)¶ Diagonalization framework.
-
SpectralDecompositioncd
diagonalize(const Matrix<complex<double>> &A) Diagonalization framework.
Diagonalize a complex double matrix
- Return
Decomposed matrix
- Parameters
A: Matrix to be diagonalized
-
void
diagonalize(SpectralDecompositioncd &S, const Matrix<complex<double>> &A) Diagonalize a complex double martrix.
- Parameters
S: Decomposed matrix (call-by-reference)A: Matrix to be diagonalized
-
SpectralDecompositiond
diagonalize(const Matrix<double> &A) Diagonalize a double matrix.
- Return
Decomposed matrix
- Parameters
A: Matrix to be diagonalized
-
void
diagonalize(SpectralDecompositiond &S, const Matrix<double> &A) Diagonalize a double martrix.
- Parameters
S: Decomposed matrix (call-by-reference)A: Matrix to be diagonalized
-
template<typename
T>
Matrix<T>toMatrix(const SpectralDecomposition<T> &X) Construct matrix from its decomposition.
- Return
re-constructed matrix
- Parameters
X: Decomposed matrix
-
template<typename
T>
SpectralDecomposition<T>sqrt(SpectralDecomposition<T> X) Calculate squareroot of matrix (decomposed)
- Return
squareroot of matrix (decomposed)
- Parameters
X: Decomposed matrix
-
template<typename
T>
SpectralDecomposition<T>inverse(SpectralDecomposition<T> X, double eps)
-
template<typename
T>
Matrix<T>identityMatrix(size_t dim)¶ Create an identity matrix.
Convenience & Management.
- Return
identity-matrix
- Template Parameters
T: Type of identity matrix
- Parameters
dim: dimension
-
Matrixcd
identityMatrixcd(size_t dim)
-
Matrixd
identityMatrixd(size_t dim)
-
Eigen::MatrixXd
toEigen(Matrixd A)
-
Eigen::MatrixXcd
toEigen(Matrixcd A)
-
Matrixd
toQutree(const Eigen::MatrixXd &A)
-
Matrixcd
toQutree(const Eigen::MatrixXcd &A)
-
void
-
file
MatrixBLAS.h - #include “Matrix.h”
-
file
stdafx.h - #include <stdio.h>#include <vector>#include <list>#include <assert.h>#include <iostream>#include <fstream>#include <complex>#include <memory>
-
file
Tensor.h - #include “TensorShape.h”#include “Core/Matrix.h”
Typedefs
-
using
value_type= T¶
Functions
-
template<typename
T>
TsingleDotProd(const Tensor<T> &A, const Tensor<T> &B, size_t n, size_t m)¶ Non-member functions.
-
template<typename
T, typenameU>
voidcontraction1(Matrix<U> &h, const Tensor<T> &bra, const Tensor<T> &ket, size_t A, size_t B, size_t B2, size_t C, bool zero)¶
-
template<typename
T>
voidcontraction(Matrix<T> &S, const Tensor<T> &A, const Tensor<T> &B, size_t before, size_t active1, size_t active2, size_t behind)¶
-
template<typename
T>
voidcontraction(Matrix<T> &S, const Tensor<T> &A, const Tensor<T> &B, size_t k, bool zero = true)¶
-
template<typename
T, typenameU>
voidmatrixTensor(Tensor<T> &C, const Matrix<U> &A, const Tensor<T> &B, size_t before, size_t activeC, size_t activeB, size_t after, bool zero = true)¶
-
template<typename
T, typenameU>
voidtMatrixTensor(Tensor<T> &C, const Matrix<U> &A, const Tensor<T> &B, size_t before, size_t activeC, size_t activeB, size_t after, bool zero = true)¶
-
template<typename
T, typenameU>
voidmatrixTensor(Tensor<T> &C, const Matrix<U> &A, const Tensor<T> &B, size_t mode, bool zero = true)¶
-
template<typename
T, typenameU>
Tensor<T>matrixTensor(const Matrix<U> &A, const Tensor<T> &B, size_t mode)¶
-
template<typename
T, typenameU>
voidtensorMatrix(Tensor<T> &C, const Tensor<T> &B, const Matrix<U> &A, size_t mode, bool zero = true)¶
-
template<typename
T, typenameU>
Tensor<T>tensorMatrix(const Tensor<T> &B, const Matrix<U> &A, size_t mode)¶
-
template<typename
T, typenameU>
Tensor<T>tMatrixTensor(const Matrix<U> &A, const Tensor<T> &B, size_t mode)¶
-
template<typename
T, typenameU>
voidmultStateAB(Tensor<T> &C, const Matrix<U> &A, const Tensor<T> &B, bool zero = true)¶
-
template<typename
T, typenameU>
voidmultStateArTB(Tensor<T> &C, const Matrix<U> &A, const Tensor<T> &B)¶
-
template<typename
T>
Tensor<T>projectOut(const Tensor<T> &A, const Tensor<T> &B)¶ Project B out of A, i.e. Anew = (1-P_B)*A.
This routine takes a Tensor A and makes it orthogonal to B. It can be written as A_new = (1 - P_B) A, where P_B is the projector onto B.
-
template<typename
T>
Tensor<complex<double>>projectOrthogonal(const Tensor<complex<double>> &A, const Tensor<T> &B)¶
-
template<typename
T>
Tensor<T>ones(const TensorShape &shape)¶
-
using
-
file
Tensor_Extension.h - #include “Tensor.h”#include <random>
-
file
Tensor_Extension_Implementation.h - #include “Tensor_Extension.h”
-
file
Tensor_Implementation.h - #include “Tensor.h”#include “TensorShape.h”#include “stdafx.h”#include “Util/qutree_rng.h”
Functions
-
template<typename
T>
TsingleDotProd(const Tensor<T> &A, const Tensor<T> &B, size_t n, size_t m) Non-member functions.
-
void
matvec_(double *C, double *B, double *mat, int *a, int *b, int *c, int *add)¶
-
void
ctmatvec_(double *C, double *B, double *mat, int *a, int *b, int *c, int *add)¶
-
void
rmatvec_(double *C, double *B, double *mat, int *a, int *b, int *c, int *add)¶
-
void
rhomat_(double *Bra, double *Ket, double *M, int *a, int *b, int *c)¶
-
template<typename
T, typenameU>
voidcontraction1(Matrix<U> &h, const Tensor<T> &bra, const Tensor<T> &ket, size_t A, size_t B, size_t B2, size_t C, bool zero)
-
template<typename
T>
voidcontraction(Matrix<T> &S, const Tensor<T> &A, const Tensor<T> &B, size_t before, size_t active1, size_t active2, size_t behind)
-
template<typename
T>
voidcontraction(Matrix<T> &S, const Tensor<T> &A, const Tensor<T> &B, size_t k, bool zero)
-
template<typename
T, typenameU>
voidmatrixTensor1(Tensor<T> &C, const Matrix<U> &h, const Tensor<T> &B, size_t before, size_t active, size_t activeC, size_t after, bool zero)¶
-
template<typename
T, typenameU>
voidmatrixTensor(Tensor<T> &C, const Matrix<U> &A, const Tensor<T> &B, size_t before, size_t activeC, size_t activeB, size_t after, bool zero)
-
template<typename
T, typenameU>
voidtMatrixTensor(Tensor<T> &C, const Matrix<U> &A, const Tensor<T> &B, size_t before, size_t activeC, size_t activeB, size_t after, bool zero)
-
template<typename
T, typenameU>
voidmatrixTensor(Tensor<T> &C, const Matrix<U> &A, const Tensor<T> &B, size_t mode, bool zero)
-
template<typename
T, typenameU>
Tensor<T>matrixTensor(const Matrix<U> &A, const Tensor<T> &B, size_t mode)
-
template<typename
T, typenameU>
voidtensorMatrix(Tensor<T> &C, const Tensor<T> &B, const Matrix<U> &A, size_t mode, bool zero)
-
template<typename
T, typenameU>
Tensor<T>tensorMatrix(const Tensor<T> &B, const Matrix<U> &A, size_t mode)
-
template<typename
T, typenameU>
Tensor<T>tMatrixTensor(const Matrix<U> &A, const Tensor<T> &B, size_t mode)
-
template<typename
T, typenameU>
voidmultStateAB(Tensor<T> &C, const Matrix<U> &A, const Tensor<T> &B, bool zero)
-
template<typename
T, typenameU>
voidmultStateArTB(Tensor<T> &C, const Matrix<U> &A, const Tensor<T> &B)
-
template<typename
T>
Tensor<T>projectOut(const Tensor<T> &A, const Tensor<T> &B) Project B out of A, i.e. Anew = (1-P_B)*A.
This routine takes a Tensor A and makes it orthogonal to B. It can be written as A_new = (1 - P_B) A, where P_B is the projector onto B.
-
template<typename
T>
Tensor<complex<double>>projectOrthogonal(const Tensor<complex<double>> &A, const Tensor<T> &B)
-
template<typename
T>
Tensor<T>toTensor(const Matrix<T> &B, const TensorShape &shape, size_t mode)
-
template<typename
T>
Tensor<T>ones(const TensorShape &shape)
-
template<typename
T>
Tensor<T>rand(const TensorShape &shape)¶
-
template<typename
-
file
TensorBLAS.h - #include “Tensor.h”
Functions
-
template<typename
T, typenameU>
voidmatrixTensor1(Tensor<T> &C, const Matrix<U> &h, const Tensor<T> &B, size_t before, size_t active, size_t activeC, size_t after, bool zero)
-
template<typename
T, typenameU>
voidmatrixTensor2(Tensor<T> &C, const Matrix<U> &h, const Tensor<T> &B, Tensor<T> &D, size_t before, size_t active, size_t activeC, size_t after, bool zero)¶
-
template<typename
T, typenameU>
voidmatrixTensor3(Tensor<T> &C, const Matrix<U> &h, const Tensor<T> &B, Tensor<T> &Ket_work, Tensor<T> &hKet_work, size_t before, size_t active, size_t activeC, size_t after, bool zero)¶
-
template<typename
T, typenameU>
voidcontraction1(Matrix<U> &h, const Tensor<T> &bra, const Tensor<T> &ket, size_t A, size_t B, size_t B2, size_t C, bool zero)
-
template<typename
T>
voidcontraction2(Matrix<T> &h, const Tensor<T> &bra, const Tensor<T> &ket, Tensor<T> &bra_work, Tensor<T> &ket_work, size_t A, size_t B, size_t B2, size_t C, bool zero)¶
-
template<typename
T>
voidgeneral_contraction(const Tensor<T> &A, const Tensor<T> &B, Tensor<T> &result, const vector<size_t> &A_indices, const vector<size_t> &B_indices)¶
-
template<typename
T, typenameQ>
voidgeneral_contraction(const Tensor<T> &A, const Tensor<T> &B, Tensor<T> &result, const std::vector<std::pair<Q, Q>> &contraction_pairs)¶
-
template<typename
T>
voidgeneral_transpose_bd(T *dst, const T *src, size_t a, size_t b, size_t c, size_t d, size_t e)¶
-
template<typename
T>
boolis_contraction_legal(const Tensor<T> &TensorA, const Tensor<T> &TensorB, vector<size_t> Acontraction, vector<size_t> Bcontraction)¶
-
template<typename
T>
voidgeneral_transpose(Tensor<T> &dst, const Tensor<T> &src, size_t index_one, size_t index_two)¶
-
template<typename
T>
voidgeneral_transpose_to_order(Tensor<T> &dst, const Tensor<T> &src, const vector<size_t> &form)¶
-
template<typename
T, typenameU>
voidmatrixTensorBLAS(Tensor<T> &C, Tensor<T> &workC, const Matrix<U> &A, const Tensor<T> &B, size_t mode, bool zero = true)¶ ==== Wrappers ====
==== Wrappers ====
======================================================================== Wrappers for matrixTensor product and contraction
-
template<typename
T, typenameU>
voidmatrixTensorBLAS(Tensor<T> &C, const Matrix<U> &A, const Tensor<T> &B, size_t mode, bool zero = true)¶
-
template<typename
T, typenameU>
Tensor<T>matrixTensorBLAS(const Matrix<U> &A, const Tensor<T> &B, size_t mode, bool zero = true)¶
-
template<typename
T>
voidcontractionBLAS(Matrix<T> &h, Tensor<T> &workA, Tensor<T> &workB, const Tensor<T> &A, const Tensor<T> &B, size_t mode, bool zero = true)¶
-
template<typename
-
file
TensorShape.h - #include “stdafx.h”
Functions
-
TensorShape()¶
-
TensorShape(const initializer_list<size_t> &dims)¶
-
TensorShape(const vector<size_t> &dim)¶
-
TensorShape(istream &is)¶
-
TensorShape(const string &file)¶
-
~TensorShape()¶
-
void
initialize(const vector<size_t> &dim)¶
-
void
write(ostream &os) const¶
-
void
write(const string &filename) const¶
-
void
readDim(istream &is)¶
-
size_t
order() const¶
-
size_t
lastIdx() const¶
-
size_t
totalDimension() const¶
-
size_t
lastBefore() const¶
-
size_t
lastDimension() const¶
-
void
setDimension(size_t act, size_t k)¶
-
vector<size_t>
dimensions() const¶
-
void
print(ostream &os = cout) const¶
-
size_t
before(size_t k) const¶
-
size_t
after(size_t k) const¶
-
vector<size_t>
indexMapping(size_t I, const TensorShape &shape)¶
-
size_t
indexMapping(const vector<size_t> &idxs, const TensorShape &shape)¶
-
void
indexMapping(vector<size_t> &idxs, size_t I, const TensorShape &shape)¶
-
TensorShape
replaceDimension(TensorShape shape, size_t target, size_t new_dimension)¶
-
ostream &
operator<<(ostream &os, const TensorShape &tdim)¶
-
istream &
operator>>(istream &is, TensorShape &tdim)¶
-
bool
operator==(const TensorShape &tdima, const TensorShape &tdimb)¶
-
bool
operator!=(const TensorShape &tdima, const TensorShape &tdimb)¶
-
-
file
Vector.h - #include “stdafx.h”#include “Eigen/Dense”
Functions
-
file
Vector_Implementation.h - #include “Vector.h”
-
file
CDVR.h - #include “DVR/TDDVR.h”#include “TreeOperators/Potential.h”#include “DVR/DeltaVTree.h”#include “DVR/cdvr_functions.h”#include “TreeClasses/TensorTreeFunctions.h”#include “TreeClasses/SymTensorTree.h”
-
file
cdvr_functions.h - #include “TreeClasses/MatrixTree.h”#include “DVR/DeltaVTree.h”#include “DVR/MatrixTensorTree.h”#include “DVR/TreeGrids.h”
-
file
DeltaVTree.h - #include “TreeClasses/NodeAttribute.h”#include “TreeShape/Tree.h”
-
file
GridRepresentation.h - #include “TreeClasses/SparseMatrixTreeFunctions.h”#include “TreeClasses/SOPMatrixTrees.h”#include “TreeClasses/MatrixTreeFunctions.h”#include “TreeClasses/SpectralDecompositionTree.h”#include “Core/Tensor_Extension.h”
-
file
MatrixTensorTree.h - #include “TreeClasses/MatrixTreeFunctions.h”
Typedefs
-
typedef TensorTreecd
Wavefunction
Functions
-
bool
IsWorking_bottomup(const MatrixTensorTree &Psi, const Tree &tree, double eps)¶
-
bool
IsWorking_topdown(const MatrixTensorTree &Psi, const Tree &tree, double eps)¶
-
bool
IsWorking(const MatrixTensorTree &Psi, const Tree &tree, double eps = 1e-7)¶
-
typedef TensorTreecd
-
file
MatrixTensorTree.h - #include “TreeClasses/TensorTree.h”#include “TreeClasses/MatrixTreeFunctions.h”
Functions
-
void
QROrthogonalDown(TensorTreecd &Psi, const Tree &tree)¶
-
bool
IsWorking_bottomup(const MatrixTensorTree &Psi, const Tree &tree, double eps)
-
bool
IsWorking_topdown(const MatrixTensorTree &Psi, const Tree &tree, double eps)
-
bool
IsWorking(const MatrixTensorTree &Psi, const Tree &tree, double eps = 1e-7)
-
void
-
file
MatrixTensorTreeFunctions.h - #include “MatrixTensorTree.h”#include “TreeClasses/SparseMatrixTreeFunctions.h”
Typedefs
-
typedef pair<SparseMatrixTreecd, SparseMatrixTreecd>
SparseMatrixTreePaircd¶
-
typedef vector<SparseMatrixTreePaircd>
SparseMatrixTreePairscd¶
-
typedef pair<SparseMatrixTreecd, SparseMatrixTreecd>
-
file
MatrixTensorTreeFunctions.h - #include “MatrixTensorTree.h”#include “TreeClasses/SparseMatrixTreeFunctions.h”
Typedefs
-
typedef pair<SparseMatrixTreecd, SparseMatrixTreecd>
SparseMatrixTreePaircd
-
typedef vector<SparseMatrixTreePaircd>
SparseMatrixTreePairscd
-
typedef pair<SparseMatrixTreecd, SparseMatrixTreecd>
-
file
SymXMatrixTrees.h - #include “DVR/MatrixTensorTree.h”#include “TreeClasses/SparseMatrixTreeFunctions.h”#include “DVR/MatrixTensorTreeFunctions.h”#include “XMatrixTrees.h”#include “TreeClasses/SymTensorTree.h”#include “TreeClasses/SymMatrixTreeFunctions.h”
-
file
TDDVR.h - #include “DVR/TreeGrids.h”#include “DVR/XMatrixTrees.h”#include “TreeClasses/MatrixTree.h”#include “DVR/MatrixTensorTree.h”#include “TreeClasses/WorkMemory.h”#include “SymXMatrixTrees.h”
-
file
TreeGrids.h - #include “TreeClasses/SparseMatrixTreeFunctions.h”#include “TreeClasses/SymMatrixTree.h”
-
file
XMatrixTrees.h - #include “TreeClasses/SparseMatrixTreeFunctions.h”#include “TreeClasses/SOPMatrixTrees.h”#include “TreeClasses/MatrixTreeFunctions.h”#include “TreeClasses/SpectralDecompositionTree.h”#include “Core/Tensor_Extension.h”
Functions
-
Wavefunction
Regularize(Wavefunction Psi, const Tree &tree, double eps)¶
-
Wavefunction
-
file
QuTree.h - #include “Core/Matrix.h”#include “Core/Matrix_Extension.h”#include “Core/Matrix_Extension_Implementation.h”#include “Core/Matrix_Implementation.h”#include “Core/stdafx.h”#include “Core/Tensor.h”#include “Core/Tensor_Extension.h”#include “Core/Tensor_Extension_Implementation.h”#include “Core/Tensor_Implementation.h”#include “Core/TensorShape.h”#include “Core/Vector.h”#include “Core/Vector_Implementation.h”#include “TreeClasses/EdgeAttribute.h”#include “TreeClasses/MatrixTensorTree.h”#include “TreeClasses/MatrixTensorTreeFunctions.h”#include “TreeClasses/MatrixTree.h”#include “TreeClasses/MatrixTreeFunctions.h”#include “TreeClasses/MatrixTreeFunctions_Implementation.h”#include “TreeClasses/NodeAttribute.h”#include “TreeClasses/SOPMatrixTrees.h”#include “TreeClasses/SparseMatrixTree.h”#include “TreeClasses/SparseMatrixTreeFunctions.h”#include “TreeClasses/SparseMatrixTreeFunctions_Implementation.h”#include “TreeClasses/SparseNodeAttribute.h”#include “TreeClasses/SparseTree.h”#include “TreeClasses/SpectralDecompositionTree.h”#include “TreeClasses/SymTensorTree.h”#include “TreeClasses/TensorTree.h”#include “TreeClasses/TensorTreeFunctions_Implementation.h”#include “TreeClasses/TreeIO.h”#include “TreeClasses/TreeTransformation.h”#include “TreeClasses/TreeTransformation_Implementation.h”#include “TreeOperators/CoordinateTransformation.h”#include “TreeOperators/LeafFunction.h”#include “TreeOperators/LeafMatrix.h”#include “TreeOperators/LeafOperator.h”#include “TreeOperators/MultiLeafOperator.h”#include “TreeOperators/Potential.h”#include “TreeOperators/PotentialOperator.h”#include “TreeOperators/SOPVector.h”#include “TreeOperators/SumOfProductsOperator.h”#include “TreeOperators/SumOfProductsOperator_Implementation.h”#include “TreeShape/AbstractNode.h”#include “TreeShape/Edge.h”#include “TreeShape/Leaf.h”#include “TreeShape/LinearizedLeaves.h”#include “TreeShape/Node.h”#include “TreeShape/NodePosition.h”#include “TreeShape/Tree.h”#include “TreeShape/TreeFactory.h”#include “Util/BS_integrator.h”#include “Util/FFT.h”#include “Util/FFTCooleyTukey.h”#include “Util/JacobiRotationFramework.h”#include “Util/Lanzcos.h”#include “Util/QMConstants.h”#include “Util/SimultaneousDiagonalization.h”#include “../../QuTreeVM/src/Util/long_integer.h”
-
file
BlockTree.h - #include “TreeClasses/Discrete/LabelTree.h”#include “TreeClasses/Discrete/U1Symmetry.h”
Typedefs
-
using
BlockTensorShape= vector<TensorShape>¶
-
using
BlockTreeShape= NodeAttribute<BlockTensorShape>¶
-
using
Partition= vector<size_t>¶
Functions
-
vector<const ConfigurationTensor<> *>
mask(const vector<const BlockTensor *> &As, const Partition &partition)¶
-
using
-
file
LabelTree.h - #include “TreeShape/Tree.h”#include “TreeClasses/NodeAttribute.h”#include “TreeClasses/Discrete/SymmetricSCF.h”#include “TreeClasses/Discrete/U1Symmetry.h”
Typedefs
Functions
-
ostream &
operator<<(ostream &os, const LabelDimension &dim)¶
-
TensorShape
LabelShape(const TensorShape &shape, const Label &label)¶
-
ostream &
-
file
SymmetricSCF.h - #include “TreeClasses/NodeAttribute.h”#include <iostream>#include <random>
Functions
-
ConfigurationTensor
randomConfigurationTensor(const TensorShape &shape, mt19937 &gen)¶
-
ConfigurationTensor
bottomTensor(const TensorShape &shape)¶
-
Configuration
optimize(ConfigurationTree<> &Psi, function<double(const Configuration<> &c)> f, const Tree &tree, size_t n_sweep = 3, size_t verboseness = 1, )¶
-
size_t
to_integer(const Configuration<> &c)¶
-
vector<size_t>
split_integers(const Configuration<> &c, size_t n)¶
-
double
to_double(size_t i, size_t max_val)¶
-
void
split_doubles(vector<double> &xs, vector<size_t> &x_int, vector<size_t> &tmp, const Configuration<> &c, size_t n)¶
-
vector<double>
split_doubles(const Configuration<> &c, size_t n)¶
-
ConfigurationTensor
-
file
U1Symmetry.h - #include “stdio.h”#include <random>#include “TreeClasses/Discrete/SymmetricSCF.h”
Typedefs
-
using
Label= size_t¶ Symmetry label, e.g. particle number.
-
using
ilist= list<size_t>¶
-
using
ivec= vector<size_t>¶
Functions
-
size_t
factorial(size_t n)¶ Rationale: Reading https://math.stackexchange.com/questions/474741/formula-for-combinations-with-replacement helps understanding the thoughts behind partitions & combinatorics in this file.
-
size_t
binomial(size_t k, size_t n)¶
-
Labels
label_combinations(const NodeAttribute<Labels> &up, const NodeAttribute<Labels> &down, const Range &range, const Node &node, const Node &hole)¶
-
size_t
nPartitions(size_t sum, size_t nSummands)¶
-
using
-
file
EdgeAttribute.h
-
file
EntropyTree.h - #include “TreeClasses/NodeAttribute.h”#include “TreeShape/Tree.h”#include “TreeClasses/TensorTree.h”
-
file
HamiltonianRepresentation.h - #include “TreeOperators/Hamiltonian.h”#include “TreeClasses/SparseMatrixTreeFunctions.h”#include “TreeClasses/MatrixTreeFunctions.h”#include “TreeClasses/SpectralDecompositionTree.h”#include “Util/QMConstants.h”#include “DVR/CDVR.h”#include “DVR/MatrixTensorTreeFunctions.h”#include “TreeOperators/ActiveCounter.h”
Functions
-
Tensorcd
Apply(const Hamiltonian &H, const Tensorcd &Phi, const HamiltonianRepresentation &hRep, const Node &node)¶
-
Matrixcd
Expectation(const HamiltonianRepresentation &hRep, const Wavefunction &Psi, const Hamiltonian &H, const Tree &tree)¶
-
void
LayerDerivative(Tensorcd &dPhi, double time, const Tensorcd &Phi, const Hamiltonian &H, const HamiltonianRepresentation &hRep, const Node &node, complex<double> propagation_phase = 1.)¶
-
void
Derivative(Wavefunction &dPsi, HamiltonianRepresentation &hRep, double time, const Wavefunction &Psi, const Hamiltonian &H, const Tree &tree, complex<double> propagation_phase = 1.)¶
-
void
symDerivative(MatrixTensorTree &dPsi, HamiltonianRepresentation &hRep, double time, const MatrixTensorTree &Psi, const Hamiltonian &H, const Tree &tree, complex<double> propagation_phase = 1.)¶
-
void
output(const HamiltonianRepresentation &hrep, const Wavefunction &Psi, const Hamiltonian &H, const Tree &tree)¶
-
Tensorcd
-
file
IntegratorInterface.h - #include “TreeClasses/HamiltonianRepresentation.h”
-
file
IntegratorVariables.h - #include “TreeOperators/Hamiltonian.h”
-
file
LayerInterface.h - #include “TreeClasses/HamiltonianRepresentation.h”
-
file
MatrixTree.h - #include “NodeAttribute.h”#include “TreeShape/Tree.h”
Functions
-
template<typename
T>
ostream &operator<<(ostream &os, const MatrixTree<T> &S)¶
-
template<typename
T>
istream &operator>>(istream &is, MatrixTree<T> &S)¶
-
template<typename
-
file
MatrixTreeFunctions.h - #include “TreeClasses/TensorTree.h”#include “TreeClasses/MatrixTree.h”
-
file
MatrixTreeFunctions_Implementation.h - #include “MatrixTreeFunctions.h”#include “Core/TensorBLAS.h”
-
file
NodeAttribute.h - #include “TreeShape/Node.h”#include “TreeShape/Edge.h”#include “TreeShape/Tree.h”
Functions
-
template<class
A>
voidprint(const NodeAttribute<A> &ATree, const Tree &tree)¶
Variables
-
vector<A>
attributes_¶
-
template<class
-
file
SOPMatrixTrees.h - #include “TreeClasses/SparseMatrixTree.h”#include “TreeOperators/SumOfProductsOperator.h”
-
file
SparseMatrixTree.h - #include “TreeClasses/SparseNodeAttribute.h”#include “TreeClasses/TensorTree.h”
Typedefs
-
typedef SparseMatrixTree<complex<double>>
SparseMatrixTreecd¶
-
typedef SparseMatrixTree<double>
SparseMatrixTreed¶
-
using
SparseMatrixTrees= vector<SparseMatrixTree<T>>¶
-
typedef SparseMatrixTrees<complex<double>>
SparseMatrixTreescd¶
-
typedef SparseMatrixTrees<double>
SparseMatrixTreesd¶
-
typedef SparseMatrixTree<complex<double>>
-
file
SparseMatrixTreeFunctions.h - #include “TreeClasses/SparseMatrixTree.h”#include “TreeClasses/SOPMatrixTrees.h”#include “TreeClasses/MatrixTree.h”#include “TreeClasses/WorkMemory.h”
-
file
SparseMatrixTreeFunctions_Implementation.h - #include “TreeClasses/SparseMatrixTreeFunctions.h”#include “TreeClasses/MatrixTreeFunctions.h”#include “TreeClasses/SparseTensorTree.h”#include “Core/TensorBLAS.h”
-
file
SparseNodeAttribute.h - #include “SparseTree.h”#include “NodeAttribute.h”
Variables
-
shared_ptr<SparseTree>
active_¶ TreeMarker which marks whether a node is active_ or not.
-
vector<A>
attributes_ Attributes only at every active_ node.
-
shared_ptr<SparseTree>
-
file
SparseTensorTree.h - #include “TreeClasses/SparseNodeAttribute.h”#include “TreeClasses/TensorTree.h”
-
file
SparseTree.h - #include “NodeAttribute.h”#include “TreeShape/Tree.h”#include “TreeOperators/MultiLeafOperator.h”#include “TreeOperators/SumOfProductsOperator.h”#include <map>#include <chrono>
-
file
SpectralDecompositionTree.h - #include “NodeAttribute.h”#include “Core/Matrix.h”#include “TreeClasses/MatrixTreeFunctions.h”#include “Core/Vector.h”
Typedefs
-
typedef SpectralDecompositionTree<complex<double>>
SpectralDecompositionTreecd¶
-
typedef SpectralDecompositionTree<double>
SpectralDecompositionTreed¶
Functions
-
template<typename
T>
voidcanonicalTransformation(TensorTree<T> &Psi, const Tree &tree, bool orthogonal = false)¶
-
template<typename
T>
MatrixTree<T>sqrt(MatrixTree<T> X, const Tree &tree)¶
-
template<typename
T>
SpectralDecompositionTree<T>inverse(SpectralDecompositionTree<T> X, double eps = 1e-7)¶
-
template<typename
T>
MatrixTree<T>inverse(MatrixTree<T> X, const Tree &tree, double eps = 1e-7)¶
-
template<typename
T>
MatrixTree<T>toMatrixtree(const SpectralDecompositionTree<T> &X, const Tree &tree)¶
-
typedef SpectralDecompositionTree<complex<double>>
-
file
SymMatrixTree.h Typedefs
-
using
SymMatrixTrees= vector<SymMatrixTree>¶
-
using
-
file
SymMatrixTreeFunctions.h
-
file
SymTensorTree.h - #include “MatrixTensorTreeFunctions.h”#include “SymMatrixTree.h”
Functions
-
bool
isWorking(const SymTensorTree &Psi, const Tree &tree)¶
-
void
symDotProduct(const SymTensorTree &Bra, const SymTensorTree &Ket, const Tree &tree)¶
-
template<typename
T>
voidcreateWeighted(TensorTree<T> &weighted, TensorTree<T> &down, const TensorTreecd &up, const Tree &tree)¶
-
bool
-
file
TensorTree.h - #include “NodeAttribute.h”#include “TreeShape/Tree.h”#include “Core/Tensor.h”#include <random>
Functions
-
TensorTree()¶ Default constructor without memory allocation.
-
TensorTree(istream &is)¶ Construct TensorTree from stream.
-
TensorTree(const string &filename)¶ Construct TensorTree from file.
-
TensorTree(mt19937 &gen, const Tree &tree, bool delta_lowest = true)¶ Create tensor tree and occupy the coefficients.
-
~TensorTree() Default destructor.
-
void
initialize(const Tree &tree)¶ Create Tensors for all nodes.
Allocate memory. Call only after initializing TreeMarker. Requires default constructor.
-
void
read(istream &is)¶ (File) I/O read TensorTree from stream (binary format)
-
void
write(ostream &os) const Write TensorTree to stream (binary format)
-
void
write(const string &filename, bool append = true) const¶ Write TensorTree to file (binary format)
-
TensorTree &
operator+=(const TensorTree<T> &R)¶ Arithmetic operators.
-
TensorTree &
operator-=(const TensorTree<T> &R)¶
-
TensorTree
operator+(const TensorTree<T> &R)¶
-
TensorTree
operator-(const TensorTree<T> &R)¶
-
TensorTree
operator*(T c)¶
-
TensorTree
operator/(T c)¶
-
template<typename
T>
voidorthogonal(TensorTree<T> &Psi, const Tree &tree)¶
-
template<typename
T>
voidqrOrthogonal(TensorTree<T> &Psi, const Tree &tree)¶
-
template<typename
T>
voidorthonormal(TensorTree<T> &Psi, const Tree &tree)¶
-
template<typename
T>
ostream &operator<<(ostream &os, const TensorTree<T> &t)¶
-
template<typename
T>
istream &operator>>(istream &is, TensorTree<T> &t)¶
-
template<typename
T>
TensorTree<T>operator*(T c, TensorTree<T> R)¶
-
template<typename
T>
TensorTree<T>operator/(T c, TensorTree<T> R)¶
-
-
file
TensorTree_Implementation.h - #include “TensorTree.h”#include “Core/Tensor_Extension.h”
Functions
-
template<typename
T>
voidorthogonal(TensorTree<T> &Psi, const Tree &tree)
-
template<typename
T>
voidqrOrthogonal(TensorTree<T> &Psi, const Tree &tree)
-
template<typename
T>
voidorthonormal(TensorTree<T> &Psi, const Tree &tree)
-
template<typename
T>
ostream &operator<<(ostream &os, const TensorTree<T> &t)
-
template<typename
T>
istream &operator>>(istream &is, TensorTree<T> &t)
-
template<typename
-
file
TensorTreeFunctions.h - #include “TreeClasses/SpectralDecompositionTree.h”
-
file
TensorTreeFunctions_Implementation.h - #include “TensorTreeFunctions.h”
-
file
TreeIO.h - #include “TreeClasses/MatrixTreeFunctions.h”#include “TreeClasses/TensorTree.h”#include “TreeClasses/SparseMatrixTree.h”
-
file
TreeTransformation.h - #include “TreeClasses/MatrixTreeFunctions.h”
-
file
TreeTransformation_Implementation.h - #include “TreeClasses/TreeTransformation.h”#include “TreeClasses/SpectralDecompositionTree.h”
-
file
WorkMemory.h - #include “TensorTree.h”
-
file
ActiveCounter.h - #include “TreeClasses/NodeAttribute.h”#include “TreeOperators/SumOfProductsOperator.h”#include “TreeClasses/SparseMatrixTree.h”
Functions
-
size_t
nActives(const SparseMatrixTreecd &hmat, const MLOcd &M, const SparseMatrixTreecd &hcon, const Node &node)¶
-
size_t
-
file
CoordinateTransformation.h - #include “Core/Vector.h”
-
file
DeltaOperator.h - #include “Core/Matrix.h”#include “Core/Tensor.h”#include “TreeClasses/SparseMatrixTreeFunctions.h”#include “Core/TensorBLAS.h”
Functions
-
Matrixcd
product(const DeltaOperator &w, const Matrixcd &r, DeltaMemory *mem_ptr)¶
-
Matrixcd
-
file
FortranOperator.h - #include “TreeOperators/LeafOperator.h”
Typedefs
-
typedef function<void(int *, int *, double *, double *, int *, double *, double *, double *)>
FortranSystemH¶
-
typedef function<void(int *, int *, double *, double *, int *, double *, double *, double *)>
-
file
FortranSOP.h - #include “TreeOperators/Hamiltonian.h”#include “Core/Vector.h”#include “TreeOperators/FortranOperator.h”#include “Core/Matrix.h”
Typedefs
-
typedef TensorTreecd
Wavefunction
Functions
-
void
ApplyFortranDDX(complex<double> hPsi[], complex<double> Psi[], const LeafInterface &phys, int dim)¶
-
void
ApplyFortranKIN(complex<double> hPsi[], complex<double> Psi[], const LeafInterface &phys, int dim)¶
-
typedef TensorTreecd
-
file
Hamiltonian.h - #include “TreeOperators/SumOfProductsOperator.h”
-
file
LeafFunction.h - #include “LeafOperator.h”
Typedefs
-
using
LeafFun= function<void(const LeafInterface&, Tensor<T>&, const Tensor<T>&)>¶
-
typedef LeafFunPair<complex<double>>
LeafFunPaircd¶
-
typedef LeafFunPair<double>
LeafFunPaird¶
-
typedef LeafFunction<complex<double>>
LeafFunctioncd¶
Functions
-
LeafFunction()¶
-
~LeafFunction()
-
void
apply(const LeafInterface &grid, Tensor<T> &hAcoeff, const Tensor<T> &Acoeff) const¶
-
using
-
file
LeafMatrix.h - #include “LeafOperator.h”#include “Core/Matrix.h”#include “TreeShape/Leaf.h”
Functions
-
Matrixcd
toMatrix(const LeafOperatorcd &h, const Leaf &leaf)¶
-
Matrixd
toMatrix(const LeafOperatord &h, const Leaf &leaf)¶
-
LeafMatrix()¶
-
~LeafMatrix()
-
virtual void
apply(const LeafInterface &grid, Tensor<T> &hAcoeff, const Tensor<T> &Acoeff) const
Variables
-
Matrix<T>
h_
-
Matrixcd
-
file
LeafOperator.h - #include “Core/Tensor.h”#include “TreeShape/LeafTypes/LeafInterface.h”
Typedefs
-
typedef LeafOperator<complex<double>>
LeafOperatorcd¶
-
typedef LeafOperator<double>
LeafOperatord¶
-
typedef LeafOperator<complex<double>>
-
file
MultiLeafOperator.h - #include “Core/Tensor.h”#include “TreeShape/Tree.h”#include “TreeClasses/TensorTree.h”#include “LeafOperator.h”#include “LeafFunction.h”#include “LeafMatrix.h”#include “PotentialOperator.h”
Typedefs
-
using
MLO= MultiLeafOperator<T>¶
Variables
-
vector<shared_ptr<LeafOperator<T>>>
leafOperators_¶ These are the SPOs.
-
vector<size_t>
targetLeaves_¶ These are the modes the SPOs act on.
-
PotentialOperator
v_¶ The potential operator.
-
bool
hasV_¶ Is there a PotentialOperator?
-
using
-
file
Potential.h - #include “Core/Vector.h”#include “TreeShape/Tree.h”
-
file
PotentialOperator.h - #include “Core/stdafx.h”#include “TreeOperators/Potential.h”#include “TreeOperators/CoordinateTransformation.h”
-
file
SOPVector.h - #include “SumOfProductsOperator.h”
Functions
-
SOPVector()¶
-
-
file
SumOfProductsOperator.h - #include “MultiLeafOperator.h”
Typedefs
-
using
SOP= SumOfProductsOperator<T>¶
-
using
-
file
SumOfProductsOperator_Implementation.h - #include “TreeOperators/SumOfProductsOperator.h”
Functions
-
template<typename
T>
SumOfProductsOperator<T>operator+(const SumOfProductsOperator<T> &A, const SumOfProductsOperator<T> &B)¶
-
template<typename
-
file
contractCircuit.h - #include “TreeOperators/TensorOperators/contractSOP.h”#include “TreeOperators/SOPVector.h”
Functions
-
template<typename
T>
TensorTreeOperator<T>contractCircuit(const SOP<T> &S, const TensorTreeOperator<T> &U, size_t maxIter, const Tree &optree, ostream *os)¶ Calculate product of SOP operator with TTNO, i.e. A = S * U.
- Return
contracted TTNO A
- Template Parameters
T: base-type
- Parameters
S: Sum-of-product operator that is appliedU: contrcted OperatormaxIter: code will leave after max-Iterations if not convergedoptree: operator treeos: out-stream for output during optimization (optional)
-
template<typename
-
file
contractSOP.h - #include “TreeOperators/TensorOperators/TensorTreeOperator.h”#include “TreeOperators/TensorOperators/TTOMatrixTree.h”#include “TreeOperators/TensorOperators/TTOHoleTree.h”
-
file
TensorOperatorRepresentation.h
-
file
TensorTreeOperator.h - #include “TreeClasses/NodeAttribute.h”#include “TreeClasses/TensorTree.h”#include “TreeOperators/LeafMatrix.h”#include “TreeOperators/MultiLeafOperator.h”#include “TreeOperators/SumOfProductsOperator.h”
Typedefs
-
typedef TensorTreeOperator<double>
TensorTreeOperatord¶
-
typedef TensorTreeOperator<complex<double>>
TensorTreeOperatorcd¶
Functions
-
typedef TensorTreeOperator<double>
-
file
TTOcontraction.h - #include “TreeClasses/TensorTree.h”#include “TreeOperators/TensorOperators/TensorTreeOperator.h”#include “TreeOperators/TensorOperators/TTOrepresentation.h”
-
file
TTOcontraction_Implementation.h - #include “TreeOperators/TensorOperators/TTOcontraction.h”
-
file
TTOHoleTree.h - #include “TTOMatrixTree.h”
-
file
TTOMatrixTree.h - #include “TensorTreeOperator.h”#include “TreeClasses/MatrixTree.h”#include “TreeOperators/SumOfProductsOperator.h”
-
file
TTOrepresentation.h - #include “TreeClasses/TensorTree.h”#include “TreeOperators/TensorOperators/TensorTreeOperator.h”
-
file
TreeSOP.h - #include “TreeClasses/NodeAttribute.h”#include “TreeOperators/LeafOperator.h”
Typedefs
-
typedef vector<shared_ptr<LeafOperatorcd>>
LeafOperatorLib¶
-
typedef vector<NodeOperator>
NodeProductOperator¶
Functions
-
bool
IsActive(const NodeOperator &h, const NodeProductOperator &M)¶
-
void
print(const NodeSOPlist &sopl, const vector<string> &names, size_t indent)¶
-
typedef vector<shared_ptr<LeafOperatorcd>>
-
file
AbstractNode.h - #include “Core/stdafx.h”#include “NodePosition.h”
-
file
Edge.h - #include “TreeShape/Node.h”
-
file
Leaf.h - #include “Core/stdafx.h”#include “AbstractNode.h”#include “NodePosition.h”#include “LeafTypes/LeafInterface.h”
Functions
-
Leaf(istream &file, AbstractNode *up, NodePosition position)¶
-
Leaf(size_t dim, size_t mode, size_t type, size_t subtype, PhysPar par)¶
-
Leaf()¶
-
~Leaf()
-
void
CreatePrimitiveBasis(size_t type, size_t subtype, size_t dim)¶
-
void
info(ostream &os = cout) const¶
-
void
write(ostream &os = cout) const
-
size_t
nTotalNodes() const¶
-
size_t
nNodes() const¶
-
size_t
nLeaves() const¶
-
AbstractNode *
nextNode()¶
-
AbstractNode *
nextSCFNode(AbstractNode *in)¶
-
AbstractNode *
nextNodeManthe()¶
-
int &
mode() const¶
-
size_t
Type() const¶
-
size_t
dim() const¶
-
int
type() const¶
-
const LeafInterface &
interface()¶
-
void
setPar(PhysPar par)¶
-
PhysPar
par() const¶
-
double
omega() const¶
-
double
r0() const¶
-
double
wfr0() const¶
-
double
wfOmega() const¶
-
void
update(const NodePosition &p)¶
-
void
updatePosition(const NodePosition &p)¶
-
void
setParent(AbstractNode *node)¶
-
-
file
DVRBasis.h - #include “Core/Tensor.h”#include “LeafInterface.h”#include “Core/Matrix.h”#include “Core/Vector.h”
-
file
FFTGrid.h - #include “LeafInterface.h”#include “Core/Matrix.h”#include “Core/Vector.h”#include “Core/Tensor.h”
-
file
HO_Basis.h - #include “Util/SimultaneousDiagonalization.h”#include “DVRBasis.h”
-
file
LeafInterface.h - #include “Core/Tensor.h”
-
file
LegendrePolynomials.h - #include <iostream>#include “DVRBasis.h”
-
file
SpinGroup.h - #include “LeafInterface.h”#include “Core/Matrix.h”#include “Core/Vector.h”#include “Core/Tensor.h”#include <random>#include “Util/QMConstants.h”
-
file
LinearizedLeaves.h - #include “Leaf.h”
-
file
Node.h - #include “Core/stdafx.h”#include “AbstractNode.h”#include “Leaf.h”#include “NodePosition.h”
Functions
-
Node()¶
-
Node(istream &file, Node *up, const NodePosition &position)¶
-
~Node()
-
void
initialize(istream &file, Node *up, const NodePosition &position)¶
-
void
info(ostream &os = cout) const
-
void
write(ostream &os) const
-
size_t
nTotalNodes() const
-
size_t
nNodes() const
-
size_t
nLeaves() const
-
int
type() const
-
bool
isBottomlayer() const¶
-
bool
isToplayer() const¶
-
size_t
childIdx() const¶
-
size_t
parentIdx() const¶
-
int
nChildren() const¶
-
const TensorShape &
shape()¶
-
void
expandChild(size_t i)¶
-
NodePosition
position() const¶
-
auto
begin() const¶ Swipe bottom-up over attributes_ at every active_ node.
-
auto
end() const¶ Swipe bottom-up over attributes_ at every active_ node.
-
void
setAddress(int newaddress)¶
-
int
address() const¶
-
AbstractNode *
nextNode()
-
AbstractNode *
nextSCFNode(AbstractNode *in)
-
AbstractNode *
nextNodeManthe()
-
unique_ptr<AbstractNode>
downUnique(size_t i)¶
-
void
setParent(AbstractNode *up)
-
void
update(const NodePosition &p)
-
void
updatePosition(const NodePosition &p)¶
-
void
updatennodes()¶
-
void
updateTDim()¶
-
void
resetCounters()¶
Variables
-
size_t
nTotalNodes_¶
-
size_t
nNodes_¶
-
size_t
nLeaves_¶
-
TensorShape
tensorDim_¶
-
AbstractNode *
parent_
-
vector<unique_ptr<AbstractNode>>
child_¶
-
int
nextNodeNum_= {0}¶
-
size_t
nextNodeNumFortran_= {0}¶
-
NodePosition
position_
-
int
address_
-
int
nodeType_
-
bool
bottomLayer_¶
-
-
file
NodePosition.h - #include “Core/stdafx.h”
Functions
-
NodePosition()¶
-
~NodePosition()
-
friend NodePosition
operator*(NodePosition p, size_t k)¶
-
friend NodePosition
operator*(NodePosition p, NodePosition q)¶
-
void
info(ostream &os = cout, bool print_layer = false) const¶
-
size_t
childIdx() const¶
-
size_t
layer() const¶
-
-
file
Tree.h - #include “Node.h”#include “Edge.h”#include “LinearizedLeaves.h”#include <map>#include <numeric>
-
file
Tree.h - #include “TreeNode.h”#include <map>
Functions
-
TreeNode
Group(const TreeNode &node, const NodeContent &c)¶
-
TreeNode
-
file
TreeFactory.h - #include “TreeShape/Tree.h”
-
file
BS_integrator.h - #include “Core/stdafx.h”#include <functional>#include “Core/Tensor.h”
-
file
FFT.h - #include “Core/Tensor.h”
-
file
FFTCooleyTukey.h - #include “Core/Vector.h”#include “Core/stdafx.h”#include “Core/Tensor.h”#include <bitset>
-
file
GateOperators.h - #include “Core/Matrix.h”#include “TreeOperators/SumOfProductsOperator.h”#include “TreeOperators/SOPVector.h”
Functions
-
Matrixcd
sigma_x()¶ Rationale:
Small library for Quantum Circuits
Only contains functions that are needed for unit testing
-
SOPVectorcd
QFT(size_t mode_start, size_t n_bit, bool adjungate = false, size_t approx = 0)¶
-
Matrixcd
-
file
GradientDescent.h - #include “Core/stdafx.h”
-
file
GradientDescent_Implementation.h - #include “Util/GradientDescent.h”
-
file
JacobiRotationFramework.h - #include “Core/Matrix.h”
-
file
Lanzcos.h - #include <glob.h>#include “Core/TensorShape.h”#include “Core/Tensor.h”#include “Core/Matrix.h”#include “Core/Vector.h”
-
file
MultiIndex.h - #include “Core/stdafx.h”
-
file
normal_modes.h - #include “TreeOperators/Potential.h”#include “TreeOperators/CoordinateTransformation.h”#include “TreeOperators/Hamiltonian.h”
Functions
-
Vectord
getx0(const Tree &tree, const CoordinateTransformation &U)¶
-
void
find_minimum(const Hamiltonian &H, const Tree &tree)¶
-
Vectord
-
file
Overlaps.h - #include “TreeClasses/TensorTree.h”
Functions
-
void
wavefunctionOverlap(const string &file1, const string &file2, const Tree &tree, OverlapType = diagonal)¶
-
void
wavefunctionOverlap(const vector<TensorTreecd> &Psi, const vector<TensorTreecd> &Chi, const Tree &tree, OverlapType = full)¶
-
void
-
file
QMConstants.h - #include “Core/stdafx.h”
-
file
qutree_rng.h - #include <random>
-
file
RandomMatrices.h - #include “Core/Matrix.h”#include <random>
-
file
RandomProjector.h - #include <random>#include “Core/Matrix.h”#include “Core/Tensor.h”
-
file
RandomProjector_Implementation.h - #include “Util/RandomProjector.h”#include “Core/MatrixBLAS.h”
-
file
RungeKutta4.h - #include <iostream>#include <fstream>#include <functional>
-
file
SimultaneousDiagonalization.h - #include “Core/Matrix.h”#include “Core/Vector.h”#include “Core/stdafx.h”#include <random>#include “JacobiRotationFramework.h”
-
file
string_ext.h - #include <string>
-
file
TreeNode.h - #include <utility>#include <vector>#include <iostream>#include “Core/TensorShape.h”
Typedefs
-
typedef vector<size_t>
Path¶
-
typedef vector<size_t>
-
file
WeightedSimultaneousDiagonalization.h - #include “Core/Matrix.h”#include “Core/Vector.h”#include “JacobiRotationFramework.h”
Variables
-
[anonymous]
WSD= WeightedSimultaneousDiagonalization¶
-
[anonymous]
-
file
ApplyFirstOrder.cpp - #include “Applications/ApplyFirstOrder.h”#include “Util/RandomProjector.h”#include “TreeClasses/EntropyTree.h”#include “TreeClasses/SparseTree.h”#include “Applications/TreeApplyOperator.h”#include “TreeClasses/TreeIO.h”
-
file
CMFIntegrator.cpp - #include “Applications/CMFIntegrator.h”#include <chrono>#include “TreeClasses/TreeIO.h”
Variables
-
constexpr bool
eom_spf= true¶
-
constexpr bool
-
file
Eigenstates.cpp - #include “Applications/Eigenstates.h”#include “TreeClasses/SpectralDecompositionTree.h”#include <iomanip>
Functions
-
Vectord
propagatorEnergies(const Wavefunction &Psi, const Tree &tree, double out)
-
Vectord
Eigenstate(Wavefunction &Psi, const Hamiltonian &H, const Tree &tree, const Tree &cdvrtree)¶
-
void
Status(const Vectord &eigenvalues, const Vectord &propergatorev, const Matrixcd &S, ostream &os)
-
void
Eigenstates(IntegratorVariables &ivar)
-
Vectord
-
file
SCF.cpp - #include “Applications/SCF.h”#include “TreeClasses/SparseMatrixTreeFunctions.h”#include “TreeClasses/HamiltonianRepresentation.h”#include “TreeClasses/TreeIO.h”#include “Core/TensorBLAS.h”#include <iomanip>#include <chrono>
Functions
-
void
apply(Tensorcd &HA, const Tensorcd &A, const SparseMatrixTreescd &hMats, const SparseMatrixTreescd &hCons, const SparseMatrixTreecd &hCorr, const SparseMatrixTreecd &hConCorr, const MatrixTreecd *rho, const Hamiltonian &H, const Node &node, const vector<size_t> &n_actives, Tensorcd *work)¶
-
void
apply(Tensorcd &HA, const Tensorcd &A, const HamiltonianRepresentation &hrep, const Hamiltonian &H, const Node &node)¶
-
Tensorcd
apply(const Tensorcd &A, const HamiltonianRepresentation &hrep, const Hamiltonian &H, const Node &node)¶
-
void
testKrylovSpace(const KrylovSpace &space, const HamiltonianRepresentation &hrep, const Hamiltonian &H, const Node &node)¶
-
void
solveKrylovSpace(KrylovSpace &krylov, Tensorcd Psi, const HamiltonianRepresentation &hrep, const Hamiltonian &H, const Node &node, size_t krylov_size, double conversion)¶
-
void
imaginaryTimePropagation(Tensorcd &Psi, const KrylovSpace &kry, double beta)¶
-
void
diagonalizeKrylov(Tensorcd &Psi, const KrylovSpace &kry)¶
-
void
outputSCF(Tensorcd Psi, const HamiltonianRepresentation &hrep, const Hamiltonian &H, const Node &node)¶
-
void
scf(SCF_parameters &par)
-
void
-
file
TreeApplyOperator.cpp - #include “Applications/TreeApplyOperator.h”#include “Core/Tensor_Extension.h”#include “Util/RandomProjector_Implementation.h”#include “TreeOperators/DeltaOperator.h”#include “TreeClasses/TreeIO.h”
-
file
TreeApplyOperatorDynamic.cpp - #include “Applications/TreeApplyOperatorDynamic.h”#include “TreeClasses/TreeIO.h”#include “Util/RandomProjector.h”#include “TreeClasses/EntropyTree.h”
-
file
JacobiRotationFramework.cpp - #include “Util/JacobiRotationFramework.h”
-
file
Matrix_Instantiations.cpp - #include “Core/Matrix_Implementation.h”#include “Core/Matrix_Extension_Implementation.h”#include “Util/RandomProjector_Implementation.h”
Functions
-
template Vector<complex<double> > multAB< cd >(const Matrix < complex< double >> & A, const Vector < complex< double >> & B) Arithmetic.
-
template Vector<double> multAB< doub >(const Matrix < double > & A, const Vector < double > & B)
-
template Vector<cd> multATB< cd >(const Matrix < cd > & A, const Vector < cd > & B)
-
template Vector<d> multATB< d >(const Matrix < d > & A, const Vector < d > & B)
-
template Matrix<double> multAB(const Matrix < double > & A, const Matrix < double > & B)
-
template Matrix<cd> multAB(const Matrix < cd > & A, const Matrix < cd > & B)
-
template Matrix<double> multATB(const Matrix < double > & A, const Matrix < double > & B)
-
template Matrix<cd> multATB(const Matrix < cd > & A, const Matrix < cd > & B)
-
template Matrix<cd> addAB(const Matrix < cd > & A, const Matrix < cd > & B)
-
template Matrix<doub> addAB(const Matrix < doub > & A, const Matrix < doub > & B)
-
template Matrix<doub> substAB(const Matrix < doub > & A, const Matrix < doub > & B)
-
template Matrix<cd> substAB< cd >(const Matrix < cd > & A, const Matrix < cd > & B)
-
template Matrix<cd> multscalar< cd, cd >(const cd sca, const Matrix < cd > & B)
-
template Matrix<cd> multscalar< cd, doub >(const double sca, const Matrix < cd > & B)
-
template Matrix<doub> multscalar< doub, doub >(const double sca, const Matrix < doub > & B)
-
template Matrix<cd> unitarySimilarityTrafo< cd >(const Matrix < cd > & A, const Matrix < cd > & B)
-
template Matrix<double> unitarySimilarityTrafo< doub >(const Matrix < double > & A, const Matrix < double > & B)
-
template Matrix<cd> re(const Matrix < cd > & A)
-
template Matrix<d> re(const Matrix < d > & A)
-
template Matrix<cd> identityMatrix(size_t dim) Convenience & Management.
Convenience & Management.
- Return
identity-matrix
- Template Parameters
T: Type of identity matrix
- Parameters
dim: dimension
-
template double residual(const Matrixcd & A, const Matrixcd & B)
-
template double residual(const Matrixd & A, const Matrixd & B)
-
template Matrix<cd> regularize(const Matrix < cd > & A, double eps)
-
template Matrix<d> regularize(const Matrix < d > & A, double eps)
-
template Matrix<cd> merge(const Matrix < cd > & A, const Matrix < cd > & B, const Matrix < cd > & AB)
-
template Matrix<d> merge(const Matrix < d > & A, const Matrix < d > & B, const Matrix < d > & AB)
-
template Matrix<cd> subMatrix(const Matrix < cd > A, size_t dim1, size_t dim2)
-
template Matrix<d> subMatrix(const Matrix < d > A, size_t dim1, size_t dim2)
-
template ostream& operator<<< cd >(ostream & os, const Matrixcd & A)
-
template istream& operator>>< cd >(istream & is, Matrixcd & A)
-
template ostream& operator<<< doub >(ostream & os, const Matrix < doub > & A)
-
template istream& operator>>< doub >(istream & is, Matrix < doub > & A)
-
template Matrix<double> euclideanDistance(const Matrix < double > & A)
-
template SpectralDecompositioncd sqrt(SpectralDecompositioncd X) Matrix Extension.
-
template SpectralDecompositiond sqrt(SpectralDecompositiond X)
-
template SpectralDecompositioncd inverse(SpectralDecompositioncd X, double eps)
-
template SpectralDecompositiond inverse(SpectralDecompositiond X, double eps)
-
template Matrixcd toMatrix(const SpectralDecompositioncd & X)
-
template Matrixd toMatrix(const SpectralDecompositiond & X)
-
template SpectralDecomposition<double> reduceRank(const SpectralDecomposition < double > & x, size_t rank)
-
template SpectralDecomposition<cd> reduceRank(const SpectralDecomposition < cd > & x, size_t rank)
-
-
file
MatrixBLAS.cpp - #include “Core/MatrixBLAS.h”#include <cblas.h>#include <lapacke.h>
-
file
stdafx.cpp - #include “Core/stdafx.h”
Functions
-
double
conj(double x)
-
int
conj(const int d)
-
double
-
file
Tensor_Extension_Instantiations.cpp - #include “Core/Tensor_Extension_Implementation.h”
Typedefs
-
typedef complex<double>
cd
-
typedef double
d
-
typedef complex<double>
-
file
Tensor_Instantiations.cpp - #include “Core/Tensor_Implementation.h”
Typedefs
-
typedef complex<double>
cd
-
typedef double
doub
-
typedef double
d
Functions
-
template Tensor<cd> productElementwise(const Tensor < cd > & A, const Tensor < cd > & B)
-
template Tensor<d> productElementwise(const Tensor < d > & A, const Tensor < d > & B)
-
template Tensor<cd> matrixTensor< cd, cd >(const Matrix < cd > & A, const Tensor < cd > & B, size_t mode)
-
template void matrixTensor< cd, cd >(Tensor < cd > & C, const Matrix < cd > & A, const Tensor < cd > & B, size_t mode, bool zero)
-
template Tensor<cd> tMatrixTensor< cd, cd >(const Matrix < cd > & A, const Tensor < cd > & B, size_t mode)
-
template Tensor<cd> multStateAB(const Matrix < cd > & A, const Tensor < cd > & B)
-
template Tensor<cd> multStateArTB< cd, cd >(const Matrix < cd > & A, const Tensor < cd > & B)
-
template void multStateArTB< cd, cd >(Tensor < cd > & C, const Matrix < cd > & A, const Tensor < cd > & B)
-
template void gramSchmidt< cd >(Tensor < cd > & A)
-
template void multStateAB< cd, cd >(Tensor < cd > & C, const Matrix < cd > & A, const Tensor < cd > & B, bool zero)
-
template Tensor<cd> project< cd >(const Tensor < cd > & A, const Tensor < cd > & B)
-
template Tensor<cd> projectOut< cd >(const Tensor < cd > & A, const Tensor < cd > & B)
-
template Tensor<cd> projectOrthogonal< cd >(const Tensor < cd > & A, const Tensor < cd > & B)
-
template void multAdd< cd, cd >(Tensor < cd > & A, const Tensor < cd > & B, cd coeff)
-
template Tensor<cd> conj< cd >(Tensor < cd > A)
-
template double residual(Tensorcd A, const Tensorcd & B)
-
template Matrix<cd> toMatrix(const Tensor < cd > & A)
-
template Matrix<cd> moveToMatrix(Tensor < cd > & A)
-
template Tensor<cd> toTensor(const Matrix < cd > & B)
-
template Matrix<cd> toMatrix(const Tensor < cd > & A, size_t mode)
-
template Tensor<cd> toTensor(const Matrix < cd > & B, const TensorShape & shape, size_t mode)
-
template Tensor<cd> moveToTensor(Matrix < cd > & B)
-
template void contraction< cd >(Matrix < cd > & S, const Tensor < cd > & A, const Tensor < cd > & B, size_t before, size_t active1, size_t active2, size_t behind)
-
template void matrixTensor< cd >(Tensor < cd > & C, const Matrix < cd > & A, const Tensor < cd > & B, size_t before, size_t activeC, size_t activeB, size_t after, bool zero)
-
template Matrix<cd> contraction(const Tensor < cd > & A, const Tensor < cd > & B, size_t k)
-
template void contraction(Matrix < cd > & S, const Tensor < cd > & A, const Tensor < cd > & B, size_t k, bool zero)
-
template Tensor<cd> qr(const Tensor < cd > & A)
-
template Tensor<cd> qr(const Tensor < cd > & A, size_t mode)
-
template void tensorMatrix(Tensor < cd > & C, const Tensor < cd > & B, const Matrix < cd > & A, size_t mode, bool zero)
-
template Tensor<cd> tensorMatrix(const Tensor < cd > & B, const Matrix < cd > & A, size_t mode)
-
template ostream& operator<<< cd >(ostream &, const Tensor < cd > &)
-
template istream& operator>>< cd >(istream &, Tensor < cd > &)
-
template bool operator==< cd >(const Tensor < cd > & A, const Tensor < cd > & B)
-
template Tensor<double> matrixTensor< doub, doub >(const Matrix < double > & A, const Tensor < double > & B, size_t mode)
-
template void matrixTensor< doub, doub >(Tensor < double > & C, const Matrix < double > & A, const Tensor < double > & B, size_t mode, bool zero)
-
template void tensorMatrix(Tensor < double > & C, const Tensor < double > & B, const Matrix < double > & A, size_t mode, bool zero)
-
template Tensor<double> tensorMatrix(const Tensor < double > & B, const Matrix < double > & A, size_t mode)
-
template Tensor<double> tMatrixTensor< doub, doub >(const Matrix < double > & A, const Tensor < double > & B, size_t mode)
-
template Tensor<double> multStateAB(const Matrix < double > & A, const Tensor < double > & B)
-
template Tensor<d> projectOut< d >(const Tensor < d > & A, const Tensor < d > & B)
-
template Tensor<double> multStateArTB< doub, doub >(const Matrix < double > & A, const Tensor < double > & B)
-
template void multStateArTB< doub, doub >(Tensor < doub > & C, const Matrix < doub > & A, const Tensor < doub > & B)
-
template void gramSchmidt< double >(Tensor < double > & A)
-
template void multStateAB< doub, doub >(Tensor < double > & C, const Matrix < double > & A, const Tensor < double > & B, bool zero)
-
template void multAdd< doub, doub >(Tensor < double > & A, const Tensor < double > & B, doub coeff)
-
template Tensor<double> conj< double >(Tensor < double > A)
-
template double residual(Tensord A, const Tensord & B)
-
template Matrix<double> toMatrix(const Tensor < double > & A)
-
template Matrix<d> moveToMatrix(Tensor < d > & A)
-
template Tensor<double> toTensor(const Matrix < double > & B)
-
template void contraction< doub >(Matrix < doub > & S, const Tensor < doub > & A, const Tensor < doub > & B, size_t before, size_t active1, size_t active2, size_t behind)
-
template void matrixTensor< doub >(Tensor < doub > & C, const Matrix < doub > & A, const Tensor < doub > & B, size_t before, size_t activeC, size_t activeB, size_t after, bool zero)
-
template Matrix<doub> contraction(const Tensor < doub > & A, const Tensor < doub > & B, size_t k)
-
template void contraction(Matrix < doub > & S, const Tensor < doub > & A, const Tensor < doub > & B, size_t k, bool zero)
-
template Tensor<doub> qr(const Tensor < doub > & A)
-
template Tensor<doub> qr(const Tensor < doub > & A, size_t mode)
-
template ostream& operator<<< doub >(ostream &, const Tensor < doub > &)
-
template istream& operator>>< doub >(istream &, Tensor < doub > &)
-
template bool operator==< doub >(const Tensor < doub > & A, const Tensor < doub > & B)
-
template void multAdd< cd, double >(Tensor < cd > & A, const Tensor < cd > & B, double coeff) Mixed double/complex<double>
-
template Tensor<cd> matrixTensor< cd, doub >(const Matrix < doub > & A, const Tensor < cd > & B, size_t mode)
-
template Tensor<cd> tMatrixTensor< cd, doub >(const Matrix < doub > & A, const Tensor < cd > & B, size_t mode)
-
template Tensord ones< double >(const TensorShape & shape)
-
template Tensorcd ones< complex< double > >(const TensorShape & shape)
-
template Tensord rand< double >(const TensorShape & shape)
-
template Tensorcd rand< complex< double > >(const TensorShape & shape)
-
typedef complex<double>
-
file
TensorBLAS.cpp - #include “Core/TensorBLAS.h”#include <cblas.h>#include <numeric>#include “Core/MatrixBLAS.h”
Defines
-
swap(type, x, y)¶
Typedefs
-
typedef complex<double>
cd ======================================================================== Template Instantiations
-
typedef double
d
Functions
-
template<typename
T, typenameU>
voidmatrixTensor1(Tensor<T> &C, const Matrix<U> &h, const Tensor<T> &B, size_t before, size_t active, size_t activeC, size_t after, bool zero)
-
template<typename
T, typenameU>
voidmatrixTensor2(Tensor<T> &C, const Matrix<U> &h, const Tensor<T> &B, Tensor<T> &D, size_t before, size_t active, size_t activeC, size_t after, bool zero)
-
template<typename
T, typenameU>
voidmatrixTensor3(Tensor<T> &hKet, const Matrix<U> &h, const Tensor<T> &Ket, Tensor<T> &Ket_work, Tensor<T> &hKet_work, size_t A, size_t B, size_t B2, size_t C, bool zero)
-
template<typename
T>
voidcontraction2(Matrix<T> &h, const Tensor<T> &bra, const Tensor<T> &ket, Tensor<T> &bra_work, Tensor<T> &ket_work, size_t A, size_t B, size_t B2, size_t C, bool zero)
-
template<typename
T, typenameU>
voidmatrixTensorBLAS(Tensor<T> &C, Tensor<T> &workC, const Matrix<U> &A, const Tensor<T> &B, size_t mode, bool zero) Wrapper for matrix-Tensor product.
==== Wrappers ====
======================================================================== Wrappers for matrixTensor product and contraction
-
template<typename
T, typenameU>
voidmatrixTensorBLAS(Tensor<T> &C, const Matrix<U> &A, const Tensor<T> &B, size_t mode, bool zero)
-
template<typename
T>
voidcontractionBLAS(Matrix<T> &h, Tensor<T> &workA, Tensor<T> &workB, const Tensor<T> &A, const Tensor<T> &B, size_t mode, bool zero)
-
template<typename
T>
voidcontractionBLAS(Matrix<T> &h, const Tensor<T> &A, const Tensor<T> &B, size_t mode, bool zero) Wrapper for matrix-Tensor product.
-
template<typename
T>
Matrix<T>contractionBLAS(const Tensor<T> &A, const Tensor<T> &B, size_t mode, bool zero)
-
template<typename
T, typenameU>
Tensor<T>matrixTensorBLAS(const Matrix<U> &A, const Tensor<T> &B, size_t mode, bool zero)
-
template<typename
T>
voidgeneral_contraction(const Tensor<T> &A, const Tensor<T> &B, Tensor<T> &result, const vector<size_t> &A_indices, const vector<size_t> &B_indices)
-
template<typename
T>
boolis_contraction_legal(const Tensor<T> &TensorA, const Tensor<T> &TensorB, vector<size_t> Acontraction, vector<size_t> Bcontraction)
-
template<typename
T>
voidgeneral_transpose_to_order(Tensor<T> &dst, const Tensor<T> &src, const vector<size_t> &form)
-
template<typename
T>
voidgeneral_transpose(Tensor<T> &dst, const Tensor<T> &src, size_t index_one, size_t index_two)
-
template<typename
T>
voidgeneral_transpose_bd(T *dst, const T *src, size_t a, size_t b, size_t c, size_t d, size_t e)
-
template<typename
T, typenameQ>
voidgeneral_contraction(const Tensor<T> &A, const Tensor<T> &B, Tensor<T> &result, const std::vector<std::pair<Q, Q>> &contraction_pairs)
-
template void matrixTensor1(Tensor < cd > & C, const Matrix < cd > & h, const Tensor < cd > & B, size_t before, size_t active, size_t activeC, size_t after, bool zero)
-
template void matrixTensor2(Tensor < cd > & C, const Matrix < cd > & h, const Tensor < cd > & B, Tensorcd & D, size_t before, size_t active, size_t activeC, size_t after, bool zero)
-
template void matrixTensor3(Tensor < cd > & hKet, const Matrix < cd > & h, const Tensor < cd > & Ket, Tensor < cd > & Ket_work, Tensor < cd > & hKet_work, size_t A, size_t B, size_t B2, size_t C, bool zero)
-
template void contraction2(Matrix < cd > & h, const Tensor < cd > & bra, const Tensor < cd > & ket, Tensor < cd > & bra_work, Tensor < cd > & ket_work, size_t A, size_t B, size_t B2, size_t C, bool zero)
-
template void transpose(double * dest, const double * src, size_t dim1, size_t dim2, double beta)
-
template void transpose(cd * dest, const cd * src, size_t dim1, size_t dim2, cd beta)
-
template void transpose2< complex< double >, 4 >(cd * dest, const cd * src, size_t lda, size_t ldb)
-
template void transposeAB(cd * dest, const cd * src, size_t A, size_t B, size_t C)
-
template void contraction2(Matrix < d > & h, const Tensor < d > & bra, const Tensor < d > & ket, Tensor < d > & bra_work, Tensor < d > & ket_work, size_t A, size_t B, size_t B2, size_t C, bool zero)
-
template void general_contraction(const Tensor < cd > & A, const Tensor < cd > & B, Tensor < cd > & result, const vector< size_t > & A_indices, const vector< size_t > & B_indices)
-
template void general_contraction(const Tensor < d > & A, const Tensor < d > & B, Tensor < d > & result, const vector< size_t > & A_indices, const vector< size_t > & B_indices)
-
template void general_transpose_bd(cd * dst, const cd * src, size_t a, size_t b, size_t c, size_t d, size_t e)
-
template void general_transpose_bd(d * dst, const d * src, size_t a, size_t b, size_t c, size_t d, size_t e)
-
template bool is_contraction_legal(const Tensor < cd > & TensorA, const Tensor < cd > & TensorB, vector< size_t > Acontraction, vector< size_t > Bcontraction)
-
template bool is_contraction_legal(const Tensor < d > & TensorA, const Tensor < d > & TensorB, vector< size_t > Acontraction, vector< size_t > Bcontraction)
-
template void general_transpose(Tensor < cd > & dst, const Tensor < cd > & src, size_t index_one, size_t index_two)
-
template void general_transpose(Tensor < d > & dst, const Tensor < d > & src, size_t index_one, size_t index_two)
-
template void general_transpose_to_order(Tensor < d > & dst, const Tensor < d > & src, const vector< size_t > & form)
-
template void general_transpose_to_order(Tensor < cd > & dst, const Tensor < cd > & src, const vector< size_t > & form)
-
template void general_contraction(const Tensor < cd > & A, const Tensor < cd > & B, Tensor < cd > & result, const std::vector< std::pair< int, int >> & contraction_pairs)
-
template void general_contraction(const Tensor < cd > & A, const Tensor < cd > & B, Tensor < cd > & result, const std::vector< std::pair< size_t, size_t >> & contraction_pairs)
-
template void general_contraction(const Tensor < d > & A, const Tensor < d > & B, Tensor < d > & result, const std::vector< std::pair< int, int >> & contraction_pairs)
-
template void general_contraction(const Tensor < d > & A, const Tensor < d > & B, Tensor < d > & result, const std::vector< std::pair< size_t, size_t >> & contraction_pairs)
-
template void matrixTensorBLAS(Tensor < cd > & C, Tensor < cd > & workC, const Matrix < cd > & A, const Tensor < cd > & B, size_t mode, bool zero) ==== Wrappers ====
-
template void matrixTensorBLAS(Tensor < cd > & C, const Matrix < cd > & A, const Tensor < cd > & B, size_t mode, bool zero)
-
template void contractionBLAS(Matrix < cd > & h, Tensor < cd > & workA, Tensor < cd > & workB, const Tensor < cd > & A, const Tensor < cd > & B, size_t mode, bool zero)
-
template void contractionBLAS(Matrix < cd > & h, const Tensor < cd > & A, const Tensor < cd > & B, size_t mode, bool zero)
-
template Tensor<cd> matrixTensorBLAS(const Matrix < cd > & A, const Tensor < cd > & B, size_t mode, bool zero)
-
template Matrix<cd> contractionBLAS(const Tensor < cd > & A, const Tensor < cd > & B, size_t mode, bool zero)
-
template void matrixTensorBLAS(Tensor < d > & C, Tensor < d > & workC, const Matrix < d > & A, const Tensor < d > & B, size_t mode, bool zero)
-
template void matrixTensorBLAS(Tensor < d > & C, const Matrix < d > & A, const Tensor < d > & B, size_t mode, bool zero)
-
template void contractionBLAS(Matrix < d > & h, Tensor < d > & workA, Tensor < d > & workB, const Tensor < d > & A, const Tensor < d > & B, size_t mode, bool zero)
-
template void contractionBLAS(Matrix < d > & h, const Tensor < d > & A, const Tensor < d > & B, size_t mode, bool zero)
-
template Tensor<d> matrixTensorBLAS(const Matrix < d > & A, const Tensor < d > & B, size_t mode, bool zero)
-
template Matrix<d> contractionBLAS(const Tensor < d > & A, const Tensor < d > & B, size_t mode, bool zero)
-
-
file
TensorShape.cpp - #include “Core/TensorShape.h”
Functions
-
size_t
ContractDimensionsBefore(const vector<size_t> &dim, size_t k)¶
-
vector<size_t>
ContractDimensionsBefore(const vector<size_t> &dim)¶
-
size_t
ContractDimensionsAfter(const vector<size_t> &dim, size_t k)¶
-
vector<size_t>
ContractDimensionsAfter(const vector<size_t> &dim)¶
-
ostream &
operator<<(ostream &os, const TensorShape &tdim)
-
istream &
operator>>(istream &is, TensorShape &tdim)
-
bool
operator==(const TensorShape &tdima, const TensorShape &tdimb)
-
bool
operator!=(const TensorShape &tdima, const TensorShape &tdimb)
-
TensorShape
replaceDimension(TensorShape shape, size_t target, size_t new_dimension)
-
vector<size_t>
indexMapping(size_t I, const TensorShape &shape)
-
size_t
indexMapping(const vector<size_t> &idx, const TensorShape &shape)
-
void
indexMapping(vector<size_t> &idxs, size_t I, const TensorShape &shape)
-
size_t
-
file
Vector_Instantiations.cpp - #include “Core/Vector_Implementation.h”
Typedefs
-
typedef complex<double>
cd
-
typedef double
d
Functions
-
template void normalize(Vectord & a)
-
template void normalize(Vectorcd & a)
-
template double residual(const Vectord & A, const Vectord & B)
-
template double residual(const Vectorcd & A, const Vectorcd & B)
-
template Vector<cd> reverse(const Vector < cd > & A)
-
template Vector<d> reverse(const Vector < d > & A)
-
template cd sum(const Vector < cd > & A)
-
template d sum(const Vector < d > & A)
-
template Vector<d> regularize(Vector < d > A, double eps)
-
template Vector<cd> regularize(Vector < cd > A, double eps)
-
template Vector<d> inverse(Vector < d > A, d eps)
-
template Vector<cd> inverse(Vector < cd > A, d eps)
-
typedef complex<double>
-
file
CDVR.cpp - #include “DVR/CDVR.h”
Functions
-
void
UpdateNodeDVRLocal(Tensorcd &dvr, const TreeGrids &grids, const TreeGrids &holegrids, const PotentialOperator &V, const Node &node, size_t part, bool out = false, ostream &os = cout)¶
-
void
UpdateNodeDVR(TensorTreecd &dvr, const TreeGrids &grids, const TreeGrids &holegrids, const PotentialOperator &V, const Tree &tree, size_t part, bool out, ostream &os)¶
-
void
UpdateEdgeDVRLocal(Matrixd &edgedvr, const TreeGrids &grids, const TreeGrids &holegrids, const PotentialOperator &V, const Node &node, size_t part, bool out = false, ostream &os = cout)¶
-
void
UpdateEdgeDVR(MatrixTreed &cdvr, const TreeGrids &grids, const TreeGrids &holegrids, const PotentialOperator &V, const Tree &tree, size_t part, bool out, ostream &os = cout)¶
-
void
-
file
cdvr_functions.cpp - #include “DVR/cdvr_functions.h”#include “Core/Tensor_Extension.h”#include “Core/TensorBLAS.h”
-
file
DeltaVTree.cpp - #include “DVR/DeltaVTree.h”
-
file
GridRepresentation.cpp - #include “GridRepresentation.h”#include “DVR/MatrixTensorTree.h”
-
file
MatrixTensorTree.cpp - #include “DVR/MatrixTensorTree.h”#include “TreeClasses/SpectralDecompositionTree.h”#include “Core/TensorBLAS.h”
Functions
-
bool
IsWorking_bottomup(const MatrixTensorTree &Psi, const Tree &tree, double eps)
-
bool
IsWorking_topdown(const MatrixTensorTree &Psi, const Tree &tree, double eps)
-
bool
IsWorking(const MatrixTensorTree &Psi, const Tree &tree, double eps)
-
bool
-
file
MatrixTensorTree.cpp - #include “TreeClasses/MatrixTensorTree.h”#include “TreeClasses/SpectralDecompositionTree.h”
Functions
-
bool
IsWorking_bottomup(const MatrixTensorTree &Psi, const Tree &tree, double eps)
-
bool
IsWorking_topdown(const MatrixTensorTree &Psi, const Tree &tree, double eps)
-
bool
IsWorking(const MatrixTensorTree &Psi, const Tree &tree, double eps)
-
bool
-
file
MatrixTensorTreeFunctions.cpp - #include “DVR/MatrixTensorTreeFunctions.h”
-
file
MatrixTensorTreeFunctions.cpp - #include “TreeClasses/MatrixTensorTreeFunctions.h”
-
file
SymXMatrixTrees.cpp - #include “DVR/SymXMatrixTrees.h”
-
file
TDDVR.cpp - #include <Core/TensorBLAS.h>#include “DVR/TDDVR.h”#include “TreeClasses/MatrixTreeFunctions.h”#include “TreeClasses/SparseMatrixTreeFunctions.h”#include “Util/WeightedSimultaneousDiagonalization.h”#include “TreeClasses/SymMatrixTreeFunctions.h”
Functions
-
vector<Matrixcd>
getXs(const vector<SparseMatrixTreecd> &Xs, const Node &node)¶
-
void
LayerGrid(TreeGrids &grids, Matrixcd &trafo, const vector<SparseMatrixTreecd> &Xs, Matrixcd w, const Node &node)¶
-
void
updateGrids(TreeGrids &grids, MatrixTreecd &trafo, const vector<SparseMatrixTreecd> &Xs, const MatrixTreecd &rho, const Tree &tree)¶
-
void
layerGrid(TreeGrids &grids, Matrixcd &trafo, vector<Matrixcd> xs, Matrixcd w, const Node &node)¶
-
vector<Matrixcd>
getX(const SymXMatrixTrees &Xs, const Node &node, bool up)¶
-
void
updateGrids(SymTreeGrid &sgrids, SymMatrixTree &u, const SymXMatrixTrees &xsym, const SymMatrixTree &rho, const Tree &tree)¶
-
vector<Matrixcd>
-
file
XMatrixTrees.cpp - #include “DVR/XMatrixTrees.h”#include <random>
Functions
-
Wavefunction
Regularize(Wavefunction Psi, const Tree &tree, double eps)
-
Matrixcd
BuildX(const Tensorcd &Phi, const Matrixcd &rho, const SparseMatrixTreescd &xmats, const Node &node, double eps)
-
Wavefunction
-
file
BlockTree.cpp - #include “TreeClasses/Discrete/BlockTree.h”#include <numeric>
Functions
-
size_t
min(size_t a, size_t b)¶
-
ostream &
operator<<(ostream &os, const LabelDimension &dim)
-
Labels
label_combinations(const NodeAttribute<Labels> &up, const NodeAttribute<Labels> &down, const Range &range, const Node &node, const Node &hole)
-
size_t
labelDimension(const Label &label, size_t dimension, size_t n_hole)
-
size_t
-
file
SymmetricSCF.cpp - #include “TreeClasses/Discrete/SymmetricSCF.h”
Functions
-
template<typename
T>
ostream &operator<<(ostream &os, const Configuration<T> &c)
-
template ostream& operator<<(ostream & os, const Configuration < size_t > &)
-
template<typename
T>
ostream &operator<<(ostream &os, const ConfigurationTensor<T> &c)
-
template ostream& operator<<(ostream & os, const ConfigurationTensor < size_t > & c)
-
template<typename
T>
ostream &operator<<(ostream &os, const ConfigurationTree<T> &a)
-
template ostream& operator<<(ostream & os, const ConfigurationTree < size_t > & c)
-
ConfigurationTensor
randomConfigurationTensor(const TensorShape &shape, mt19937 &gen)
-
ConfigurationTree
randomConfigurationTree(const Tree &tree, mt19937 &gen)
-
ConfigurationTensor
bottomTensor(const TensorShape &shape)
-
ConfigurationTensor
cartesianProduct(Configuration<> &idx, const ConfigurationTree<> &Psi, const Node &node)¶
-
Configuration
resort(const Configuration<> &c, const Configuration<> &idx)¶
-
vector<size_t>
findIndices(const vector<size_t> &idx, const vector<size_t> &all)¶
-
ConfigurationTensor
sliceDown(const ConfigurationTensor<> &B, const vector<size_t> &idx)¶
-
ConfigurationTensor
slice(const ConfigurationTensor<> &B, size_t start, size_t n)¶
-
ConfigurationTensor
select_unique(const ConfigurationTensor<> &A, size_t n)¶
-
ConfigurationTensor
sortForEnergy(const ConfigurationTensor<> &A, const vector<double> &E)¶
-
vector<double>
integrateEnergy(const ConfigurationTensor<> &A, const vector<double> &E)¶
-
vector<double>
evaluateGrid(const ConfigurationTensor<> &A, const Configuration<> &idx, function<double(const Configuration<> &c)> f, pair<Configuration<>, double> &optimal, map<Configuration<>, double> &results, size_t verboseness, )¶
-
Configuration
optimize(ConfigurationTree<> &Psi, function<double(const Configuration<> &c)> f, const Tree &tree, size_t n_sweep, size_t verboseness, )
-
size_t
to_integer(const Configuration<> &c)
-
void
split_integers(vector<size_t> &vec, vector<size_t> &tmp, const Configuration<> &c, size_t n)¶
-
vector<size_t>
split_integers(const Configuration<> &c, size_t n)
-
double
to_double(size_t i, size_t max_val)
-
void
split_doubles(vector<double> &xs, vector<size_t> &x_int, vector<size_t> &tmp, const Configuration<> &c, size_t n)
-
vector<double>
split_doubles(const Configuration<> &c, size_t n)
-
template<typename
-
file
U1Symmetry.cpp - #include “TreeClasses/Discrete/U1Symmetry.h”#include <list>
Functions
-
size_t
factorial(size_t n) Rationale: Reading https://math.stackexchange.com/questions/474741/formula-for-combinations-with-replacement helps understanding the thoughts behind partitions & combinatorics in this file.
-
size_t
binomial(size_t k, size_t n)
-
void
helper(vector<Labels> &res, const vector<Labels> &numbers, size_t depth, Labels slate, size_t size, size_t sum)¶
-
ostream &
operator<<(ostream &os, const ivec &X)
-
void
combinatoricalMap(ivec &idx, size_t I, size_t k, size_t N)
-
void
combinatoricalMap(size_t &I, const ivec &idx, size_t k, size_t N)
-
void
combinationToPartition(ivec &p) Helper-function that does: 0111011 -> 032 (interfaced for unit test)
-
void
partitionMap(ivec &idx, size_t &I, size_t sum, size_t nSummands) returns the Ith partitions for ‘nSummands’ summands that sum up to ‘sum’.
-
size_t
nPartitions(size_t sum, size_t nSummands)
-
size_t
-
file
EntropyTree.cpp - #include “TreeClasses/EntropyTree.h”#include “TreeClasses/TensorTreeFunctions.h”#include “TreeClasses/SpectralDecompositionTree.h”
-
file
HamiltonianRepresentation.cpp - #include “TreeClasses/HamiltonianRepresentation.h”
Functions
-
Tensorcd
Apply(const Hamiltonian &H, const Tensorcd &Phi, const HamiltonianRepresentation &hRep, const Node &node)
-
Matrixcd
Expectation(const HamiltonianRepresentation &hRep, const Wavefunction &Psi, const Hamiltonian &H, const Tree &tree)
-
void
LayerDerivative(Tensorcd &dPhi, double time, const Tensorcd &Phi, const Hamiltonian &H, const HamiltonianRepresentation &hRep, const Node &node, complex<double> propagation_phase)
-
void
Derivative(Wavefunction &dPsi, HamiltonianRepresentation &hRep, double time, const Wavefunction &Psi, const Hamiltonian &H, const Tree &tree, complex<double> propagation_phase)
-
void
symLayerDerivative(Tensorcd &dPhi, double time, const Tensorcd &Phi, const Hamiltonian &H, const HamiltonianRepresentation &hRep, const Node &node, complex<double> propagation_phase)¶
-
void
symDerivative(MatrixTensorTree &dPsi, HamiltonianRepresentation &hRep, double time, const MatrixTensorTree &Psi, const Hamiltonian &H, const Tree &tree, complex<double> propagation_phase)
-
void
output(const HamiltonianRepresentation &hrep, const Wavefunction &Psi, const Hamiltonian &H, const Tree &tree)
-
size_t
nActives(const SparseMatrixTreecd &hmat, const MLOcd &M, const SparseMatrixTreecd &hcon, const Node &node)
-
Tensorcd
-
file
LayerInterface.cpp - #include “TreeClasses/LayerInterface.h”
-
file
MatrixTree.cpp - #include “TreeClasses/MatrixTree.h”
Functions
-
template<typename
T>
ostream &operator<<(ostream &os, const MatrixTree<T> &S)
-
template<typename
T>
istream &operator>>(istream &is, MatrixTree<T> &S)
-
template<typename
-
file
MatrixTreeFunctions.cpp - #include “TreeClasses/MatrixTreeFunctions_Implementation.h”#include “TreeClasses/TreeTransformation_Implementation.h”
-
file
SparseMatrixTree.cpp - #include “TreeClasses/SparseMatrixTree.h”
-
file
SparseMatrixTreeFunctions.cpp - #include “TreeClasses/SparseMatrixTreeFunctions_Implementation.h”
-
file
SparseTensorTree.cpp - #include “TreeClasses/SparseTensorTree.h”
-
file
SparseTree.cpp - #include “TreeClasses/SparseTree.h”
-
file
SpectralDecompositionTree.cpp - #include “TreeClasses/SpectralDecompositionTree.h”
Functions
-
template<typename
T>
MatrixTree<T>toMatrixtree(const SpectralDecompositionTree<T> &X, const Tree &tree)
-
template<typename
T>
voidcanonicalTransformation(TensorTree<T> &Psi, const Tree &tree, bool orthogonal)
-
template<typename
T>
MatrixTree<T>sqrt(MatrixTree<T> X, const Tree &tree)
-
template<typename
T>
SpectralDecompositionTree<T>inverse(SpectralDecompositionTree<T> X, double eps)
-
template<typename
T>
MatrixTree<T>inverse(MatrixTree<T> X, const Tree &tree, double eps)
-
template SpectralDecompositionTreecd sqrt(SpectralDecompositionTreecd X)
-
template SpectralDecompositionTreed sqrt(SpectralDecompositionTreed X)
-
template MatrixTreecd sqrt(MatrixTreecd X, const Tree & tree)
-
template MatrixTreed sqrt(MatrixTreed X, const Tree & tree)
-
template SpectralDecompositionTreecd inverse(SpectralDecompositionTreecd X, double eps)
-
template SpectralDecompositionTreed inverse(SpectralDecompositionTreed X, double eps)
-
template MatrixTreecd inverse(MatrixTreecd X, const Tree & tree, double eps)
-
template MatrixTreed inverse(MatrixTreed X, const Tree & tree, double eps)
-
template MatrixTreecd toMatrixtree(const SpectralDecompositionTreecd & X, const Tree & tree)
-
template MatrixTreed toMatrixtree(const SpectralDecompositionTreed & X, const Tree & tree)
-
template void canonicalTransformation(TensorTreecd & Psi, const Tree & tree, bool orthogonal)
-
template void canonicalTransformation(TensorTreed & Psi, const Tree & tree, bool orthogonal)
-
template<typename
-
file
SymTensorTree.cpp - #include “TreeClasses/SymTensorTree.h”#include “TreeClasses/SpectralDecompositionTree.h”#include “Core/Tensor_Extension.h”
Functions
-
double
epsUpNormalization(const SymTensorTree &Psi, const Tree &tree)¶
-
double
epsDownNormalization(const SymTensorTree &Psi, const Tree &tree)¶
-
bool
isWorking(const SymTensorTree &Psi, const Tree &tree)
-
double
-
file
TensorTree_Instantiation.cpp - #include “TreeClasses/TensorTree.h”#include “TreeClasses/TensorTree_Implementation.h”#include “TreeClasses/TensorTreeFunctions_Implementation.h”
Typedefs
-
typedef complex<double>
cd
-
typedef double
d
Functions
-
template ostream& operator<<< cd >(ostream &, const TensorTree < cd > &)
-
template istream& operator>>< cd >(istream &, TensorTree < cd > &)
-
template TensorTree<cd> operator*(cd c, TensorTree < cd > R)
-
template TensorTree<cd> operator/(cd c, TensorTree < cd > R)
-
template ostream& operator<<< d >(ostream &, const TensorTree < d > &)
-
template istream& operator>>< d >(istream &, TensorTree < d > &)
-
template TensorTree<d> operator*(d c, TensorTree < d > R)
-
template TensorTree<d> operator/(d c, TensorTree < d > R)
-
template void orthogonal< cd >(TensorTree < cd > & Psi, const Tree & tree)
-
template void orthogonal< d >(TensorTree < d > & Psi, const Tree & tree)
-
template void qrOrthogonal< cd >(TensorTree < cd > & Psi, const Tree & tree)
-
template void orthonormal< cd >(TensorTree < cd > & Psi, const Tree & tree)
-
template void orthonormal< d >(TensorTree < d > & Psi, const Tree & tree)
-
typedef complex<double>
-
file
TreeIO.cpp - #include “TreeClasses/TreeIO.h”#include “TreeClasses/SpectralDecompositionTree.h”
Typedefs
-
typedef complex<double>
cd
-
typedef double
d
-
typedef complex<double>
-
file
TreeTransformations.cpp - #include “TreeClasses/TreeTransformation_Implementation.h”
Typedefs
-
typedef complex<double>
cd
-
typedef double
d
-
typedef complex<double>
-
file
FortranOperator.cpp - #include “TreeOperators/FortranOperator.h”
-
file
FortranSOP.cpp - #include “TreeOperators/FortranSOP.h”#include “Core/Matrix.h”
Functions
-
void
DDXCPP(int *mode, double hPsi[], double Psi[], int *dim, double matrix[], double trafo[])¶
-
void
KINCPP(int *mode, double hPsi[], double Psi[], int *dim, double matrix[], double trafo[])¶
-
void
fillpara_(int *f, double *para)¶
-
void
ApplyFortranDDX(complex<double> hPsi[], complex<double> Psi[], const LeafInterface &grid, int dim)
-
void
ApplyFortranKIN(complex<double> hPsi[], complex<double> Psi[], const LeafInterface &grid, int dim)
-
void
-
file
LeafFunction.cpp - #include “TreeOperators/LeafFunction.h”
-
file
LeafMatrix.cpp - #include “TreeOperators/LeafMatrix.h”
Functions
-
Matrixcd
toMatrix(const LeafOperatorcd &h, const Leaf &leaf)
-
Matrixd
toMatrix(const LeafOperator<double> &h, const Leaf &leaf)¶
-
Matrixcd
-
file
MultiLeafOperator.cpp - #include “TreeOperators/MultiLeafOperator.h”
Typedefs
-
typedef complex<double>
cd
Functions
-
template<typename
T>
MultiLeafOperator<T>operator*(const MultiLeafOperator<T> &A, const MultiLeafOperator<T> &B)¶
-
template MultiLeafOperator<cd> operator*(const MultiLeafOperator < cd > & A, const MultiLeafOperator < cd > & B)
-
typedef complex<double>
-
file
SumOfProductsOperator.cpp - #include “TreeOperators/SumOfProductsOperator_Implementation.h”#include “TreeOperators/SOPVector.h”
Typedefs
-
typedef complex<double>
cd
-
typedef double
d double
Functions
-
template SumOfProductsOperator<cd> operator*<cd >(cd c, const SOP < cd > & A)
-
template SumOfProductsOperator<cd> operator*(const SOP < cd > & A, complex< double > c)
-
template SumOfProductsOperator<cd> operator*(const MLO < cd > & M, const SOP < cd > & A)
-
template SumOfProductsOperator<cd> operator*(const SOP < cd > & A, const MLO < cd > & M)
-
template SumOfProductsOperator<cd> operator*(const SOP < cd > & A, const SOP < cd > & B)
-
template SumOfProductsOperator<cd> operator+(const SOP < cd > & A, const SOP < cd > & B)
-
template SumOfProductsOperator<d> operator*<d >(d c, const SOP < d > & A)
-
template SumOfProductsOperator<d> operator*(const SOP < d > & A, double c)
-
template SumOfProductsOperator<d> operator*(const MLO < d > & M, const SOP < d > & A)
-
template SumOfProductsOperator<d> operator*(const SOP < d > & A, const MLO < d > & M)
-
template SumOfProductsOperator<d> operator*(const SOP < d > & A, const SOP < d > & B)
-
template SumOfProductsOperator<d> operator+(const SOP < d > & A, const SOP < d > & B)
-
typedef complex<double>
-
file
contractCircuit.cpp - #include “TreeOperators/TensorOperators/contractCircuit.h”#include “TreeClasses/MatrixTensorTreeFunctions.h”
Typedefs
-
typedef complex<double>
cd
-
typedef double
d
Functions
-
template<typename
T>
Tensor<T>apply(Tensor<T> A, const MatrixTree<T> &rep, const MatrixTree<T> &hole, const Node &node)¶
-
template<typename
T>
doubleiterateCircuit(TensorTreeOperator<T> &A, const TensorTreeOperator<T> &U, const SOP<T> &S, const Tree &optree)¶
-
template<typename
T>
doubleerror_circuit(const TensorTreeOperator<T> &A, const SOP<T> &S, const TensorTreeOperator<T> &U, const Tree &optree)¶
-
template<typename
T>
TensorTreeOperator<T>contractCircuit(const SOP<T> &S, const TensorTreeOperator<T> &U, size_t maxIter, const Tree &optree, ostream *os) Calculate product of SOP operator with TTNO, i.e. A = S * U.
- Return
contracted TTNO A
- Template Parameters
T: base-type
- Parameters
S: Sum-of-product operator that is appliedU: contrcted OperatormaxIter: code will leave after max-Iterations if not convergedoptree: operator treeos: out-stream for output during optimization (optional)
-
template<typename
T>
TensorTreeOperator<T>contractCircuit(const SOPVector<T> &S, size_t maxIter, const Tree &optree, ostream *os)
-
template double error_circuit(const TensorTreeOperator < d > & A, const SOP < d > & S, const TensorTreeOperator < d > & U, const Tree & optree)
-
template double error_circuit(const TensorTreeOperator < cd > & A, const SOP < cd > & S, const TensorTreeOperator < cd > & U, const Tree & optree)
-
template double iterateCircuit(TensorTreeOperator < d > & A, const TensorTreeOperator < d > & U, const SOP < d > & S, const Tree & optree)
-
template double iterateCircuit(TensorTreeOperator < cd > & A, const TensorTreeOperator < cd > & U, const SOP < cd > & S, const Tree & optree)
-
template TensorTreeOperator<d> contractCircuit(const SOP < d > & S, const TensorTreeOperator < d > & U, size_t maxIter, const Tree & optree, ostream * os)
-
template TensorTreeOperator<cd> contractCircuit(const SOP < cd > & S, const TensorTreeOperator < cd > & U, size_t maxIter, const Tree & optree, ostream * os)
-
template TensorTreeOperator<d> contractCircuit(const SOPVector < d > & S, size_t maxIter, const Tree & optree, ostream * os)
-
template TensorTreeOperator<cd> contractCircuit(const SOPVector < cd > & S, size_t maxIter, const Tree & optree, ostream * os)
-
typedef complex<double>
-
file
contractSOP.cpp - #include “TreeOperators/TensorOperators/contractSOP.h”#include “TreeClasses/TensorTreeFunctions.h”
Typedefs
-
typedef double
d
-
typedef complex<double>
cd
Functions
-
template<typename
T>
voidcontractSOP(TensorTreeOperator<T> &A, const SOP<T> &S, size_t maxIter, const Tree &optree, ostream *os)
-
template<typename
T>
Tensor<T>applyLayer(const TTOMatrixTree<T> &rep, const TTOHoleTree<T> &hole, const SOP<T> &S, const Node &node)¶
-
template<typename
T>
voiditerate(TensorTreeOperator<T> &A, TTOMatrixTree<T> &rep, TTOHoleTree<T> &hole, const SOP<T> &S, const Tree &optree)¶
-
template<typename
T>
doubleerror(const TensorTreeOperator<T> &A, const SOP<T> &S, const Tree &optree, ostream *os)
-
template void contractSOP(TensorTreeOperator < d > & A, const SOP < d > & S, size_t maxIter, const Tree & optree, ostream * os)
-
template void contractSOP< cd >(TensorTreeOperator < cd > & A, const SOP < cd > & S, size_t maxIter, const Tree & optree, ostream * os)
-
template double error(const TensorTreeOperator < d > & A, const SOP < d > & S, const Tree & optree, ostream * os)
-
template double error(const TensorTreeOperator < cd > & A, const SOP < cd > & S, const Tree & optree, ostream * os)
-
typedef double
-
file
TensorTreeOperator.cpp - #include “TreeOperators/TensorOperators/TensorTreeOperator.h”
Typedefs
-
typedef double
d
-
typedef complex<double>
cd
Functions
-
template<typename
T>
TensorTreeOperator<T>product(const MLO<T> &M, TensorTreeOperator<T> A, const Tree &tree)
-
template void toTensor(Tensor < d > & A, const MLO < d > & M, size_t part, const Leaf & leaf)
-
template void toTensor(Tensord & A, const Matrixd & M, size_t part, const Leaf & leaf)
-
template Matrixd toMatrix(const MLOd & M, const Leaf & leaf)
-
template Matrixd toMatrix(const Tensord & B, size_t l, const Leaf & leaf)
-
template TensorTreeOperator<d> product(const MLO < d > & M, TensorTreeOperator < d > A, const Tree & tree)
-
template void toTensor(Tensorcd & A, const MLOcd & M, size_t part, const Leaf & leaf)
-
template void toTensor(Tensorcd & A, const Matrixcd & M, size_t part, const Leaf & leaf)
-
template Matrixcd toMatrix(const MLOcd & M, const Leaf & leaf)
-
template Matrixcd toMatrix(const Tensorcd & B, size_t l, const Leaf & leaf)
-
template TensorTreeOperator<cd> product(const MLO < cd > & M, TensorTreeOperator < cd > A, const Tree & tree)
-
typedef double
-
file
TTNO_instantiations.cpp - #include “TreeOperators/TensorOperators/TensorTreeOperator.h”#include “TreeOperators/TensorOperators/TTOHoleTree.h”#include “TreeOperators/TensorOperators/TTOMatrixTree.h”#include “TreeOperators/TensorOperators/TTOcontraction_Implementation.h”#include “TreeOperators/TensorOperators/TTOrepresentation.h”#include “TreeOperators/TensorOperators/contractSOP.h”
Typedefs
-
typedef double
d
-
typedef complex<double>
cd
Functions
-
template Tensor<d> apply(const Tensor < d > & Phi, const TensorTreeOperator < d > & H, const TTOrepresentation < d > & rep, const TTOcontraction < d > & con, const Node & node)
-
template Tensor<cd> apply(const Tensor < cd > & Phi, const TensorTreeOperator < cd > & H, const TTOrepresentation < cd > & rep, const TTOcontraction < cd > & con, const Node & node)
-
typedef double
-
file
TTOMatrixTree.cpp - #include “TreeOperators/TensorOperators/TTOMatrixTree.h”
Typedefs
-
typedef double
d
-
typedef complex<double>
cd
Functions
-
template<typename
T>
TprodMk(const vector<size_t> &idx, const vector<Matrix<T>> &Mk, size_t l, int skip)
-
template Tensor<cd> toTensor(const SOP < cd > & S, const Leaf & leaf)
-
template Tensor<d> toTensor(const SOP < d > & S, const Leaf & leaf)
-
template d prodMk(const vector< size_t > & idx, const vector< Matrix < d >> & Mk, size_t l, int skip = -1)
-
template cd prodMk(const vector< size_t > & idx, const vector< Matrix < cd >> & Mk, size_t l, int skip = -1)
-
typedef double
-
file
TTOrepresentation.cpp - #include “TreeOperators/TensorOperators/TTOrepresentation.h”
-
file
MatrixListTree.cpp - #include “TreeOperators/TreeStructured/MatrixListTree.h”
-
file
TreeSOP.cpp - #include “TreeOperators/TreeStructured/TreeSOP.h”
Functions
-
void
print(const NodeProductOperator &mpo, complex<double> coeff, const vector<string> &names, size_t indent)¶
-
void
print(const NodeSOP &sop, const vector<string> &names, size_t indent)
-
void
print(const NodeSOPlist &sopl, const vector<string> &names, size_t indent)
-
bool
IsActive(const NodeOperator &h, const NodeProductOperator &M)
-
void
-
file
Leaf.cpp - #include “TreeShape/Leaf.h”#include “TreeShape/LeafTypes/DVRBasis.h”#include “TreeShape/LeafTypes/HO_Basis.h”#include “TreeShape/LeafTypes/FFTGrid.h”#include “TreeShape/LeafTypes/LegendrePolynomials.h”#include “TreeShape/LeafTypes/SpinGroup.h”
-
file
DVRBasis.cpp - #include “TreeShape/LeafTypes/DVRBasis.h”
-
file
FFTGrid.cpp - #include “TreeShape/LeafTypes/FFTGrid.h”#include “Util/FFT.h”#include “Util/QMConstants.h”
-
file
HO_Basis.cpp - #include “TreeShape/LeafTypes/HO_Basis.h”
-
file
LegendrePolynomials.cpp - #include “TreeShape/LeafTypes/LegendrePolynomials.h”
-
file
SpinGroup.cpp - #include “TreeShape/LeafTypes/SpinGroup.h”#include <chrono>
-
file
LinearizedLeaves.cpp - #include “TreeShape/LinearizedLeaves.h”
-
file
Node.cpp - #include “TreeShape/Node.h”
-
file
NodePosition.cpp - #include “TreeShape/NodePosition.h”
Functions
-
NodePosition
operator*(NodePosition p, size_t k)
-
NodePosition
operator*(NodePosition p, NodePosition q)
-
NodePosition
-
file
Tree.cpp - #include “TreeShape/Tree.h”
-
file
TreeFactory.cpp - #include “TreeShape/TreeFactory.h”
-
file
FFT.cpp - #include “Util/FFT.h”
-
file
GateOperators.cpp - #include “Util/GateOperators.h”#include “Util/QMConstants.h”
Functions
-
Matrixcd
sigma_x() Rationale:
Small library for Quantum Circuits
Only contains functions that are needed for unit testing
-
Matrixcd
sigma_y()
-
Matrixcd
sigma_z()
-
SOPcd
CNot(size_t c, size_t t)
-
SOPcd
CZ(size_t c, size_t t) CNot Chain.
-
Matrixcd
rk(size_t k, bool adj)¶ Define complex rotation operator, denoted by Rk, where k indicates angle=1/(2^k)
-
SOPVectorcd
QFT(size_t mode_start, size_t n_bit, bool adjungate, size_t approx)
-
Matrixcd
-
file
normal_modes.cpp - #include “Util/normal_modes.h”#include “TreeOperators/CoordinateTransformation.h”
-
file
Overlaps.cpp - #include “Util/Overlaps.h”#include “TreeClasses/MatrixTreeFunctions.h”#include <iomanip>
Functions
-
vector<TensorTreecd>
readTensorTrees(const string &file1)¶
-
void
adjustNOCl(vector<TensorTreecd> &Psi, const Tree &tree)¶
-
void
wavefunctionOverlap(const string &file1, const string &file2, const Tree &tree, OverlapType type)
-
void
wavefunctionOverlap(const vector<TensorTreecd> &Psi, const vector<TensorTreecd> &Chi, const Tree &tree, OverlapType type)
-
vector<TensorTreecd>
-
file
RandomMatrices.cpp - #include “Util/RandomMatrices.h”
-
file
SimultaneousDiagonalization.cpp - #include “Util/SimultaneousDiagonalization.h”
-
file
string_ext.cpp - #include “Util/string_ext.h”#include <algorithm>
-
file
WeightedSimultaneousDiagonalization.cpp - #include “Util/WeightedSimultaneousDiagonalization.h”
-
group
Integrator This module holds all classes related to mctdh-Integrators.
-
group
Core This group includes the basic datastructures in QuTree.
These datastructures include the Vector, Matrix, and Tensor classes.
Typedefs
-
typedef Matrix<complex<double>>
Matrixcd General typedef for complex matrices.
-
typedef Matrix<double>
Matrixd General typedef for real matrices.
-
using
SpectralDecomposition= pair<Matrix<T>, Vectord> General typedef for Matrix<T>, Vectord pairs.
-
typedef SpectralDecomposition<complex<double>>
SpectralDecompositioncd Specialization of SpectralDecomposition of Matrixcd.
-
typedef SpectralDecomposition<double>
SpectralDecompositiond Specialization of SpectralDecomposition of Matrixd.
-
typedef Matrix<complex<double>>
-
group
QuTree QuTree is a C++ Tensor and Tensor Tree library.
This library has classes that are similar to libraries like Lapack, Eigen, Armadillo, etc., but its focus is concentrated on handling high-order Tensors and Tensor Trees.
-
group
Tree Group for classes related to tree handling.
This group contains all functionality pertaining to Trees.
Classes in this group use a TTBasis to generate new classes that use and work with the tree structure provided by TTBasis. The classes in this group should either inherit from TreeStructureObject (for classes that have some object at EVERY node in a tree) or SparseTreeStructuredObject (for classes that have some object at a SUBSET of all nodes in the tree).
-
group
Operators This group is a bundle of classes that handle operators. System specific operators are NOT included here.
This group contains general operator classes that are required to evaluate working equations for tensor tree approaches.
-
group
TTNO This class is a tree tensor network operator (TTNO)
-
group
TTBasis This group contains classes to construct and handle a tensor tree basis.
-
group
Util This group includes common utilites in QuTree.
-
dir
/home/docs/checkouts/readthedocs.org/user_builds/qutree/checkouts/latest/include/Applications
-
dir
/home/docs/checkouts/readthedocs.org/user_builds/qutree/checkouts/latest/src/Applications
-
dir
/home/docs/checkouts/readthedocs.org/user_builds/qutree/checkouts/latest/include/Core
-
dir
/home/docs/checkouts/readthedocs.org/user_builds/qutree/checkouts/latest/src/Core
-
dir
/home/docs/checkouts/readthedocs.org/user_builds/qutree/checkouts/latest/src/TreeClasses/Discrete
-
dir
/home/docs/checkouts/readthedocs.org/user_builds/qutree/checkouts/latest/include/TreeClasses/Discrete
-
dir
/home/docs/checkouts/readthedocs.org/user_builds/qutree/checkouts/latest/include/DVR
-
dir
/home/docs/checkouts/readthedocs.org/user_builds/qutree/checkouts/latest/src/DVR
-
dir
/home/docs/checkouts/readthedocs.org/user_builds/qutree/checkouts/latest/include
-
dir
/home/docs/checkouts/readthedocs.org/user_builds/qutree/checkouts/latest/include/TreeShape/LeafTypes
-
dir
/home/docs/checkouts/readthedocs.org/user_builds/qutree/checkouts/latest/src/TreeShape/LeafTypes
-
dir
/home/docs/checkouts/readthedocs.org/user_builds/qutree/checkouts/latest/src
-
dir
/home/docs/checkouts/readthedocs.org/user_builds/qutree/checkouts/latest/include/TreeOperators/TensorOperators
-
dir
/home/docs/checkouts/readthedocs.org/user_builds/qutree/checkouts/latest/src/TreeOperators/TensorOperators
-
dir
/home/docs/checkouts/readthedocs.org/user_builds/qutree/checkouts/latest/src/TreeClasses
-
dir
/home/docs/checkouts/readthedocs.org/user_builds/qutree/checkouts/latest/include/TreeClasses
-
dir
/home/docs/checkouts/readthedocs.org/user_builds/qutree/checkouts/latest/src/TreeOperators
-
dir
/home/docs/checkouts/readthedocs.org/user_builds/qutree/checkouts/latest/include/TreeOperators
-
dir
/home/docs/checkouts/readthedocs.org/user_builds/qutree/checkouts/latest/src/TreeShape
-
dir
/home/docs/checkouts/readthedocs.org/user_builds/qutree/checkouts/latest/include/TreeShape
-
dir
/home/docs/checkouts/readthedocs.org/user_builds/qutree/checkouts/latest/src/TreeOperators/TreeStructured
-
dir
/home/docs/checkouts/readthedocs.org/user_builds/qutree/checkouts/latest/include/TreeOperators/TreeStructured
-
dir
/home/docs/checkouts/readthedocs.org/user_builds/qutree/checkouts/latest/src/Util
-
dir
/home/docs/checkouts/readthedocs.org/user_builds/qutree/checkouts/latest/include/Util