ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/UserCode/FGolf/Tools/tools.h
Revision: 1.3
Committed: Fri Mar 18 20:51:22 2011 UTC (14 years, 1 month ago) by fgolf
Content type: text/plain
Branch: MAIN
CVS Tags: ss_summer2011approvalV2, ss_summer2011approval, synchMay2011v1, ss20May2011, HEAD
Changes since 1.2: +1 -0 lines
Error occurred while calculating annotation data.
Log Message:
add LorentzVector typedef

File Contents

# Content
1 // -*- C++ -*-
2
3 #ifndef TOOLS_H
4 #define TOOLS_H
5
6 #include "TH1F.h"
7 #include "TH2F.h"
8 #include "TH3F.h"
9 #include "TVector3.h"
10 #include <algorithm>
11 #include <vector>
12 #include <set>
13 #include "Math/VectorUtil.h"
14
15 using std::vector;
16 typedef ROOT::Math::LorentzVector<ROOT::Math::PxPyPzE4D<float> > LorentzVector;
17
18 struct DorkyEventIdentifier {
19 // this is a workaround for not having unique event id's in MC
20 DorkyEventIdentifier (class CMS2 &cms2);
21 DorkyEventIdentifier (unsigned long int r, unsigned long int e, unsigned long int l);
22 unsigned long int run, event, lumi_section;
23 float trks_d0;
24 float trks_pt, trks_eta, trks_phi;
25 bool operator < (const DorkyEventIdentifier &) const;
26 bool operator == (const DorkyEventIdentifier &) const;
27 };
28
29 extern std::set<DorkyEventIdentifier> already_seen;
30
31 bool is_duplicate (const DorkyEventIdentifier &id);
32
33 void saveHist(const char* filename, const char* pat="*");
34
35 extern class TDirectory *histo_directory;
36
37 double dRbetweenVectors(const LorentzVector & vec1, const LorentzVector & vec2 );
38 #endif