Problem 1711 - Bug in the production of Cherenkov photons (wrong number of photons due to wrong refractive index)
Summary: Bug in the production of Cherenkov photons (wrong number of photons due to wr...
Status: RESOLVED WONTFIX
Alias: None
Product: Geant4
Classification: Unclassified
Component: processes/optical (show other problems)
Version: 10.0
Hardware: PC Linux
: P5 normal
Assignee: gum
URL:
Depends on:
Blocks:
 
Reported: 2015-02-09 15:40 CET by erik.dietz-laursonn
Modified: 2015-04-30 00:04 CEST (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this problem.
Description erik.dietz-laursonn 2015-02-09 15:40:47 CET
When doing some validation plots, I encountered a problem in the production of Cherenkov photons and I believe it is caused by a bug:

1) When simulating a material with an energy-independent refraction index, I get a Cherenkov spectrum with the number of photons equally distributed over the full energy range (as expected).

2) When simulating a material with a refraction index that is rising linearly with rising energy (in my case from 1.125 at 1eV to 1.8 at 15eV), everything is fine and the result is a Cherenkov spectrum which shows a decreasing number of photons with decreasing energy/refraction index and which stops at the energy then the refraction index falls below the critical value (n < 1/beta).
http://hypernews.slac.stanford.edu/HyperNews/geant4/get/AUX/2015/01/28/08.33-83406-Cherenkov_linearRise.png

3) When simulating the refraction index the other way round (in my case decreasing from 1.8 at 1eV to 1.125 at 15eV), one would expect the same results as before (just the other way round). But the simulation shows a different behaviour: For small beta values (the refractive index falls below the critical value), no photons are produced. For larger beta values (the refractive index is always above the critical value), photons are produced, but they are distributed like in the case of an energy-independent refraction index.
http://hypernews.slac.stanford.edu/HyperNews/geant4/get/AUX/2015/01/28/08.33-63731-renkov_linearDecrease.png

4) To investigate this, I also simulated a more complex refractive index:
http://hypernews.slac.stanford.edu/HyperNews/geant4/get/AUX/2015/01/28/08.33-3986-Cherenkov_refIndex.png
The resulting energy distribution
(http://hypernews.slac.stanford.edu/HyperNews/geant4/get/AUX/2015/01/28/08.33-66871-Cherenkov_complex.png)
shows, that the simulation limits the refraction index (that is effectively used for the Cherenkov process) to values below the last value specified in the G4MaterialPropertyVector (in my case 1.7 at 15eV). As a result, unexpected plateaus appear in the energy distribution.

I looked into the G4Cerenkov.cc and I think there is mistake in the usage of G4MaterialPropertyVector::GetMinValue() and G4MaterialPropertyVector::GetMaxValue():
The names of the functions suggest that they return the minimal/maximal property (-> refractive index) value that is specified in the G4MaterialPropertyVector. In that case, the line "if (nMax < BetaInverse) -> no photons generated" would be correct. (No Cherenkov photons, if the maximal refractive index is below the critical value)
But actually, these functions just return the first/last entry and not the maximal/minimal one (I think the G4MaterialPropertyVector class was change in the last few years. Maybe before that, the functions did what there names suggest.). This results in the problem described in 3).
The problem described in 4) suggests the conclusion, that The same functions are used in other stages of the creation of Cherenkov photons and leading to the use of wrong refraction index values and thus a wrong number of Cherenkov photons, a wrong energy distribution, and wrong emission angles.
Comment 1 gum 2015-03-16 19:31:00 CET
> 2) When simulating a material with a refraction index that is rising
> > linearly with rising energy (in my case from 1.125 at 1eV to 1.8 at
> > 15eV), everything is fine and the result is a Cherenkov spectrum which
> > shows a decreasing number of photons with decreasing energy/refraction
> > index and which stops at the energy then the refraction index falls
> > below the critical value (n < 1/beta).

This is a normally dispersive medium. The index of refraction must not
change linearly with rising energy so long as it is monotonically.

> > 3) When simulating the refraction index the other way round (in my case
> > decreasing from 1.8 at 1eV to 1.125 at 15eV), one would expect the same
> > results as before (just the other way round). But the simulation shows a
> > different behaviour: For small beta values (the refractive index falls
> > below the critical value), no photons are produced. For larger beta
> > values (the refractive index is always above the critical value),
> > photons are produced, but they are distributed like in the case of an
> > energy-independent refraction index.

I don't know of any transparent medium with the property dn(e)/de < 0

> > I looked into the G4Cerenkov.cc and I think there is mistake in the
> > usage of G4MaterialPropertyVector::GetMinValue() and
> > G4MaterialPropertyVector::GetMaxValue():
> > The names of the functions suggest that they return the minimal/maximal
> > property (-> refractive index) value that is specified in the
> > G4MaterialPropertyVector. In that case, the line "if (nMax <
> > BetaInverse) -> no photons generated" would be correct. (No Cherenkov
> > photons, if the maximal refractive index is below the critical value)
> > But actually, these functions just return the first/last entry and not
> > the maximal/minimal one

You are correct. I agree that the naming of the methods suggests
differently. Yet the implementation simply takes the last entry in a
table with increasing energy entries as the maximum. For a normally
dispersive medium the index of refraction will be maximal at the highest
energy entry.

> > (I think the G4MaterialPropertyVector class was
> > change in the last few years. Maybe before that, the functions did what
> > there names suggest.).

No, the code has always been like this - even already in the old Geant3
source.

I don't know how realistic it is to generate Cerenkov light in material
with absorbtion bands etc.

Perhaps, I should clarify in the documentation that the generation of
Cerenkov photons in Geant4 is for 'normally dispersive media'.

To find the maximum in a list of numbers is certainly more time
consuming than to simply take the last one. I am not sure that doing so
for the vast majority of cases where it's not really required warrants
changing the code.

Do you have a use case?
Comment 2 gum 2015-04-30 00:04:54 CEST
The generation of Cerenkov photons in Geant4 is for 'normally dispersive media':

dn(e)/de > 0

e.g. the index of refraction can change with rising energy so long as it is monotonically. So,for a normally dispersive medium the index of refraction will be maximal at the highest energy entry.

The documentation will be change to clearly indicate that G4Cerenkov is written for normally dispersive media without absorption bands.