ThePEG  1.8.0
TensorWaveFunction.h
1 // -*- C++ -*-
2 //
3 // TensorWaveFunction.h is a part of ThePEG - Toolkit for HEP Event Generation
4 // Copyright (C) 2003-2011 Peter Richardson, Leif Lonnblad
5 //
6 // ThePEG is licenced under version 2 of the GPL, see COPYING for details.
7 // Please respect the MCnet academic guidelines, see GUIDELINES for details.
8 //
9 #ifndef ThePEG_TensorWaveFunction_H
10 #define ThePEG_TensorWaveFunction_H
11 //
12 // This is the declaration of the TensorWaveFunction class.
13 //
14 #include "WaveFunctionBase.h"
15 #include "VectorWaveFunction.h"
16 #include <ThePEG/Helicity/LorentzTensor.h>
17 #include <ThePEG/Helicity/TensorSpinInfo.h>
18 #include <ThePEG/EventRecord/Particle.h>
19 #include <ThePEG/EventRecord/RhoDMatrix.h>
20 
21 namespace ThePEG {
22 namespace Helicity {
23 
32 };
33 
68 
69 public:
70 
84  : WaveFunctionBase(p,part,dir), _wf(wave)
85  {
86  assert(iSpin()==PDT::Spin2);
87  }
88 
114  Complex tt)
115  : WaveFunctionBase(p,part), _wf(xx,xy,xz,xt,
116  yx,yy,yz,yt,
117  zx,zy,zz,zt,
118  tx,ty,tz,tt)
119  {
120  assert(iSpin()==PDT::Spin2);
121  }
122 
132  unsigned int ihel,Direction dir,
134  : WaveFunctionBase(p,part,dir)
135  {
136  assert(iSpin()==PDT::Spin2);
137  calculateWaveFunction(ihel,phase);
138  }
139 
147  tcPDPtr part,Direction dir)
148  : WaveFunctionBase(p,part,dir), _wf()
149  {
150  assert(iSpin()==PDT::Spin2);
151  }
152 
157 
161  TensorWaveFunction(vector<TensorWaveFunction> & wave,
162  tPPtr part,Direction dir,bool time,bool massless,
163  bool=true,
165  calculateWaveFunctions(wave,part,dir,massless,phase);
166  constructSpinInfo(wave,part,dir,time,massless);
167  }
169 
177  Complex operator ()(int i, int j) const {
178  return _wf(i,j);
179  }
180 
184  Complex & operator () (int i, int j) {
185  return _wf(i,j);
186  }
187 
191  const LorentzTensor<double> & wave() const {return _wf;}
192 
196  Complex xx() const {return _wf.xx();}
197 
201  Complex yx() const {return _wf.yx();}
202 
206  Complex zx() const {return _wf.zx();}
207 
211  Complex tx() const {return _wf.tx();}
212 
216  Complex xy() const {return _wf.xy();}
217 
221  Complex yy() const {return _wf.yy();}
222 
226  Complex zy() const {return _wf.zy();}
227 
231  Complex ty() const {return _wf.ty();}
232 
236  Complex xz() const {return _wf.xz();}
237 
241  Complex yz() const {return _wf.yz();}
242 
246  Complex zz() const {return _wf.zz();}
247 
251  Complex tz() const {return _wf.tz();}
252 
256  Complex xt() const {return _wf.xt();}
257 
261  Complex yt() const {return _wf.yt();}
262 
266  Complex zt() const {return _wf.zt();}
267 
271  Complex tt() const {return _wf.tt();}
273 
278 
284  void reset(unsigned int ihel,TensorPhase phase=default_tensor_phase) {
285  calculateWaveFunction(ihel,phase);
286  }
288 
289 public:
290 
294  void transform(const LorentzRotation & r) {
295  _wf.transform(r);
297  }
298 
299 public:
300 
304  static void calculateWaveFunctions(vector<LorentzTensor<double> > & waves,
305  tPPtr particle,Direction,bool massless,
307 
311  static void calculateWaveFunctions(vector<TensorWaveFunction> & waves,
312  tPPtr particle,Direction,bool massless,
314 
318  static void calculateWaveFunctions(vector<LorentzTensor<double> > & waves,
319  RhoDMatrix & rho,
320  tPPtr particle,Direction,bool massless,
322 
326  static void calculateWaveFunctions(vector<TensorWaveFunction> & waves,
327  RhoDMatrix & rho,
328  tPPtr particle,Direction,bool massless,
330 
334  static void constructSpinInfo(const vector<LorentzTensor<double> > & waves,
335  tPPtr part,Direction dir, bool time,bool massless);
336 
340  static void constructSpinInfo(const vector<TensorWaveFunction> & waves,
341  tPPtr part,Direction dir, bool time,bool massless);
342 
343 private:
344 
350  void calculateWaveFunction(unsigned int ihel,
352 
353 private:
354 
359 
360 };
361 }
362 }
363 
364 #endif