Geant4 Cross Reference |
1 ------------------------------------------------------------------- 2 3 ========================================================= 4 Geant4 - X-Ray Telescope Example 5 ========================================================= 6 7 8 Introduction 9 ------------ 10 XrayTel is an advanced Geant4 example based on a realistic simulation of 11 an X-ray Telescope. It is based on work carried out by a team of Geant4 12 experts to simulate the interaction between X-ray Telescopes XMM-Newton 13 and Chandra with low energy protons present in the orbital radiation 14 background. The X-ray mirrors are designed to collect x-ray photons at 15 grazing-incidence angles and focus them onto detectors at the focal plane. 16 However, this mechanism also seems to work for low energy protons which, 17 if they reach the detectors in sufficient numbers, can cause damage. 18 In this example, the geometry has been simplified by using a single mirror 19 shell and no baffles, but all the dimensions and materials are realistic. 20 21 The aim of this advanced example is to illustrate the use advanced 22 GUI, visualisation, particle generation and analysis schemes available 23 in Geant4: 24 25 - macros are provided to display the geometry and particle tracks with 26 OpenGL, DAWN Postscript or VRML visualisation 27 28 - the generation of particles is done via the new General Particle Source 29 30 - histograming facilities are available through the G4AnalysisManager tools 31 32 In order to be able to use any of these packages, prior installation is 33 necessary and a number of environment variables will have to be set. 34 35 36 NOTE: The geometry is refreshed on the viewer at the beginning of each run, 37 but the tracks are plotted only in case an interesting event occurs. 38 This is the case only for about 1 every 10**4 events. 39 40 41 42 2. Run 43 44 To execute a sample simulation with visualisation of proton tracks 45 reaching the detector run: 46 47 XrayTel 48 49 execute command "/control/execute test.mac" 50 51 To enable visualisation, uncomment one line from test.mac: 52 /control/execute vis.mac 53 54 If the analysis options are set, histograms will 55 automatically created and the corresponding files will be created. 56 A 1D histogram will display the energy distribution of the protons 57 that reach the detector at the end of the run. 58 59 60 3. Detector description 61 62 The telescope and detector geometry is defined in 63 XrayTelDetectorConstruction.cc 64 65 66 4. Physics processes 67 68 The physics processes are in XrayTelPhysicsList.cc 69 The main process in this example is G4hMultipleScattering for scattering of the protons 70 off the mirror surfaces. 71 72 73 5. Event generation 74 75 This is done using the new General Particle Source. Documentation for 76 this can be found in: 77 78 http://reat.space.qinetiq.com/gps/ 79 80 81 6. Analysis 82 83 Relevant information from the simulation is processed in the XrayTelAnalysis 84 class and saved, through the G4AnalysisManager interface, to Histograms and 85 Tuples. The output file is written in Root format, but one can easily switch to Xml (or Csv, Hdf5) by changing the G4AnalysisManager default file type in XrayTelAnalysis::book(). 86 No external software is required (apart from the Hdf5 case). 87