Message: What is the Order in which secondaries get simulated? Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

Question What is the Order in which secondaries get simulated? 

Forum: Event and Track Management
Date: 02 Jun, 2017
From: Paul Hackspacher <Paul Hackspacher>

Hello everybody!

So I'm trying to simulate radioactive decay (in this example the Th-232 chain specifically) inside a liquid scintillator detector, and I'm kinda confused. I was expecting all of the secondaries to be simulated before the next isotope decay is processed (last in, first out). And for the most part, that's exactly what Geant4 does... except for Compton electrons. For some reason, those get processed whenever the simulation feels like it. I still haven't figured out what exactly the sequence is. Unfortunately, I need to save the information of the secondaries for each decay independently, so I need all secondaries to be simulated before the subsequent decay begins. Having the Compton electrons at a later point in the calculation means that their properties become assigned to the wrong isotope within my output.

I have attached the tracking verbosity below. As you can see from the track and parent IDs, each secondary gets processed immediately, until a gamma produces Compton electrons (Track ID 13). The simulation then continues to simulate subsequent decays until Pb212 produces an electron (Track ID 35) after which ALL electrons get processed one after another, including the ones on the "waiting list". My code then wrongly assigns these to the Pb212 decay instead of the Th228 decay.

So I'd like to know: Is this a bug or is this the intended behaviour of Geant4? Is it possible to rearrange the order of the secondaries, so that each secondary gets simulated after its respective radioactive decay?

Thanks in advance,

Paul

=============================================================

*********************************************************************************************************
* G4Track Information:   Particle = Th232[0.0],   Track ID = 1,   Parent ID = 0
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      447     -139  2.7e+03         0        0        0         0       scint initStep
    1      447     -139  2.7e+03         0        0        0         0       scint RadioactiveDecay

*********************************************************************************************************
* G4Track Information:   Particle = alpha,   Track ID = 3,   Parent ID = 1
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      447     -139  2.7e+03      4.01        0        0         0       scint initStep
    1      447     -139  2.7e+03         0     4.01   0.0255    0.0255       scint hIoni

*********************************************************************************************************
* G4Track Information:   Particle = Ra228[0.0],   Track ID = 2,   Parent ID = 1
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      447     -139  2.7e+03    0.0705        0        0         0       scint initStep
    1      447     -139  2.7e+03         0   0.0705 0.000382  0.000382       scint hIoni
    2      447     -139  2.7e+03         0        0        0  0.000382       scint RadioactiveDecay

*********************************************************************************************************
* G4Track Information:   Particle = e-,   Track ID = 6,   Parent ID = 2
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      447     -139  2.7e+03  0.000379        0        0         0       scint initStep
    1      447     -139  2.7e+03         0 0.000379 1.61e-05  1.61e-05       scint eIoni

*********************************************************************************************************
* G4Track Information:   Particle = Ac228[33.1],   Track ID = 4,   Parent ID = 2
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      447     -139  2.7e+03  2.35e-09        0        0         0       scint initStep
    1      447     -139  2.7e+03         0 2.35e-09 6.92e-08  6.92e-08       scint hIoni
    2      447     -139  2.7e+03         0        0        0  6.92e-08       scint RadioactiveDecay

*********************************************************************************************************
* G4Track Information:   Particle = e-,   Track ID = 8,   Parent ID = 4
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      447     -139  2.7e+03    0.0132        0        0         0       scint initStep
    1      447     -139  2.7e+03         0   0.0132  0.00454   0.00454       scint eIoni

*********************************************************************************************************
* G4Track Information:   Particle = Ac228[0.0],   Track ID = 7,   Parent ID = 4
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      447     -139  2.7e+03         0        0        0         0       scint initStep
    1      447     -139  2.7e+03         0        0        0         0       scint RadioactiveDecay

*********************************************************************************************************
* G4Track Information:   Particle = e-,   Track ID = 11,   Parent ID = 7
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      447     -139  2.7e+03    0.0048        0        0         0       scint initStep
    1      447     -139  2.7e+03         0   0.0048 0.000768  0.000768       scint eIoni

