VMPS++
Loading...
Searching...
No Matches
KondoSU2xU1.h
Go to the documentation of this file.
1#ifndef KONDOMODELSU2XU1_H_
2#define KONDOMODELSU2XU1_H_
3
4//include "ParamHandler.h" // from HELPERS
5#include "symmetry/S1xS2.h"
6#include "symmetry/SU2.h"
7#include "symmetry/U1.h"
8#include "bases/SpinBase.h"
9#include "bases/FermionBase.h"
10//include "Mpo.h"
11//include "models/HubbardSU2xU1.h"
13#include "ParamReturner.h"
14
15#include "Geometry2D.h" // from TOOLS
16
17namespace VMPS
18{
37class KondoSU2xU1 : public Mpo<Sym::S1xS2<Sym::SU2<Sym::SpinSU2>,Sym::U1<Sym::ChargeU1> >,double>,
38 public KondoObservables<Sym::S1xS2<Sym::SU2<Sym::SpinSU2>,Sym::U1<Sym::ChargeU1> > >,
39 public ParamReturner
40{
41public:
44 static constexpr MODEL_FAMILY FAMILY = KONDO;
45
46private:
47 typedef Eigen::Index Index;
49 typedef Eigen::Matrix<double,Eigen::Dynamic,Eigen::Dynamic> MatrixType;
51
52public:
53
56 KondoSU2xU1 (const size_t &L, const vector<Param> &params, const BC &boundary=BC::OPEN, const DMRG::VERBOSITY::OPTION &VERB=DMRG::VERBOSITY::OPTION::ON_EXIT);
58
59 static qarray<2> singlet (int N) {return qarray<2>{1,N};};
60 static qarray<2> polaron (int L, int N=0) {return qarray<2>{L-N+1,N};};
61
71 template<typename Symmetry_>
72 static void set_operators (const std::vector<SpinBase<Symmetry_> > &B, const std::vector<FermionBase<Symmetry_> > &F, const ParamHandler &P,
73 PushType<SiteOperator<Symmetry_,double>,double>& pushlist, std::vector<std::vector<std::string>>& labellist,
74 const BC boundary=BC::OPEN);
75
78 bool validate (qType qnum) const;
79
81 // Mpo<Symmetry> c (size_t locx, size_t locy=0, double factor=1.);
82 // Mpo<Symmetry> cdag (size_t locx, size_t locy=0, double factor=sqrt(2.));
83 // Mpo<Symmetry> cc (size_t locx, size_t locy=0);
84 // Mpo<Symmetry> cdagcdag (size_t locx, size_t locy=0);
85 // ///@}
86
87
88 // ///@{
89 // Mpo<Symmetry> n (size_t locx, size_t locy=0);
90 // Mpo<Symmetry> nh (size_t locx, size_t locy=0);
91 // Mpo<Symmetry> ns (size_t locx, size_t locy=0);
92 // Mpo<Symmetry> d (size_t locx, size_t locy=0);
93 // Mpo<Symmetry> cdagc (size_t locx1, size_t locx2, size_t locy1=0, size_t locy2=0);
94 // Mpo<Symmetry> ccdag (size_t locx1, size_t locx2, size_t locy1=0, size_t locy2=0);
95 // Mpo<Symmetry> dh_excitation (size_t locx);
96 // ///@}
97
98 // ///@{
99 // Mpo<Symmetry> nn (size_t locx1, size_t locx2, size_t locy1=0, size_t locy2=0);
100 //*\warning not implemented
101// Mpo<Symmetry> cdagcdagcc (size_t locx1, size_t locx2, size_t locy1=0, size_t locy2=0);
103
105 // Mpo<Symmetry> Simp (size_t locx, size_t locy=0, double factor=1.);
106 // Mpo<Symmetry> Simpdag (size_t locx, size_t locy=0, double factor=sqrt(3.));
107 // Mpo<Symmetry> Ssub (size_t locx, size_t locy=0, double factor=1.);
108 // Mpo<Symmetry> Ssubdag (size_t locx, size_t locy=0, double factor=sqrt(3.));
109 // Mpo<Symmetry,complex<double> > Simp_ky (vector<complex<double> > phases) const;
110 // Mpo<Symmetry,complex<double> > Simpdag_ky (vector<complex<double> > phases, double factor=sqrt(3.)) const;
111 // // for compatibility:
112 // Mpo<Symmetry> S (size_t locx, size_t locy=0, double factor=1.) {return Simp(locx,locy,factor);};
113 // Mpo<Symmetry> Sdag (size_t locx, size_t locy=0, double factor=sqrt(3.)) {return Simpdag(locx,locy,factor);};
114 // ///@}
115
116 // ///@{
117 // Mpo<Symmetry> SimpSimp (size_t locx1, size_t locx2, size_t locy1=0, size_t locy2=0);
118 // Mpo<Symmetry> SsubSsub (size_t locx1, size_t locx2, size_t locy1=0, size_t locy2=0);
119 // Mpo<Symmetry> SimpSsub (size_t locx1, size_t locx2, size_t locy1=0, size_t locy2=0);
121
122// ///@{ \warning not implemented
123// Mpo<Symmetry> SimpSsubSimpSimp (size_t locx1, size_t locx2,
124// size_t loc3x, size_t loc4x,
125// size_t locy1=0, size_t locy2=0, size_t loc3y=0, size_t loc4y=0);
126// Mpo<Symmetry> SimpSsubSimpSsub (size_t locx1, size_t locx2,
127// size_t loc3x, size_t loc4x,
128// size_t locy1=0, size_t locy2=0, size_t loc3y=0, size_t loc4y=0);
129// ///@}
130
131 static const map<string,any> defaults;
132 static const map<string,any> sweep_defaults;
133};
134
135const map<string,any> KondoSU2xU1::defaults =
136{
137 {"t",1.}, {"tPrime",0.}, {"tRung",0.},
138 {"J",1.}, {"Jdir",0.},
139 {"U",0.}, {"Uph",0.},
140 {"V",0.}, {"Vrung",0.},
141 {"mu",0.}, {"t0",0.},
142 {"Inext",0.}, {"Iprev",0.}, {"I3next",0.}, {"I3prev",0.}, {"I3loc",0.},
143 {"D",2ul}, {"maxPower",2ul}, {"CYLINDER",false}, {"Ly",1ul}, {"LyF",1ul}
144};
145
146const map<string,any> VMPS::KondoSU2xU1::sweep_defaults =
147{
148 {"max_alpha",100.}, {"min_alpha",1.}, {"lim_alpha",11ul}, {"eps_svd",1.e-7},
149 {"Mincr_abs", 50ul}, {"Mincr_per", 2ul}, {"Mincr_rel", 1.1},
150 {"min_Nsv",0ul}, {"max_Nrich",-1},
151 {"max_halfsweeps",30ul}, {"min_halfsweeps",6ul},
152 {"Minit",1ul}, {"Qinit",1ul}, {"Mlimit",10000ul},
153 {"tol_eigval",1.e-7}, {"tol_state",1.e-6},
154 {"savePeriod",0ul}, {"CALC_S_ON_EXIT", true}, {"CONVTEST", DMRG::CONVTEST::VAR_2SITE}
155};
156
158KondoSU2xU1 (const size_t &L, const vector<Param> &params, const BC &boundary, const DMRG::VERBOSITY::OPTION &VERB)
159:Mpo<Symmetry> (L, Symmetry::qvacuum(), "", PROP::HERMITIAN, PROP::NON_UNITARY, boundary, VERB),
160 KondoObservables(L,params,KondoSU2xU1::defaults),
161 ParamReturner(KondoSU2xU1::sweep_defaults)
162{
163 ParamHandler P(params,defaults);
164
165 size_t Lcell = P.size();
166
167 for (size_t l=0; l<N_sites; ++l)
168 {
169 N_phys += P.get<size_t>("LyF",l%Lcell);
170 setLocBasis((B[l].get_basis().combine(F[l].get_basis())).qloc(),l);
171 }
172
173 this->set_name("Kondo");
174
176 std::vector<std::vector<std::string>> labellist;
177 set_operators(B, F, P, pushlist, labellist, boundary);
178
179 this->construct_from_pushlist(pushlist, labellist, Lcell);
180 this->finalize(PROP::COMPRESS, P.get<size_t>("maxPower"));
181
182 this->precalc_TwoSiteData();
183}
184
186validate (qType qnum) const
187{
188 frac S_elec(qnum[1],2); //electrons have spin 1/2
189 frac Smax = S_elec;
190 for (size_t l=0; l<N_sites; ++l) { Smax+=static_cast<int>(B[l].orbitals())*frac(B[l].get_D()-1,2); } //add local spins to Smax
191
192 frac S_tot(qnum[0]-1,2);
193 if (Smax.denominator()==S_tot.denominator() and S_tot<=Smax and qnum[0]<=2*2*static_cast<int>(this->N_phys) and qnum[0]>0) {return true;}
194 else {return false;}
195}
196
197template<typename Symmetry_>
199set_operators (const std::vector<SpinBase<Symmetry_> > &B, const std::vector<FermionBase<Symmetry_> > &F, const ParamHandler &P,
200 PushType<SiteOperator<Symmetry_,double>,double>& pushlist, std::vector<std::vector<std::string>>& labellist, const BC boundary)
201{
202 std::size_t Lcell = P.size();
203 std::size_t N_sites = B.size();
204 if(labellist.size() != N_sites) {labellist.resize(N_sites);}
205
206 for (std::size_t loc=0; loc<N_sites; ++loc)
207 {
208 size_t lm1 = (loc==0)? N_sites-1 : loc-1;
209 size_t lp1 = (loc+1)%N_sites;
210 size_t lp2 = (loc+2)%N_sites;
211
212 std::size_t Forbitals = F[loc].orbitals();
213 std::size_t Fnext_orbitals = F[(loc+1)%N_sites].orbitals();
214 std::size_t Fnextn_orbitals = F[(loc+2)%N_sites].orbitals();
215
216 std::size_t Borbitals = B[loc].orbitals();
217 std::size_t Bnext_orbitals = B[(loc+1)%N_sites].orbitals();
218 std::size_t Bnextn_orbitals = B[(loc+2)%N_sites].orbitals();
219
220 stringstream Slabel;
221 Slabel << "S=" << print_frac_nice(frac(B[loc].get_D()-1,2));
222 labellist[loc].push_back(Slabel.str());
223
224 auto push_full = [&N_sites, &loc, &B, &F, &P, &pushlist, &labellist, &boundary] (string xxxFull, string label,
225 const vector<SiteOperatorQ<Symmetry_,Eigen::MatrixXd> > &first,
226 const vector<vector<SiteOperatorQ<Symmetry_,Eigen::MatrixXd> > > &last,
227 vector<double> factor, bool FERMIONIC) -> void
228 {
229 ArrayXXd Full = P.get<Eigen::ArrayXXd>(xxxFull);
230 vector<vector<std::pair<size_t,double> > > R = Geometry2D::rangeFormat(Full);
231
232 if (static_cast<bool>(boundary)) {assert(R.size() == N_sites and "Use an (N_sites)x(N_sites) hopping matrix for open BC!");}
233 else {assert(R.size() >= 2*N_sites and "Use at least a (2*N_sites)x(N_sites) hopping matrix for infinite BC!");}
234
235 for (size_t j=0; j<first.size(); j++)
236 for (size_t h=0; h<R[loc].size(); ++h)
237 {
238 size_t range = R[loc][h].first;
239 double value = R[loc][h].second;
240
241 if (range != 0)
242 {
243 vector<SiteOperatorQ<Symmetry_,Eigen::MatrixXd> > ops(range+1);
244 ops[0] = first[j];
245 for (size_t i=1; i<range; ++i)
246 {
247 if (FERMIONIC) {ops[i] = kroneckerProduct(B[(loc+i)%N_sites].Id(), F[(loc+i)%N_sites].sign());}
248 else {ops[i] = kroneckerProduct(B[(loc+i)%N_sites].Id(), F[(loc+i)%N_sites].Id());}
249 }
250 ops[range] = last[j][(loc+range)%N_sites];
251 pushlist.push_back(std::make_tuple(loc, ops, factor[j] * value));
252 }
253 }
254
255 stringstream ss;
256 ss << label << "(" << Geometry2D::hoppingInfo(Full) << ")";
257 labellist[loc].push_back(ss.str());
258 };
259
260 if (P.HAS("tFull"))
261 {
262 SiteOperatorQ<Symmetry_,Eigen::MatrixXd> c_sign_local = kroneckerProduct(B[loc].Id(),F[loc].c(0) * F[loc].sign());
263 SiteOperatorQ<Symmetry_,Eigen::MatrixXd> cdag_sign_local = kroneckerProduct(B[loc].Id(),(F[loc].cdag(0) * F[loc].sign()));
264 vector<SiteOperatorQ<Symmetry_,Eigen::MatrixXd> > c_ranges(N_sites); for (size_t i=0; i<N_sites; i++) {c_ranges[i] = kroneckerProduct(B[loc].Id(),F[i].c(0));}
265 vector<SiteOperatorQ<Symmetry_,Eigen::MatrixXd> > cdag_ranges(N_sites); for (size_t i=0; i<N_sites; i++) {cdag_ranges[i] = kroneckerProduct(B[loc].Id(),F[i].cdag(0));}
266
267 vector<SiteOperatorQ<Symmetry_,Eigen::MatrixXd> > first {cdag_sign_local,c_sign_local};
268 vector<vector<SiteOperatorQ<Symmetry_,Eigen::MatrixXd> > > last {c_ranges,cdag_ranges};
269 push_full("tFull", "tᵢⱼ", first, last, {-std::sqrt(2.),-std::sqrt(2.)}, PROP::FERMIONIC);
270 }
271
272 if (P.HAS("JdirFull"))
273 {
274 vector<SiteOperatorQ<Symmetry_,Eigen::MatrixXd> > first {kroneckerProduct(B[loc].Sdag(0),F[loc].Id())};
275 vector<SiteOperatorQ<Symmetry_,Eigen::MatrixXd> > S_ranges(N_sites);
276 for (size_t i=0; i<N_sites; i++) {S_ranges[i] = kroneckerProduct(B[i].S(0),F[loc].Id());}
277
278 vector<vector<SiteOperatorQ<Symmetry_,Eigen::MatrixXd> > > last {S_ranges};
279 push_full("Jdirfull", "Jdirᵢⱼ", first, last, {std::sqrt(3.)}, PROP::BOSONIC);
280 }
281
282 // local terms
283
284 // Kondo-J
285 param1d J = P.fill_array1d<double>("J", "Jorb", Forbitals, loc%Lcell);
286 labellist[loc].push_back(J.label);
287
288 // t⟂
289 param2d tPerp = P.fill_array2d<double>("tRung", "t", "tPerp", Forbitals, loc%Lcell, P.get<bool>("CYLINDER"));
290 labellist[loc].push_back(tPerp.label);
291
292 // V⟂
293 param2d Vperp = P.fill_array2d<double>("Vrung", "V", "Vperp", Forbitals, loc%Lcell, P.get<bool>("CYLINDER"));
294 labellist[loc].push_back(Vperp.label);
295
296 // Hubbard-U
297 param1d U = P.fill_array1d<double>("U", "Uorb", Forbitals, loc%Lcell);
298 labellist[loc].push_back(U.label);
299
300 // Hubbard-U
301 param1d Uph = P.fill_array1d<double>("Uph", "Uphorb", Forbitals, loc%Lcell);
302 labellist[loc].push_back(Uph.label);
303
304 // mu
305 param1d mu = P.fill_array1d<double>("mu", "muorb", Forbitals, loc%Lcell);
306 labellist[loc].push_back(mu.label);
307
308 // t0
309 param1d t0 = P.fill_array1d<double>("t0", "t0orb", Forbitals, loc%Lcell);
310 labellist[loc].push_back(t0.label);
311
312 if (F[loc].dim() > 1)
313 {
314 OperatorType KondoHamiltonian({1,0}, B[loc].get_basis().combine(F[loc].get_basis()));
315
316 ArrayXXd Jperp = B[loc].ZeroHopping();
317 ArrayXXd Jperpsub = F[loc].ZeroHopping();
318 ArrayXXd Vz = F[loc].ZeroHopping();
319 ArrayXXd Vxy = F[loc].ZeroHopping();
320
321 //set Hubbard part of Kondo Hamiltonian
322 KondoHamiltonian = kroneckerProduct(B[loc].Id(), F[loc].template HubbardHamiltonian<double>(U.a,Uph.a,t0.a-mu.a,tPerp.a,Vperp.a,Vz,Vxy,Jperpsub));
323
324 //set Heisenberg part of Hamiltonian
325// KondoHamiltonian += OperatorType::outerprod(B[loc].HeisenbergHamiltonian(Jperp), F[loc].Id(), {1,0});
326
327 //set interaction part of Hamiltonian.
328 for (int alfa=0; alfa<Forbitals; ++alfa)
329 {
330 assert(Borbitals == Forbitals and "Can only do a Kondo ladder with the same amount of spins and fermionic orbitals in y-direction!");
331 KondoHamiltonian += J(alfa) * sqrt(3.) * SiteOperatorQ<Symmetry_,Eigen::MatrixXd>::outerprod(B[loc].Sdag(alfa), F[loc].S(alfa), {1,0});
332 }
333
334 pushlist.push_back(std::make_tuple(loc, Mpo<Symmetry_,double>::get_N_site_interaction(KondoHamiltonian), 1.));
335 }
336
337 // NN terms
338 if (!P.HAS("tFull"))
339 {
340 // t∥
341 param2d tPara = P.fill_array2d<double>("t", "tPara", {Forbitals, Fnext_orbitals}, loc%Lcell);
342 labellist[loc].push_back(tPara.label);
343
344 // V∥
345 param2d Vpara = P.fill_array2d<double>("V", "Vpara", {Forbitals, Fnext_orbitals}, loc%Lcell);
346 labellist[loc].push_back(Vpara.label);
347
348 // JdirPara∥
349 param2d JdirPara = P.fill_array2d<double>("Jdir", "JdirPara", {Borbitals, Bnext_orbitals}, loc%Lcell);
350 labellist[loc].push_back(JdirPara.label);
351
352 if (loc < N_sites-1 or !static_cast<bool>(boundary))
353 {
354 for (int alfa=0; alfa<Forbitals; ++alfa)
355 for (int beta=0; beta<Fnext_orbitals; ++beta)
356 {
357 auto cF_loc = kroneckerProduct(B[loc].Id(), F[loc].c(alfa)) * kroneckerProduct(B[loc].Id(), F[loc].sign());
358 auto cdagF_loc = kroneckerProduct(B[loc].Id(), F[loc].cdag(alfa)) * kroneckerProduct(B[loc].Id(), F[loc].sign());
359
360 pushlist.push_back(std::make_tuple(loc, Mpo<Symmetry_,double>::get_N_site_interaction(cdagF_loc,kroneckerProduct(B[lp1].Id(),F[lp1].c(beta))),-std::sqrt(2.)*tPara(alfa,beta)));
361 pushlist.push_back(std::make_tuple(loc, Mpo<Symmetry_,double>::get_N_site_interaction(cF_loc,kroneckerProduct(B[lp1].Id(),F[lp1].cdag(beta))),-std::sqrt(2.)*tPara(alfa,beta)));
362
363 pushlist.push_back(std::make_tuple(loc, Mpo<Symmetry_,double>::get_N_site_interaction(kroneckerProduct(B[loc].Id(),F[loc].n(alfa)),
364 kroneckerProduct(B[lp1].Id(),F[lp1].n(beta))),Vpara(alfa,beta)));
365 }
366
367 for (int alfa=0; alfa<Borbitals; ++alfa)
368 for (int beta=0; beta<Bnext_orbitals; ++beta)
369 {
370 auto Sdag_loc = kroneckerProduct(B[loc].Sdag(alfa), F[loc].Id());
371 auto S_tight = kroneckerProduct(B[lp1].S(beta), F[lp1].Id());
372
373 pushlist.push_back(std::make_tuple(loc, Mpo<Symmetry_,double>::get_N_site_interaction(Sdag_loc, S_tight), JdirPara(alfa,beta) * std::sqrt(3.)));
374 }
375 }
376
377 // NN Kondo terms
378
379 param2d InextPara = P.fill_array2d<double>("Inext", "InextPara", {Borbitals, Fnext_orbitals}, loc%Lcell);
380 labellist[loc].push_back(InextPara.label);
381
382 if (loc < N_sites-1 or !static_cast<bool>(boundary))
383 {
384 for (int alfa=0; alfa<Borbitals; ++alfa)
385 for (int beta=0; beta<Fnext_orbitals; ++beta)
386 {
387 pushlist.push_back(std::make_tuple(loc, Mpo<Symmetry_,double>::get_N_site_interaction( kroneckerProduct(B[loc].Sdag(alfa), F[loc].Id()),
388 kroneckerProduct(B[lp1].Id(), F[lp1].S(beta))), sqrt(3.) * InextPara(alfa,beta)));
389 }
390 }
391
392 param2d IprevPara = P.fill_array2d<double>("Iprev", "IprevPara", {Forbitals, Bnext_orbitals}, loc%Lcell);
393 labellist[loc].push_back(IprevPara.label);
394
395 if (lm1 < N_sites-1 or !static_cast<bool>(boundary))
396 {
397 for (int alfa=0; alfa<Forbitals; ++alfa)
398 for (int beta=0; beta<Bnext_orbitals; ++beta)
399 {
400 pushlist.push_back(std::make_tuple(loc, Mpo<Symmetry_,double>::get_N_site_interaction( kroneckerProduct(B[lm1].Id(), F[lm1].Sdag(alfa)),
401 kroneckerProduct(B[loc].S(beta), F[loc].Id())), sqrt(3.) * IprevPara(alfa,beta)));
402 }
403 }
404
405 // NNN terms
406
407 param2d tPrime = P.fill_array2d<double>("tPrime", "tPrime_array", {Forbitals, Fnextn_orbitals}, loc%Lcell);
408 labellist[loc].push_back(tPrime.label);
409
410 if (loc < N_sites-2 or !static_cast<bool>(boundary))
411 {
412 for (std::size_t alfa=0; alfa<Forbitals; ++alfa)
413 for (std::size_t beta=0; beta<Fnextn_orbitals; ++beta)
414 {
415 auto cF_loc = kroneckerProduct(B[loc].Id(), F[loc].c(alfa)) * kroneckerProduct(B[loc].Id(), F[loc].sign());
416 auto cdagF_loc = kroneckerProduct(B[loc].Id(), F[loc].cdag(alfa)) * kroneckerProduct(B[loc].Id(), F[loc].sign());
417
418 pushlist.push_back(std::make_tuple(loc, Mpo<Symmetry_,double>::get_N_site_interaction(cdagF_loc,
419 kroneckerProduct(B[lp1].Id(),F[lp1].sign()),
420 kroneckerProduct(B[lp2].Id(),F[lp2].c(beta))),-std::sqrt(2.)*tPrime(alfa,beta)));
421 pushlist.push_back(std::make_tuple(loc, Mpo<Symmetry_,double>::get_N_site_interaction(cF_loc,
422 kroneckerProduct(B[lp1].Id(),F[lp1].sign()),
423 kroneckerProduct(B[lp2].Id(),F[lp2].cdag(beta))),-std::sqrt(2.)*tPrime(alfa,beta)));
424 }
425 }
426 }
427 }
428}
429
430
431// Mpo<Sym::S1xS2<Sym::SU2<Sym::SpinSU2>,Sym::U1<Sym::ChargeU1> > > KondoSU2xU1::
432// make_local (KONDO_SUBSYSTEM SUBSYS,
433// string name,
434// size_t locx, size_t locy,
435// const OperatorType &Op,
436// double factor, bool FERMIONIC, bool HERMITIAN) const
437// {
438// assert(locx<F.size() and locy<F[locx].dim());
439// assert(SUBSYS != IMPSUB);
440// stringstream ss;
441// ss << name << "(" << locx << "," << locy << ")";
442
443// Mpo<Sym::S1xS2<Sym::SU2<Sym::SpinSU2>,Sym::U1<Sym::ChargeU1> > > Mout(N_sites, Op.Q(), ss.str(), HERMITIAN);
444// for (size_t l=0; l<F.size(); ++l) {Mout.setLocBasis((B[l].get_basis().combine(F[l].get_basis())).qloc(),l);}
445
446// OperatorType OpExt;
447// vector<SiteOperator<Symmetry,MatrixType::Scalar> > SignExt(locx);
448
449// if (SUBSYS == SUB)
450// {
451// OpExt = OperatorType::outerprod(B[locx].Id(), Op, Op.Q());
452// for (size_t l=0; l<locx; ++l)
453// {
454// SignExt[l] = OperatorType::outerprod(B[l].Id(), F[l].sign(), Symmetry::qvacuum()).plain<double>();
455// }
456// }
457// else if (SUBSYS == IMP)
458// {
459// assert(!FERMIONIC and "Impurity cannot be fermionic!");
460// OpExt = OperatorType::outerprod(Op, F[locx].Id(), Op.Q());
461// }
462
463// Mout.set_locality(locx);
464// Mout.set_localOperator(OpExt.plain<double>());
465
466// (FERMIONIC)? Mout.setLocal(locx, (factor * OpExt).plain<double>(), SignExt)
467// : Mout.setLocal(locx, (factor * OpExt).plain<double>());
468
469// return Mout;
470// }
471
472// Mpo<Sym::S1xS2<Sym::SU2<Sym::SpinSU2>,Sym::U1<Sym::ChargeU1> > > KondoSU2xU1::
473// make_corr (KONDO_SUBSYSTEM SUBSYS,
474// string name1, string name2,
475// size_t locx1, size_t locx2, size_t locy1, size_t locy2,
476// const OperatorType &Op1, const OperatorType &Op2,
477// qarray<Symmetry::Nq> Qtot,
478// double factor,
479// bool BOTH_HERMITIAN)
480// {
481// assert(locx1<this->N_sites and locx2<this->N_sites);
482// stringstream ss;
483// ss << name1 << "(" << locx1 << "," << locy1 << ")" << name2 << "(" << locx2 << "," << locy2 << ")";
484
485// bool HERMITIAN = (BOTH_HERMITIAN and locx1==locx2 and locy1==locy2)? true:false;
486
487// Mpo<Symmetry> Mout(N_sites, Qtot, ss.str(), HERMITIAN);
488// for (size_t l=0; l<this->N_sites; l++) {Mout.setLocBasis((B[l].get_basis().combine(F[l].get_basis())).qloc(),l);}
489
490// OperatorType Op1Ext;
491// OperatorType Op2Ext;
492
493// if (SUBSYS == SUB)
494// {
495// Op1Ext = OperatorType::outerprod(B[locx1].Id(), Op1, Op1.Q());
496// Op2Ext = OperatorType::outerprod(B[locx2].Id(), Op2, Op2.Q());
497// }
498// else if (SUBSYS == IMP)
499// {
500// Op1Ext = OperatorType::outerprod(Op1, F[locx1].Id(), Op1.Q());
501// Op2Ext = OperatorType::outerprod(Op2, F[locx2].Id(), Op2.Q());
502// }
503// else if (SUBSYS == IMPSUB)
504// {
505// Op2Ext = OperatorType::outerprod(Op1, F[locx1].Id(), Op1.Q());
506// Op1Ext = OperatorType::outerprod(B[locx2].Id(), Op2, Op2.Q());
507// }
508
509// if (locx1 == locx2)
510// {
511// auto LocProd = OperatorType::prod(Op1Ext, Op2Ext, Qtot);
512// Mout.setLocal(locx1, factor * LocProd.plain<double>());
513// }
514// else
515// {
516// Mout.setLocal({locx1, locx2}, {factor * Op1Ext.plain<double>(), Op2Ext.plain<double>()});
517// }
518
519// return Mout;
520// }
521
522// Mpo<Sym::S1xS2<Sym::SU2<Sym::SpinSU2>,Sym::U1<Sym::ChargeU1> >,complex<double> > KondoSU2xU1::
523// make_FourierYSum (string name, const vector<OperatorType> &Ops,
524// double factor, bool HERMITIAN, const vector<complex<double> > &phases) const
525// {
526// stringstream ss;
527// ss << name << "_ky(";
528// for (int l=0; l<phases.size(); ++l)
529// {
530// ss << phases[l];
531// if (l!=phases.size()-1) {ss << ",";}
532// else {ss << ")";}
533// }
534
535// // all Ops[l].Q() must match
536// Mpo<Sym::S1xS2<Sym::SU2<Sym::SpinSU2>,Sym::U1<Sym::ChargeU1> >,complex<double> > Mout(N_sites, Ops[0].Q(), ss.str(), HERMITIAN);
537// for (size_t l=0; l<F.size(); ++l) {Mout.setLocBasis((B[l].get_basis().combine(F[l].get_basis())).qloc(),l);}
538
539// vector<complex<double> > phases_x_factor = phases;
540// for (int l=0; l<phases.size(); ++l)
541// {
542// phases_x_factor[l] = phases[l] * factor;
543// }
544
545// vector<SiteOperator<Symmetry,complex<double> > > OpsPlain(Ops.size());
546// for (int l=0; l<OpsPlain.size(); ++l)
547// {
548// OpsPlain[l] = Ops[l].plain<double>().cast<complex<double> >();
549// }
550
551// Mout.setLocalSum(OpsPlain, phases_x_factor);
552
553// return Mout;
554// }
555
556// //-----------------------------------------
557
558// Mpo<Sym::S1xS2<Sym::SU2<Sym::SpinSU2>,Sym::U1<Sym::ChargeU1> > > KondoSU2xU1::
559// n (size_t locx, size_t locy)
560// {
561// return make_local(SUB, "n", locx,locy, F[locx].n(locy), 1., false, true);
562// }
563
564// Mpo<Sym::S1xS2<Sym::SU2<Sym::SpinSU2>,Sym::U1<Sym::ChargeU1> > > KondoSU2xU1::
565// nh (size_t locx, size_t locy)
566// {
567// return make_local(SUB, "nh", locx,locy, F[locx].nh(locy), 1., false, true);
568// }
569
570// Mpo<Sym::S1xS2<Sym::SU2<Sym::SpinSU2>,Sym::U1<Sym::ChargeU1> > > KondoSU2xU1::
571// ns (size_t locx, size_t locy)
572// {
573// return make_local(SUB, "ns", locx,locy, F[locx].ns(locy), 1., false, true);
574// }
575
576// Mpo<Sym::S1xS2<Sym::SU2<Sym::SpinSU2>,Sym::U1<Sym::ChargeU1> > > KondoSU2xU1::
577// d (size_t locx, size_t locy)
578// {
579// return make_local(SUB, "d", locx,locy, F[locx].d(locy), 1., false, true);
580// }
581
582// Mpo<Sym::S1xS2<Sym::SU2<Sym::SpinSU2>,Sym::U1<Sym::ChargeU1> > > KondoSU2xU1::
583// c (size_t locx, size_t locy, double factor)
584// {
585// return make_local(SUB, "c", locx,locy, F[locx].c(locy), factor, true, false);
586// }
587
588// Mpo<Sym::S1xS2<Sym::SU2<Sym::SpinSU2>,Sym::U1<Sym::ChargeU1> > > KondoSU2xU1::
589// cdag (size_t locx, size_t locy, double factor)
590// {
591// return make_local(SUB, "c†", locx,locy, F[locx].cdag(locy), factor, true, false);
592// }
593
594// Mpo<Sym::S1xS2<Sym::SU2<Sym::SpinSU2>,Sym::U1<Sym::ChargeU1> > > KondoSU2xU1::
595// cc (size_t locx, size_t locy)
596// {
597// stringstream ss;
598// ss << "c" << UP << "c" << DN;
599// return make_local(SUB, ss.str(), locx,locy, F[locx].cc(locy), 1., false, false);
600// }
601
602// Mpo<Sym::S1xS2<Sym::SU2<Sym::SpinSU2>,Sym::U1<Sym::ChargeU1> > > KondoSU2xU1::
603// cdagcdag (size_t locx, size_t locy)
604// {
605// stringstream ss;
606// ss << "c†" << UP << "c†" << DN;
607// return make_local(SUB, ss.str(), locx,locy, F[locx].cdagcdag(locy), 1., false, false);
608// }
609
610// Mpo<Sym::S1xS2<Sym::SU2<Sym::SpinSU2>,Sym::U1<Sym::ChargeU1> > > KondoSU2xU1::
611// Ssub (size_t locx, size_t locy, double factor)
612// {
613// return make_local(SUB, "Ssub", locx,locy, F[locx].S(locy), factor, false, false);
614// }
615
616// Mpo<Sym::S1xS2<Sym::SU2<Sym::SpinSU2>,Sym::U1<Sym::ChargeU1> > > KondoSU2xU1::
617// Ssubdag (size_t locx, size_t locy, double factor)
618// {
619// return make_local(SUB, "Ssub†", locx,locy, F[locx].Sdag(locy), factor, false, false);
620// }
621
622// Mpo<Sym::S1xS2<Sym::SU2<Sym::SpinSU2>,Sym::U1<Sym::ChargeU1> > > KondoSU2xU1::
623// Simp (size_t locx, size_t locy, double factor)
624// {
625// return make_local(IMP, "Simp", locx,locy, B[locx].S(locy), factor, false, false);
626// }
627
628// Mpo<Sym::S1xS2<Sym::SU2<Sym::SpinSU2>,Sym::U1<Sym::ChargeU1> > > KondoSU2xU1::
629// Simpdag (size_t locx, size_t locy, double factor)
630// {
631// return make_local(IMP, "Simp†", locx,locy, B[locx].Sdag(locy), factor, false, false);
632// }
633
634
635// Mpo<Sym::S1xS2<Sym::SU2<Sym::SpinSU2>,Sym::U1<Sym::ChargeU1> >, complex<double> > KondoSU2xU1::
636// Simp_ky (vector<complex<double> > phases) const
637// {
638// vector<OperatorType> Ops(N_sites);
639// for (size_t l=0; l<N_sites; ++l)
640// {
641// Ops[l] = F[l].S(0);
642// }
643// return make_FourierYSum("S", Ops, 1., false, phases);
644// }
645
646// Mpo<Sym::S1xS2<Sym::SU2<Sym::SpinSU2>,Sym::U1<Sym::ChargeU1> >, complex<double> > KondoSU2xU1::
647// Simpdag_ky (vector<complex<double> > phases, double factor) const
648// {
649// vector<OperatorType> Ops(N_sites);
650// for (size_t l=0; l<N_sites; ++l)
651// {
652// Ops[l] = F[l].Sdag(0);
653// }
654// return make_FourierYSum("S†", Ops, 1., false, phases);
655// }
656
657// Mpo<Sym::S1xS2<Sym::SU2<Sym::SpinSU2>,Sym::U1<Sym::ChargeU1> > > KondoSU2xU1::
658// nn (size_t locx1, size_t locx2, size_t locy1, size_t locy2)
659// {
660// return make_corr (SUB, "n","n", locx1,locx2,locy1,locy2, F[locx1].n(locy1), F[locx2].n(locy2), Symmetry::qvacuum(), 1., true);
661// }
662
663// Mpo<Sym::S1xS2<Sym::SU2<Sym::SpinSU2>,Sym::U1<Sym::ChargeU1> > > KondoSU2xU1::
664// SsubSsub (size_t locx1, size_t locx2, size_t locy1, size_t locy2)
665// {
666// return make_corr (SUB, "Ssub","Ssub", locx1,locx2,locy1,locy2, F[locx1].Sdag(locy1),F[locx2].S(locy2), Symmetry::qvacuum(), sqrt(3.), false);
667// }
668
669// Mpo<Sym::S1xS2<Sym::SU2<Sym::SpinSU2>,Sym::U1<Sym::ChargeU1> > > KondoSU2xU1::
670// SimpSimp (size_t locx1, size_t locx2, size_t locy1, size_t locy2)
671// {
672// return make_corr (IMP, "Simp","Simp", locx1,locx2,locy1,locy2, B[locx1].Sdag(locy1),B[locx2].S(locy2), Symmetry::qvacuum(), sqrt(3.), false);
673// }
674
675// Mpo<Sym::S1xS2<Sym::SU2<Sym::SpinSU2>,Sym::U1<Sym::ChargeU1> > > KondoSU2xU1::
676// SimpSsub (size_t locx1, size_t locx2, size_t locy1, size_t locy2)
677// {
678// return make_corr (IMPSUB, "Simp","Ssub", locx1,locx2,locy1,locy2, B[locx1].Sdag(locy1),F[locx2].S(locy2), Symmetry::qvacuum(), sqrt(3.), false);
679// }
680
681// Mpo<Sym::S1xS2<Sym::SU2<Sym::SpinSU2>,Sym::U1<Sym::ChargeU1> > > KondoSU2xU1::
682// cdagc (size_t locx1, size_t locx2, size_t locy1, size_t locy2)
683// {
684// assert(locx1<this->N_sites and locx2<this->N_sites);
685// stringstream ss;
686// ss << "c†(" << locx1 << "," << locy1 << ")" << "c(" << locx2 << "," << locy2 << ")";
687
688// Mpo<Symmetry> Mout(N_sites, Symmetry::qvacuum(), ss.str());
689// for (size_t l=0; l<this->N_sites; l++) {Mout.setLocBasis((B[l].get_basis().combine(F[l].get_basis())).qloc(),l);}
690
691// auto cdag = OperatorType::outerprod(B[locx1].Id(), F[locx1].cdag(locy1),{2,+1});
692// auto c = OperatorType::outerprod(B[locx2].Id(), F[locx2].c(locy2), {2,-1});
693// auto sign1 = OperatorType::outerprod(B[locx1].Id(), F[locx1].sign(), {1, 0});
694// auto sign2 = OperatorType::outerprod(B[locx2].Id(), F[locx2].sign(), {1, 0});
695
696// vector<SiteOperator<Symmetry,MatrixType::Scalar> > signs;
697// for (size_t l=min(locx1,locx2)+1; l<max(locx1,locx2); l++)
698// {
699// signs.push_back(OperatorType::outerprod(B[l].Id(), F[l].sign(), {1, 0}).plain<double>());
700// }
701
702// if (locx1 == locx2)
703// {
704// Mout.setLocal(locx1, sqrt(2.) * OperatorType::prod(cdag,c,Symmetry::qvacuum()).plain<double>());
705// }
706// else if (locx1<locx2)
707// {
708// Mout.setLocal({locx1, locx2}, {sqrt(2.) * OperatorType::prod(cdag, sign1, {2,+1}).plain<double>(), c.plain<double>()}, signs);
709// }
710// else if (locx1>locx2)
711// {
712// Mout.setLocal({locx2, locx1}, {sqrt(2.) * OperatorType::prod(c, sign2, {2,-1}).plain<double>(), cdag.plain<double>()}, signs);
713// }
714// return Mout;
715// }
716
717// Mpo<Sym::S1xS2<Sym::SU2<Sym::SpinSU2>,Sym::U1<Sym::ChargeU1> > > KondoSU2xU1::
718// ccdag (size_t locx1, size_t locx2, size_t locy1, size_t locy2)
719// {
720// assert(locx1<this->N_sites and locx2<this->N_sites);
721// stringstream ss;
722// ss << "c(" << locx1 << "," << locy1 << ")" << "c†(" << locx2 << "," << locy2 << ")";
723
724// Mpo<Symmetry> Mout(N_sites, Symmetry::qvacuum(), ss.str());
725// for(size_t l=0; l<this->N_sites; l++) { Mout.setLocBasis((B[l].get_basis().combine(F[l].get_basis())).qloc(),l); }
726
727// auto cdag = OperatorType::outerprod(B[locx1].Id(),F[locx1].cdag(locy1),{2,+1});
728// auto c = OperatorType::outerprod(B[locx2].Id(),F[locx2].c(locy2),{2,-1});
729// auto sign = OperatorType::outerprod(B[locx2].Id(),F[locx2].sign(),{1,0});
730
731// if (locx1 == locx2)
732// {
733// auto product = sqrt(2.)*OperatorType::prod(c,cdag,Symmetry::qvacuum());
734// Mout.setLocal(locx1,product.plain<double>());
735// }
736// else if (locx1<locx2)
737// {
738// Mout.setLocal({locx1, locx2}, {sqrt(2.) * OperatorType::prod(c, sign, {2,-1}).plain<double>(),
739// cdag.plain<double>()},
740// sign.plain<double>());
741// }
742// else if (locx1>locx2)
743// {
744// Mout.setLocal({locx2, locx1}, {sqrt(2.)*OperatorType::prod(cdag, sign, {2,+1}).plain<double>(),
745// c.plain<double>()},
746// sign.plain<double>());
747// }
748// return Mout;
749// }
750
751// Mpo<Sym::S1xS2<Sym::SU2<Sym::SpinSU2>,Sym::U1<Sym::ChargeU1> > > KondoSU2xU1::
752// dh_excitation (size_t loc)
753// {
754// size_t lp1 = loc+1;
755
756// OperatorType PsiRloc = OperatorType::prod(OperatorType::prod(F[loc].c(0), F[loc].sign(), {2,-1}), F[loc].ns(0), {2,-1});
757// OperatorType PsidagLlp1 = OperatorType::prod(F[lp1].cdag(0), F[lp1].ns(0),{2,1});
758
759// Mpo<Symmetry> Mout(N_sites, Symmetry::qvacuum(), "dh");
760// for(size_t l=0; l<this->N_sites; l++) { Mout.setLocBasis((B[l].get_basis().combine(F[l].get_basis())).qloc(),l); }
761
762// OperatorType Op1Ext = OperatorType::outerprod(B[loc].Id(), PsiRloc, PsiRloc.Q());
763// OperatorType Op2Ext = OperatorType::outerprod(B[lp1].Id(), PsidagLlp1, PsidagLlp1.Q());
764
765// Mout.setLocal({loc, lp1}, {Op1Ext.plain<double>(), Op2Ext.plain<double>()});
766
767// return Mout;
768// }
769
770// Mpo<Sym::S1xS2<Sym::SU2<Sym::SpinSU2>,Sym::U1<Sym::ChargeU1> > > KondoSU2xU1::
771// cdagcdagcc (size_t locx1, size_t locx2, size_t locy1, size_t locy2)
772// {
773// assert(locx1<this->N_sites and locx2<this->N_sites);
774// stringstream ss;
775// ss << "η†(" << locx1 << "," << locy1 << ")" << "η(" << locx2 << "," << locy2 << ")";
776
777// Mpo<Symmetry> Mout(N_sites, N_legs);
778// for(size_t l=0; l<this->N_sites; l++) { Mout.setLocBasis(Spins.basis().combine(F.basis()),l); }
779
780// auto Etadag = Operator::outerprod(Spins.Id(),F.cdagcdag(locy1),{1,2});
781// auto Eta = Operator::outerprod(Spins.Id(),F.cc(locy2),{1,-2});
782// Mout.label = ss.str();
783// Mout.setQtarget(Symmetry::qvacuum());
784// Mout.qlabel = KondoSU2xU1::SNlabel;
785// if(locx1 == locx2)
786// {
787// auto product = Operator::prod(Etadag,Eta,Symmetry::qvacuum());
788// Mout.setLocal(locx1,product,Symmetry::qvacuum());
789// return Mout;
790// }
791// else
792// {
793// Mout.setLocal({locx1, locx2}, {Etadag, Eta}, {{1,2},{1,-2}});
794// return Mout;
795// }
796// }
797
798// Mpo<Sym::S1xS2<Sym::SU2<Sym::SpinSU2>,Sym::U1<Sym::ChargeU1> > > KondoSU2xU1::
799// SimpSsubSimpSimp (size_t locx1, size_t locx2, size_t loc3x, size_t loc4x,
800// size_t locy1, size_t locy2, size_t loc3y, size_t loc4y)
801// {
802// assert(locx1<this->N_sites and locx2<this->N_sites and loc3x<this->N_sites and loc4x<this->N_sites);
803// stringstream ss;
804// ss << SOP1 << "(" << locx1 << "," << locy1 << ")" << SOP2 << "(" << locx2 << "," << locy2 << ")" <<
805// SOP3 << "(" << loc3x << "," << loc3y << ")" << SOP4 << "(" << loc4x << "," << loc4y << ")";
806// Mpo<2> Mout(this->N_sites, this->N_legs, locBasis(), {0,0}, KondoSU2xU1::NMlabel, ss.str());
807// MatrixXd IdSub(F.dim(),F.dim()); IdSub.setIdentity();
808// MatrixXd IdImp(Mpo<2>::qloc[locx2].size()/F.dim(), Mpo<2>::qloc[locx2].size()/F.dim()); IdImp.setIdentity();
809// Mout.setLocal({locx1, locx2, loc3x, loc4x}, {kroneckerProduct(S.Scomp(SOP1,locy1),IdSub),
810// kroneckerProduct(IdImp,F.Scomp(SOP2,locy2)),
811// kroneckerProduct(S.Scomp(SOP3,loc3y),IdSub),
812// kroneckerProduct(S.Scomp(SOP4,loc4y),IdSub)});
813// return Mout;
814// }
815
816// Mpo<Sym::S1xS2<Sym::SU2<Sym::SpinSU2>,Sym::U1<Sym::ChargeU1> > > KondoSU2xU1::
817// SimpSsubSimpSsub (size_t locx1, size_t locx2, size_t loc3x, size_t loc4x,
818// size_t locy1, size_t locy2, size_t loc3y, size_t loc4y)
819// {
820// assert(locx1<this->N_sites and locx2<this->N_sites and loc3x<this->N_sites and loc4x<this->N_sites);
821// stringstream ss;
822// ss << SOP1 << "(" << locx1 << "," << locy1 << ")" << SOP2 << "(" << locx2 << "," << locy2 << ")" <<
823// SOP3 << "(" << loc3x << "," << loc3y << ")" << SOP4 << "(" << loc4x << "," << loc4y << ")";
824// Mpo<2> Mout(this->N_sites, this->N_legs, locBasis(), {0,0}, KondoSU2xU1::NMlabel, ss.str());
825// MatrixXd IdSub(F.dim(),F.dim()); IdSub.setIdentity();
826// MatrixXd IdImp(Mpo<2>::qloc[locx2].size()/F.dim(), Mpo<2>::qloc[locx2].size()/F.dim()); IdImp.setIdentity();
827// Mout.setLocal({locx1, locx2, loc3x, loc4x}, {kroneckerProduct(S.Scomp(SOP1,locy1),IdSub),
828// kroneckerProduct(IdImp,F.Scomp(SOP2,locy2)),
829// kroneckerProduct(S.Scomp(SOP3,loc3y),IdSub),
830// kroneckerProduct(IdImp,F.Scomp(SOP4,loc4y))}
831// );
832// return Mout;
833// }
834
835
836// bool KondoSU2xU1::
837// validate (qType qnum) const
838// {
839// int Sx2 = static_cast<int>(D-1); // necessary because of size_t
840// return (qnum[0]-1+N_legs*Sx2*imploc.size())%2 == qnum[1]%2;
841// }
842
843} //end namespace VMPS
844
845#endif
boost::rational< int > frac
Definition: DmrgExternal.h:11
std::string print_frac_nice(frac r)
Definition: DmrgExternal.h:32
size_t dim(const PivotMatrix0< Symmetry, Scalar, MpoScalar > &H)
MODEL_FAMILY
Definition: DmrgTypedefs.h:96
@ KONDO
Definition: DmrgTypedefs.h:96
BC
Definition: DmrgTypedefs.h:161
@ B
Definition: DmrgTypedefs.h:130
SiteOperator< Symmetry, Scalar_ > kroneckerProduct(const SiteOperator< Symmetry, Scalar_ > &O1, const SiteOperator< Symmetry, Scalar_ > &O2)
Definition: SiteOperator.h:164
std::enable_if< Dummy::IS_SPIN_SU2(), Mpo< Sym::S1xS2< Sym::SU2< Sym::SpinSU2 >, Sym::U1< Sym::ChargeU1 > > > >::type cdag(size_t locx, size_t locy=0, double factor=std::sqrt(2.)) const
std::enable_if< Dummy::IS_SPIN_SU2(), Mpo< Sym::S1xS2< Sym::SU2< Sym::SpinSU2 >, Sym::U1< Sym::ChargeU1 > > > >::type c(size_t locx, size_t locy=0, double factor=1.) const
std::enable_if< Dummy::IS_SPIN_SU2(), Mpo< Sym::S1xS2< Sym::SU2< Sym::SpinSU2 >, Sym::U1< Sym::ChargeU1 > > > >::type S(size_t locx, size_t locy=0, double factor=1.) const
vector< SpinBase< Sym::S1xS2< Sym::SU2< Sym::SpinSU2 >, Sym::U1< Sym::ChargeU1 > > > > B
vector< FermionBase< Sym::S1xS2< Sym::SU2< Sym::SpinSU2 >, Sym::U1< Sym::ChargeU1 > > > > F
std::enable_if<!Dummy::IS_SPIN_SU2(), Mpo< Sym::S1xS2< Sym::SU2< Sym::SpinSU2 >, Sym::U1< Sym::ChargeU1 > > > >::type n(size_t locx, size_t locy=0) const
std::size_t N_phys
Definition: MpoTerms.h:400
void finalize(const bool COMPRESS=true, const std::size_t power=1, const double tolerance=::mynumeric_limits< double >::epsilon())
Definition: MpoTerms.h:1281
std::size_t N_sites
Definition: MpoTerms.h:395
void setLocBasis(const std::vector< std::vector< qType > > &q)
Definition: MpoTerms.h:715
DMRG::VERBOSITY::OPTION VERB
Definition: MpoTerms.h:102
void set_name(const std::string &label_in)
Definition: MpoTerms.h:471
std::string label
Definition: MpoTerms.h:615
Definition: Mpo.h:40
void construct_from_pushlist(const PushType< OperatorType, CouplScalar > &pushlist, const std::vector< std::vector< std::string > > &labellist, size_t Lcell)
static SiteOperatorQ< Symmetry, MatrixType_ > outerprod(const SiteOperatorQ< Symmetry, MatrixType_ > &O1, const SiteOperatorQ< Symmetry, MatrixType_ > &O2, const qType &target)
Definition: U1.h:25
Kondo Model.
Definition: KondoSU2xU1.h:40
static constexpr MODEL_FAMILY FAMILY
Definition: KondoSU2xU1.h:44
static qarray< 2 > singlet(int N)
Definition: KondoSU2xU1.h:59
static qarray< 2 > polaron(int L, int N=0)
Definition: KondoSU2xU1.h:60
static const map< string, any > defaults
Definition: KondoSU2xU1.h:131
Sym::S1xS2< Sym::SU2< Sym::SpinSU2 >, Sym::U1< Sym::ChargeU1 > > Symmetry
Definition: KondoSU2xU1.h:42
Eigen::Index Index
Definition: KondoSU2xU1.h:47
Symmetry::qType qType
Definition: KondoSU2xU1.h:48
bool validate(qType qnum) const
Definition: KondoSU2xU1.h:186
static void set_operators(const std::vector< SpinBase< Symmetry_ > > &B, const std::vector< FermionBase< Symmetry_ > > &F, const ParamHandler &P, PushType< SiteOperator< Symmetry_, double >, double > &pushlist, std::vector< std::vector< std::string > > &labellist, const BC boundary=BC::OPEN)
Definition: KondoSU2xU1.h:199
static const map< string, any > sweep_defaults
Definition: KondoSU2xU1.h:132
Eigen::Matrix< double, Eigen::Dynamic, Eigen::Dynamic > MatrixType
Definition: KondoSU2xU1.h:49
#define MAKE_TYPEDEFS(MODEL)
Definition: macros.h:4
const bool COMPRESS
Definition: DmrgTypedefs.h:499
const bool FERMIONIC
Definition: DmrgTypedefs.h:496
const bool BOSONIC
Definition: DmrgTypedefs.h:498
Definition: qarray.h:26