Skip to content

Commit

Permalink
Merge pull request #14 from SiLab-Bonn/development
Browse files Browse the repository at this point in the history
FIX: fix bug in fluence calculation and update gamma table entry
  • Loading branch information
leloup314 authored Aug 26, 2022
2 parents 6f5fd3f + 79aed13 commit 2d23376
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
6 changes: 3 additions & 3 deletions irrad_spectroscopy/physics.py
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ def isotope_dose_rate(isotope, activity, distance, material='air', time=None):
return total_dose_rate


def fluence_from_activity(isotope, acticity, cross_section, molar_mass, sample_mass, abundance=1.0, cooldown_time=0.0):
def fluence_from_activity(isotope, activity, cross_section, molar_mass, sample_mass, abundance=1.0, cooldown_time=0.0):
"""
Calculation of the theoretical particle fluence [# particles / cm^2] which produced a given *activity* of
an *isotope* with a production *cross_section* in a given, thin (e.g. *cross_section* const.) *sample_mass*.
Expand Down Expand Up @@ -184,7 +184,7 @@ def fluence_from_activity(isotope, acticity, cross_section, molar_mass, sample_m
sample_mass_in_grams *= abundance # Correct for abundance in material
dc = decay_constant(half_life)

fluence = acticity / cross_section_in_cm_square * molar_mass / (sample_mass_in_grams * 6.02214076e23) * 1 / dc
fluence *= np.exp(-dc * cooldown_time * 60**2) # Correct for time passed since activity was produced
fluence = activity / cross_section_in_cm_square * molar_mass / (sample_mass_in_grams * 6.02214076e23) / dc
fluence /= np.exp(-dc * cooldown_time * 60**2) # Correct for time passed since activity was produced

return fluence
8 changes: 4 additions & 4 deletions irrad_spectroscopy/tables/gamma_table.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -153,10 +153,10 @@ isotopes:
- 944.132
- 2240.395
probability:
- 0.5022099999999999
- 0.48965000000000003
- 0.03897
- 0.0121
- 0.9998
- 0.9758
- 0.0776
- 0.02414
Cr:
name: Chromium
Z: 24
Expand Down

0 comments on commit 2d23376

Please sign in to comment.