9 #ifndef ThePEG_LorentzSpinor_H
10 #define ThePEG_LorentzSpinor_H
12 #include "ThePEG/Config/ThePEG.h"
13 #include "ThePEG/Vectors/LorentzRotation.h"
14 #include "ThePEG/Vectors/ThreeVector.h"
16 #include "LorentzSpinor.fh"
17 #include "LorentzSpinorBar.h"
18 #include "LorentzPolarizationVector.h"
68 template<
typename Value>
78 for(
unsigned int ix=0;ix<4;++ix)
_spin[ix]=Value();
86 complex<Value> c,complex<Value> d,
101 assert( i >= 0 && i <= 3 );
109 assert( i >= 0 && i <= 3 );
117 assert( i >= 0 && i <= 3 );
125 assert( i >= 0 && i <= 3 );
223 template<
typename ValueB>
226 typedef complex<typename BinaryOpTraits<Value,ValueB>::MulT> ResultT;
229 ResultT p1(fb.
s3()*
s2()),p2(fb.
s4()*
s1());
230 vec.setX( -(p1+p2) );
231 vec.setY( ii*(p1-p2) );
232 p1 = fb.
s3()*
s1();p2 = fb.
s4()*
s2();
233 vec.setZ( -(p1-p2) );
242 template<
typename ValueB>
245 typedef complex<typename BinaryOpTraits<Value,ValueB>::MulT> ResultT;
248 ResultT p1(fb.
s1()*
s4()),p2(fb.
s2()*
s3());
250 vec.setY( -ii*(p1-p2));
251 p1 = fb.
s1()*
s3();p2 = fb.
s2()*
s4();
261 template<
typename ValueB>
264 typedef complex<typename BinaryOpTraits<Value,ValueB>::MulT> ResultT;
267 ResultT s1s4(fb.
s1()*
s4()),s2s3(fb.
s2()*
s3()),
268 s3s2(fb.
s3()*
s2()),s4s1(fb.
s4()*
s1()),
269 s1s3(fb.
s1()*
s3()),s2s4(fb.
s2()*
s4()),
270 s3s1(fb.
s3()*
s1()),s4s2(fb.
s4()*
s2());
271 vec.setX( s1s4+s2s3-s3s2-s4s1 );
272 vec.setY( -ii*(s1s4-s2s3-s3s2+s4s1));
273 vec.setZ( s1s3-s2s4-s3s1+s4s2 );
274 vec.setT( s1s3+s2s4+s3s1+s4s2);
285 template<
typename ValueB>
289 typedef complex<typename BinaryOpTraits<Value,ValueB>::MulT> ResultT;
292 ResultT p1(fb.
s3()*
s2()),p2(fb.
s4()*
s1());
293 vec.setX( -left*(p1+p2));
294 vec.setY( ii*left*(p1-p2));
295 p1 = fb.
s3()*
s1();p2 = fb.
s4()*
s2();
296 vec.setZ( -left*(p1-p2));
297 vec.setT( left*(p1+p2));
299 vec.setX(vec.x()+right*(p1+p2));
300 vec.setY(vec.y()-ii*right*(p1-p2));
301 p1 = fb.
s1()*
s3();p2 = fb.
s2()*
s4();
302 vec.setZ(vec.z()+right*(p1-p2));
303 vec.setT(vec.t()+right*(p1+p2));
314 template<
typename ValueB>
315 complex<typename BinaryOpTraits<Value,ValueB>::MulT>
324 template<
typename ValueB>
325 complex<typename BinaryOpTraits<Value,ValueB>::MulT>
334 template<
typename ValueB>
335 complex<typename BinaryOpTraits<Value,ValueB>::MulT>
344 template<
typename ValueB>
345 complex<typename BinaryOpTraits<Value,ValueB>::MulT>
357 template<
typename ValueB>
358 complex<typename BinaryOpTraits<Value,ValueB>::MulT>
361 return left*(fb.
s1()*
s1()+fb.
s2()*
s2())
362 + right*(fb.
s3()*
s3()+fb.
s4()*
s4());
381 #ifndef ThePEG_TEMPLATES_IN_CC_FILE
382 #include "LorentzSpinor.tcc"
LorentzVector< complex< typename BinaryOpTraits< Value, ValueB >::MulT > > vectorCurrent(const LorentzSpinorBar< ValueB > &fb) const
Calculate the vector current .
complex< Value > s4() const
Get fourth component.
A 4-component Lorentz vector.
complex< Value > s3() const
Get third component.
complex< Value > operator[](int i) const
Subscript operator to return spinor components.
LorentzSpinor(complex< Value > a, complex< Value > b, complex< Value > c, complex< Value > d, SpinorType s=unknown_spinortype)
Constructor with complex numbers specifying the components, optionally specifying s...
LorentzSpinor(SpinorType t=unknown_spinortype)
Default zero constructor, optionally specifying t, the type.
LorentzSpinorBar< Value > bar() const
Return the barred spinor.
std::complex< double > Complex
ThePEG code should use Complex for all complex scalars.
complex< Value > & operator[](int i)
Set components by index.
This file contains enumerations used by LorentzSpinor and LorentzSpinorBar classes.
The LorentzRotation class combine a SpinOneLorentzRotation and a spin SpinHalfLorentzRotation to prov...
This is the main namespace within which all identifiers in ThePEG are declared.
ostream & left(ostream &os)
Stream manipulator setting an ostream to left-adjust its ouput.
complex< typename BinaryOpTraits< Value, ValueB >::MulT > leftScalar(const LorentzSpinorBar< ValueB > &fb) const
Calculate the left-handed scalar .
complex< Value > s3() const
Get third component.
The LorentzSpinor class is designed to store a spinor.
complex< Value > s1() const
Get first component.
LorentzVector< complex< typename BinaryOpTraits< Value, ValueB >::MulT > > rightCurrent(const LorentzSpinorBar< ValueB > &fb) const
Calculate the right-handed current .
complex< Value > s2() const
Get second component.
LorentzVector< complex< typename BinaryOpTraits< Value, ValueB >::MulT > > leftCurrent(const LorentzSpinorBar< ValueB > &fb) const
Calculate the left-handed current .
LorentzSpinor & boost(double, double, double)
Standard Lorentz boost specifying the components of the beta vector.
LorentzSpinor conjugate() const
Return the conjugated spinor .
LorentzSpinor & transform(const LorentzRotation &r)
General Lorentz transformation.
LorentzVector< complex< typename BinaryOpTraits< Value, ValueB >::MulT > > generalCurrent(const LorentzSpinorBar< ValueB > &fb, Complex left, Complex right) const
Calculate a general current with arbitary left and right couplings, i.e.
void setS1(complex< Value > in)
Set first component.
LorentzSpinor & transform(const SpinHalfLorentzRotation &)
General Lorentz transformation.
void setS3(complex< Value > in)
Set third component.
SpinorType
Enumeration to specify spinor type.
complex< Value > s1() const
Get first component.
complex< Value > & operator()(int i)
Set components by index.
const SpinHalfLorentzRotation & half() const
The spin- transformation.
SpinorType _type
Type of spinor.
void setS2(complex< Value > in)
Set second component.
complex< typename BinaryOpTraits< Value, ValueB >::MulT > scalar(const LorentzSpinorBar< ValueB > &fb) const
Calculate the scalar .
complex< typename BinaryOpTraits< Value, ValueB >::MulT > generalScalar(const LorentzSpinorBar< ValueB > &fb, Complex left, Complex right) const
Calculate a general scalar product with arbitary left and right couplings, i.e.
ostream & right(ostream &os)
Stream manipulator setting an ostream to right-adjust its ouput.
void setS4(complex< Value > in)
Set fourth component.
complex< Value > s4() const
Get fourth component.
SpinorType Type() const
Return the type of the spinor.
The SpinHalfLorentzRotation class is designed to offer the same features as the HepLorentzRotation cl...
complex< Value > operator()(int i) const
Subscript operator to return spinor components.
The LorentzSpinorBar class implements the storage of a barred LorentzSpinor.
complex< typename BinaryOpTraits< Value, ValueB >::MulT > pseudoScalar(const LorentzSpinorBar< ValueB > &fb) const
Calculate the pseudoscalar .
complex< typename BinaryOpTraits< Value, ValueB >::MulT > rightScalar(const LorentzSpinorBar< ValueB > &fb) const
Calculate the right-handed scalar .
complex< Value > s2() const
Get second component.
complex< Value > _spin[4]
Storage of the components.