Fork me on GitHub

source: git/classes/DelphesHepMCReader.h@ 944c250

ImprovedOutputFile Timing dual_readout llp
Last change on this file since 944c250 was 7c0fcd5, checked in by Pavel Demin <demin@…>, 10 years ago

delete duplicate license file and prepend GPLv3 header to all source code files

  • Property mode set to 100644
File size: 2.6 KB
Line 
1/*
2 * Delphes: a framework for fast simulation of a generic collider experiment
3 * Copyright (C) 2012-2014 Universite catholique de Louvain (UCL), Belgium
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation, either version 3 of the License, or
8 * (at your option) any later version.
9 *
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
14 *
15 * You should have received a copy of the GNU General Public License
16 * along with this program. If not, see <http://www.gnu.org/licenses/>.
17 */
18
19#ifndef DelphesHepMCReader_h
20#define DelphesHepMCReader_h
21
22/** \class DelphesHepMCReader
23 *
24 * Reads HepMC file
25 *
26 *
27 * $Date$
28 * $Revision$
29 *
30 *
31 * \author P. Demin - UCL, Louvain-la-Neuve
32 *
33 */
34
35#include <map>
36#include <vector>
37
38#include <stdio.h>
39
40class TObjArray;
41class TStopwatch;
42class TDatabasePDG;
43class ExRootTreeBranch;
44class DelphesFactory;
45
46class DelphesHepMCReader
47{
48public:
49
50 DelphesHepMCReader();
51 ~DelphesHepMCReader();
52
53 void SetInputFile(FILE *inputFile);
54
55 void Clear();
56 bool EventReady();
57
58 bool ReadBlock(DelphesFactory *factory,
59 TObjArray *allParticleOutputArray,
60 TObjArray *stableParticleOutputArray,
61 TObjArray *partonOutputArray);
62
63 void AnalyzeEvent(ExRootTreeBranch *branch, long long eventNumber,
64 TStopwatch *readStopWatch, TStopwatch *procStopWatch);
65
66private:
67
68 void AnalyzeParticle(DelphesFactory *factory,
69 TObjArray *allParticleOutputArray,
70 TObjArray *stableParticleOutputArray,
71 TObjArray *partonOutputArray);
72
73 void FinalizeParticles(TObjArray *allParticleOutputArray);
74
75 FILE *fInputFile;
76
77 char *fBuffer;
78
79 TDatabasePDG *fPDG;
80
81 int fEventNumber, fMPI, fProcessID, fSignalCode, fVertexCounter, fBeamCode[2];
82 double fScale, fAlphaQCD, fAlphaQED;
83
84 double fMomentumCoefficient, fPositionCoefficient;
85
86 int fStateSize;
87 std::vector< int > fState;
88
89 int fWeightSize;
90 std::vector< double > fWeight;
91
92 int fID1, fID2;
93 double fX1, fX2, fScalePDF, fPDF1, fPDF2;
94
95 int fOutVertexCode, fVertexID, fInCounter, fOutCounter;
96 double fX, fY, fZ, fT;
97
98 int fParticleCode, fPID, fStatus, fInVertexCode;
99 double fPx, fPy, fPz, fE, fMass, fTheta, fPhi;
100
101 int fParticleCounter;
102
103 std::map< int, std::pair < int, int > > fMotherMap;
104 std::map< int, std::pair < int, int > > fDaughterMap;
105};
106
107#endif // DelphesHepMCReader_h
108
109
Note: See TracBrowser for help on using the repository browser.