CHROMA
barspinmat_w.cc
Go to the documentation of this file.
1 /*! \file
2  * \brief Baryon spin and projector matrices
3  */
4 
5 #include "chromabase.h"
7 
8 namespace Chroma
9 {
10 
11  /*! \ingroup hadron */
12  namespace BaryonSpinMats
13  {
14  //! NR = (1/2)* ( 1 + g_4 )
15  SpinMatrix NR()
16  {
17  SpinMatrix g_one = 1.0;
18  return SpinMatrix(0.5 * (g_one + (g_one * Gamma(8))));
19  }
20 
21  //! NRnegPar = (1/2)* ( 1 - g_4 )
22  SpinMatrix NRnegPar()
23  {
24  SpinMatrix g_one = 1.0;
25  return SpinMatrix(0.5 * (g_one - (g_one * Gamma(8))));
26  }
27 
28  //! C = Gamma(10)
29  SpinMatrix C()
30  {
31  return SpinMatrix(Gamma(10) * SpinMatrix(1.0));
32  }
33 
34  //! C NR = (1/2)*C * ( 1 + g_4 )
35  SpinMatrix CNR()
36  {
37  SpinMatrix g_one = 1.0;
38  return SpinMatrix(Gamma(10) * NR());
39  }
40 
41  //! C gamma_5 gamma_4 = - Gamma(13)
42  SpinMatrix Cg5g4()
43  {
44  SpinMatrix g_mone = -1.0;
45  return SpinMatrix(Gamma(13) * g_mone);
46  }
47 
48  //! C g_k = C gamma_k
49  SpinMatrix Cgk(int k)
50  {
51  SpinMatrix g_one = 1.0;
52  SpinMatrix gt;
53 
54  // NOTE: not being too careful about minus signs. Should check.
55  // However, all current uses have these matrices coming as a square
56  switch (k)
57  {
58  case 1:
59  gt = Gamma(11) * g_one;
60  break;
61 
62  case 2:
63  gt = Gamma(8) * g_one;
64  break;
65 
66  case 3:
67  gt = Gamma(14) * g_one;
68  break;
69 
70  default:
71  gt = g_one; // Make compiler happy
72  QDPIO::cerr << __func__ << ": invalid k=" << k << std::endl;
73  QDP_abort(1);
74  }
75  return gt;
76  }
77 
78  //! C g_\mu = \gamma_4 \gamma_2 \gamma_\mu
79  SpinMatrix Cgmu(int k)
80  {
81  SpinMatrix g_one = 1.0;
82  SpinMatrix gt;
83 
84  //signs have been checked...
85  switch (k)
86  {
87  case 1:
88  gt = Gamma(11) * g_one;
89  break;
90 
91  case 2:
92  gt = -(Gamma(8) * g_one);
93  break;
94 
95  case 3:
96  gt = -(Gamma(14) * g_one);
97  break;
98 
99  case 4:
100  gt = Gamma(2) * g_one;
101  break;
102 
103  default:
104  gt = g_one; // Make compiler happy
105  QDPIO::cerr << __func__ << ": invalid k=" << k << std::endl;
106  QDP_abort(1);
107  }
108  return gt;
109  }
110 
111  //! C g_\mu = \gamma_4 \gamma_2 transpose(\gamma_\mu)
112  SpinMatrix CgmuTrans(int k)
113  {
114  k--; //for compatibility with the Cgmu
115  SpinMatrix g_one = 1.0;
116  SpinMatrix gt;
117  //QDPIO::cout<<"CgmuTrans("<<k<<")"<<std::endl ;
118  SpinMatrix gmu = Gamma(1<<k)*g_one ;
119 
120  //signs have been checked...
121  // Gamma(10) = gamma_2 gamma_4
122  gt = Gamma(10)*transpose(gmu);
123 
124  return gt;
125  }
126 
127  //! C g4 g_k = C gamma_4 gamma_k
128  SpinMatrix Cg4gk(int k)
129  {
130  SpinMatrix g_one = 1.0;
131  SpinMatrix gt;
132 
133  // NOTE: not being too careful about minus signs. Should check.
134  // However, all current uses have these matrices coming as a square
135  switch (k)
136  {
137  case 1:
138  gt = Gamma(3) * g_one;
139  break;
140 
141  case 2:
142  gt = Gamma(0) * g_one;
143  break;
144 
145  case 3:
146  gt = Gamma(6) * g_one;
147  break;
148 
149  default:
150  gt = g_one; // Make compiler happy
151  QDPIO::cerr << __func__ << ": invalid k=" << k << std::endl;
152  QDP_abort(1);
153  }
154  return gt;
155  }
156 
157  //! C g_k NR = C gamma_k (1/2)(1 + gamma_4)
158  SpinMatrix CgkNR(int k)
159  {
160  return SpinMatrix(Cgk(k) * NR());
161  }
162 
163 
164  //! C g_5 = C gamma_5 = Gamma(5)
165  SpinMatrix Cg5()
166  {
167  return SpinMatrix(Gamma(5) * SpinMatrix(1.0));
168  }
169 
170 
171  //! C g_5 NR = (1/2)*C gamma_5 * ( 1 + g_4 )
172  SpinMatrix Cg5NR()
173  {
174  return SpinMatrix(Gamma(5) * NR());
175  }
176 
177  //! C g_5 NR = (1/2)*C gamma_5 * ( 1 - g_4 )
178  SpinMatrix Cg5NRnegPar()
179  {
180  SpinMatrix g_one = 1.0;
181 
182  return SpinMatrix(Gamma(5) * NRnegPar());
183  }
184 
185  //! C gamma_- = Cgm = (C gamma_-)^T
186  SpinMatrix Cgm()
187  {
188  SpinMatrix g_one = 1.0;
189  SpinMatrix g_tmp1 = 0.5 * (Gamma(2) * g_one + timesI(Gamma(1) * g_one));
190  return SpinMatrix(Gamma(10) * g_tmp1);
191  }
192 
193  //! C gamma_4 gamma_- = Cg4m
194  SpinMatrix Cg4m()
195  {
196  SpinMatrix g_one = 1.0;
197  SpinMatrix g_tmp1 = 0.5 * (Gamma(2) * g_one + timesI(Gamma(1) * g_one));
198  return SpinMatrix(Gamma(10) * (Gamma(8) * g_tmp1));
199  }
200 
201  //! C gamma_- NR = CgmNR = C gamma_- (1/2)(1 + gamma_4)
202  SpinMatrix CgmNR()
203  {
204  return SpinMatrix(Cgm() * NR());
205  }
206 
207  //! C gamma_+ = Cgm = (C gamma_+)^T
208  SpinMatrix Cgp()
209  {
210  SpinMatrix g_one = 1.0;
211  SpinMatrix g_tmp1 = 0.5 * (timesI(Gamma(1) * g_one) - Gamma(2) * g_one);
212  return SpinMatrix(Gamma(10) * g_tmp1);
213  }
214 
215  //! C gamma_4 gamma_+ = Cg4p
216  SpinMatrix Cg4p()
217  {
218  SpinMatrix g_one = 1.0;
219  SpinMatrix g_tmp1 = 0.5 * (timesI(Gamma(1) * g_one) - Gamma(2) * g_one );
220  return SpinMatrix(Gamma(10) * (Gamma(8) * g_tmp1));
221  }
222 
223  //! C gamma_+ NR = CgpNR = C gamma_+ (1/2)(1 + gamma_4)
224  SpinMatrix CgpNR()
225  {
226  return SpinMatrix(Cgp() * NR());
227  }
228 
229 
230 
231 
232  //! T = (1 + gamma_4) / 2 = (1 + Gamma(8)) / 2
233  SpinMatrix Tunpol()
234  {
235  return NR();
236  }
237 
238 
239  //! T = (1 + gamma_4) / 2 = (1 - Gamma(8)) / 2
240  SpinMatrix TunpolNegPar()
241  {
242  return NRnegPar();
243  }
244 
245 
246  //! T = \Sigma_3 (1 + gamma_4) / 2 = -i (Gamma(3) + Gamma(11)) / 2
247  SpinMatrix Tpol()
248  {
249  SpinMatrix g_one = 1.0;
250  return SpinMatrix(0.5 * timesMinusI(Gamma(3)*g_one + Gamma(11)*g_one));
251  }
252 
253  //! T = \Sigma_3 (1 - gamma_4) / 2 = -i (-Gamma(3) + Gamma(11)) / 2
254  SpinMatrix TpolNegPar()
255  {
256  SpinMatrix g_one = 1.0;
257  return SpinMatrix(0.5 * timesMinusI(Gamma(11)*g_one-Gamma(3)*g_one));
258  }
259 
260 
261  //! T = (1 + \Sigma_3)*(1 + gamma_4) / 2 = (1 + Gamma(8) - i G(3) - i G(11)) / 2
262  SpinMatrix Tmixed()
263  {
264  SpinMatrix g_one = 1.0;
265  return SpinMatrix(0.5*(g_one + Gamma(8)*g_one + timesMinusI(Gamma(3)*g_one + Gamma(11)*g_one)));
266  }
267 
268  //! T = (1 - \Sigma_3)*(1 - gamma_4) / 2 = (1 - Gamma(8) + i G(3) - i G(11)) / 2
269  // Need to flip the spin for time reversal
270  SpinMatrix TmixedNegPar()
271  {
272  SpinMatrix g_one = 1.0;
273  return SpinMatrix(0.5*(g_one - Gamma(8)*g_one + timesMinusI(Gamma(3)*g_one - Gamma(11)*g_one)));
274  }
275 
276  //! T = (1 + i \gamma_5 \gamma_3 )/2 = 1/2 *( 1 - iG(11) )
277  SpinMatrix TspinUp(){
278  SpinMatrix g_one = 1.0;
279  return SpinMatrix(0.5*(g_one + timesMinusI(Gamma(11)*g_one)));
280  }
281  //! T = (1 - i \gamma_5 \gamma_3 )/2 = 1/2 *( 1 + iG(11) )
282  SpinMatrix TspinDown(){
283  SpinMatrix g_one = 1.0;
284  return SpinMatrix(0.5*(g_one - timesMinusI(Gamma(11)*g_one)));
285  }
286 
287 #ifndef _FRANKLIN_
288  //! T = i \gamma_5 (\gamma_1 + i \gamma_2 )
289  SpinMatrix T_ig5XpiY(){
290  SpinMatrix g_one = 1.0;
291  SpinMatrix tt = (Gamma(1)*g_one - timesMinusI(Gamma(2)*g_one));
292  return SpinMatrix(-timesMinusI(Gamma(15)*tt));
293  }
294  //! T = i \gamma_5 (\gamma_1 - i \gamma_2 )
295  SpinMatrix T_ig5XmiY(){
296  SpinMatrix g_one = 1.0;
297  SpinMatrix tt = (Gamma(1)*g_one + timesMinusI(Gamma(2)*g_one));
298  return SpinMatrix(-timesMinusI(Gamma(15)*tt));
299  }
300 #else
301  //FIX FRANKLIN GNU COMPILER BUG
302  //! T = i \gamma_5 (\gamma_1 - i \gamma_2 )
303  SpinMatrix T_ig5XmiY( )
304  {
305  SpinMatrix g_one = 1.0;
306  //SpinMatrix tt = (Gamma(1)*g_one + timesMinusI(Gamma(2)*g_one));
307  SpinMatrix tt = (Gamma(14)*g_one - timesMinusI(Gamma(13)*g_one));
308  return SpinMatrix(timesMinusI(tt));
309  }
310 
311  //! T = i \gamma_5 (\gamma_1 + i \gamma_2 )
312  SpinMatrix T_ig5XpiY(){
313  SpinMatrix g_one = 1.0;
314  SpinMatrix tt = (Gamma(14)*g_one + timesMinusI(Gamma(13)*g_one));
315  return SpinMatrix(timesMinusI(tt));
316  }
317 #endif
318 
319  }
320 
321 } // end namespace
Baryon spin and projector matrices.
Primary include file for CHROMA library code.
SpinMatrix Cg4m()
C gamma_4 gamma_- = Cg4m.
SpinMatrix Tmixed()
T = (1 + \Sigma_3)*(1 + gamma_4) / 2 = (1 + Gamma(8) - i G(3) - i G(11)) / 2.
SpinMatrix Cgp()
C gamma_+ = Cgm = (C gamma_+)^T.
SpinMatrix Cg4p()
C gamma_4 gamma_+ = Cg4p.
SpinMatrix T_ig5XpiY()
T = i \gamma_5 (\gamma_1 + i \gamma_2 )
SpinMatrix Tunpol()
T = (1 + gamma_4) / 2 = (1 + Gamma(8)) / 2.
SpinMatrix CgpNR()
C gamma_+ NR = CgpNR = C gamma_+ (1/2)(1 + gamma_4)
SpinMatrix Cgmu(int k)
C g_\mu = \gamma_4 \gamma_2 \gamma_\mu.
Definition: barspinmat_w.cc:79
SpinMatrix NRnegPar()
NRnegPar = (1/2)* ( 1 - g_4 )
Definition: barspinmat_w.cc:22
SpinMatrix Cg5NRnegPar()
C g_5 NR = (1/2)*C gamma_5 * ( 1 - g_4 )
SpinMatrix CgkNR(int k)
C g_k NR = C gamma_k (1/2)(1 + gamma_4)
SpinMatrix TunpolNegPar()
T = (1 + gamma_4) / 2 = (1 - Gamma(8)) / 2.
SpinMatrix T_ig5XmiY()
T = i \gamma_5 (\gamma_1 - i \gamma_2 )
SpinMatrix TpolNegPar()
T = \Sigma_3 (1 - gamma_4) / 2 = -i (-Gamma(3) + Gamma(11)) / 2.
SpinMatrix NR()
NR = (1/2)* ( 1 + g_4 )
Definition: barspinmat_w.cc:15
SpinMatrix Cgm()
C gamma_- = Cgm = (C gamma_-)^T.
SpinMatrix TspinDown()
T = (1 - i \gamma_5 \gamma_3 )/2 = 1/2 *( 1 + iG(11) )
SpinMatrix TmixedNegPar()
T = (1 - \Sigma_3)*(1 - gamma_4) / 2 = (1 - Gamma(8) + i G(3) - i G(11)) / 2.
SpinMatrix CgmNR()
C gamma_- NR = CgmNR = C gamma_- (1/2)(1 + gamma_4)
SpinMatrix Cg5()
C g_5 = C gamma_5 = Gamma(5)
SpinMatrix C()
C = Gamma(10)
Definition: barspinmat_w.cc:29
SpinMatrix TspinUp()
T = (1 + i \gamma_5 \gamma_3 )/2 = 1/2 *( 1 - iG(11) )
SpinMatrix Cgk(int k)
C g_k = C gamma_k.
Definition: barspinmat_w.cc:49
SpinMatrix CgmuTrans(int k)
C g_\mu = \gamma_4 \gamma_2 transpose(\gamma_\mu)
SpinMatrix Cg4gk(int k)
C g4 g_k = C gamma_4 gamma_k.
SpinMatrix CNR()
C NR = (1/2)*C * ( 1 + g_4 )
Definition: barspinmat_w.cc:35
SpinMatrix Cg5NR()
C g_5 NR = (1/2)*C gamma_5 * ( 1 + g_4 )
SpinMatrix Cg5g4()
C gamma_5 gamma_4 = - Gamma(13)
Definition: barspinmat_w.cc:42
SpinMatrix Tpol()
T = \Sigma_3 (1 + gamma_4) / 2 = -i (Gamma(3) + Gamma(11)) / 2.
Asqtad Staggered-Dirac operator.
Definition: klein_gord.cc:10
void transpose(multi2d< LatticeColorVector > &dist_rep, const multi2d< LatticeColorVector > &prop_rep)
Take transpose of a matrix in (explicit) spin space.
int k
Definition: invbicg.cc:119