hpstr
The Heavy Photon Search Toolkit for Reconstruction (hpstr) provides an interface to physics data from the HPS experiment saved in the LCIO format and converts it into an ROOT based format.
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
AnaHelpers.h
Go to the documentation of this file.
1
7#include <iostream>
8
9#include "TMatrix.h"
10#include "TVector3.h"
11#include "TRotation.h"
12#include "TMatrixDSym.h"
13#include "TMatrixTSym.h"
14
15// HPSTR
16#include "Track.h"
17#include "TrackerHit.h"
18#include "RawSvtHit.h"
19#include "Particle.h"
20#include "Vertex.h"
21#include "CalCluster.h"
22#include "CalHit.h"
28
29 public :
30
31 AnaHelpers();
32
39 TVector3 rotateToSvtFrame(TVector3 v);
40
47 TVector3 rotationToSvtFrame(const TVector3& v);
48
55 TMatrixDSym rotateToSvtFrame(TMatrixDSym cov) {
56 return cov.Similarity(*rotSvt_sym);
57 }
58
65 TMatrixDSym rotateToHpsFrame(TMatrixDSym cov) {
66 return cov.SimilarityT(*rotSvt_sym);
67 }
68
76 void InnermostLayerCheck(Track* trk, bool& foundL1, bool& foundL2);
77
87 bool GetParticlesFromVtx(Vertex* vtx, Particle*& ele, Particle*& pos);
88
100 bool MatchToGBLTracks(int ele_id, int pos_id, Track* & ele_trk, Track* & pos_trk, std::vector<Track*>& trks);
101
102
103 bool GetParticlesFromVtxAndParticleList(std::vector<Particle*>& parts, Vertex* vtx, Particle*& ele, Particle*& pos);
104 bool IsECalFiducial(CalCluster* clu);
106 Particle* GetParticleFromCluster(std::vector<Particle*>& parts,CalCluster* cluster);
107 static std::string getFileName(std::string filePath, bool withExtension);
108 Track* GetTrackFromParticle(std::vector<Track*>& trks,Particle* part);
109
110
111 private:
112
113 const double SVT_ANGLE = -30.5e-3;
114 TRotation rotSvt;
115 TMatrixDSym* rotSvt_sym;
116 bool debug_{false};
117};
118
119
Class that encapsulate calorimeter hit information.
Class used to encapsulate information about a particle.
Class used to encapsulate raw svt hit information.
Class used to encapsulate track information.
Class used to encapsulate tracker hit information.
Class used to encapsulate Vertex information.
brief description more details
Definition AnaHelpers.h:27
TRotation rotSvt
description
Definition AnaHelpers.h:114
void InnermostLayerCheck(Track *trk, bool &foundL1, bool &foundL2)
Checks if a track has a 3d hit on innermost layer and second innermost layer.
TMatrixDSym rotateToHpsFrame(TMatrixDSym cov)
brief description
Definition AnaHelpers.h:65
TMatrixDSym * rotSvt_sym
description
Definition AnaHelpers.h:115
TVector3 rotationToSvtFrame(const TVector3 &v)
Rotate a vector from HPS to SVT Frame via TRotation.
Particle * GetParticleFromCluster(std::vector< Particle * > &parts, CalCluster *cluster)
bool MatchToGBLTracks(int ele_id, int pos_id, Track *&ele_trk, Track *&pos_trk, std::vector< Track * > &trks)
brief description
bool IsECalFiducial(CalCluster *clu)
const double SVT_ANGLE
Angle between SVT system and HPS coordinates.
Definition AnaHelpers.h:113
TVector3 rotateToSvtFrame(TVector3 v)
Rotate a vector from HPS to SVT Frame (i.e. for position/momentum rotation)
bool GetParticlesFromVtxAndParticleList(std::vector< Particle * > &parts, Vertex *vtx, Particle *&ele, Particle *&pos)
TMatrixDSym rotateToSvtFrame(TMatrixDSym cov)
Rotate a matrix from HPS to SVT Frame (i.e. for covariance matrix rotation)
Definition AnaHelpers.h:55
double GetClusterCoplanarity(CalCluster *cl1, CalCluster *cl2)
static std::string getFileName(std::string filePath, bool withExtension)
Definition AnaHelpers.cxx:5
bool GetParticlesFromVtx(Vertex *vtx, Particle *&ele, Particle *&pos)
Get the Particles From Vtx object.
Track * GetTrackFromParticle(std::vector< Track * > &trks, Particle *part)
bool debug_
description
Definition AnaHelpers.h:116
Definition Track.h:32