BOSS 6.6.4.p01
BESIII Offline Software System
Loading...
Searching...
No Matches
MyUtil.h File Reference
#include "GaudiKernel/NTuple.h"
#include "CLHEP/Vector/LorentzVector.h"
#include "EmcRecEventModel/RecEmcShower.h"

Go to the source code of this file.

Functions

void fill (NTuple::Array< double > &nt_p4, const HepLorentzVector &p4)
 
void fill (NTuple::Matrix< double > &nt_p4, const HepLorentzVector &p4, int i)
 
HepLorentzVector getP4 (RecEmcShower *gtrk)
 

Function Documentation

◆ fill() [1/2]

void fill ( NTuple::Array< double > &  nt_p4,
const HepLorentzVector &  p4 
)

Definition at line 3 of file MyUtil.cxx.

3 {
4 nt_p4[0] = p4.x();
5 nt_p4[1] = p4.y();
6 nt_p4[2] = p4.z();
7 nt_p4[3] = p4.e();
8}

Referenced by dchain::CombinatoricList< CandidateClass >::bar(), dchain::CombinatoricList< CandidateClass >::begin(), dchain::CombinatoricList< CandidateClass >::conjugation_iterate(), dchain::CombinatoricList< CandidateClass >::end(), DQADtag::execute(), DCChargedVisibleList< Charged, CandidateClass >::fill(), DCNeutralVisibleList< Neutral, CandidateClass >::fill(), DCNeutralNCVisibleList< NeutralNC, CandidateClass >::fill(), dchain::CombinatoricList< CandidateClass >::iterate(), dchain::CombinatoricList< CandidateClass >::labeledCandidateList(), dchain::NeutralVisibleList< Neutral, Neutral::CandidateClass >::NeutralVisibleList(), dchain::CombinatoricList< CandidateClass >::operator()(), DCChargedVisibleList< Charged, CandidateClass >::operator=(), DCDecayList< DecayClass, CandidateClass >::operator=(), DCNeutralNCVisibleList< NeutralNC, CandidateClass >::operator=(), DCNeutralVisibleList< Neutral, CandidateClass >::operator=(), dchain::DecayList< DecayClass, CandidateClass >::operator=(), dchain::ChargedVisibleList< Charged, CandidateClass >::operator=(), dchain::NeutralVisibleList< Neutral, CandidateClass >::operator=(), dchain::CombinatoricList< CandidateClass >::partial_begin(), dchain::CombinatoricList< CandidateClass >::partial_end(), dchain::CombinatoricList< CandidateClass >::partial_iterate(), dchain::CombinatoricList< CandidateClass >::partial_particle_begin(), dchain::CombinatoricList< CandidateClass >::partial_particle_end(), dchain::CombinatoricList< CandidateClass >::particle_begin(), and dchain::CombinatoricList< CandidateClass >::particle_end().

◆ fill() [2/2]

void fill ( NTuple::Matrix< double > &  nt_p4,
const HepLorentzVector &  p4,
int  i 
)

Definition at line 10 of file MyUtil.cxx.

10 {
11 nt_p4[i][0] = p4.x();
12 nt_p4[i][1] = p4.y();
13 nt_p4[i][2] = p4.z();
14 nt_p4[i][3] = p4.e();
15}

◆ getP4()

HepLorentzVector getP4 ( RecEmcShower gtrk)

Definition at line 16 of file MyUtil.cxx.

16 {
17 double eraw = gtrk->energy();
18 double phi = gtrk->phi();
19 double the = gtrk->theta();
20
21 double pxy = eraw * sin(the);
22
23 HepLorentzVector ptrk( pxy * cos(phi),
24 pxy * sin(phi),
25 eraw * cos(the),
26 eraw );
27
28 return ptrk;
29}
double sin(const BesAngle a)
Definition: BesAngle.h:210
double cos(const BesAngle a)
Definition: BesAngle.h:213
double theta() const
Definition: DstEmcShower.h:38
double phi() const
Definition: DstEmcShower.h:39
double energy() const
Definition: DstEmcShower.h:45

Referenced by Pi0::make_pi0_list(), high_momentum::operator()(), and Pi0::Pi0ListToTDS().