Generating density effect correction files with ESTAR - nrc-cnrc/EGSnrc GitHub Wiki
Custom materials can be added by creating your own density correction files. This is done using the ESTAR program provided by NIST, though currently some manual steps are required to adjust the format to be compatible with EGSnrc.
-
Go to the ESTAR web application.
-
Click on
unique material
to specify a compound or mixture. -
Enter a
Material Name
,density
and the formulae and relative weights. ClickSubmit
. -
In order to use the same energy grid for the data as in EGSnrc, create a new text file. Copy the data below into a text file. On the ESTAR page, click on the
Choose File
button underAdditional Energies
and select the file.
1.00E-03
1.25E-03
1.50E-03
1.75E-03
2.00E-03
2.50E-03
3.00E-03
3.50E-03
4.00E-03
4.50E-03
5.00E-03
5.50E-03
6.00E-03
7.00E-03
8.00E-03
9.00E-03
1.00E-02
1.25E-02
1.50E-02
1.75E-02
2.00E-02
2.50E-02
3.00E-02
3.50E-02
4.00E-02
4.50E-02
5.00E-02
5.50E-02
6.00E-02
7.00E-02
8.00E-02
9.00E-02
1.00E-01
1.25E-01
1.50E-01
1.75E-01
2.00E-01
2.50E-01
3.00E-01
3.50E-01
4.00E-01
4.50E-01
5.00E-01
5.50E-01
6.00E-01
7.00E-01
8.00E-01
9.00E-01
1.00E+00
1.25E+00
1.50E+00
1.75E+00
2.00E+00
2.50E+00
3.00E+00
3.50E+00
4.00E+00
4.50E+00
5.00E+00
5.50E+00
6.00E+00
7.00E+00
8.00E+00
9.00E+00
1.00E+01
1.25E+01
1.50E+01
1.75E+01
2.00E+01
2.50E+01
3.00E+01
3.50E+01
4.00E+01
4.50E+01
5.00E+01
5.50E+01
6.00E+01
7.00E+01
8.00E+01
9.00E+01
1.00E+02
1.25E+02
1.50E+02
1.75E+02
2.00E+02
2.50E+02
3.00E+02
3.50E+02
4.00E+02
4.50E+02
5.00E+02
5.50E+02
6.00E+02
7.00E+02
8.00E+02
9.00E+02
1.00E+03
1.25E+03
1.50E+03
1.75E+03
2.00E+03
2.50E+03
3.00E+03
3.50E+03
4.00E+03
4.50E+03
5.00E+03
5.50E+03
6.00E+03
7.00E+03
8.00E+03
9.00E+03
1.00E+04
-
Uncheck the
Include default energies
checkbox. Now, clickSubmit
. -
Copy the table data in a spreadsheet and export the two columns
Kinetic Energy
andDensity Effect Parameter
to a text file. (You can also use theDownload data
button; however if you entered a custom mean ionization energy, the downloaded data might be wrong!) -
This data is the foundation of your new density correction file for EGSnrc. However, it is necessary to insert the 3-line file header expected by EGSnrc:
line 1: description
line 2: numberOfEnergies meanIonizationEnergy density numberOfElements
line 3: for each element: atomicNumber massFraction
remaining lines: data from ESTAR
The description
on line 1 is a comment. On the second line the numberOfEnergies
is the number of energies that you saved into the file in step 4 (which should be 113
). The meanIonizationEnergy
and density
are the values in the ESTAR output. The numberOfElements
is the number of atomic elements in the material. Finally, line 3 is a list of atomicNumber
and massFraction
pairs for each atomic element. For example, below is a sample density correction file for water. Save this file with a .density
extension, in your $EGS_HOME/pegs4/density/
directory.
water_icru90 calculated with ESTAR, I = 78 eV, rho = 0.998 g/cm3 (20 degree C)
113 78.00000 0.998000 2
1 0.111894 8 0.888106
1.000E-03 0.000E+00
1.250E-03 0.000E+00
1.500E-03 0.000E+00
1.750E-03 0.000E+00
2.000E-03 0.000E+00
2.500E-03 0.000E+00
3.000E-03 0.000E+00
3.500E-03 0.000E+00
4.000E-03 0.000E+00
4.500E-03 0.000E+00
5.000E-03 0.000E+00
5.500E-03 0.000E+00
6.000E-03 0.000E+00
7.000E-03 0.000E+00
8.000E-03 0.000E+00
9.000E-03 0.000E+00
1.000E-02 0.000E+00
1.250E-02 0.000E+00
1.500E-02 0.000E+00
1.750E-02 0.000E+00
2.000E-02 0.000E+00
2.500E-02 0.000E+00
3.000E-02 0.000E+00
3.500E-02 0.000E+00
4.000E-02 0.000E+00
4.500E-02 0.000E+00
5.000E-02 0.000E+00
5.500E-02 0.000E+00
6.000E-02 0.000E+00
7.000E-02 0.000E+00
8.000E-02 0.000E+00
9.000E-02 0.000E+00
1.000E-01 0.000E+00
1.250E-01 0.000E+00
1.500E-01 0.000E+00
1.750E-01 0.000E+00
2.000E-01 0.000E+00
2.500E-01 0.000E+00
3.000E-01 0.000E+00
3.500E-01 0.000E+00
4.000E-01 0.000E+00
4.500E-01 0.000E+00
5.000E-01 0.000E+00
5.500E-01 6.126E-04
6.000E-01 1.501E-02
7.000E-01 5.338E-02
8.000E-01 1.005E-01
9.000E-01 1.529E-01
1.000E+00 2.086E-01
1.250E+00 3.535E-01
1.500E+00 4.982E-01
1.750E+00 6.377E-01
2.000E+00 7.704E-01
2.500E+00 1.014E+00
3.000E+00 1.231E+00
3.500E+00 1.426E+00
4.000E+00 1.601E+00
4.500E+00 1.760E+00
5.000E+00 1.906E+00
5.500E+00 2.041E+00
6.000E+00 2.165E+00
7.000E+00 2.390E+00
8.000E+00 2.589E+00
9.000E+00 2.767E+00
1.000E+01 2.928E+00
1.250E+01 3.276E+00
1.500E+01 3.567E+00
1.750E+01 3.817E+00
2.000E+01 4.039E+00
2.500E+01 4.417E+00
3.000E+01 4.734E+00
3.500E+01 5.009E+00
4.000E+01 5.252E+00
4.500E+01 5.469E+00
5.000E+01 5.665E+00
5.500E+01 5.845E+00
6.000E+01 6.010E+00
7.000E+01 6.305E+00
8.000E+01 6.563E+00
9.000E+01 6.792E+00
1.000E+02 6.998E+00
1.250E+02 7.436E+00
1.500E+02 7.796E+00
1.750E+02 8.102E+00
2.000E+02 8.367E+00
2.500E+02 8.810E+00
3.000E+02 9.173E+00
3.500E+02 9.481E+00
4.000E+02 9.747E+00
4.500E+02 9.982E+00
5.000E+02 1.019E+01
5.500E+02 1.038E+01
6.000E+02 1.056E+01
7.000E+02 1.086E+01
8.000E+02 1.113E+01
9.000E+02 1.137E+01
1.000E+03 1.158E+01
1.250E+03 1.202E+01
1.500E+03 1.239E+01
1.750E+03 1.270E+01
2.000E+03 1.296E+01
2.500E+03 1.341E+01
3.000E+03 1.377E+01
3.500E+03 1.408E+01
4.000E+03 1.435E+01
4.500E+03 1.458E+01
5.000E+03 1.480E+01
5.500E+03 1.499E+01
6.000E+03 1.516E+01
7.000E+03 1.547E+01
8.000E+03 1.574E+01
9.000E+03 1.597E+01
1.000E+04 1.618E+01