CHROMA
barQll_w.cc
Go to the documentation of this file.
1 /*! \file
2  * \brief Heavy Baryon (Qll) 2-pt function : Orginos and Savage
3  */
4 
5 #include "chromabase.h"
6 #include "util/ft/sftmom.h"
7 #include "barQll_w.h"
8 
9 namespace Chroma {
10 
11 //! Lambdaq and SigmaQ 2-pt functions
12 /*!
13  * \ingroup hadron
14  *
15  * This routine is specific to Wilson fermions!
16  *
17  * Construct baryon propagators for the LambdaQ and SigmaQ(*) with
18  * degenerate "u" and "d" quarks. In the heavy quark limit the Sigma
19  * and Sigma* are degenerate. The heavy quark is inserted in the infinitely heavy quark limit
20  * by a Wilson-Line without spin indices.
21  * We are effectively propagating a spin-0 diquark and a spin-1 diquark.
22  *
23  * \param u gauge field (Read)
24  * \param quark_prop1 quark propagator 1 ( Read )
25  * \param quark_prop2 quark propagator 2 ( Read )
26  * \param src_coord cartesian coordinates of the source ( Read )
27  * \param phases object holds list of momenta and Fourier phases ( Read )
28  * \param xml xml file object ( Read )
29  * \param xml_group group name for xml data ( Read )
30  *
31  */
32 
33 void Qll(const multi1d<LatticeColorMatrix>& u,
34  const LatticePropagator& quark_prop1,
35  const LatticePropagator& quark_prop2,
36  const multi1d<int>& src_coord,
37  const SftMom& phases,
38  XMLWriter& xml,
39  const std::string& xml_group)
40 {
41  START_CODE();
42 
43  if ( Ns != 4 || Nc != 3 ){ /* Code is specific to Ns=4 and Nc=3. */
44  QDPIO::cerr<<"Qll code only works for Nc=3 and Ns=4\n";
45  QDP_abort(111) ;
46  }
47 #if QDP_NC == 3
48  int length = phases.numSubsets() ;
49  int num_mom = phases.numMom();
50 
51  LatticeColorMatrix Qprop;
52 
53  HeavyQuarkProp(Qprop,u,src_coord,length);
54 
55  multi1d<DComplex> barLamQ;
56  multi1d<DComplex> barSigQ;
57  LatticePropagator di_quark;
58  LatticeComplex LamQ_prop, SigQx_prop, SigQy_prop, SigQz_prop;
59 
60 
61 
62  // LambdaQ : |LambdaQ> = (d C gamma_5 u) Q
63 
64  //spin-0 diquark
65  di_quark = quarkContract13(quark_prop1 * Gamma(5), Gamma(5) * quark_prop2);
66 
67  LamQ_prop = traceColor(Qprop * traceSpin(di_quark));
68 
69 
70  // SigmQ : |SigmaQ> = (d C gamma_mu u) Q : The SigmaQ and SigmaQ* are degenerate!!!!
71 
72  //spin-1 diquark oriented in x-direction
73  di_quark = quarkContract13(quark_prop1 * Gamma(11), Gamma(11) * quark_prop2);
74 
75  SigQx_prop = traceColor(Qprop * traceSpin(di_quark));
76 
77  //spin-1 diquark oriented in y-direction
78  di_quark = quarkContract13(quark_prop1 * Gamma(8), Gamma(8) * quark_prop2);
79 
80  SigQy_prop = traceColor(Qprop * traceSpin(di_quark));
81 
82  //spin-1 diquark oriented in z-direction
83  di_quark = quarkContract13(quark_prop1 * Gamma(14), Gamma(14) * quark_prop2);
84 
85  SigQz_prop = traceColor(Qprop * traceSpin(di_quark));
86 
87 
88  // Project onto zero momentum
89  multi2d<DComplex> hsumLamQ,hsumSigQx,hsumSigQy,hsumSigQz;
90  hsumLamQ = phases.sft(LamQ_prop);
91  hsumSigQx = phases.sft(SigQx_prop);
92  hsumSigQy = phases.sft(SigQy_prop);
93  hsumSigQz = phases.sft(SigQz_prop);
94 
95  multi2d<DComplex> LQprop(num_mom,length) ;
96  multi2d<DComplex> SQxprop(num_mom,length) ;
97  multi2d<DComplex> SQyprop(num_mom,length) ;
98  multi2d<DComplex> SQzprop(num_mom,length) ;
99 
100 
101  for(int sink_mom_num=0; sink_mom_num < num_mom; ++sink_mom_num)
102  for(int t = 0; t < length; ++t)
103  {
104  int t_eff = (t - src_coord[Nd-1] + length) % length;
105  LQprop[sink_mom_num][t_eff] = hsumLamQ[sink_mom_num][t];
106  SQxprop[sink_mom_num][t_eff] = hsumSigQx[sink_mom_num][t];
107  SQyprop[sink_mom_num][t_eff] = hsumSigQy[sink_mom_num][t];
108  SQzprop[sink_mom_num][t_eff] = hsumSigQz[sink_mom_num][t];
109  }
110 
111 
112  //XMLWriter xml_bar(xml);
113  push(xml, xml_group);
114  write(xml, "LambdaQ", LQprop[0]);
115  write(xml, "SigmaQx", SQxprop[0]);
116  write(xml, "SigmaQy", SQyprop[0]);
117  write(xml, "SigmaQz", SQzprop[0]);
118  pop(xml);
119 #endif
120  END_CODE();
121 }
122 
123 void Qll(const multi1d<LatticeColorMatrix>& u,
124  const LatticePropagator& quark_propagator,
125  const multi1d<int>& src_coord,
126  const SftMom& phases,
127  XMLWriter& xml,
128  const std::string& xml_group){
129  Qll(u,quark_propagator,quark_propagator,src_coord,phases,xml,xml_group) ;
130 }
131 
132 //! Heavy Quark Propagator
133 /*!
134  * \ingroup hadron
135  *
136  *
137  * This constructs the propagator for a spinless Wilson-Line propagating from the
138  * point src_coord forward in time, and vanishing on previous time-slices.
139  *
140  * \param Qprop Wilson-Line (write)
141  * \param u Gauge Field (Read)
142  * \param src_coord cartesian coordinates of the source ( Read )
143  * \param length Time length
144  * Added:
145  * \param bc Boundary condition = +/- 1 (p,ap bcs) or
146  * 0 for Dirichlet (no wraparound, default)
147  */
148 
149 void HeavyQuarkProp(LatticeColorMatrix& Qprop,
150  const multi1d<LatticeColorMatrix>& u,
151  const multi1d<int>& src_coord,int length,
152  int bc)
153 {
154 
155  Set slice ;
156  slice.make(TimeSliceFunc(Nd-1));
157 
158  Qprop = 0.0 ;
159 
160  ColorMatrix one = 1.0 ;
161 
162  pokeSite(Qprop,one,src_coord);
163 
164  LatticeColorMatrix U_t_minus_one ;
165  U_t_minus_one = shift(u[Nd-1],BACKWARD,Nd-1) ;
166  if (bc==0){//Dirichlet
167  for(int t(src_coord[Nd-1]+1);t<length;t++){
168  Qprop[slice[t]] = shift(Qprop,BACKWARD,Nd-1)*U_t_minus_one ;
169  }
170  }
171  else if (bc==1){//periodic bc's
172  for(int t(1);t<length;t++){
173  int t_eff = (t - src_coord[Nd-1] + length) % length;
174  Qprop[slice[t_eff]] = shift(Qprop,BACKWARD,Nd-1)*U_t_minus_one ;
175  }
176  }
177  else if (bc==-1){//anti-periodic
178  for(int t(1);t<length;t++){
179  int t_eff = (t - src_coord[Nd-1] + length) % length;
180  if (t_eff==0)//When we hit the boundary
181  Qprop[slice[t_eff]] = -shift(Qprop,BACKWARD,Nd-1)*U_t_minus_one ;
182  else
183  Qprop[slice[t_eff]] = shift(Qprop,BACKWARD,Nd-1)*U_t_minus_one ;
184  }
185  }
186 
187  Qprop = conj(transpose(Qprop));
188  std::cout<<"Norm of fwd prop = "<<norm2(Qprop)<<std::endl;
189 }
190 
191 
192 //! Backwards Heavy Quark Propagator
193 /*!
194  * \ingroup hadron
195  *
196  * This constructs the propagator for a spinless Wilson-Line propagating from the
197  * point src_coord BACKWARD in time, and vanishing on later time-slices.
198  *
199  * \param Qprop Wilson-Line (write)
200  * \param u Gauge Field (Read)
201  * \param src_coord cartesian coordinates of the source ( Read )
202  * \param length Timelength
203  * \param bc =0 Boundary condition (default 0 = Dirichlet,
204  * otherwise +/-1)
205  */
206 
207 void HeavyQuarkPropBack(LatticeColorMatrix& Qprop,
208  const multi1d<LatticeColorMatrix>& u,
209  const multi1d<int>& src_coord,int length,
210  int bc)
211 {
212 
213  Set slice ;
214  slice.make(TimeSliceFunc(Nd-1));
215 
216  /**
217  This is all wrong.
218  I have to rethink this whole deal...
219  Sigh.
220 
221  **/
222 
223  Qprop = 0.0 ;
224 
225  ColorMatrix one = 1.0 ;
226 
227  pokeSite(Qprop,one,src_coord);
228 
229  LatticeColorMatrix U_t_plus_one ;
230  U_t_plus_one = shift(u[Nd-1],FORWARD,Nd-1) ;
231  if (bc==0){
232  for(int t(src_coord[Nd-1]-2);t>=0;t--){
233  // Qprop[slice[t]] = shift(Qprop,FORWARD,Nd-1)*U_t_plus_one;
234  Qprop[slice[t]] = U_t_plus_one*shift(Qprop,FORWARD,Nd-1);
235  }
236  }
237  else if (bc==1){//periodic bc's
238  for(int t(1);t<length;t++){
239  int t_eff = (src_coord[Nd-1] - t - length) % length;
240  Qprop[slice[t_eff]] = U_t_plus_one*shift(Qprop,FORWARD,Nd-1);
241  // Qprop[slice[t_eff]] = shift(Qprop,FORWARD,Nd-1)*U_t_plus_one;
242  }
243  }
244  else if (bc==-1){//anti-periodic
245  for(int t(1);t<length;t++){
246  int t_eff = length + (src_coord[Nd-1] - t - length) % length;
247  if (t_eff==(length-1))//When we hit the boundary
248  Qprop[slice[t_eff]] = -U_t_plus_one*shift(Qprop,FORWARD,Nd-1);
249  // Qprop[slice[t_eff]] = -shift(Qprop,FORWARD,Nd-1)*U_t_plus_one;
250  else
251  Qprop[slice[t_eff]] = U_t_plus_one*shift(Qprop,FORWARD,Nd-1);
252  // Qprop[slice[t_eff]] = shift(Qprop,FORWARD,Nd-1)*U_t_plus_one;
253  }
254  }
255  // Don't think we need to do this....
256  //Qprop = conj(transpose(Qprop));
257  std::cout<<"Norm of bwd prop = "<<norm2(Qprop)<<std::endl;
258 }
259 
260 
261 }
Heavy Baryon (Qll) 2-pt function : Orginos and Savage.
Primary include file for CHROMA library code.
Fourier transform phase factor support.
Definition: sftmom.h:35
int numSubsets() const
Number of subsets - length in decay direction.
Definition: sftmom.h:63
multi2d< DComplex > sft(const LatticeComplex &cf) const
Do a sumMulti(cf*phases,getSet())
Definition: sftmom.cc:524
int numMom() const
Number of momenta.
Definition: sftmom.h:60
Function object used for constructing the time-slice set.
Definition: barQll_w.h:95
void write(XMLWriter &xml, const std::string &path, const AsqtadFermActParams &param)
Writer parameters.
void HeavyQuarkProp(LatticeColorMatrix &Qprop, const multi1d< LatticeColorMatrix > &u, const multi1d< int > &src_coord, int length, int bc)
Heavy Quark Propagator.
Definition: barQll_w.cc:149
void Qll(const multi1d< LatticeColorMatrix > &u, const LatticePropagator &quark_prop1, const LatticePropagator &quark_prop2, const multi1d< int > &src_coord, const SftMom &phases, XMLWriter &xml, const std::string &xml_group)
Lambdaq and SigmaQ 2-pt functions.
Definition: barQll_w.cc:33
void HeavyQuarkPropBack(LatticeColorMatrix &Qprop, const multi1d< LatticeColorMatrix > &u, const multi1d< int > &src_coord, int length, int bc)
Backwards Heavy Quark Propagator.
Definition: barQll_w.cc:207
multi1d< int > bc
int t
Definition: meslate.cc:37
Nd
Definition: meslate.cc:74
Asqtad Staggered-Dirac operator.
Definition: klein_gord.cc:10
static multi1d< LatticeColorMatrix > u
void transpose(multi2d< LatticeColorVector > &dist_rep, const multi2d< LatticeColorVector > &prop_rep)
Take transpose of a matrix in (explicit) spin space.
Double one
Definition: invbicg.cc:105
push(xml_out,"Condensates")
pop(xml_out)
START_CODE()
::std::string string
Definition: gtest.h:1979
#define FORWARD
Definition: primitives.h:82
#define BACKWARD
Definition: primitives.h:83
Fourier transform phase factor support.