*********************************************************************************************************
* G4Track Information:   Particle = Th228[1688.4],   Track ID = 9,   Parent ID = 7
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      447     -139  2.7e+03   3.8e-07        0        0         0       scint initStep
    1      447     -139  2.7e+03         0  3.8e-07 8.73e-07  8.73e-07       scint hIoni
    2      447     -139  2.7e+03         0        0        0  8.73e-07       scint RadioactiveDecay

*********************************************************************************************************
* G4Track Information:   Particle = Th228[57.8],   Track ID = 12,   Parent ID = 9
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      447     -139  2.7e+03         0        0        0         0       scint initStep
    1      447     -139  2.7e+03         0        0        0         0       scint RadioactiveDecay

*********************************************************************************************************
* G4Track Information:   Particle = e-,   Track ID = 15,   Parent ID = 12
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      447     -139  2.7e+03    0.0381        0        0         0       scint initStep
    1      447     -139  2.7e+03         0   0.0381   0.0296    0.0296       scint eIoni

*********************************************************************************************************
* G4Track Information:   Particle = gamma,   Track ID = 13,   Parent ID = 9
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      447     -139  2.7e+03      1.63        0        0         0       scint initStep
    1      462     -106 2.87e+03     0.438        0      178       178       scint compt
    2      632    -23.4 2.87e+03     0.254        0      189       368       scint compt
    3      721     -146 2.94e+03     0.162        0      166       533       scint compt
    4      789     -131 2.83e+03     0.113        0      129       662       scint compt
    5      801     -112 2.85e+03    0.0858        0     33.5       696       scint compt
    6      793     -111 2.85e+03     0.066        0     8.97       705       scint compt
    7      832     -144 2.85e+03     0.061        0     52.3       757       scint compt
    8      834     -144 2.85e+03      0.05        0     2.29       759       scint compt
    9      832     -142 2.86e+03         0 0.000288     15.8       775       scint phot

*********************************************************************************************************
* G4Track Information:   Particle = Th228[0.0],   Track ID = 14,   Parent ID = 12
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      447     -139  2.7e+03         0        0        0         0       scint initStep
    1      447     -139  2.7e+03         0        0        0         0       scint RadioactiveDecay

*********************************************************************************************************
* G4Track Information:   Particle = alpha,   Track ID = 26,   Parent ID = 14
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      447     -139  2.7e+03      5.42        0        0         0       scint initStep
    1      447     -139  2.7e+03         0     5.42   0.0413    0.0413       scint hIoni

*********************************************************************************************************
* G4Track Information:   Particle = Ra224[0.0],   Track ID = 25,   Parent ID = 14
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      447     -139  2.7e+03     0.097        0        0         0       scint initStep
    1      447     -139  2.7e+03         0    0.097 0.000444  0.000444       scint hIoni
    2      447     -139  2.7e+03         0        0        0  0.000444       scint RadioactiveDecay

*********************************************************************************************************
* G4Track Information:   Particle = alpha,   Track ID = 28,   Parent ID = 25
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      447     -139  2.7e+03      5.69        0        0         0       scint initStep
    1      447     -139  2.7e+03         0     5.69   0.0446    0.0446       scint hIoni

*********************************************************************************************************
* G4Track Information:   Particle = Rn220[0.0],   Track ID = 27,   Parent ID = 25
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      447     -139  2.7e+03     0.104        0        0         0       scint initStep
    1      447     -139  2.7e+03         0    0.104 0.000462  0.000462       scint hIoni
    2      447     -139  2.7e+03         0        0        0  0.000462       scint RadioactiveDecay

*********************************************************************************************************
* G4Track Information:   Particle = alpha,   Track ID = 30,   Parent ID = 27
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      447     -139  2.7e+03      6.29        0        0         0       scint initStep
    1      447     -139  2.7e+03         0     6.29   0.0525    0.0525       scint hIoni

*********************************************************************************************************
* G4Track Information:   Particle = Po216[0.0],   Track ID = 29,   Parent ID = 27
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      447     -139  2.7e+03     0.117        0        0         0       scint initStep
    1      447     -139  2.7e+03         0    0.117 0.000494  0.000494       scint hIoni
    2      447     -139  2.7e+03         0        0        0  0.000494       scint RadioactiveDecay

