File tree Expand file tree Collapse file tree 5 files changed +49
-48
lines changed
photon_production_fission Expand file tree Collapse file tree 5 files changed +49
-48
lines changed Original file line number Diff line number Diff line change @@ -777,14 +777,15 @@ void Material::init_bremsstrahlung()
777777 // Loop over photon energies
778778 double c = 0.0 ;
779779 for (int i = 0 ; i < j; ++i) {
780- // Integrate the CDF from the PDF using the trapezoidal rule in log-log
781- // space
780+ // Integrate the CDF from the PDF using the fact that the PDF is linear
781+ // in log-log space
782782 double w_l = std::log (data::ttb_e_grid (i));
783783 double w_r = std::log (data::ttb_e_grid (i + 1 ));
784784 double x_l = std::log (ttb->pdf (j, i));
785785 double x_r = std::log (ttb->pdf (j, i + 1 ));
786-
787- c += 0.5 * (w_r - w_l) * (std::exp (w_l + x_l) + std::exp (w_r + x_r));
786+ double beta = (x_r - x_l) / (w_r - w_l);
787+ double a = beta + 1.0 ;
788+ c += std::exp (w_l + x_l) / a * std::expm1 (a * (w_r - w_l));
788789 ttb->cdf (j, i + 1 ) = c;
789790 }
790791
Original file line number Diff line number Diff line change @@ -16,12 +16,12 @@ tally 2:
16161.573004E+00
17174.296434E-04
18181.845934E-07
19- 2.350021E -01
20- 5.522600E -02
19+ 2.350047E -01
20+ 5.522722E -02
21210.000000E+00
22220.000000E+00
23- 2.350021E -01
24- 5.522600E -02
23+ 2.350047E -01
24+ 5.522722E -02
25250.000000E+00
26260.000000E+00
27270.000000E+00
@@ -73,8 +73,8 @@ tally 3:
73730.000000E+00
74740.000000E+00
75750.000000E+00
76- 1.774451E +05
77- 3.148675E +10
76+ 1.774484E +05
77+ 3.148794E +10
78780.000000E+00
79790.000000E+00
80800.000000E+00
@@ -85,8 +85,8 @@ tally 3:
85850.000000E+00
86860.000000E+00
87870.000000E+00
88- 7.691658E +03
89- 5.916160E +07
88+ 7.692488E +03
89+ 5.917437E +07
90900.000000E+00
91910.000000E+00
9292tally 4:
@@ -122,8 +122,8 @@ tally 4:
1221220.000000E+00
1231230.000000E+00
1241240.000000E+00
125- 1.774451E +05
126- 3.148675E +10
125+ 1.774484E +05
126+ 3.148794E +10
1271270.000000E+00
1281280.000000E+00
1291290.000000E+00
@@ -134,7 +134,7 @@ tally 4:
1341340.000000E+00
1351350.000000E+00
1361360.000000E+00
137- 7.691658E +03
138- 5.916160E +07
137+ 7.692488E +03
138+ 5.917437E +07
1391390.000000E+00
1401400.000000E+00
Original file line number Diff line number Diff line change 11k-combined:
2- 2.270911E +00 4.568134E -02
2+ 2.278476E +00 6.220292E -02
33tally 1:
4- 2.663476E +00
5- 2.366726E +00
4+ 2.664071E +00
5+ 2.369250E +00
660.000000E+00
770.000000E+00
8- 2.663476E +00
9- 2.366726E +00
8+ 2.664071E +00
9+ 2.369250E +00
10100.000000E+00
11110.000000E+00
12120.000000E+00
@@ -18,52 +18,52 @@ tally 1:
18180.000000E+00
19190.000000E+00
2020tally 2:
21- 2.636709E +00
22- 2.318646E +00
23- 4.230052E +08
24- 5.967879E +16
21+ 2.640755E +00
22+ 2.326201E +00
23+ 4.245217E +08
24+ 6.012128E +16
25250.000000E+00
26260.000000E+00
27- 2.636709E +00
28- 2.318646E +00
29- 4.230052E +08
30- 5.967879E +16
27+ 2.640755E +00
28+ 2.326201E +00
29+ 4.245217E +08
30+ 6.012128E +16
31310.000000E+00
32320.000000E+00
33330.000000E+00
34340.000000E+00
35- 2.455009E +06
36- 2.015314E +12
35+ 2.479234E +06
36+ 2.052367E +12
37370.000000E+00
38380.000000E+00
39390.000000E+00
40400.000000E+00
41- 2.455009E +06
42- 2.015314E +12
41+ 2.479234E +06
42+ 2.052367E +12
43430.000000E+00
44440.000000E+00
4545tally 3:
46- 2.660004E +00
47- 2.358564E +00
48- 4.230052E +08
49- 5.967879E +16
46+ 2.657846E +00
47+ 2.354717E +00
48+ 4.245217E +08
49+ 6.012128E +16
50500.000000E+00
51510.000000E+00
52- 2.660004E +00
53- 2.358564E +00
54- 4.230052E +08
55- 5.967879E +16
52+ 2.657846E +00
53+ 2.354717E +00
54+ 4.245217E +08
55+ 6.012128E +16
56560.000000E+00
57570.000000E+00
58580.000000E+00
59590.000000E+00
60- 2.455009E +06
61- 2.015314E +12
60+ 2.479234E +06
61+ 2.052367E +12
62620.000000E+00
63630.000000E+00
64640.000000E+00
65650.000000E+00
66- 2.455009E +06
67- 2.015314E +12
66+ 2.479234E +06
67+ 2.052367E +12
68680.000000E+00
69690.000000E+00
Original file line number Diff line number Diff line change 11tally 1:
2- 2.263938E +02
3- 5.125417E +04
2+ 2.263761E +02
3+ 5.124615E +04
440.000000E+00
550.000000E+00
Original file line number Diff line number Diff line change 1- 952c20fefac374d3b9fd28627fda7d5ae262f8cd7c01a33f0381526204a2287c18e56259a599dc6fdc1b59a2d2866fdfeedea371154c8fa7a69dc5c445b08c2d
1+ a5880ad9262e8aba90801783891ee74618144101401f06fb46e954e851a3c517ab28d5f0d6e1b2b364844f08d363cba35ab23b63fc81012ea8a6a328755d56c4
You can’t perform that action at this time.
0 commit comments