CHROMA
wallrhopiff_w.cc
Go to the documentation of this file.
1 /*! \file
2  * \brief Wall-sink rho^+ <-> gamma+pi^+ form-factors
3  *
4  * Form factors constructed from a quark and a backward quark propagator
5  */
6 
7 #include "chromabase.h"
9 
10 namespace Chroma {
11 
12 //! Wall-sink rho^+ <-> gamma+pi^+ form-factors
13 /*!
14  * \ingroup hadron
15  *
16  * This routine is specific to Wilson fermions!
17  *
18  * \param form Mega-structure holding form-factors ( Write )
19  * \param u gauge fields (used for non-local currents) ( Read )
20  * \param forw_u_prop forward U quark propagator ( Read )
21  * \param back_u_prop backward D quark propagator ( Read )
22  * \param forw_d_prop forward U quark propagator ( Read )
23  * \param back_d_prop backward D quark propagator ( Read )
24  * \param u_x2 forward U quark propagator evaluated at sink ( Read )
25  * \param d_x2 forward D quark propagator evaluated at sink ( Read )
26  * \param phases fourier transform phase factors ( Read )
27  * \param t0 time slice of the source ( Read )
28  * \param wall_source true if using a wall source ( Read )
29  */
30 
32  const multi1d<LatticeColorMatrix>& u,
33  const LatticePropagator& forw_u_prop,
34  const LatticePropagator& back_u_prop,
35  const LatticePropagator& forw_d_prop,
36  const LatticePropagator& back_d_prop,
37  const Propagator& u_x2,
38  const Propagator& d_x2,
39  const SftMom& phases,
40  int t0,
41  bool wall_source)
42 {
43  START_CODE();
44 
45  if ( Ns != 4 || Nc != 3 || Nd != 4 ) // Code is specific to Ns=4, Nc=3, Nd=4
46  return;
47 
48  form.subroutine = "wallRhoPiFormFac";
49 
50  // Length of lattice in decay direction and 3pt correlations fcns
51  int length = phases.numSubsets();
52 
53  int G5 = Ns*Ns-1;
54 
55  // The list of meaningful insertions
56  // The gamma matrices specified correspond to
57  // V_mu and A_mu = gamma_mu gamma_5, specificially
58  // where in the Chroma code gamma_5 = g_3 g_2 g_1 g_0
59  //
60  // GAMMA CURRENT
61  // 1 V_0
62  // 2 V_1
63  // 4 V_2
64  // 8 V_3
65  // 14 -A_0
66  // 13 A_1
67  // 11 -A_2
68  // 7 A_3
69  multi1d<int> gamma_list(2*Nd);
70  gamma_list[0] = 1;
71  gamma_list[1] = 2;
72  gamma_list[2] = 4;
73  gamma_list[3] = 8;
74  gamma_list[4] = 14;
75  gamma_list[5] = 13;
76  gamma_list[6] = 11;
77  gamma_list[7] = 7;
78 
79  // Quark names
80  multi1d<std::string> quark_name(2);
81  quark_name[0] = "u";
82  quark_name[1] = "d";
83 
84  // Formfac names
85  multi1d<std::string> formfac_name(2);
86  formfac_name[0] = "rho->gamma+pi";
87  formfac_name[0] = "pi+gamma->rho";
88 
89  // Projector names
90  multi1d<std::string> proj_name(1);
91  proj_name[0] = "none";
92 
93 
94  // Antiquarks
95  LatticePropagator anti_u_prop = adj(Gamma(G5)*back_u_prop*Gamma(G5));
96  LatticePropagator anti_d_prop = adj(Gamma(G5)*back_d_prop*Gamma(G5));
97 
98 
99  // Resize some things - this is needed upfront because I traverse the
100  // structure in a non-recursive scheme
101  form.quark.resize(quark_name.size());
102  for (int ud=0; ud < form.quark.size(); ++ud)
103  {
104  form.quark[ud].formfac.resize(formfac_name.size());
105  for(int dp = 0; dp < form.quark[ud].formfac.size(); ++dp)
106  {
107  form.quark[ud].formfac[dp].lorentz.resize(Nd);
108  for(int lorz = 0; lorz < form.quark[ud].formfac[dp].lorentz.size(); ++lorz)
109  {
110  form.quark[ud].formfac[dp].lorentz[lorz].projector.resize(proj_name.size());
111  for (int proj = 0; proj < form.quark[ud].formfac[dp].lorentz[lorz].projector.size(); ++proj)
112  {
113  form.quark[ud].formfac[dp].lorentz[lorz].projector[proj].insertion.resize(gamma_list.size());
114  }
115  }
116  }
117  }
118 
119 
120  // For calculational purpose, loop over insertions first.
121  // This is out-of-order from storage within the data structure
122  // Loop over gamma matrices of the insertion current of insertion current
123  for(int gamma_ctr = 0; gamma_ctr < gamma_list.size(); ++gamma_ctr)
124  {
125  int gamma_value = gamma_list[gamma_ctr];
126  int mu = gamma_ctr % Nd;
127  bool compute_nonlocal = (gamma_ctr < Nd) ? true : false;
128 
129  // Loop over "u"=0 or "d"=1 pieces
130  for(int ud = 0; ud < form.quark.size(); ++ud)
131  {
132  WallFormFac_quark_t& quark = form.quark[ud];
133  quark.quark_ctr = ud;
134  quark.quark_name = quark_name[ud];
135 
136  LatticePropagator local_insert_prop, nonlocal_insert_prop;
137 
138  switch (ud)
139  {
140  case 0:
141  {
142  // "\bar u O u" insertion in rho
143  // The local non-conserved current contraction
144  local_insert_prop = anti_u_prop*Gamma(gamma_value)*forw_u_prop;
145 
146  if (compute_nonlocal)
147  {
148  // Construct the non-local (possibly conserved) current contraction
149  nonlocal_insert_prop = nonlocalCurrentProp(u, mu, forw_u_prop, anti_u_prop);
150  }
151  }
152  break;
153 
154  case 1:
155  {
156  // "\bar d O d" insertion in rho
157  // The local non-conserved current contraction
158  local_insert_prop = anti_d_prop*Gamma(gamma_value)*forw_d_prop;
159 
160  if (compute_nonlocal)
161  {
162  // Construct the non-local (possibly conserved) current contraction
163  nonlocal_insert_prop = nonlocalCurrentProp(u, mu, forw_d_prop, anti_d_prop);
164  }
165  }
166  break;
167 
168  default:
169  QDP_error_exit("Unknown ud type", ud);
170  }
171 
172 
173  // Loop over "rho->pi"=0, "pi->rho"=1 types of form-factors
174  for(int dp = 0; dp < quark.formfac.size(); ++dp)
175  {
176  WallFormFac_formfac_t& formfac = quark.formfac[dp];
177  formfac.formfac_ctr = dp;
178  formfac.formfac_name = formfac_name[dp];
179 
180  LatticeComplex local_contract, nonlocal_contract;
181 
182 
183  // Loop over Lorentz indices of source and sink hadron operators
184  for(int lorz = 0; lorz < formfac.lorentz.size(); ++lorz)
185  {
186  WallFormFac_lorentz_t& lorentz = formfac.lorentz[lorz];
187  lorentz.lorentz_ctr = lorz;
188 
189  int sigma = lorz; // Lorentz index at source or sink
190  int gamma_value1, gamma_value2;
191 
192  if (dp == 0)
193  {
194  gamma_value1 = G5;
195  gamma_value2 = 1 << sigma;
196  }
197  else
198  {
199  gamma_value1 = 1 << sigma;
200  gamma_value2 = G5;
201  }
202 
203  lorentz.snk_gamma = gamma_value1;
204  lorentz.src_gamma = gamma_value2;
205 
206  // Contractions depend on "ud" (u or d quark contribution)
207  // and source/sink operators
208  switch (ud)
209  {
210  case 0:
211  {
212  // "\bar u O u" insertion in rho
213  // The local non-conserved current contraction
214  local_contract =
215  trace(Gamma(gamma_value1)*local_insert_prop*Gamma(gamma_value2)*
216  Gamma(G5)*adj(d_x2)*Gamma(G5));
217 
218  if (compute_nonlocal)
219  {
220  // Construct the non-local (possibly conserved) current contraction
221  nonlocal_contract =
222  trace(Gamma(gamma_value1)*nonlocal_insert_prop*Gamma(gamma_value2)*
223  Gamma(G5)*adj(d_x2)*Gamma(G5));
224  }
225  }
226  break;
227 
228  case 1:
229  {
230  // "\bar d O d" insertion in rho
231  // The local non-conserved current contraction
232  local_contract =
233  trace(Gamma(gamma_value1)*u_x2*Gamma(gamma_value2)*
234  Gamma(G5)*adj(local_insert_prop)*Gamma(G5));
235 
236  if (compute_nonlocal)
237  {
238  // Construct the non-local (possibly conserved) current contraction
239  nonlocal_contract =
240  trace(Gamma(gamma_value1)*u_x2*Gamma(gamma_value2)*
241  Gamma(G5)*adj(nonlocal_insert_prop)*Gamma(G5));
242  }
243  }
244  break;
245 
246  default:
247  QDP_error_exit("Unknown ud type", ud);
248  }
249 
250 
251  // Loop over the spin projectors - none here
252  for (int proj = 0; proj < lorentz.projector.size(); ++proj)
253  {
254  WallFormFac_projector_t& projector = lorentz.projector[proj];
255  projector.proj_ctr = proj;
256  projector.proj_name = proj_name[proj];
257 
258  WallFormFac_insertion_t& insertion = projector.insertion[gamma_ctr];
259 
260  insertion.gamma_ctr = gamma_ctr;
261  insertion.mu = mu;
262  insertion.gamma_value = gamma_value;
263 
264  // The local non-conserved std::vector-current matrix element
265  LatticeComplex corr_local_fn = local_contract;
266 
267  // The nonlocal (possibly conserved) current matrix element
268  LatticeComplex corr_nonlocal_fn = nonlocal_contract;
269 
270  multi1d<WallFormFac_momenta_t>& momenta = insertion.momenta;
271 
272  wallFormFacSft(momenta, corr_local_fn, corr_nonlocal_fn, phases,
273  compute_nonlocal, t0);
274 
275  } // end for(proj)
276  } // end for(lorz)
277  } // end for(dp)
278  } // end for(ud)
279  } // end for(gamma_ctr)
280 
281  END_CODE();
282 }
283 
284 } // end namespace Chroma
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
int mu
Definition: cool.cc:24
void wallFormFacSft(multi1d< WallFormFac_momenta_t > &momenta, const LatticeComplex &corr_local_fn, const LatticeComplex &corr_nonlocal_fn, const SftMom &phases, bool compute_nonlocal, int t0)
Do slow SFT over hadron correlator data.
Definition: wallff_w.cc:54
void wallRhoPiFormFac(WallFormFac_formfacs_t &form, const multi1d< LatticeColorMatrix > &u, const LatticePropagator &forw_u_prop, const LatticePropagator &back_u_prop, const LatticePropagator &forw_d_prop, const LatticePropagator &back_d_prop, const Propagator &u_x2, const Propagator &d_x2, const SftMom &phases, int t0, bool wall_source)
Wall-sink rho^+ <-> gamma+pi^+ form-factors.
LatticePropagator nonlocalCurrentProp(const multi1d< LatticeColorMatrix > &u, int mu, const LatticePropagator &forw_prop, const LatticePropagator &anti_prop)
Compute nonlocal current propagator.
Definition: wallff_w.cc:28
Nd
Definition: meslate.cc:74
Asqtad Staggered-Dirac operator.
Definition: klein_gord.cc:10
QDP_error_exit("too many BiCG iterations", n_count, rsd_sq, cp, c, re_rvr, im_rvr, re_a, im_a, re_b, im_b)
int G5
Definition: pbg5p_w.cc:57
static multi1d< LatticeColorMatrix > u
START_CODE()
multi1d< WallFormFac_lorentz_t > lorentz
Definition: wallff_w.h:51
multi1d< WallFormFac_quark_t > quark
Definition: wallff_w.h:64
multi1d< WallFormFac_momenta_t > momenta
Definition: wallff_w.h:29
multi1d< WallFormFac_projector_t > projector
Definition: wallff_w.h:44
multi1d< WallFormFac_insertion_t > insertion
Definition: wallff_w.h:36
multi1d< WallFormFac_formfac_t > formfac
Definition: wallff_w.h:58
Wall-sink rho^+ -> gamma+pi^+ form-factors.