GQCP
Loading...
Searching...
No Matches
Public Types | Public Member Functions | Static Public Member Functions | List of all members
GQCP::HoppingMatrix< _Scalar > Class Template Reference

#include <HoppingMatrix.hpp>

Collaboration diagram for GQCP::HoppingMatrix< _Scalar >:
Collaboration graph

Public Types

using Scalar = _Scalar
 

Public Member Functions

 HoppingMatrix (const SquareMatrix< Scalar > &H)
 
size_t numberOfLatticeSites () const
 
const SquareMatrix< Scalar > & matrix () const
 
SquareMatrix< Scalar > & matrix ()
 

Static Public Member Functions

template<typename Z = Scalar>
static enable_if_t< std::is_same< Z, double >::value, HoppingMatrix< double > > Dense (std::vector< double > &triagonal_data)
 
template<typename Z = Scalar>
static enable_if_t< std::is_same< Z, double >::value, HoppingMatrix< double > > Homogeneous (const AdjacencyMatrix &A, const double t)
 
template<typename Z = Scalar>
static enable_if_t< std::is_same< Z, double >::value, HoppingMatrix< double > > FromLinkVector (const AdjacencyMatrix &A, std::vector< double > &link_vector)
 

Detailed Description

template<typename _Scalar>
class GQCP::HoppingMatrix< _Scalar >

The Hubbard hopping matrix.

Template Parameters
_ScalarThe scalar type of the elements of the hopping matrix.

Member Typedef Documentation

◆ Scalar

template<typename _Scalar >
using GQCP::HoppingMatrix< _Scalar >::Scalar = _Scalar

Constructor & Destructor Documentation

◆ HoppingMatrix()

template<typename _Scalar >
GQCP::HoppingMatrix< _Scalar >::HoppingMatrix ( const SquareMatrix< Scalar > &  H)
inline

Create a hopping matrix from its representation as a SquareMatrix.

Parameters
HThe Hubbard hopping matrix, represented as a SquareMatrix.

Member Function Documentation

◆ Dense()

template<typename _Scalar >
template<typename Z = Scalar>
static enable_if_t< std::is_same< Z, double >::value, HoppingMatrix< double > > GQCP::HoppingMatrix< _Scalar >::Dense ( std::vector< double > &  triagonal_data)
inlinestatic

Create a hopping matrix from a vector containing the upper triangle.

Parameters
cslineA vector that contains the upper triangle (in column-major ordering) of the Hubbard hopping matrix.
Returns
The hopping matrix that corresponds to the given comma-separated line.

◆ FromLinkVector()

template<typename _Scalar >
template<typename Z = Scalar>
static enable_if_t< std::is_same< Z, double >::value, HoppingMatrix< double > > GQCP::HoppingMatrix< _Scalar >::FromLinkVector ( const AdjacencyMatrix A,
std::vector< double > &  link_vector 
)
inlinestatic

Generate the Hubbard hopping matrix from an adjacency matrix and link vector containing values for different parameters t.

Parameters
AThe adjacency matrix specifying the connectivity of the Hubbard lattice.
link_vectorA vector that contains the values of the links, in a given adjacency matrix.
Note
This constructor is only available in the real case (for the std::enable_if, see https://stackoverflow.com/a/17842695/7930415).

◆ Homogeneous()

template<typename _Scalar >
template<typename Z = Scalar>
static enable_if_t< std::is_same< Z, double >::value, HoppingMatrix< double > > GQCP::HoppingMatrix< _Scalar >::Homogeneous ( const AdjacencyMatrix A,
const double  t 
)
inlinestatic

Generate the Hubbard hopping matrix from an adjacency matrix and Hubbard model parameter t.

Parameters
AThe adjacency matrix specifying the connectivity of the Hubbard lattice.
tThe Hubbard parameter t. Note that a positive value for t means a negative neighbour hopping term.
Note
This constructor is only available in the real case (for the std::enable_if, see https://stackoverflow.com/a/17842695/7930415).

◆ matrix() [1/2]

template<typename _Scalar >
SquareMatrix< Scalar > & GQCP::HoppingMatrix< _Scalar >::matrix ( )
inline
Returns
A writable reference to the matrix representation of this hopping matrix.

◆ matrix() [2/2]

template<typename _Scalar >
const SquareMatrix< Scalar > & GQCP::HoppingMatrix< _Scalar >::matrix ( ) const
inline
Returns
A read-only reference to the matrix representation of this hopping matrix.

◆ numberOfLatticeSites()

template<typename _Scalar >
size_t GQCP::HoppingMatrix< _Scalar >::numberOfLatticeSites ( ) const
inline
Returns
The number of lattice sites corresponding used in this hopping matrix.

The documentation for this class was generated from the following file: