source: trunk/Mars/mcorsika/MCorsikaEvtHeader.h@ 9893

Last change on this file since 9893 was 9616, checked in by rohlfs, 14 years ago
can read also EventIO files
File size: 2.5 KB
Line 
1#ifndef MARS_MCorsikaEvtHeader
2#define MARS_MCorsikaEvtHeader
3
4#ifndef MARS_MParContainer
5#include "MParContainer.h"
6#endif
7
8#ifndef ROOT_TVector3
9#include <TVector3.h>
10#endif
11
12// gcc 3.2
13//class ifstream;
14#include <iosfwd>
15
16class MCorsikaFormat;
17
18class MCorsikaEvtHeader : public MParContainer
19{
20private:
21 UInt_t fEvtNumber; // Event number
22// UInt_t fParticleID; // Particle ID (see MMcEvtBasic or CORSIKA manual)
23 Float_t fTotalEnergy; // [GeV]
24
25 Float_t fStartAltitude; // [g/cm²]
26 Float_t fFirstTargetNum; // Number of first target if fixed
27 Float_t fFirstInteractionHeight; // [cm] z coordinate, first intercation height
28
29 Float_t fMomentumX; // [GeV/c] "+west" "-east"
30 Float_t fMomentumY; // [GeV/c] "+south" "-north" (north denotes the magnet north which is defined to be in the geografic north!)
31 Float_t fMomentumZ; // [GeV/c] "+upwards" "-downwards"
32
33 Float_t fZd; // [rad] Zenith distance
34 Float_t fAz; // [rad] Azimuth (north=0; east=90) (north denotes the magnet north which is defined to be in the geografic north!)
35
36 Float_t fX; // [cm] Position of telescope on ground x / - impact parameter x
37 Float_t fY; // [cm] Position of telescope on gorund y / - impact parameter y
38
39 Float_t fWeightedNumPhotons; // weighted number of photons arriving at observation level
40
41public:
42 MCorsikaEvtHeader(const char *name=NULL, const char *title=NULL);
43
44 //void Clear(Option_t * = NULL);
45 void Print(Option_t * = NULL) const;
46
47 UInt_t GetEvtNumber() const { return fEvtNumber; }
48// UInt_t GetParticleID() const { return fParticleID; }
49
50 TVector3 GetMomentum() const { return TVector3(fMomentumX, fMomentumY, fMomentumZ); }
51 TVector2 GetImpactPos() const { return TVector2(fX, fY); }
52
53 Float_t GetTotalEnergy() const { return fTotalEnergy; }
54 Float_t GetFirstInteractionHeight() const { return fFirstInteractionHeight; }
55
56 Float_t GetZd() const { return fZd; }
57 Float_t GetAz() const { return fAz; }
58
59 Float_t GetX() const { return fX; }
60 Float_t GetY() const { return fY; }
61
62 Double_t GetImpact() const;
63
64 Int_t ReadEvt(MCorsikaFormat * fInFormat); // read in event header block
65 Bool_t ReadEvtEnd(MCorsikaFormat * fInFormat); // read in event end block
66
67 ClassDef(MCorsikaEvtHeader, 1) // Parameter Conatiner for raw EVENT HEADER
68};
69
70#endif
Note: See TracBrowser for help on using the repository browser.