*********************************************************************************************************
* G4Track Information:   Particle = alpha,   Track ID = 32,   Parent ID = 29
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      447     -139  2.7e+03      6.78        0        0         0       scint initStep
    1      447     -139  2.7e+03         0     6.78   0.0594    0.0594       scint hIoni

*********************************************************************************************************
* G4Track Information:   Particle = Pb212[0.0],   Track ID = 31,   Parent ID = 29
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      447     -139  2.7e+03     0.128        0        0         0       scint initStep
    1      447     -139  2.7e+03         0    0.128 0.000522  0.000522       scint hIoni
    2      447     -139  2.7e+03         0        0        0  0.000522       scint RadioactiveDecay

*********************************************************************************************************
* G4Track Information:   Particle = e-,   Track ID = 35,   Parent ID = 31
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      447     -139  2.7e+03     0.161        0        0         0       scint initStep
    1      447     -139  2.7e+03         0    0.161    0.353     0.353       scint eIoni

*********************************************************************************************************
* G4Track Information:   Particle = e-,   Track ID = 24,   Parent ID = 13
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      832     -142 2.86e+03    0.0497        0        0         0       scint initStep
    1      832     -142 2.86e+03         0   0.0497   0.0474    0.0474       scint eIoni

*********************************************************************************************************
* G4Track Information:   Particle = e-,   Track ID = 23,   Parent ID = 13
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      834     -144 2.85e+03    0.0111        0        0         0       scint initStep
    1      834     -144 2.85e+03         0   0.0111  0.00332   0.00332       scint eIoni

*********************************************************************************************************
* G4Track Information:   Particle = e-,   Track ID = 22,   Parent ID = 13
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      832     -144 2.85e+03    0.0049        0        0         0       scint initStep
    1      832     -144 2.85e+03         0   0.0049 0.000796  0.000796       scint eIoni

*********************************************************************************************************
* G4Track Information:   Particle = e-,   Track ID = 21,   Parent ID = 13
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      793     -111 2.85e+03    0.0198        0        0         0       scint initStep
    1      793     -111 2.85e+03         0   0.0198   0.0093    0.0093       scint eIoni

*********************************************************************************************************
* G4Track Information:   Particle = e-,   Track ID = 20,   Parent ID = 13
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      801     -112 2.85e+03    0.0272        0        0         0       scint initStep
    1      801     -112 2.85e+03         0   0.0272   0.0164    0.0164       scint eIoni

*********************************************************************************************************
* G4Track Information:   Particle = e-,   Track ID = 19,   Parent ID = 13
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      789     -131 2.83e+03    0.0487        0        0         0       scint initStep
    1      789     -131 2.83e+03         0   0.0487   0.0457    0.0457       scint eIoni

*********************************************************************************************************
* G4Track Information:   Particle = e-,   Track ID = 18,   Parent ID = 13
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      721     -146 2.94e+03    0.0918        0        0         0       scint initStep
    1      721     -146 2.94e+03         0   0.0918    0.138     0.138       scint eIoni

*********************************************************************************************************
* G4Track Information:   Particle = e-,   Track ID = 17,   Parent ID = 13
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      632    -23.4 2.87e+03     0.184        0        0         0       scint initStep
    1      633    -23.2 2.87e+03         0    0.184    0.439     0.439       scint eIoni

*********************************************************************************************************
* G4Track Information:   Particle = e-,   Track ID = 16,   Parent ID = 13
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      462     -106 2.87e+03      1.19        0        0         0       scint initStep
    1      462     -105 2.87e+03     0.651    0.212     1.66      1.66       scint eIoni
    2      461     -104 2.88e+03      0.35    0.301     1.89      3.54       scint eIoni
    3      461     -103 2.88e+03   0.00328    0.346     1.16      4.71       scint eIoni
    4      461     -103 2.88e+03         0  0.00328 0.000401      4.71       scint eIoni

