mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-28 22:26:08 -04:00
Simplify multiplying of tally uncertainties by t-value.
This commit is contained in:
parent
0b67b5ac5e
commit
e88ef6e3b5
1 changed files with 8 additions and 11 deletions
|
|
@ -1603,18 +1603,15 @@ contains
|
|||
TALLY_LOOP: do i = 1, n_tallies
|
||||
t => tallies(i)
|
||||
|
||||
! Multiply uncertainty by t-value
|
||||
if (confidence_intervals) then
|
||||
do k = 1, size(t % results, 2)
|
||||
do j = 1, size(t % results, 1)
|
||||
! Calculate t-value for confidence intervals
|
||||
if (confidence_intervals) then
|
||||
alpha = ONE - CONFIDENCE_LEVEL
|
||||
t_value = t_percentile(ONE - alpha/TWO, t % n_realizations - 1)
|
||||
end if
|
||||
t % results(j,k) % sum_sq = t_value * t % results(j,k) % sum_sq
|
||||
end do
|
||||
end do
|
||||
! Calculate t-value for confidence intervals
|
||||
if (confidence_intervals) then
|
||||
alpha = ONE - CONFIDENCE_LEVEL
|
||||
t_value = t_percentile(ONE - alpha/TWO, t % n_realizations - 1)
|
||||
end if
|
||||
|
||||
! Multiply uncertainty by t-value
|
||||
t % results % sum_sq = t_value * t % results % sum_sq
|
||||
end if
|
||||
|
||||
! Write header block
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue