Problem 1002 - energy loss greater than initial energy when using LowEnergy package
Summary: energy loss greater than initial energy when using LowEnergy package
Status: CLOSED INVALID
Alias: None
Product: Geant4
Classification: Unclassified
Component: processes/electromagnetic/lowenergy (show other problems)
Version: 9.1
Hardware: PC Linux
: P3 normal
Assignee: Maria.Grazia.Pia
URL:
Depends on:
Blocks:
 
Reported: 2008-02-25 08:35 CET by Robert Freudenberg
Modified: 2008-02-27 19:14 CET (History)
1 user (show)

See Also:


Attachments
Output for standard and LowEnergy librarys (73.53 KB, text/plain)
2008-02-25 08:35 CET, Robert Freudenberg
Details

Note You need to log in before you can comment on or make changes to this problem.
Description Robert Freudenberg 2008-02-25 08:35:33 CET
Created attachment 18 [details]
Output for standard and LowEnergy librarys

Hello,

this is a copy of my posting in the User Forum for electromagnetic processes:

On Fri, 22 Feb 2008, Robert wrote:

> *** Discussion title: Electromagnetic Processes
> Email replies to PublicHyperNews@slac.stanford.edu must include:
>   In-Reply-To: <"/emprocess/812"@geant4-hn.slac.stanford.edu>
>   Subject: ...change this to be about your reply.
> 
> Dear all,
> 
> I've the problem, that I get too much energy! My aim is to simulate the
> energy deposition in 100 um thick spherical shells around a point source
> of 500 keV electrons. When I use the standard Geant4 librarys for
> electromagnetic processes everything works fine, as you can see below:
> 
> Extraction of MyPhysicsList.cc
> 
>   if(particleName == "gamma")
>     {
>       //gamma
>       pMan->AddDiscreteProcess(new G4PhotoElectricEffect);
>       pMan->AddDiscreteProcess(new G4ComptonScattering);
>       pMan->AddDiscreteProcess(new G4GammaConversion);
>     }
>   else if(particleName == "e-")
>     {
>       //electron
>       pMan->AddProcess(new G4MultipleScattering, -1, 1, 1);
>       pMan->AddProcess(new G4eIonisation, -1, 2, 2);
>     }
>   else if(particleName == "e+")
>     {
>       //positron
>       pMan->AddProcess(new G4MultipleScattering, -1, 1, 1);
>       pMan->AddProcess(new G4eIonisation, -1, 2, 2);
>       pMan->AddProcess(new G4eBremsstrahlung, -1, 3, 3);
>       pMan->AddProcess(new G4eplusAnnihilation, 0, -1, 4);
>      }
> 
> The results look as expected:
> 
> ******Run 0 finished! 
>    Simulated events: 1
>  Shell[0]   E_abs: 20.0067911778766 keV   
>  Shell[1]   E_abs: 18.46432871484156 keV   
>  Shell[2]   E_abs: 17.16755680496905 keV   
>  Shell[3]   E_abs: 15.4193391766694 keV   
>  Shell[4]   E_abs: 23.61578150214196 keV   
>  Shell[5]   E_abs: 20.47036611695079 keV   
>  Shell[6]   E_abs: 98.07545602952851 keV   
>  Shell[7]   E_abs: 134.2114403391701 keV   
>  Shell[8]   E_abs: 152.5689401378521 keV   
>  Shell[9]   E_abs: 0 eV
>  Shell[10]   E_abs: 0 eV 
>     total absorbed energy: 500 keV
> 
> When I change to the LowEnergy package in MyPhysicsList.cc via:
> 
>   if(particleName == "gamma")
>     {
>       //gamma
>       pMan->AddDiscreteProcess(new G4LowEnergyRayleigh);
>       pMan->AddDiscreteProcess(new G4LowEnergyPhotoElectric);
>       pMan->AddDiscreteProcess(new G4LowEnergyCompton);
>       pMan->AddDiscreteProcess(new G4LowEnergyGammaConversion); 
>     }
>   else if(particleName == "e-")
>     {
>       //electron
>       pMan->AddProcess(new G4MultipleScattering, -1, 1, 1);
>       pMan->AddProcess(new G4LowEnergyIonisation, -1, 2, 2);
>       pMan->AddProcess(new G4LowEnergyBremsstrahlung, -1, 3, 3);
>     }
>   else if(particleName == "e+")
>     {
>       //positron
>       pMan->AddProcess(new G4MultipleScattering, -1, 1, 1);
>       pMan->AddProcess(new G4eplusAnnihilation, 0, -1, 4);
>       pMan->AddProcess(new G4LowEnergyIonisation, -1, 2, 2);
>       pMan->AddProcess(new G4LowEnergyBremsstrahlung, -1, 3, 3);
>     }
> 
> then I got via the G4PSEnergyDeposit-scorer a total absorbed energy of
> 561.4 keV.
> 
> ******Run 0 finished! 
>    Simulated events: 1
>  Shell[0]   E_abs: 32.46440622087332 keV
>  Shell[1]   E_abs: 28.14419079032732 keV
>  Shell[2]   E_abs: 35.09535948072306 keV
>  Shell[3]   E_abs: 66.8380046101959 keV 
>  Shell[4]   E_abs: 45.85848368358489 keV 
>  Shell[5]   E_abs: 48.56747246418793 keV 
>  Shell[6]   E_abs: 51.08569021249662 keV 
>  Shell[7]   E_abs: 166.0850614863725 keV 
>  Shell[8]   E_abs: 87.2664894852086 keV 
>  Shell[9]   E_abs: 0 eV 
>  Shell[10]   E_abs: 0 eV 
>     total absorbed energy: 561.4051584339702 keV
> 
> I already found, that the problem results from an energy loss dE which
> is twice the kinetic energy KinE of my particle as you can see by a
> detailed output of tracking:
> 
> *********************************************************************************************************
> * G4Track Information:   Particle = e-,   Track ID = 16,   Parent ID = 1
> *********************************************************************************************************
> 
> Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
>     0   -0.419    0.624   -0.239   0.00145        0        0         0 shell_physical[] initStep
>     1   -0.419    0.624   -0.239         0   0.0029   0.0215    0.0215 shell_physical[] msc
> 
> *********************************************************************************************************
> * G4Track Information:   Particle = e-,   Track ID = 15,   Parent ID = 1
> *********************************************************************************************************
> 
> Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
>     0   -0.387    0.659   -0.298   0.00317        0        0         0 shell_physical[] initStep
>     1   -0.387    0.659   -0.298         0  0.00634   0.0155    0.0155 shell_physical[] LowEnergyIoni
> 
> Does anyone knows this problem and perhaps how to solve it?
> 
> Thanks for your help
> 
> best regards, Robert
> 
> system: geant4.9.1, G4EMLOW5.1

I will attach the output file for both librarys. In the first part the standard librarys were used and in the second part of the output file the LowEnergy classes were used for simulation.
Please excuse some German words in the file, but I hope this wouldn't be an obstacle to understand the problem.

Best regards,

Robert Freudenberg
Comment 1 Maria.Grazia.Pia 2008-02-25 09:53:48 CET
This issue will be investigated in association with the design iteration foreseen in the energy loss domain. The approximate time scale for this activity ranks it as second topic of work, immediately after the termination of the current activities subject to external deadlines in March.

Best regards,

Maria Grazia Pia
Comment 2 Maria.Grazia.Pia 2008-02-27 18:55:04 CET
The wrong energy deposition with the lowenergy package is not a bug, but a matter of wrong process ordering in the user code.

The user must replace his code:

 else if(particleName == "e-")
   {
     //electron
     pMan->AddProcess(new G4MultipleScattering, -1, 1, 1);
     pMan->AddProcess(new G4LowEnergyIonisation, -1, 2, 2);
     pMan->AddProcess(new G4LowEnergyBremsstrahlung, -1, 3, 3);
   }

with the following one:

 else if(particleName == "e-")
   {
     //electron
     pMan->AddProcess(new G4MultipleScattering, -1, 1, 1);
     pMan->AddProcess(new G4LowEnergyIonisation, -1, 2, 2);
     pMan->AddProcess(new G4LowEnergyBremsstrahlung, -1, -1, 3);
   }

That means, the Bremsstrahlung process must NOT be activated for the along step
action, since it is automatically activated by the ionization
process (which is registered for the along step action).
Thus if one registers also Bremsstrahlung for the along step action, double
counting occurs.

Examples of proper usage can be found in Geant4 advanced examples using the lowenergy package: for instance, the PhysicsList of hadrontherapy (developed by Anton Lechner), brachytherapy, medical_linac, radioprotection etc.

Best regards,

Maria Grazia Pia

Comment 3 Maria.Grazia.Pia 2008-02-27 19:14:22 CET
The problem has been identified in the user code, not in Geant4.