VMPS++
Loading...
Searching...
No Matches
FermionSiteSU2xU1xZN.h
Go to the documentation of this file.
1#ifndef FERMIONSITESU2xU1xZN_H_
2#define FERMIONSITESU2xU1xZN_H_
3
5
6#include "DmrgTypedefs.h"
7
8#include "symmetry/S1xS2.h"
9#include "symmetry/SU2.h"
10#include "symmetry/U1.h"
11#include "symmetry/ZN.h"
12
14
15#ifndef YMOMENTUM
16#define YMOMENTUM 6
17#endif
18
19template <typename Symmetry> class FermionSite;
20
21template<>
22class FermionSite<Sym::S1xS2<Sym::S1xS2<Sym::SU2<Sym::SpinSU2>,Sym::U1<Sym::ChargeU1> >,Sym::ZN<Sym::Momentum,YMOMENTUM>>>
23{
24 typedef double Scalar;
27
28public:
29
31 FermionSite (bool REMOVE_DOUBLE, bool REMOVE_EMPTY, bool REMOVE_UP, bool REMOVE_DN, int mfactor_input=1, int k_input=0);
32
33 OperatorType Id_1s() const {return Id_1s_;}
34 OperatorType F_1s() const {return F_1s_;}
35
36 OperatorType c_1s() const {return c_1s_;}
37 OperatorType cdag_1s() const {return cdag_1s_;}
38
39 OperatorType n_1s() const {return n_1s_;}
40 OperatorType ns_1s() const {return n_1s() - 2.*d_1s();}
41 OperatorType nh_1s() const {return 2.*d_1s() - n_1s() + Id_1s();}
42 OperatorType d_1s() const {return d_1s_;}
43
44 OperatorType S_1s() const {return S_1s_;}
45
46 OperatorType Tz_1s() const {return 0.5*(n_1s() - Id_1s());}
47 OperatorType cc_1s() const {return p_1s_;}
48 OperatorType cdagcdag_1s() const {return pdag_1s_;}
49
51
52protected:
53
54 int k = 0;
55
57
58 OperatorType Id_1s_; //identity
59 OperatorType F_1s_; //Fermionic sign
60 OperatorType c_1s_; //annihilation
62 OperatorType n_1s_; //particle number
63 OperatorType d_1s_; //double occupancy
64 OperatorType S_1s_; //orbital spin
66 OperatorType pdag_1s_; //pairing adjoint
67};
68
70FermionSite (bool REMOVE_DOUBLE, bool REMOVE_EMPTY, bool REMOVE_UP, bool REMOVE_DN, int mfactor_input, int k_input)
71:k(k_input)
72{
73 bool REMOVE_SINGLE = (REMOVE_UP or REMOVE_DN)? true:false;
74
75 typename Symmetry::qType Q;
76 Eigen::Index inner_dim;
77 std::vector<std::string> ident;
78 int ZN = Symmetry::mod()[2];
79
80 if (!REMOVE_EMPTY)
81 {
82 Q={1,0,0}; //empty state, momentum 0
83 inner_dim = 1;
84 ident.push_back("empty");
85 basis_1s_.push_back(Q,inner_dim,ident);
86 ident.clear();
87 }
88
89 if (!REMOVE_SINGLE)
90 {
91 Q={2,1,k}; //singly occupied state, momentum k
92 inner_dim = 1;
93 ident.push_back("single");
94 basis_1s_.push_back(Q,inner_dim,ident);
95 ident.clear();
96 }
97
98 if (!REMOVE_DOUBLE)
99 {
100 Q={1,2,posmod(k+k,ZN)}; //doubly occupied state, momentum 2*k mod ZN
101 inner_dim = 1;
102 ident.push_back("double");
103 basis_1s_.push_back(Q,inner_dim,ident);
104 ident.clear();
105 }
106
107 //cout << "single site basis" << endl << this->basis_1s_ << endl;
108
109 Id_1s_ = OperatorType({1,0,0},basis_1s_,"id");
110 F_1s_ = OperatorType({1,0,0},basis_1s_,"F");
111 c_1s_ = OperatorType({2,-1,posmod(ZN-k,ZN)},basis_1s_,"c"); // remove momentum k = create opposite momentum N-k
112 d_1s_ = OperatorType({1,0,0},basis_1s_,"d");
113 S_1s_ = OperatorType({3,0,0},basis_1s_,"S");
114
115 // create operators one orbitals
116 if (!REMOVE_EMPTY) Id_1s_("empty", "empty") = 1.;
117 if (!REMOVE_DOUBLE) Id_1s_("double", "double") = 1.;
118 if (!REMOVE_SINGLE) Id_1s_("single", "single") = 1.;
119
120 if (!REMOVE_EMPTY) F_1s_("empty", "empty") = 1.;
121 if (!REMOVE_DOUBLE) F_1s_("double", "double") = 1.;
122 if (!REMOVE_SINGLE) F_1s_("single", "single") = -1.;
123
124 if (!REMOVE_EMPTY and !REMOVE_SINGLE) c_1s_("empty", "single") = std::sqrt(2.);
125 if (!REMOVE_DOUBLE and !REMOVE_SINGLE) c_1s_("single", "double") = 1.;
126
127 cdag_1s_ = c_1s_.adjoint();
128
129 n_1s_ = std::sqrt(2.) * OperatorType::prod(cdag_1s_,c_1s_,{1,0,0});
130 if (!REMOVE_DOUBLE) d_1s_("double", "double") = 1.;
131 if (!REMOVE_SINGLE) S_1s_("single", "single") = std::sqrt(0.75);
132 p_1s_ = -std::sqrt(0.5) * OperatorType::prod(c_1s_,c_1s_,{1,-2,posmod(ZN-k+ZN-k,ZN)}); //The sign convention corresponds to c_DN c_UP
133 pdag_1s_ = p_1s_.adjoint(); //The sign convention corresponds to (c_DN c_UP)†=c_UP† c_DN†
134}
135
136#endif //FERMIONSITESU2xU1xZN_H_
int posmod(int x)
Definition: DmrgExternal.h:20
Sym::S1xS2< Sym::S1xS2< Sym::SU2< Sym::SpinSU2 >, Sym::U1< Sym::ChargeU1 > >, Sym::ZN< Sym::Momentum, YMOMENTUM > > Symmetry
OperatorType n_1s() const
Definition: FermionSite.h:33
OperatorType Id_1s_
Definition: FermionSite.h:63
OperatorType F_1s_
Definition: FermionSite.h:64
OperatorType n_1s_
Definition: FermionSite.h:72
OperatorType d_1s_
Definition: FermionSite.h:75
Qbasis< Symmetry > basis_1s_
Definition: FermionSite.h:61
SiteOperatorQ< Symmetry, Eigen::Matrix< Scalar, Eigen::Dynamic, Eigen::Dynamic > > OperatorType
Definition: FermionSite.h:19
OperatorType d_1s() const
Definition: FermionSite.h:37
OperatorType Id_1s() const
Definition: FermionSite.h:27
Definition: Qbasis.h:39
static SiteOperatorQ< Symmetry, Eigen::Matrix< Scalar, Eigen::Dynamic, Eigen::Dynamic > > prod(const SiteOperatorQ< Symmetry, Eigen::Matrix< Scalar, Eigen::Dynamic, Eigen::Dynamic > > &O1, const SiteOperatorQ< Symmetry, Eigen::Matrix< Scalar, Eigen::Dynamic, Eigen::Dynamic > > &O2, const qType &target)
SiteOperatorQ< Symmetry, MatrixType_ > adjoint() const
Definition: U1.h:25
Definition: ZN.h:25
Definition: qarray.h:26