BOSS 7.0.2
BESIII Offline Software System
Loading...
Searching...
No Matches
EvtNeutrinoParticle Class Reference

#include <EvtNeutrinoParticle.hh>

+ Inheritance diagram for EvtNeutrinoParticle:

Public Member Functions

 EvtNeutrinoParticle ()
 
virtual ~EvtNeutrinoParticle ()
 
void init (EvtId part_n, const EvtVector4R &p4)
 
EvtDiracSpinor spParentNeutrino () const
 
EvtDiracSpinor spNeutrino () const
 
EvtSpinDensity rotateToHelicityBasis () const
 
EvtSpinDensity rotateToHelicityBasis (double alpha, double beta, double gamma) const
 
- Public Member Functions inherited from EvtParticle
 EvtParticle ()
 
virtual ~EvtParticle ()
 
virtual EvtVector4C epsParent (int i) const
 
virtual EvtVector4C eps (int i) const
 
virtual EvtVector4C epsParentPhoton (int i)
 
virtual EvtVector4C epsPhoton (int i)
 
virtual EvtDiracSpinor spParent (int) const
 
virtual EvtDiracSpinor sp (int) const
 
virtual EvtDiracSpinor spParentNeutrino () const
 
virtual EvtDiracSpinor spNeutrino () const
 
virtual EvtTensor4C epsTensorParent (int i) const
 
virtual EvtTensor4C epsTensor (int i) const
 
virtual void init (EvtId part_n, const EvtVector4R &p4)=0
 
void addDaug (EvtParticle *node)
 
void decay ()
 
void deleteTree ()
 
void deleteDaughters (bool keepChannel=false)
 
void setChannel (int i)
 
void setGeneratorFlag (int flag)
 
int getGeneratorFlag ()
 
void setIntFlag (std::vector< int > vi)
 
std::vector< int > getIntFlag ()
 
void makeDaughters (int ndaug, EvtId *id)
 
double initializePhaseSpace (int numdaughter, EvtId *daughters, double poleSize=-1., int whichTwo1=0, int whichTwo2=1)
 
EvtParticlegetDaug (int i)
 
EvtParticlenextIter (EvtParticle *rootOfTree=0)
 
void makeStdHep (EvtStdHep &stdhep, EvtSecondary &secondary, EvtId *stable_parent_ihep)
 
void makeStdHep (EvtStdHep &stdhep)
 
EvtVector4R getP4Lab ()
 
EvtVector4R getP4Restframe ()
 
EvtVector4R get4Pos ()
 
EvtParticlegetParent ()
 
void insertDaugPtr (int idaug, EvtParticle *partptr)
 
double mass () const
 
int firstornot () const
 
void setFirstOrNot ()
 
void resetFirstOrNot ()
 
EvtId getId () const
 
EvtSpinType::spintype getSpinType () const
 
int getSpinStates () const
 
const EvtVector4RgetP4 () const
 
void setP4 (const EvtVector4R &p4)
 
int getChannel () const
 
int getNDaug () const
 
void resetNDaug ()
 
void printTree () const
 
void printTreeRec (int level) const
 
std::string writeTreeRec (std::string) const
 
void dumpTree () const
 
void dumpTreeRec (int level, int dj) const
 
std::string treeStr () const
 
std::string treeStrRec (int level) const
 
void printParticle () const
 
void setLifetime (double tau)
 
void setLifetime ()
 
double getLifetime ()
 
void setDiagonalSpinDensity ()
 
void setVectorSpinDensity ()
 
void setPolarizedSpinDensity (double r00, double r11, double r22)
 
void setSpinDensityForward (const EvtSpinDensity &rho)
 
void setSpinDensityForwardHelicityBasis (const EvtSpinDensity &rho)
 
void setSpinDensityForwardHelicityBasis (const EvtSpinDensity &rho, double alpha, double beta, double gamma)
 
virtual EvtSpinDensity rotateToHelicityBasis () const =0
 
virtual EvtSpinDensity rotateToHelicityBasis (double alpha, double beta, double gamma) const =0
 
EvtSpinDensity getSpinDensityForward ()
 
void setSpinDensityBackward (const EvtSpinDensity &rho)
 
EvtSpinDensity getSpinDensityBackward ()
 
void noLifeTime ()
 
void setId (EvtId id)
 
void initDecay (bool useMinMass=false)
 
void generateMassTree ()
 
double compMassProb ()
 
void setMass (double m)
 
bool isInitialized ()
 
bool hasValidP4 ()
 
bool isDecayed ()
 
double * decayProb ()
 
void setDecayProb (double p)
 
void setInclusiveMode (int im)
 
int getInclusiveMode ()
 

Additional Inherited Members

- Protected Member Functions inherited from EvtParticle
void setp (double e, double px, double py, double pz)
 
void setp (const EvtVector4R &p4)
 
void setpart_num (EvtId particle_number)
 
- Protected Attributes inherited from EvtParticle
bool _validP4
 

Detailed Description

Definition at line 30 of file EvtNeutrinoParticle.hh.

Constructor & Destructor Documentation

◆ EvtNeutrinoParticle()

EvtNeutrinoParticle::EvtNeutrinoParticle ( )

Definition at line 36 of file EvtNeutrinoParticle.cc.

36 {
37
38 return;
39}

◆ ~EvtNeutrinoParticle()

EvtNeutrinoParticle::~EvtNeutrinoParticle ( )
virtual

