| 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 | // $Id: G4PenelopeCrossSection.hh,v 1.1 2010/07/26 09:56:42 pandola Exp $
|
|---|
| 27 | // GEANT4 tag $Name: geant4-09-04-ref-00 $
|
|---|
| 28 | //
|
|---|
| 29 | // Author: Luciano Pandola
|
|---|
| 30 | //
|
|---|
| 31 | // History:
|
|---|
| 32 | // -----------
|
|---|
| 33 | // 18 Mar 2010 L. Pandola 1st implementation.
|
|---|
| 34 | //
|
|---|
| 35 | // -------------------------------------------------------------------
|
|---|
| 36 | //
|
|---|
| 37 | // Class description:
|
|---|
| 38 | // This class is a container for cross sections and transport momenta
|
|---|
| 39 | // calculated by Penelope models (ionisation, bremsstrahlung). It stores
|
|---|
| 40 | // PhysicsTables/PhysicsVectors of
|
|---|
| 41 | // a) the "hard quantities" (above the threshold), 0-th order (cross section)
|
|---|
| 42 | // 1-st order (= stopping XS), 2-nd order (= straggling XS)
|
|---|
| 43 | // b) the "soft quantities" (below threshold), 0-th order (cross section)
|
|---|
| 44 | // 1-st order (= stopping XS), 2-nd order (= straggling XS)
|
|---|
| 45 | // c) total hard cross sections for individual oscillators
|
|---|
| 46 | // vs. energy.
|
|---|
| 47 | //
|
|---|
| 48 | // The interface *always* uses energy and cross sections, while internally
|
|---|
| 49 | // log(energy) and log(XS) are used.
|
|---|
| 50 | //
|
|---|
| 51 | // One instance per each cut-material couple should be created by the
|
|---|
| 52 | // calling class.
|
|---|
| 53 | //
|
|---|
| 54 | // Public method to retrieve hard cross section, soft stopping power,
|
|---|
| 55 | // total cross section and hard shell cross sections.
|
|---|
| 56 | //
|
|---|
| 57 | // The method NormalizeShellCrossSections() normalizes the
|
|---|
| 58 | // shell cross sections by retrieving the total hard cross section.
|
|---|
| 59 | // Used for sampling.
|
|---|
| 60 | //
|
|---|
| 61 | // Notice: all quantities stored here are *per molecule*
|
|---|
| 62 | //
|
|---|
| 63 | // -------------------------------------------------------------------
|
|---|
| 64 |
|
|---|
| 65 | #ifndef G4PENELOPECROSSSECTION_HH
|
|---|
| 66 | #define G4PENELOPECROSSSECTION_HH 1
|
|---|
| 67 |
|
|---|
| 68 | #include "globals.hh"
|
|---|
| 69 |
|
|---|
| 70 | class G4PhysicsTable;
|
|---|
| 71 | class G4DataVector;
|
|---|
| 72 |
|
|---|
| 73 | class G4PenelopeCrossSection
|
|---|
| 74 | {
|
|---|
| 75 |
|
|---|
| 76 | public:
|
|---|
| 77 | //constructor: one has to give the number of points in each PhysicsVector
|
|---|
| 78 | //(= dimension of the energy grid) and the number of shells (0 is the
|
|---|
| 79 | //default).
|
|---|
| 80 | G4PenelopeCrossSection(size_t nOfEnergyPoints,size_t nOfShells=0);
|
|---|
| 81 | //
|
|---|
| 82 | ~G4PenelopeCrossSection();
|
|---|
| 83 |
|
|---|
| 84 | G4double GetTotalCrossSection(G4double energy);
|
|---|
| 85 | G4double GetHardCrossSection(G4double energy);
|
|---|
| 86 | G4double GetSoftStoppingPower(G4double energy);
|
|---|
| 87 | G4double GetShellCrossSection(size_t shellID,G4double energy);
|
|---|
| 88 |
|
|---|
| 89 | size_t GetNumberOfShells(){return numberOfShells;};
|
|---|
| 90 |
|
|---|
| 91 | void AddCrossSectionPoint(size_t binNumber,
|
|---|
| 92 | G4double energy,G4double XH0, G4double XH1,
|
|---|
| 93 | G4double XH2,
|
|---|
| 94 | G4double XS0, G4double XS1, G4double XS2);
|
|---|
| 95 |
|
|---|
| 96 | void AddShellCrossSectionPoint(size_t binNumber,
|
|---|
| 97 | size_t shellID,G4double energy,G4double xs);
|
|---|
| 98 |
|
|---|
| 99 | void NormalizeShellCrossSections();
|
|---|
| 100 |
|
|---|
| 101 | private:
|
|---|
| 102 | G4PenelopeCrossSection & operator=(const G4PenelopeCrossSection &right);
|
|---|
| 103 | G4PenelopeCrossSection(const G4PenelopeCrossSection&);
|
|---|
| 104 |
|
|---|
| 105 | G4bool isNormalized;
|
|---|
| 106 |
|
|---|
| 107 | size_t numberOfEnergyPoints;
|
|---|
| 108 | size_t numberOfShells;
|
|---|
| 109 |
|
|---|
| 110 | //all tables are log. XS vs. log E
|
|---|
| 111 |
|
|---|
| 112 | //XS0, XS1, XS2 in Penelope nomenclature
|
|---|
| 113 | G4PhysicsTable* softCrossSections;
|
|---|
| 114 |
|
|---|
| 115 | //XH0, XH1, XH2 in Penelope nomenclature
|
|---|
| 116 | G4PhysicsTable* hardCrossSections;
|
|---|
| 117 |
|
|---|
| 118 | //XS for individual shells
|
|---|
| 119 | G4PhysicsTable* shellCrossSections;
|
|---|
| 120 |
|
|---|
| 121 | };
|
|---|
| 122 |
|
|---|
| 123 | #endif
|
|---|
| 124 |
|
|---|