1#ifndef XPED_FERMIONSSU2xSU2xU1_H_
2#define XPED_FERMIONSSU2xSU2xU1_H_
11template <
typename Symmetry>
14template <
typename Symmetry_>
15class Fermion<Sym::Combined<Sym::SU2<Sym::SpinSU2>, Sym::SU2<Sym::SpinSU2>, Symmetry_>>
17 using Scalar = double;
20 using qType =
typename Symmetry::qType;
24 Fermion(
bool REMOVE_DOUBLE,
bool REMOVE_EMPTY,
bool REMOVE_SINGLE,
bool =
true,
bool CONSIDER_CHARGE =
true);
49 std::unordered_map<std::string, std::pair<qType, std::size_t>>
labels;
64template <
typename Symmetry_>
68 for(std::size_t q = 0; q < Symmetry::Nq; ++q) {
69 if(Symmetry::IS_FERMIONIC[q] or Symmetry::IS_BOSONIC[q]) {
85 qType Q_c = Symmetry::qvacuum();
88 if constexpr(Symmetry::Nq > 2) { Q_c[2] = Symmetry::IS_MODULAR[2] ?
util::constFct::posmod(-1, Symmetry::MOD_N[2]) : -1; }
89 qType Q_S = Symmetry::qvacuum();
91 Id_1s_ =
OperatorType(Symmetry::qvacuum(), basis_1s_, labels);
93 F_1s_ =
OperatorType(Symmetry::qvacuum(), basis_1s_, labels);
97 d_1s_ =
OperatorType(Symmetry::qvacuum(), basis_1s_, labels);
104 F_1s_(
"single",
"single") = -1.;
106 c_1s_(
"empty",
"single") = std::sqrt(2.) * std::sqrt(2.);
107 c_1s_(
"single",
"spin_double") = std::sqrt(1.5);
108 c_1s_(
"single",
"orbital_double") = std::sqrt(1.5);
109 c_1s_(
"spin_double",
"triple") = -std::sqrt(2);
110 c_1s_(
"orbital_double",
"triple") = std::sqrt(2);
111 c_1s_(
"triple",
"quadrupel") = 1.;
112 cdag_1s_ = c_1s_.adjoint();
113 n_1s_ = std::sqrt(2.) * std::sqrt(2.) * OperatorType::prod(cdag_1s_, c_1s_, Symmetry::qvacuum());
115 qType Q_p = Symmetry::qvacuum();
116 if constexpr(Symmetry::Nq > 2) { Q_p[2] = Symmetry::IS_MODULAR[2] ?
util::constFct::posmod(-2, Symmetry::MOD_N[2]) : -2; }
117 p_1s_ = -std::sqrt(0.5) * OperatorType::prod(c_1s_, c_1s_, Q_p);
118 pdag_1s_ = p_1s_.adjoint();
121template <
typename Symmetry_>
125 qType Q = Symmetry::qvacuum();
126 labels.insert(std::make_pair(
"empty", std::make_pair(Q, 0)));
127 labels.insert(std::make_pair(
"quadruple", std::make_pair(Q, 1)));
128 this->basis_1s_.push_back(Q, 2);
131 this->basis_1s_.push_back(Q, 2);
132 labels.insert(std::make_pair(
"single", std::make_pair(Q, 0)));
133 labels.insert(std::make_pair(
"triple", std::make_pair(Q, 1)));
136 this->basis_1s_.push_back(Q, 1);
137 labels.insert(std::make_pair(
"spin_double", std::make_pair(Q, 0)));
140 this->basis_1s_.push_back(Q, 1);
141 labels.insert(std::make_pair(
"orbital_double", std::make_pair(Q, 0)));
143 qType Q = Symmetry::qvacuum();
144 this->basis_1s_.push_back(Q, 1);
145 labels.insert(std::make_pair(
"empty", std::make_pair(Q, 0)));
146 std::size_t dim = (Symmetry::MOD_N[ch_index] == 2 or Symmetry::MOD_N[ch_index] == 4) ? 1 : 0;
148 this->basis_1s_.push_back(Q, 1);
149 labels.insert(std::make_pair(
"quadrupel", std::make_pair(Q, dim)));
154 this->basis_1s_.push_back(Q, 1);
155 labels.insert(std::make_pair(
"single", std::make_pair(Q, 0)));
158 this->basis_1s_.push_back(Q, 1);
159 dim = (Symmetry::MOD_N[ch_index] == 2) ? 1 : 0;
160 labels.insert(std::make_pair(
"triple", std::make_pair(Q, dim)));
165 this->basis_1s_.push_back(Q, 1);
166 labels.insert(std::make_pair(
"spin_double", std::make_pair(Q, 0)));
169 this->basis_1s_.push_back(Q, 1);
170 labels.insert(std::make_pair(
"orbital_double", std::make_pair(Q, 0)));
OperatorType S_1s() const
Definition: FermionSU2xSU2xX.hpp:37
Fermion()
Definition: FermionSU2xSU2xX.hpp:23
OperatorType cdag_1s() const
Definition: FermionSU2xSU2xX.hpp:30
OperatorType cdag_1s_
Definition: FermionSU2xSU2xX.hpp:56
OperatorType nh_1s() const
Definition: FermionSU2xSU2xX.hpp:34
OperatorType c_1s_
Definition: FermionSU2xSU2xX.hpp:55
OperatorType Id_1s_
Definition: FermionSU2xSU2xX.hpp:53
OperatorType Tz_1s() const
Definition: FermionSU2xSU2xX.hpp:39
Qbasis< Symmetry, 1 > basis_1s() const
Definition: FermionSU2xSU2xX.hpp:43
OperatorType p_1s_
Definition: FermionSU2xSU2xX.hpp:60
OperatorType d_1s() const
Definition: FermionSU2xSU2xX.hpp:35
bool HAS_CHARGE
Definition: FermionSU2xSU2xX.hpp:51
OperatorType d_1s_
Definition: FermionSU2xSU2xX.hpp:58
OperatorType cc_1s() const
Definition: FermionSU2xSU2xX.hpp:40
Qbasis< Symmetry, 1 > basis_1s_
Definition: FermionSU2xSU2xX.hpp:47
OperatorType ns_1s() const
Definition: FermionSU2xSU2xX.hpp:33
OperatorType pdag_1s_
Definition: FermionSU2xSU2xX.hpp:61
OperatorType c_1s() const
Definition: FermionSU2xSU2xX.hpp:29
OperatorType n_1s() const
Definition: FermionSU2xSU2xX.hpp:32
OperatorType Id_1s() const
Definition: FermionSU2xSU2xX.hpp:26
std::unordered_map< std::string, std::pair< qType, std::size_t > > labels
Definition: FermionSU2xSU2xX.hpp:49
OperatorType F_1s() const
Definition: FermionSU2xSU2xX.hpp:27
OperatorType S_1s_
Definition: FermionSU2xSU2xX.hpp:59
OperatorType F_1s_
Definition: FermionSU2xSU2xX.hpp:54
OperatorType cdagcdag_1s() const
Definition: FermionSU2xSU2xX.hpp:41
OperatorType n_1s_
Definition: FermionSU2xSU2xX.hpp:57
Definition: Fermion.hpp:21
std::size_t ch_index
Definition: Fermion.hpp:76
OperatorType d_1s_
Definition: Fermion.hpp:93
OperatorType n_1s_
Definition: Fermion.hpp:90
OperatorType Id_1s() const
Definition: Fermion.hpp:31
Fermion()
Definition: Fermion.hpp:28
OperatorType Id_1s_
Definition: Fermion.hpp:81
OperatorType d_1s() const
Definition: Fermion.hpp:53
OperatorType n_1s() const
Definition: Fermion.hpp:45
Qbasis< Symmetry, 1 > basis_1s_
Definition: Fermion.hpp:72
void fill_basis(bool REMOVE_DOUBLE, bool REMOVE_EMPTY, bool REMOVE_SINGLE)
Definition: Fermion.hpp:208
OperatorType F_1s_
Definition: Fermion.hpp:82
Definition: Qbasis.hpp:39
constexpr int posmod(int x)
Definition: Constfct.hpp:46
Definition: CombSym.hpp:12