Merge remote-tracking branch 'upstream/develop' into mg

This commit is contained in:
Adam Nelson 2016-02-19 20:44:46 -05:00
commit 0ea1ee2b88
10 changed files with 19 additions and 15 deletions

View file

@ -84,10 +84,10 @@ to fully define the surface.
| Plane perpendicular | x-plane | :math:`x - x_0 = 0` | :math:`x_0` |
| to :math:`x`-axis | | | |
+----------------------+------------+------------------------------+-------------------------+
| Plane perpendicular | y-plane | :math:`x - x_0 = 0` | :math:`y_0` |
| Plane perpendicular | y-plane | :math:`y - y_0 = 0` | :math:`y_0` |
| to :math:`y`-axis | | | |
+----------------------+------------+------------------------------+-------------------------+
| Plane perpendicular | z-plane | :math:`x - x_0 = 0` | :math:`z_0` |
| Plane perpendicular | z-plane | :math:`z - z_0 = 0` | :math:`z_0` |
| to :math:`z`-axis | | | |
+----------------------+------------+------------------------------+-------------------------+
| Arbitrary plane | plane | :math:`Ax + By + Cz = D` | :math:`A\;B\;C\;D` |

View file

@ -341,7 +341,7 @@
"settings_file.batches = batches\n",
"settings_file.inactive = inactive\n",
"settings_file.particles = particles\n",
"settings_file.output = {'tallies': True, 'summary': True}\n",
"settings_file.output = {'tallies': True}\n",
"bounds = [-0.63, -0.63, -0.63, 0.63, 0.63, 0.63]\n",
"settings_file.source = Source(space=Box(\n",
" bounds[:3], bounds[3:], only_fissionable=True))\n",

View file

@ -286,7 +286,7 @@
"settings_file.batches = batches\n",
"settings_file.inactive = inactive\n",
"settings_file.particles = particles\n",
"settings_file.output = {'tallies': True, 'summary': True}\n",
"settings_file.output = {'tallies': True}\n",
"bounds = [-0.63, -0.63, -0.63, 0.63, 0.63, 0.63]\n",
"settings_file.source = Source(space=Box(\n",
" bounds[:3], bounds[3:], only_fissionable=True))\n",

View file

@ -392,7 +392,7 @@
"settings_file.batches = batches\n",
"settings_file.inactive = inactive\n",
"settings_file.particles = particles\n",
"settings_file.output = {'tallies': False, 'summary': True}\n",
"settings_file.output = {'tallies': False}\n",
"source_bounds = [-10.71, -10.71, -10, 10.71, 10.71, 10.]\n",
"settings_file.source = Source(Box(\n",
" source_bounds[:3], source_bounds[3:], only_fissionable=True))\n",

View file

@ -302,7 +302,7 @@
"settings_file.batches = min_batches\n",
"settings_file.inactive = inactive\n",
"settings_file.particles = particles\n",
"settings_file.output = {'tallies': False, 'summary': True}\n",
"settings_file.output = {'tallies': False}\n",
"settings_file.trigger_active = True\n",
"settings_file.trigger_max_batches = max_batches\n",
"source_bounds = [-10.71, -10.71, -10, 10.71, 10.71, 10.]\n",

View file

@ -288,7 +288,7 @@
"settings_file.batches = batches\n",
"settings_file.inactive = inactive\n",
"settings_file.particles = particles\n",
"settings_file.output = {'tallies': True, 'summary': True}\n",
"settings_file.output = {'tallies': True}\n",
"source_bounds = [-0.63, -0.63, -0.63, 0.63, 0.63, 0.63]\n",
"settings_file.source = Source(space=Box(\n",
" source_bounds[:3], source_bounds[3:]))\n",

View file

@ -340,10 +340,10 @@ out the file and "false" will not.
*Default*: false
:summary:
Writes out an ASCII summary file describing all of the user input files that
Writes out an HDF5 summary file describing all of the user input files that
were read in.
*Default*: false
*Default*: true
:tallies:
Write out an ASCII file of tally results.

View file

@ -427,7 +427,7 @@ module global
type(SetInt) :: sourcepoint_batch
! Various output options
logical :: output_summary = .false.
logical :: output_summary = .true.
logical :: output_xs = .false.
logical :: output_tallies = .true.

View file

@ -948,8 +948,8 @@ contains
if (check_for_node(node_output, "summary")) then
call get_node_value(node_output, "summary", temp_str)
temp_str = to_lower(temp_str)
if (trim(temp_str) == 'true' .or. &
trim(temp_str) == '1') output_summary = .true.
if (trim(temp_str) == 'false' .or. &
trim(temp_str) == '0') output_summary = .false.
end if
! Check for cross sections option

View file

@ -1,5 +1,6 @@
module secondary_header
use constants, only: ZERO
use endf_header, only: Tab1
use interpolation, only: interpolate_tab1
use random_lcg, only: prn
@ -54,16 +55,19 @@ contains
real(8), intent(out) :: mu ! sampled scattering cosine
integer :: n ! number of angle-energy distributions
real(8) :: p_valid ! probability that given distribution is valid
real(8) :: prob ! cumulative probability
real(8) :: c ! sampled cumulative probability
n = size(this%applicability)
if (n > 1) then
prob = ZERO
c = prn()
do i = 1, n
! Determine probability that i-th energy distribution is sampled
p_valid = interpolate_tab1(this%applicability(i), E_in)
prob = prob + interpolate_tab1(this%applicability(i), E_in)
! If i-th distribution is sampled, sample energy from the distribution
if (prn() <= p_valid) then
if (c <= prob) then
call this%distribution(i)%obj%sample(E_in, E_out, mu)
exit
end if