| Message: Re: Scintillation rise time | Not Logged In (login) |
|
Dear Martin,
> Is this crystal property implemented? No, G4Scintillation only calculates an (exponential) 'time delay' and assumes an instantaneous rise time. And while the routine is set up to sample from a slow and a fast decay time simulataneously it doesn't account for a physical finite rise time. The code simply reads: deltaTime = deltaTime - ScintillationTime * log( G4UniformRand() ); where deltaTime is first set to a random point/time along the step segment from where the scintillation photon is assumed to have originated. > If not how may I do it? I answer this with a question. How would you sample from a convolution of a finite rise-time with a finite decay time, e.g. a more realistic time distribution? If you know the code it takes to do that then the mechanism of introducing a rise-time in the material properties table is completely analogous to, for example, the "SLOWTIMECONSTANT". The G4MaterialPropertiesTable class is completely flexible in this. It simply associates a constant with a (any) character string. In your DetectorConstruction you assign the rise/decay time, for example: G4MaterialPropertiesTable* myMPT = new G4MaterialPropertiesTable(); myMPT->AddConstProperty("SLOWTIMECONSTANT",10.*ns); myMPT->AddConstProperty("RISETIMECONSTANT",0.5*ns); and in G4Scintillation.cc (you need to modify the actual G4 source) you add code to retrieve this constant: G4MaterialPropertiesTable* aMaterialPropertiesTable =
aMaterial->GetMaterialPropertiesTable(); G4double ScintillationRiseTime = aMaterialPropertiesTable->
GetConstProperty("RISETIMECONSTANT");
And you'd then have to replace the single line:
ScintillationTime * log( G4UniformRand() ); with your more complicated sampling logic. Let me know which approach to sampling from a more realistic time profile, with a rise and decay constant, you are taking. I am open to improvements of the G4 distribution. Best regards, Peter
|
|
to: |