pomerol
2.1
|
Many-body Gibbs density matrix. More...
#include <DensityMatrix.hpp>
Public Member Functions | |
DensityMatrix (StatesClassification const &S, Hamiltonian const &H, RealType beta) | |
~DensityMatrix ()=default | |
Destructor. More... | |
void | prepare () |
Allocate memory for the parts. More... | |
void | compute () |
DensityMatrixPart const & | getPart (BlockNumber B) const |
RealType | getWeight (QuantumState state) const |
RealType | getAverageEnergy () const |
Compute the average energy \( \langle E\rangle = \sum_s E_s w_s\). More... | |
void | truncateBlocks (RealType Tolerance, bool verbose=true) |
bool | isRetained (BlockNumber B) const |
Public Member Functions inherited from Pomerol::Thermal | |
Thermal (RealType beta) | |
Public Member Functions inherited from Pomerol::ComputableObject | |
ComputableObject ()=default | |
StatusEnum | getStatus () const |
Return the current computation status. More... | |
void | setStatus (StatusEnum Status_in) |
Additional Inherited Members | |
Public Types inherited from Pomerol::ComputableObject | |
enum | StatusEnum { Constructed, Prepared, Computed } |
Computation status of the object. More... | |
Data Fields inherited from Pomerol::Thermal | |
const RealType | beta |
Inverse temperature \(\beta\). More... | |
const ComplexType | MatsubaraSpacing |
Spacing between (imaginary) Matsubara frequencies, \(i\pi/\beta\). More... | |
Protected Attributes inherited from Pomerol::ComputableObject | |
StatusEnum | Status = Constructed |
Current computation status. More... | |
Many-body Gibbs density matrix.
This class represents a many-body Gibbs density matrix
\[ \hat\rho = \frac{e^{-\beta\hat H}}{Z}, \quad Z = Tr[e^{-\beta\hat H}]. \]
The matrix is stored as a list of DensityMatrixPart (diagonal blocks), which correspond to invariant subspaces/diagonal blocks of the Hamiltonian \(\hat H\).
Definition at line 42 of file DensityMatrix.hpp.
Pomerol::DensityMatrix::DensityMatrix | ( | StatesClassification const & | S, |
Hamiltonian const & | H, | ||
RealType | beta | ||
) |
Constructor.
[in] | S | Information about invariant subspaces of the Hamiltonian. |
[in] | H | The Hamiltonian \(\hat H\). |
[in] | beta | Inverse temperature \(\beta\). |
|
default |
Destructor.
void Pomerol::DensityMatrix::compute | ( | ) |
Compute statistical weights within every part (diagonal block).
RealType Pomerol::DensityMatrix::getAverageEnergy | ( | ) | const |
Compute the average energy \( \langle E\rangle = \sum_s E_s w_s\).
DensityMatrixPart const& Pomerol::DensityMatrix::getPart | ( | BlockNumber | B | ) | const |
Return a reference to a part (diagonal block).
[in] | B | Index of the part. |
RealType Pomerol::DensityMatrix::getWeight | ( | QuantumState | state | ) | const |
Return a statistical weight corresponding to a specified eigenstate.
[in] | state | Index of the eigenstate within the full Hilbert space. |
bool Pomerol::DensityMatrix::isRetained | ( | BlockNumber | B | ) | const |
Does a given block contain any non-negligible statistical weights?
[in] | B | Index of the part (block). |
void Pomerol::DensityMatrix::prepare | ( | ) |
Allocate memory for the parts.
void Pomerol::DensityMatrix::truncateBlocks | ( | RealType | Tolerance, |
bool | verbose = true |
||
) |
Check if any of the statistical weights within each block is above a given tolerance. If not, mark the respective block as irrelevant (set the Retained flag to false).
[in] | Tolerance | Statistical weights smaller or equal to this value are considered negligible. |
[in] | verbose | Print out information about the truncation results. |