*********************************************************************************************************
* G4Track Information:   Particle = e-,   Track ID = 36,   Parent ID = 16
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      462     -105 2.87e+03      0.33        0        0         0       scint initStep
    1      461     -106 2.87e+03    0.0645    0.266     1.08      1.08       scint eIoni
    2      461     -106 2.87e+03         0   0.0645   0.0749      1.16       scint eIoni

*********************************************************************************************************
* G4Track Information:   Particle = Bi212[238.6],   Track ID = 33,   Parent ID = 31
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      447     -139  2.7e+03  6.64e-07        0        0         0       scint initStep
    1      447     -139  2.7e+03         0 6.64e-07 1.13e-07  1.13e-07       scint RadioactiveDecay

*********************************************************************************************************
* G4Track Information:   Particle = e-,   Track ID = 38,   Parent ID = 33
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      447     -139  2.7e+03     0.148        0        0         0       scint initStep
    1      447     -139  2.7e+03         0    0.148    0.308     0.308       scint eIoni

*********************************************************************************************************
* G4Track Information:   Particle = Bi212[0.0],   Track ID = 37,   Parent ID = 33
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      447     -139  2.7e+03         0        0        0         0       scint initStep
    1      447     -139  2.7e+03         0        0        0         0       scint RadioactiveDecay

*********************************************************************************************************
* G4Track Information:   Particle = e-,   Track ID = 41,   Parent ID = 37
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      447     -139  2.7e+03      1.01        0        0         0       scint initStep
    1      447     -138  2.7e+03     0.489    0.184     1.46      1.46       scint eIoni
    2      445     -138  2.7e+03     0.193    0.296     1.57      3.03       scint eIoni
    3      445     -138  2.7e+03         0    0.193    0.475       3.5       scint eIoni

*********************************************************************************************************
* G4Track Information:   Particle = e-,   Track ID = 42,   Parent ID = 41
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      447     -138  2.7e+03     0.341        0        0         0       scint initStep
    1      446     -138  2.7e+03     0.001     0.34     1.13      1.13       scint eIoni
    2      446     -138  2.7e+03         0    0.001 5.95e-05      1.13       scint eIoni

*********************************************************************************************************
* G4Track Information:   Particle = Po212[0.0],   Track ID = 39,   Parent ID = 37
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      447     -139  2.7e+03  1.16e-05        0        0         0       scint initStep
    1      447     -139  2.7e+03         0 1.16e-05 4.88e-06  4.88e-06       scint hIoni
    2      447     -139  2.7e+03         0        0        0  4.88e-06       scint RadioactiveDecay

*********************************************************************************************************
* G4Track Information:   Particle = alpha,   Track ID = 44,   Parent ID = 39
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      447     -139  2.7e+03      8.78        0        0         0       scint initStep
    1      447     -139  2.7e+03         0     8.78   0.0916    0.0916       scint hIoni

*********************************************************************************************************
* G4Track Information:   Particle = Pb208[0.0],   Track ID = 43,   Parent ID = 39
*********************************************************************************************************

Step#    X(mm)    Y(mm)    Z(mm) KinE(MeV)  dE(MeV) StepLeng TrackLeng  NextVolume ProcName
    0      447     -139  2.7e+03     0.169        0        0         0       scint initStep
    1      447     -139  2.7e+03         0    0.169 0.000594  0.000594       scint hIoni
    2      447     -139  2.7e+03         0        0        0  0.000594       scint RadioactiveDecay

Inline Depth:
 1 1
 All All
Outline Depth:
 1 1
 2 2
 All All
Add message: (add)

1 Idea: Re: What is the Order in which secondaries get simulated?   (Synthex - 04 Jun, 2017)
(_ None: Re: What is the Order in which secondaries get simulated?   (Paul Hackspacher - 05 Jun, 2017)
 Add Message Add Message
to: "What is the Order in which secondaries get simulated?"

 Subscribe Subscribe

This site runs SLAC HyperNews version 1.11-slac-98, derived from the original HyperNews


[ Geant 4 Home | Geant 4 HyperNews | Search | Request New Forum | Feedback ]