9 #ifndef ST_JET_ELEMENT_H
10 #define ST_JET_ELEMENT_H
15 #include "StJetCandidate.h"
29 short id ()
const {
return mId; }
30 short detectorId ()
const {
return mDetectorId; }
31 float pt ()
const {
return mPt; }
32 float eta ()
const {
return mEta; }
33 float phi ()
const {
return mPhi; }
34 TVector3 momentum ()
const;
35 TVector3 localMomentum()
const;
36 float jt ()
const {
return localMomentum().Perp(); }
37 float ps ()
const {
return localMomentum().Px(); }
38 float pn ()
const {
return localMomentum().Py(); }
39 float pl ()
const {
return localMomentum().Pz(); }
40 float frag ()
const {
return momentum().Mag() / jet()->momentum().Mag(); }
56 inline TVector3 StJetElement::momentum()
const
59 mom.SetPtEtaPhi(mPt,mEta,mPhi);
63 inline TVector3 StJetElement::localMomentum()
const
65 TVector3 longUnit = jet()->momentum().Unit();
66 TVector3 normUnit = TVector3(0,0,1).Cross(longUnit).Unit();
67 TVector3 sideUnit = longUnit.Cross(normUnit);
68 TVector3 mom = momentum();
69 return TVector3(mom.Dot(sideUnit),mom.Dot(normUnit),mom.Dot(longUnit));
72 #endif // ST_JET_ELEMENT_H