[819] | 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: G4MuBremsstrahlungModel.hh,v 1.17 2007/10/11 09:25:31 vnivanch Exp $ |
---|
| 27 | // GEANT4 tag $Name: geant4-09-01-patch-02 $ |
---|
| 28 | // |
---|
| 29 | // ------------------------------------------------------------------- |
---|
| 30 | // |
---|
| 31 | // GEANT4 Class header file |
---|
| 32 | // |
---|
| 33 | // |
---|
| 34 | // File name: G4MuBremsstrahlungModel |
---|
| 35 | // |
---|
| 36 | // Author: Vladimir Ivanchenko on base of Laszlo Urban code |
---|
| 37 | // |
---|
| 38 | // Creation date: 18.05.2002 |
---|
| 39 | // |
---|
| 40 | // Modifications: |
---|
| 41 | // |
---|
| 42 | // 23-12-02 Change interface in order to move to cut per region (V.Ivanchenko) |
---|
| 43 | // 27-01-03 Make models region aware (V.Ivanchenko) |
---|
| 44 | // 13-02-03 Add name (V.Ivanchenko) |
---|
| 45 | // 10-02-04 Add lowestKinEnergy (V.Ivanchenko) |
---|
| 46 | // 08-04-05 Major optimisation of internal interfaces (V.Ivantchenko) |
---|
| 47 | // 13-02-06 add ComputeCrossSectionPerAtom (mma) |
---|
| 48 | // 11-10-07 Add ignoreCut flag (V.Ivanchenko) |
---|
| 49 | // |
---|
| 50 | |
---|
| 51 | // |
---|
| 52 | // Class Description: |
---|
| 53 | // |
---|
| 54 | // Implementation of energy loss for gamma emission by muons |
---|
| 55 | |
---|
| 56 | // ------------------------------------------------------------------- |
---|
| 57 | // |
---|
| 58 | |
---|
| 59 | #ifndef G4MuBremsstrahlungModel_h |
---|
| 60 | #define G4MuBremsstrahlungModel_h 1 |
---|
| 61 | |
---|
| 62 | #include "G4VEmModel.hh" |
---|
| 63 | |
---|
| 64 | class G4Element; |
---|
| 65 | class G4ParticleChangeForLoss; |
---|
| 66 | |
---|
| 67 | class G4MuBremsstrahlungModel : public G4VEmModel |
---|
| 68 | { |
---|
| 69 | |
---|
| 70 | public: |
---|
| 71 | |
---|
| 72 | G4MuBremsstrahlungModel(const G4ParticleDefinition* p = 0, |
---|
| 73 | const G4String& nam = "MuBrem"); |
---|
| 74 | |
---|
| 75 | virtual ~G4MuBremsstrahlungModel(); |
---|
| 76 | |
---|
| 77 | void SetParticle(const G4ParticleDefinition*); |
---|
| 78 | |
---|
| 79 | void Initialise(const G4ParticleDefinition*, const G4DataVector&); |
---|
| 80 | |
---|
| 81 | void SetLowestKineticEnergy(G4double e) {lowestKinEnergy = e;}; |
---|
| 82 | |
---|
| 83 | G4double MinEnergyCut(const G4ParticleDefinition*, |
---|
| 84 | const G4MaterialCutsCouple*); |
---|
| 85 | |
---|
| 86 | virtual G4double ComputeCrossSectionPerAtom( |
---|
| 87 | const G4ParticleDefinition*, |
---|
| 88 | G4double kineticEnergy, |
---|
| 89 | G4double Z, G4double A, |
---|
| 90 | G4double cutEnergy, |
---|
| 91 | G4double maxEnergy); |
---|
| 92 | |
---|
| 93 | virtual G4double CrossSectionPerVolume(const G4Material*, |
---|
| 94 | const G4ParticleDefinition*, |
---|
| 95 | G4double kineticEnergy, |
---|
| 96 | G4double cutEnergy, |
---|
| 97 | G4double maxEnergy); |
---|
| 98 | |
---|
| 99 | virtual G4double ComputeDEDXPerVolume(const G4Material*, |
---|
| 100 | const G4ParticleDefinition*, |
---|
| 101 | G4double kineticEnergy, |
---|
| 102 | G4double cutEnergy); |
---|
| 103 | |
---|
| 104 | void SampleSecondaries(std::vector<G4DynamicParticle*>*, |
---|
| 105 | const G4MaterialCutsCouple*, |
---|
| 106 | const G4DynamicParticle*, |
---|
| 107 | G4double tmin, |
---|
| 108 | G4double maxEnergy); |
---|
| 109 | |
---|
| 110 | protected: |
---|
| 111 | |
---|
| 112 | G4double MaxSecondaryEnergy(const G4ParticleDefinition*, |
---|
| 113 | G4double kineticEnergy); |
---|
| 114 | |
---|
| 115 | public: |
---|
| 116 | |
---|
| 117 | G4double ComputMuBremLoss(G4double Z, G4double A, G4double tkin, G4double cut); |
---|
| 118 | |
---|
| 119 | G4double ComputeMicroscopicCrossSection(G4double tkin, |
---|
| 120 | G4double Z, |
---|
| 121 | G4double A, |
---|
| 122 | G4double cut); |
---|
| 123 | |
---|
| 124 | G4double ComputeDMicroscopicCrossSection(G4double tkin, |
---|
| 125 | G4double Z, |
---|
| 126 | G4double A, |
---|
| 127 | G4double gammaEnergy); |
---|
| 128 | |
---|
| 129 | inline void SetIgnoreCutFlag(G4bool); |
---|
| 130 | |
---|
| 131 | inline G4bool IgnoreCutFlag() const; |
---|
| 132 | |
---|
| 133 | private: |
---|
| 134 | |
---|
| 135 | G4DataVector* ComputePartialSumSigma(const G4Material* material, |
---|
| 136 | G4double tkin, G4double cut); |
---|
| 137 | |
---|
| 138 | const G4Element* SelectRandomAtom(const G4MaterialCutsCouple* couple) const; |
---|
| 139 | |
---|
| 140 | void MakeSamplingTables(); |
---|
| 141 | |
---|
| 142 | |
---|
| 143 | // hide assignment operator |
---|
| 144 | G4MuBremsstrahlungModel & operator=(const G4MuBremsstrahlungModel &right); |
---|
| 145 | G4MuBremsstrahlungModel(const G4MuBremsstrahlungModel&); |
---|
| 146 | |
---|
| 147 | G4ParticleDefinition* theGamma; |
---|
| 148 | const G4ParticleDefinition* particle; |
---|
| 149 | G4ParticleChangeForLoss* fParticleChange; |
---|
| 150 | |
---|
| 151 | G4double highKinEnergy; |
---|
| 152 | G4double lowKinEnergy; |
---|
| 153 | G4double lowestKinEnergy; |
---|
| 154 | G4double minThreshold; |
---|
| 155 | G4double mass; |
---|
| 156 | |
---|
| 157 | // tables for sampling |
---|
| 158 | G4int nzdat,ntdat,NBIN; |
---|
| 159 | static G4double zdat[5],adat[5],tdat[8]; |
---|
| 160 | G4double ya[1001], proba[5][8][1001]; |
---|
| 161 | G4double cutFixed; |
---|
| 162 | |
---|
| 163 | G4bool ignoreCut; |
---|
| 164 | |
---|
| 165 | std::vector<G4DataVector*> partialSumSigma; |
---|
| 166 | G4bool samplingTablesAreFilled; |
---|
| 167 | |
---|
| 168 | }; |
---|
| 169 | |
---|
| 170 | //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... |
---|
| 171 | |
---|
| 172 | inline G4double G4MuBremsstrahlungModel::MaxSecondaryEnergy( |
---|
| 173 | const G4ParticleDefinition*, |
---|
| 174 | G4double kineticEnergy) |
---|
| 175 | { |
---|
| 176 | return kineticEnergy; |
---|
| 177 | } |
---|
| 178 | |
---|
| 179 | //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... |
---|
| 180 | |
---|
| 181 | inline void G4MuBremsstrahlungModel::SetIgnoreCutFlag(G4bool val) |
---|
| 182 | { |
---|
| 183 | ignoreCut = val; |
---|
| 184 | } |
---|
| 185 | |
---|
| 186 | //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... |
---|
| 187 | |
---|
| 188 | inline G4bool G4MuBremsstrahlungModel::IgnoreCutFlag() const |
---|
| 189 | { |
---|
| 190 | return ignoreCut; |
---|
| 191 | } |
---|
| 192 | |
---|
| 193 | //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... |
---|
| 194 | |
---|
| 195 | #endif |
---|