source: JEM-EUSO/esaf_lal/tags/v1_r0/esaf/packages/simulation/radiativetransfer/include/PureMCRadiativeTransfer.hh @ 117

Last change on this file since 117 was 117, checked in by moretto, 11 years ago

ESAF version compilable on mac OS

File size: 4.2 KB
Line 
1// $Id: PureMCRadiativeTransfer.hh 2681 2006-05-03 10:58:33Z moreggia $
2// Author: Sylvain Moreggia   2006/03/09
3
4/*****************************************************************************
5 * ESAF: Euso Simulation and Analysis Framework                              *
6 *                                                                           *
7 *  Id: PureMCRadiativeTransfer                                              *
8 *  Package: RadiativeTransfer                                               *
9 *  Coordinator: S. Moreggia                                                 *
10 *                                                                           *
11 *****************************************************************************/
12
13#ifndef __PUREMCRADIATIVETRANSFER_HH__
14#define __PUREMCRADIATIVETRANSFER_HH__
15
16#include "euso.hh"
17#include "RadiativeTransfer.hh"
18#include "DetectorGeometry.hh"
19#include "EarthVector.hh"
20#include "SinglePhotonPropagator.hh"
21
22////////////////////////////////////////////////////////////////////////////////
23//                                                                            //
24// PureMCRadiativeTransfer                                                    //
25//                                                                            // 
26// Pure Monte Carlo propagation of photons in the atmosphere                  //
27// MUST NOT BE USED TO SIMULATE SIGNAL ON DETECTOR PUPIL :                    //
28// indeed present simulation is dedicated to pure radiative transfer studies  // 
29//                                                                            // 
30////////////////////////////////////////////////////////////////////////////////
31
32class PhotonsInAtmosphere;
33class ListPhotonsInAtmosphere;
34class ListPhotonsOnPupil;
35class BunchOfPhotons;
36class Ground;
37class ClearSkyPropagator;
38class InCloudsPropagator;
39class SinglePhoton;
40
41class EEvent;
42
43class PureMCRadiativeTransfer : public RadiativeTransfer {
44public:
45    PureMCRadiativeTransfer();
46    virtual ~PureMCRadiativeTransfer();
47
48    // Transfer photons in atmosphere, return a list of photons on Euso pupil
49    // NO PHOTONSONPUPIL produced in this mode
50    virtual PhotonsOnPupil* Get(PhotonsInAtmosphere*, const DetectorGeometry* dg);
51   
52    // get ready for next event
53    void Reset();
54       
55    EsafConfigClass(RadiativeTransfer,PureMCRadiativeTransfer)
56   
57
58private:
59
60    // Scan fTempList before filling fTotalList, applying relevant cuts
61    void ScanTempList();
62   
63    // convert the bunch of created photons into single photons to be propagated
64    Double_t ConvertIntoSingles(const BunchOfPhotons&, Double_t);
65           
66    ListPhotonsInAtmosphere* fTotalList;  // pointer on the list created by LightSource module
67                                          // STORE SINGLEPHOTONS AFTER THEIR SCATTERING SIMU
68                                          // once inside a photon MUST NOT BE DELETED before conversion into ParentPhoton
69                                          // _must not be reset nor deleted_ by the present class
70
71    SinglePhotonPropagator* fPropagator;               // propagator for scattering simulation
72    vector<SinglePhoton*> fTempList;                   // photons kept here during scattering simu. Then copied in fTotalList
73
74   
75    size_t fNbBunch;                      // number of bunches to handle
76    Double_t fNbTot;                      // total number of photons created by LightSource
77    Double_t fNbSingles;                  // total nb of photons to propagate
78    Double_t fMaxPhNb;                    // max nb of photons to be transported --> if nb of photons is larger, simu is splitted in several steps
79    Int_t fMaxScatOrder;                  // if photon needs more scattering, it is lost
80
81    virtual Bool_t ClearMemory();
82    // release all the mem hold in the buffers
83   
84    // copy of detector geometry defined in Detector part
85    inline virtual void CopyDetectorGeometry(const DetectorGeometry* dg);
86
87    ClassDef(PureMCRadiativeTransfer,0)
88};
89
90//____________________________________________________________________________________________
91inline void PureMCRadiativeTransfer::CopyDetectorGeometry(const DetectorGeometry* dg) {
92    //
93    // set DetectorGeometry for the propagator
94    //
95    fDetGeom = dg;
96    fPropagator->CopyDetectorGeometry(fDetGeom,fDecoupled);
97}
98
99#endif  /* __PUREMCRADIATIVETRANSFER_HH__ */
100
Note: See TracBrowser for help on using the repository browser.