00001 // 00002 // ******************************************************************** 00003 // * License and Disclaimer * 00004 // * * 00005 // * The Geant4 software is copyright of the Copyright Holders of * 00006 // * the Geant4 Collaboration. It is provided under the terms and * 00007 // * conditions of the Geant4 Software License, included in the file * 00008 // * LICENSE and available at http://cern.ch/geant4/license . These * 00009 // * include a list of copyright holders. * 00010 // * * 00011 // * Neither the authors of this software system, nor their employing * 00012 // * institutes,nor the agencies providing financial support for this * 00013 // * work make any representation or warranty, express or implied, * 00014 // * regarding this software system or assume any liability for its * 00015 // * use. Please see the license in the file LICENSE and URL above * 00016 // * for the full disclaimer and the limitation of liability. * 00017 // * * 00018 // * This code implementation is the result of the scientific and * 00019 // * technical work of the GEANT4 collaboration. * 00020 // * By using, copying, modifying or distributing the software (or * 00021 // * any work based on the software) you agree to acknowledge its * 00022 // * use in resulting scientific publications, and indicate your * 00023 // * acceptance of all terms of the Geant4 Software license. * 00024 // ******************************************************************** 00025 // 00026 // Class description: 00027 // 00028 // Description: Continuous Process to calculate energy loss without 00029 // fluctuations through G4EnergyLossForExtrapolator 00030 00031 // History: 00032 // Created: 2007-05-12 00033 // Author: Pedro Arce 00034 // 00035 // Modified: 00036 // 00037 00038 #ifndef G4ErrorEnergyLoss_hh 00039 #define G4ErrorEnergyLoss_hh 00040 00041 #include "globals.hh" 00042 #include "G4VContinuousProcess.hh" 00043 #include "G4ProcessType.hh" 00044 00045 class G4EnergyLossForExtrapolator; 00046 00047 class G4ErrorEnergyLoss : public G4VContinuousProcess 00048 { 00049 00050 public: 00051 00052 G4ErrorEnergyLoss(const G4String& processName = "G4ErrorEnergyLoss", 00053 G4ProcessType type = fElectromagnetic); 00054 00055 virtual ~G4ErrorEnergyLoss(); 00056 00057 00058 G4bool IsApplicable(const G4ParticleDefinition& aParticleType); 00059 // Returns true -> 'is applicable', for all charged particles. 00060 00061 G4double GetContinuousStepLimit(const G4Track& aTrack, 00062 G4double , 00063 G4double currentMinimumStep, 00064 G4double& ); 00065 // Returns DBL_MAX as continuous step limit 00066 00067 G4VParticleChange* AlongStepDoIt(const G4Track& aTrack, 00068 const G4Step& aStep); 00069 // This is the method implementing the energy loss process. 00070 00071 // Get and Set methods 00072 G4double GetStepLimit() const { return theStepLimit; } 00073 void SetStepLimit( G4double val ) { theStepLimit = val; } 00074 00075 private: 00076 00077 void InstantiateEforExtrapolator(); 00078 // Create the G4EnergyLossForExtrapolator 00079 00080 // copy constructor and hide assignment operator 00081 G4ErrorEnergyLoss(G4ErrorEnergyLoss &); 00082 G4ErrorEnergyLoss & operator=(const G4ErrorEnergyLoss &right); 00083 00084 private: 00085 G4EnergyLossForExtrapolator* theELossForExtrapolator; 00086 00087 G4double theStepLimit; 00088 }; 00089 00091 // Inline methods 00093 00094 inline 00095 G4bool G4ErrorEnergyLoss::IsApplicable(const G4ParticleDefinition& aParticleType) 00096 { 00097 return (aParticleType.GetPDGCharge() != 0); 00098 } 00099 00100 #endif /* G4ErrorEnergyLoss_hh */