// $Id: EAtmosphereHistoPainter.hh,v 1.18 2005/10/31 16:42:08 moreggia Exp $ // Author: Anne Stutz 2004/10/19 /***************************************************************************** * ESAF: Euso Simulation and Analysis Framework * * * * Id: EAtmosphereHistoPainter * * Package: * * Coordinator: * * * *****************************************************************************/ #ifndef __EATMOSPHEREHISTOPAINTER_HH__ #define __EATMOSPHEREHISTOPAINTER_HH__ #include "ESystemOfUnits.hh" #include "EAnimator.hh" #include "TSeqCollection.h" #include #include #include class EAtmosphere; class EShower; class ETruth; class TH1F; class TH2F; class TTimer; //////////////////////////////////////////////////////////////////////////////// // // // EAtmosphereHistoPainter // // // // this class plots a set of standard histograms describing the light // // generation and transmission in atmosphere // // // //////////////////////////////////////////////////////////////////////////////// class EAtmosphereHistoPainter : public EAnimator { public: EAtmosphereHistoPainter( EAtmosphere* atm, Double_t GTUlength, ETruth* truth, EShower* show = NULL ); virtual ~EAtmosphereHistoPainter(); virtual void Draw(Option_t *opt=""); // define a cut in space-time coordinates to get a better view of Multiple Scattering contribution // then replot all the histos void MScattCut(Double_t BDFmin=2.5*0.4, Double_t BDFmax=2.5*0.8, Double_t SNR=3); const TArrayI& GetMScattCut() {return fIndex_list;} // generate all histos void BuildAll(); // generate histos of photons at creation as function of creation time void BuildDateHistos(); // generate histos of YIELD as function of altitude void BuildAltHistos(); // generate histos of photons on pupil as function of time since PRIMARY cosmic ray first interaction void BuildTofHistos(); // generate wavelength spectra of photons on pupil BEFORE and AFTER last transmission // generate also wavelength spectra of photons in atmosphere at creation void BuildWlHistos(); // generate histos of photons at creation along the track (Longitudinal Profiles) // both in km and g/cm2 void BuildLongitudinalHistos(); // photons vs their position in the FoV void BuildFovHistos(); // photons vs their direction on pupil //TOFIX when tilting mode and associated info in header void BuildAngularPupilHistos(); // Multiple scattering details void BuildMScattHistos(); void SetShower(EShower* sh) {fShower = sh;} virtual void NextFrame(); inline TVector3 EUSO() const {return fEUSO;} inline Double_t DetectorRadius() const {return fRadius;} TH1F* GetTimeHisto(const char*, const char* =0, UInt_t Nbins=0 ); TH1F* GetAltHisto(const char*, const char* =0, UInt_t Nbins=0); TH1F* GetLongitudinalHisto(const char*, const char* =0, Bool_t flag=true, UInt_t Nbins=0); TH1F* GetTofHisto(const char*, const char* =0); TH1F* GetWlHisto(const char*, const char* =0); // for single photons histos TH2F* GetWl2DHisto(const char*, const char* =0); TH1F* GetSingleAltHisto(const char*, const char* =0); TH2F* GetAlt2DHisto(const char *, const char* =0); TH1F* GetSingleLongitudinalHisto(const char *name, const char *title=0, Double_t max=50); TH1F* GetSingleLateralHisto(const char *name, const char *title=0); TH1F* GetMScattHistory(const char *name, const char *title=0); TH2F* GetSingle2DHisto(const char *name, const char *title=0, Double_t max=50); TH2F* GetFovHisto(const char *name, const char *title=0); TH1F* GetAngularHisto(const char *name, const char *title=0); TH2F* Get2DAngularHisto(const char *name, const char *title=0); TSeqCollection* GetListOfHistos() {return fHistos;} private: void UpdateHistos(); TVector3 fEUSO; Double_t fRadius; Double_t fGTUlength; Double_t fTimeMin; // of photons on pupil Double_t fTimeMax; // of photons on pupil Int_t fMaxScatOrder; // mutliple scattering max order TArrayI fIndex_list; // if MScatt cut : list of indices of selected photons -- ALL photons otherwise TSeqCollection *fHistos; EAtmosphere *fAtmosphere; // contains simu atmosphere data EShower *fShower; // contains simu shower data ETruth *fTruth; // contains the truth (used to get shower impact) Double_t *fTimeBins; // array for time axis Double_t *fAltBins; // array for altitude axis Double_t *fLongBins; // array for photons longitudinal profiles (in km) Double_t *fGramBins; // array for photons longitudinal profiles (in g/cm2) ClassDef(EAtmosphereHistoPainter,1) }; #endif /* __EATMOSPHEREHISTOPAINTER_HH__ */