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3 ] [ 10.5 ] [ 10.5.p1 ] [ 10.6 ] [ 10.6.p1 ] [ 10.6.p2 ] [ 10.6.p3 ] [ 10.7 ] [ 10.7.p1 ] [ 10.7.p2 ] [ 10.7.p3 ] [ 10.7.p4 ] [ 11.0 ] [ 11.0.p1 ] [ 11.0.p2 ] [ 11.0.p3, ] [ 11.0.p4 ] [ 11.1 ] [ 11.1.1 ] [ 11.1.2 ] [ 11.1.3 ] [ 11.2 ] [ 11.2.1 ] [ 11.2.2 ] [ 11.3.0 ]

  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 // Hadrontherapy advanced example for Geant4
 27 // See more at: https://twiki.cern.ch/twiki/bin/view/Geant4/AdvancedExamplesHadrontherapy
 28 
 29 #ifndef PassiveCarbonBeamLine_H
 30 #define PassiveCarbonBeamLine_H 1
 31 
 32 #include "globals.hh"
 33 #include "G4VUserDetectorConstruction.hh"
 34 #include "G4Box.hh"
 35 #include "G4Tubs.hh"
 36 #include "G4VisAttributes.hh"
 37 #include "G4LogicalVolume.hh"
 38 #include "G4Trd.hh"
 39 #include "PassiveCarbonBeamLineMessenger.hh"
 40 
 41 class G4VPhysicalVolume;
 42 class HadrontherapyDetectorConstruction;
 43 class HadrontherapyDetectorROGeometry;
 44 class PassiveCarbonBeamLineMessenger;
 45 
 46 class PassiveCarbonBeamLine : public G4VUserDetectorConstruction
 47 {
 48 public:
 49     
 50     PassiveCarbonBeamLine();
 51     ~PassiveCarbonBeamLine();
 52     
 53     G4VPhysicalVolume* Construct();
 54     
 55     void HadrontherapyBeamLineSupport();
 56     // Definition of the beam line support
 57     
 58     void VacuumToAirInterface();
 59     
 60     void HadrontherapyBeamMonitoring();
 61     // Definition of three monitor chambers
 62     
 63     void HadrontherapyBeamNozzle();
 64     // Definition of the beam noozle
 65     
 66     void HadrontherapyBeamFinalCollimator();
 67     // Definition of the final collimator
 68     
 69     void HadrontherapyPMMACollimator();
 70     // Definition of the PMMA collimator
 71     
 72     void HadrontherapyRippleFilter();
 73     // Definition of the ripple filter
 74     
 75     void StopperCostruction();
 76     void HadrontherapyRidgeFilter();
 77     void SetInnerRadiusFinalCollimator(G4double);
 78     // This method allows to change the size of the inner radius of the
 79     // final collimator
 80     
 81     void SetRippleFilterMaterial(G4String);
 82     // This method allows to change the material
 83     // of the ripple filter
 84     
 85     void SetRippleFilterXPosition(G4double);
 86     
 87     // The following methods allow to change parameters
 88     // of some beam line components
 89     
 90     G4Material* kapton;
 91     G4VisAttributes* redWire;
 92     G4VPhysicalVolume* mother;
 93 private:
 94     static PassiveCarbonBeamLine* instance;
 95     //passive carbon line dimensions
 96     void SetDefaultDimensions();
 97     void ConstructPassiveCarbonBeamLine();
 98     
 99     PassiveCarbonBeamLineMessenger* PassiveCarbonMessenger;
100     G4VPhysicalVolume* physicalTreatmentRoom;
101     HadrontherapyDetectorConstruction* hadrontherapyDetectorConstruction;
102     
103     ///////////////////////////////////////////////////////////////////////////
104     // Definitions of all volumes
105     // World (experimental hall)
106     G4Box* treatmentRoom;
107     G4LogicalVolume* logicTreatmentRoom;
108     
109     
110     // Beamline support
111     G4Box* beamLineSupport;
112     G4LogicalVolume* logicBeamLineSupport;
113     G4VPhysicalVolume* physiBeamLineSupport;
114     
115     // Beamline covers
116     G4Box* beamLineCover;
117     G4LogicalVolume* logicBeamLineCover;
118     G4VPhysicalVolume* physiBeamLineCover;
119     G4VPhysicalVolume* physiBeamLineCover2;
120     
121     // Vacuum pipe
122     G4Box* vacuumZone;
123     G4LogicalVolume* logicVacuumZone;
124     G4VPhysicalVolume* physiVacuumZone;
125     
126     // Scattering foil
127     G4Box* firstScatteringFoil;
128     G4LogicalVolume* logicFirstScatteringFoil;
129     G4VPhysicalVolume* physiFirstScatteringFoil;
130     
131     // Kapton window
132     G4Box* solidKaptonWindow;
133     G4LogicalVolume* logicKaptonWindow;
134     G4VPhysicalVolume* physiKaptonWindow;
135     
136     //Ripple filter
137     G4Box* SolidRippleFilter;
138     G4LogicalVolume* LogicRippleFilter;
139     G4VPhysicalVolume* PhysiRippleFilter;
140     
141     G4Box* SolidRippleFilterBase;
142     G4LogicalVolume* LogicRippleFilterBase;
143     G4VPhysicalVolume* PhysiRippleFilterBase;
144     
145     G4Trd* SolidRippleFilterTrd;
146     G4LogicalVolume* LogicRippleFilterTrd;
147     G4VPhysicalVolume* PhysiRippleFilterTrd;
148     
149     
150     //
151     G4Box* supportFoil;
152     G4LogicalVolume* LogicSupportFoil;
153     G4VPhysicalVolume* PhysiSupportFoil;
154     //
155     G4Tubs* stopper;
156     G4LogicalVolume* LogicStopper;
157     G4VPhysicalVolume* PhysicStopper;
158     //Ridge filter
159     G4Box* SolidRidgeBase;
160     G4LogicalVolume* LogicRidgeBase;
161     G4VPhysicalVolume* PhysiRidgeFilterBase;
162     
163     G4Box* SolidRidgeMother;
164     G4LogicalVolume* LogicRidgeMother;
165    // G4VPhysicalVolume* PhysiRidgeMother;
166     
167     
168     // PMMA Collimator
169     G4Box* solidPMMACollimatorSupport;
170     G4LogicalVolume* logicPMMACollimatorSupport;
171     G4VPhysicalVolume* physiPMMACollimatorSupport;
172     
173     G4Tubs* solidPMMACollimator;
174     G4LogicalVolume* logicPMMACollimator;
175     G4VPhysicalVolume* physiPMMACollimator;
176     
177     // Monitor chamber
178     G4Box* solidFirstMonitorLayer1;
179     G4LogicalVolume* logicFirstMonitorLayer1;
180     G4VPhysicalVolume* physiFirstMonitorLayer1;
181     
182     G4Box* solidFirstMonitorLayer2;
183     G4LogicalVolume* logicFirstMonitorLayer2;
184     G4VPhysicalVolume* physiFirstMonitorLayer2;
185     
186     G4Box* solidFirstMonitorLayer3;
187     G4LogicalVolume* logicFirstMonitorLayer3;
188     G4VPhysicalVolume* physiFirstMonitorLayer3;
189     
190     G4Box* solidFirstMonitorLayer4;
191     G4LogicalVolume* logicFirstMonitorLayer4;
192     G4VPhysicalVolume* physiFirstMonitorLayer4;
193     
194     // Final nozzle and collimator
195     G4Box* solidNozzleSupport;
196     G4LogicalVolume* logicNozzleSupport;
197     G4VPhysicalVolume* physiNozzleSupport;
198     
199     G4Tubs* solidHoleNozzleSupport;
200     G4LogicalVolume* logicHoleNozzleSupport;
201     G4VPhysicalVolume* physiHoleNozzleSupport;
202     
203     G4Tubs* solidBrassTube3;
204     G4LogicalVolume* logicBrassTube3;
205     G4VPhysicalVolume* physiBrassTube3;
206     
207     G4Tubs* solidBrassTube2;
208     G4LogicalVolume* logicBrassTube2;
209     G4VPhysicalVolume* physiBrassTube2;
210     
211     G4Tubs* solidBrassTube;
212     G4LogicalVolume* logicBrassTube;
213     G4VPhysicalVolume* physiBrassTube;
214     
215     // Final collimator
216     G4Tubs* solidFinalCollimator;
217     G4VPhysicalVolume* physiFinalCollimator;
218     G4LogicalVolume* logicFinalCollimator;
219     
220     ///////////////////////////////////////////////////////////////////////////
221     // Dimensions and positions of all volumes
222     // Beamline support
223     G4double beamLineSupportXSize;
224     G4double beamLineSupportYSize;
225     G4double beamLineSupportZSize;
226     G4double beamLineSupportXPosition;
227     G4double beamLineSupportYPosition;
228     G4double beamLineSupportZPosition;
229     
230     // Beamline covers
231     G4double beamLineCoverXSize;
232     G4double beamLineCoverYSize;
233     G4double beamLineCoverZSize;
234     G4double beamLineCoverXPosition;
235     G4double beamLineCoverYPosition;
236     G4double beamLineCoverZPosition;
237     
238     // vacuum pipe
239     G4double vacuumZoneXSize;
240     G4double vacuumZoneYSize;
241     G4double vacuumZoneZSize;
242     G4double vacuumPipeXPosition;
243     
244     // Scattering foil
245     G4double firstScatteringFoilXSize;
246     G4double firstScatteringFoilYSize;
247     G4double firstScatteringFoilZSize;
248     G4double firstScatteringFoilXPosition;
249     
250     // kapton Windows
251     G4double kaptonWindowXSize;
252     G4double kaptonWindowYSize;
253     G4double kaptonWindowZSize;
254     G4double kaptonWindowXPosition;
255     
256     // PMMA Collimator
257     G4double PMMACollimatorSupportXSize;
258     G4double PMMACollimatorSupportYSize;
259     G4double PMMACollimatorSupportZSize;
260     G4double PMMACollimatorXPosition;
261     G4double innerRadiusPMMACollimator;
262     G4double outerRadiusPMMACollimator;
263     G4double hightPMMACollimator;
264     G4double startAnglePMMACollimator;
265     G4double spanningAnglePMMACollimator;
266     
267     // Monitor chamber
268     G4double monitor1XSize;
269     G4double monitor2XSize;
270     G4double monitor3XSize;
271     G4double monitorYSize;
272     G4double monitorZSize;
273     G4double monitor1XPosition;
274     G4double monitor2XPosition;
275     G4double monitor4XPosition;
276     
277     // Final nozzle and collimator
278     G4double nozzleSupportXSize;
279     G4double nozzleSupportYSize;
280     G4double nozzleSupportZSize;
281     G4double nozzleSupportXPosition;
282     
283     G4double innerRadiusHoleNozzleSupport;
284     G4double outerRadiusHoleNozzleSupport;
285     G4double hightHoleNozzleSupport;
286     G4double startAngleHoleNozzleSupport;
287     G4double spanningAngleHoleNozzleSupport;
288     
289     G4double innerRadiusBrassTube3;
290     G4double outerRadiusBrassTube3;
291     G4double hightBrassTube3;
292     G4double startAngleBrassTube3;
293     G4double spanningAngleBrassTube3;
294     G4double brassTube3XPosition;
295     
296     G4double innerRadiusBrassTube2;
297     G4double outerRadiusBrassTube2;
298     G4double hightBrassTube2;
299     G4double startAngleBrassTube2;
300     G4double spanningAngleBrassTube2;
301     
302     G4double innerRadiusBrassTube;
303     G4double outerRadiusBrassTube;
304     G4double hightBrassTube;
305     G4double startAngleBrassTube;
306     G4double spanningAngleBrassTube;
307     G4double brassTubeXPosition;
308     
309     // Final collimator
310     G4double outerRadiusFinalCollimator;
311     G4double innerRadiusFinalCollimator;
312     G4double hightFinalCollimator;
313     G4double startAngleFinalCollimator;
314     G4double spanningAngleFinalCollimator;
315     G4double finalCollimatorXPosition;
316     
317     // Colors
318     G4VisAttributes* blue;
319     G4VisAttributes* gray;
320     G4VisAttributes* white;
321     G4VisAttributes* red;
322     G4VisAttributes* yellow;
323     G4VisAttributes* green;
324     G4VisAttributes* darkGreen;
325     G4VisAttributes* darkOrange3;
326     G4VisAttributes* skyBlue;
327     G4VisAttributes* black;
328     
329     // Elements, compounds and materials
330     G4Material *aluminumNist;
331     G4Material* copperNistMaterial;
332     G4Material* airNist;
333     G4Material* kaptonNist;
334     G4Material* galacticNist;
335     G4Material* PMMANist;
336     G4Material* tantalumNist;
337     G4Material* brass;
338     
339     G4Material* beamLineSupportMaterial;
340     G4Material* vacuumZoneMaterial;
341     G4Material* kaptonWindowMaterial;
342     G4Material* firstScatteringFoilMaterial;
343     
344     G4Material* layer1MonitorChamberMaterial;
345     G4Material* layer2MonitorChamberMaterial;
346     G4Material* layer3MonitorChamberMaterial;
347     G4Material* layer4MonitorChamberMaterial;
348     G4Material* nozzleSupportMaterial;
349     G4Material* holeNozzleSupportMaterial;
350     G4Material* seconHoleNozzleSupportMaterial;
351     G4Material* brassTubeMaterial;
352     G4Material* brassTube2Material;
353     G4Material* brassTube3Material;
354     G4Material* finalCollimatorMaterial;
355     G4Material* PMMACollimatorMaterial;
356     G4Material* rippleFilterMaterial;
357     G4Material* rippleFilterBoxMaterial;
358     
359     HadrontherapyDetectorROGeometry* RO;
360     
361     G4VPhysicalVolume* PhysiTrapp1;
362     G4VPhysicalVolume* PhysiTrapp2;
363     G4VPhysicalVolume* PhysiTrapp3;
364     G4VPhysicalVolume* PhysiTrapp4;
365     G4VPhysicalVolume* PhysiTrapp5;
366     G4VPhysicalVolume* PhysiTrapp6;
367     G4VPhysicalVolume* PhysiTrapp7;
368     G4VPhysicalVolume* PhysiTrapp8;
369     G4VPhysicalVolume* PhysiTrapp9;
370     G4VPhysicalVolume* PhysiTrapp10;
371     G4VPhysicalVolume* PhysiTrapp11;
372     G4VPhysicalVolume* PhysiTrapp12;
373     G4VPhysicalVolume* PhysiTrapp13;
374     G4VPhysicalVolume* PhysiTrapp14;
375     G4VPhysicalVolume* PhysiTrapp15;
376     G4VPhysicalVolume* PhysiTrapp16;
377     
378     
379 };
380 #endif
381 
382