Template Struct one_body_operator¶
Defined in File one_body_operator.hpp
Inheritance Relationships¶
Base Type¶
public Hermitian_operator(Struct Hermitian_operator)
Struct Documentation¶
-
template<typename op_field>
struct one_body_operator : public Hermitian_operator¶ one-body operator
Public Functions
Constructor from name and matrix elements.
- Parameters:
_name – name of the operator
_the_model – model
_elements – nonzero one-body matrix elements
-
void check_Hermiticity()¶
checks whether the list of elements is Hermitian
-
void check_spin_flip()¶
determines whether the operator has spin-flip terms sets the bool variable spin_flip accordingly
-
void check_spin_symmetry()¶
determines whether the operator is symmetric under the exchange of up and down spins
-
virtual void set_target(vector<bool> &in_bath)¶
set the target of an operator 1 : cluster 2 : bath only 3 : hybridization
- Parameters:
in_bath – vector of bool defining the status of each site
-
inline virtual void set_hopping_matrix(double value, matrix<Complex> &tc, bool spin_down, int sys_mixing)¶
-
virtual shared_ptr<HS_Hermitian_operator> build_HS_operator(sector sec, bool complex_HS_op)¶
returns a pointer to, and constructs the associated HS operator in the sector with basis B.
-
virtual void print(ostream &fout)¶
prints definition to a file
- Parameters:
fout – output stream
-
template<typename HS_field>
void set_hopping_matrix_templ(double value, matrix<HS_field> &tc, bool spin_down, int sys_mixing)¶
-
virtual vector<matrix_element<Complex>> matrix_elements()¶
returns a list of complexified matrix elements
-
inline virtual string type()¶
-
inline virtual void set_hopping_matrix(double value, matrix<double> &tc, bool spin_down, int sys_mixing)
Adds the contribution of the operator to the matrices tc, tb or tcb.
-
inline virtual void set_hopping_matrix(double value, matrix<double> &tc, bool spin_down, int sys_mixing)
Public Members
-
bool spin_flip¶
-
vector<matrix_element<op_field>> elements¶
matrix elements
-
map<index_pair, op_field> element_map¶
temporary map form of elements, for checks
-
map<int, shared_ptr<HS_half_operator<op_field>>> half_operators¶
Hilbert space realizations, organized by particle number.
-
map<int, shared_ptr<HS_half_operator<op_field>>> half_operators_dw¶
the same, for the spin_down part, if different