1 | // |
---|
2 | // ******************************************************************** |
---|
3 | // * License and Disclaimer * |
---|
4 | // * * |
---|
5 | // * The Geant4 software is copyright of the Copyright Holders of * |
---|
6 | // * the Geant4 Collaboration. It is provided under the terms and * |
---|
7 | // * conditions of the Geant4 Software License, included in the file * |
---|
8 | // * LICENSE and available at http://cern.ch/geant4/license . These * |
---|
9 | // * include a list of copyright holders. * |
---|
10 | // * * |
---|
11 | // * Neither the authors of this software system, nor their employing * |
---|
12 | // * institutes,nor the agencies providing financial support for this * |
---|
13 | // * work make any representation or warranty, express or implied, * |
---|
14 | // * regarding this software system or assume any liability for its * |
---|
15 | // * use. Please see the license in the file LICENSE and URL above * |
---|
16 | // * for the full disclaimer and the limitation of liability. * |
---|
17 | // * * |
---|
18 | // * This code implementation is the result of the scientific and * |
---|
19 | // * technical work of the GEANT4 collaboration. * |
---|
20 | // * By using, copying, modifying or distributing the software (or * |
---|
21 | // * any work based on the software) you agree to acknowledge its * |
---|
22 | // * use in resulting scientific publications, and indicate your * |
---|
23 | // * acceptance of all terms of the Geant4 Software license. * |
---|
24 | // ******************************************************************** |
---|
25 | // |
---|
26 | // ---------------------------------------------------------------------------- |
---|
27 | // $Id: HadrontherapyAnalysisManager.hh; May 2005 |
---|
28 | // ---------------------------------------------------------------------------- |
---|
29 | // GEANT 4 - Hadrontherapy example |
---|
30 | // ---------------------------------------------------------------------------- |
---|
31 | // Code developed by: |
---|
32 | // |
---|
33 | // G.A.P. Cirrone(a)*, F. Di Rosa(a), S. Guatelli(b), G. Russo(a) |
---|
34 | // |
---|
35 | // (a) Laboratori Nazionali del Sud |
---|
36 | // of the INFN, Catania, Italy |
---|
37 | // (b) INFN Section of Genova, Genova, Italy |
---|
38 | // |
---|
39 | // * cirrone@lns.infn.it |
---|
40 | // ---------------------------------------------------------------------------- |
---|
41 | |
---|
42 | #ifdef G4ANALYSIS_USE |
---|
43 | #ifndef HADRONTHERAPYANALYSISMANAGER_HH |
---|
44 | #define HADRONTHERAPYANALYSISMANAGER_HH 1 |
---|
45 | |
---|
46 | #include "globals.hh" |
---|
47 | # include <AIDA/AIDA.h> |
---|
48 | |
---|
49 | namespace AIDA{ |
---|
50 | class ITree; |
---|
51 | class IAnalysisFactory; |
---|
52 | class ITreeFactory; |
---|
53 | } |
---|
54 | |
---|
55 | class HadrontherapyAnalysisManager |
---|
56 | { |
---|
57 | private: |
---|
58 | HadrontherapyAnalysisManager(); |
---|
59 | |
---|
60 | public: |
---|
61 | ~HadrontherapyAnalysisManager(); |
---|
62 | |
---|
63 | static HadrontherapyAnalysisManager* getInstance(); |
---|
64 | |
---|
65 | void book(); |
---|
66 | // Book the histograms and ntuples in a .hbk file |
---|
67 | |
---|
68 | void FillEnergyDeposit(G4int voxelXId, G4int voxelYId, G4int voxelZId, |
---|
69 | G4double energyDeposit); |
---|
70 | // Fill the ntuple with the energy deposit in the phantom |
---|
71 | |
---|
72 | void BraggPeak(G4int, G4double); |
---|
73 | // Fill 1D histogram with the Bragg peak in the phantom |
---|
74 | |
---|
75 | void SecondaryProtonEnergyDeposit(G4int slice, G4double energy); |
---|
76 | // Fill 1D histogram with the energy deposit of secondary protons |
---|
77 | |
---|
78 | void SecondaryNeutronEnergyDeposit(G4int slice, G4double energy); |
---|
79 | // Fill 1D histogram with the energy deposit of secondary neutrons |
---|
80 | |
---|
81 | void SecondaryAlphaEnergyDeposit(G4int slice, G4double energy); |
---|
82 | // Fill 1D histogram with the energy deposit of secondary alpha particles |
---|
83 | |
---|
84 | void SecondaryGammaEnergyDeposit(G4int slice, G4double energy); |
---|
85 | // Fill 1D histogram with the energy deposit of secondary gamma |
---|
86 | |
---|
87 | void SecondaryElectronEnergyDeposit(G4int slice, G4double energy); |
---|
88 | // Fill 1D histogram with the energy deposit of secondary electrons |
---|
89 | |
---|
90 | void SecondaryTritonEnergyDeposit(G4int slice, G4double energy); |
---|
91 | // Fill 1D histogram with the energy deposit of secondary tritons |
---|
92 | |
---|
93 | void SecondaryDeuteronEnergyDeposit(G4int slice, G4double energy); |
---|
94 | // Fill 1D histogram with the energy deposit of secondary deuterons |
---|
95 | |
---|
96 | void SecondaryPionEnergyDeposit(G4int slice, G4double energy); |
---|
97 | // Fill 1D histogram with the energy deposit of secondary pions |
---|
98 | |
---|
99 | void electronEnergyDistribution(G4double secondaryParticleKineticEnergy); |
---|
100 | // Energy distribution of secondary electrons originated in the phantom |
---|
101 | |
---|
102 | void gammaEnergyDistribution(G4double secondaryParticleKineticEnergy); |
---|
103 | // Energy distribution of secondary gamma originated in the phantom |
---|
104 | |
---|
105 | void deuteronEnergyDistribution(G4double secondaryParticleKineticEnergy); |
---|
106 | // Energy distribution of secondary deuterons originated in the phantom |
---|
107 | |
---|
108 | void tritonEnergyDistribution(G4double secondaryParticleKineticEnergy); |
---|
109 | // Energy distribution of secondary tritons originated in the phantom |
---|
110 | |
---|
111 | void alphaEnergyDistribution(G4double secondaryParticleKineticEnergy); |
---|
112 | // Energy distribution of secondary alpha originated in the phantom |
---|
113 | |
---|
114 | void genericIonInformation(G4int, G4double, G4int, G4double); |
---|
115 | |
---|
116 | void finish(); |
---|
117 | // Close the .hbk file with the histograms and the ntuples |
---|
118 | |
---|
119 | private: |
---|
120 | static HadrontherapyAnalysisManager* instance; |
---|
121 | AIDA::IAnalysisFactory* aFact; |
---|
122 | AIDA::ITree* theTree; |
---|
123 | AIDA::IHistogramFactory *histFact; |
---|
124 | AIDA::ITupleFactory *tupFact; |
---|
125 | AIDA::IHistogram1D *h1; |
---|
126 | AIDA::IHistogram1D *h2; |
---|
127 | AIDA::IHistogram1D *h3; |
---|
128 | AIDA::IHistogram1D *h4; |
---|
129 | AIDA::IHistogram1D *h5; |
---|
130 | AIDA::IHistogram1D *h6; |
---|
131 | AIDA::IHistogram1D *h7; |
---|
132 | AIDA::IHistogram1D *h8; |
---|
133 | AIDA::IHistogram1D *h9; |
---|
134 | AIDA::IHistogram1D *h10; |
---|
135 | AIDA::IHistogram1D *h11; |
---|
136 | AIDA::IHistogram1D *h12; |
---|
137 | AIDA::IHistogram1D *h13; |
---|
138 | AIDA::IHistogram1D *h14; |
---|
139 | AIDA::ITuple *ntuple; |
---|
140 | AIDA::ITuple *ionTuple; |
---|
141 | }; |
---|
142 | #endif |
---|
143 | #endif |
---|
144 | |
---|