Definition at line 34 of file EvtNeutrinoParticle.cc.

34{}

Member Function Documentation

◆ init()

void EvtNeutrinoParticle::init ( EvtId  part_n,
const EvtVector4R p4 
)
virtual

Initialiaze particle with id and 4momentum.

Implements EvtParticle.

Definition at line 41 of file EvtNeutrinoParticle.cc.

41 {
42
43 _validP4=true;
44 setp(p4);
45 setpart_num(part_n);
46
47 double e,px,py,pz;
48 e=p4.get(0);
49 px=p4.get(1);
50 py=p4.get(2);
51 pz=p4.get(3);
52
53 if (EvtPDL::getStdHep(part_n)==0){
54 report(ERROR,"EvtGen") << "Error in EvtNeutrinoParticle::init, part_n="
55 << part_n.getId()<<endl;
56 }
57
58 if (EvtPDL::getStdHep(part_n)>0){
59
60 double beta,alpha,p2,norm;
61
62 // See Sakurai p. 167-169
63 // and Renton p. 126
64
65 p2=px*px+py*py+pz*pz;
66
67 beta=acos(pz/sqrt(p2));
68 alpha=atan2(py,px);
69
70 norm=sqrt(2*e);
71
72 double cosb,sinb,cosa,sina;
73
74 cosb=cos(0.5*beta);
75 sinb=sin(0.5*beta);
76
77 cosa=cos(0.5*alpha);
78 sina=sin(0.5*alpha);
79
80 spinor_parent.set(-norm*sinb*EvtComplex(cosa,-sina),
81 norm*cosb*EvtComplex(cosa,sina),
82 norm*sinb*EvtComplex(cosa,-sina),
83 -norm*cosb*EvtComplex(cosa,sina));
84
85 }
86 else{
87
88 px=-p4.get(1);
89 py=-p4.get(2);
90 pz=-p4.get(3);
91
92 double pn,sqrpn;
93
94 pn=e;
95 sqrpn=sqrt(pn-pz);
96
97 spinor_parent.set((1.0/sqrpn)*EvtComplex(px,-py),
98 EvtComplex(sqrpn,0.0),
99 (-1.0/sqrpn)*EvtComplex(px,-py),
100 -EvtComplex(sqrpn,0.0));
101
102
103 }
104
105 setLifetime();
106
107}
ostream & report(Severity severity, const char *facility)
Definition: EvtReport.cc:36
@ ERROR
Definition: EvtReport.hh:49
const double alpha
double sin(const BesAngle a)
double cos(const BesAngle a)
void set(const EvtComplex &sp0, const EvtComplex &sp1, const EvtComplex &sp2, const EvtComplex &sp3)
int getId() const
Definition: EvtId.hh:41
static int getStdHep(EvtId id)
Definition: EvtPDL.hh:56
void setLifetime()
Definition: EvtParticle.cc:93
void setp(double e, double px, double py, double pz)
Definition: EvtParticle.hh:398
void setpart_num(EvtId particle_number)
Definition: EvtParticle.hh:400
double get(int i) const
Definition: EvtVector4R.hh:179

Referenced by EvtParticleFactory::particleFactory().

◆ rotateToHelicityBasis() [1/2]

EvtSpinDensity EvtNeutrinoParticle::rotateToHelicityBasis ( ) const
virtual

Returns a rotation matrix need to rotate the basis state to the helicity basis. The EvtSpinDensity matrix is just use as a matrix here. This function is to be implemented in each derived class.

Implements EvtParticle.

Definition at line 126 of file EvtNeutrinoParticle.cc.

126 {
127
128 report(ERROR,"EvtGen") << "rotateToHelicityBasis not implemented for neutrino.";
129 report(ERROR,"EvtGen") << "Will terminate execution.";
130
131 ::abort();
132
133 EvtSpinDensity rho;
134 return rho;
135
136}

◆ rotateToHelicityBasis() [2/2]

EvtSpinDensity EvtNeutrinoParticle::rotateToHelicityBasis ( double  alpha,
double  beta,
double  gamma 
) const
virtual

Implements EvtParticle.

Definition at line 138 of file EvtNeutrinoParticle.cc.

140 {
141
142 report(ERROR,"EvtGen") << "rotateToHelicityBasis(alpha,beta,gamma) not implemented for neutrino.";
143 report(ERROR,"EvtGen") << "Will terminate execution.";
144
145 ::abort();
146
147 EvtSpinDensity rho;
148 return rho;
149
150
151}

◆ spNeutrino()

EvtDiracSpinor EvtNeutrinoParticle::spNeutrino ( ) const
virtual

Returns Dirac spinor in the particles own restframe for a Neutrino particle.

Reimplemented from EvtParticle.

Definition at line 115 of file EvtNeutrinoParticle.cc.

115 {
116
117 report(ERROR,"EvtGen") << "Tried to get neutrino spinor in restframe";
118 report(ERROR,"EvtGen") << "Will terminate execution.";
119
120 ::abort();
121
122 return spinor_rest;
123}

◆ spParentNeutrino()

EvtDiracSpinor EvtNeutrinoParticle::spParentNeutrino ( ) const
virtual

Returns Dirac spinor in the parents restframe for a Neutrino particle.

Reimplemented from EvtParticle.

Definition at line 110 of file EvtNeutrinoParticle.cc.

110 {
111
112 return spinor_parent;
113}

The documentation for this class was generated from the following files: