mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-26 21:25:36 -04:00
Avoid divide-by-zero errors with score==ZERO check
This commit is contained in:
parent
174ff92b33
commit
92b58c2b56
1 changed files with 3 additions and 1 deletions
|
|
@ -3039,6 +3039,8 @@ contains
|
|||
logical :: scoring_diff_nuclide
|
||||
real(8) :: dsigT, dsigA, dsigF, cum_dsig
|
||||
|
||||
if (score == ZERO) return
|
||||
|
||||
associate(deriv => tally_derivs(t % deriv))
|
||||
select case (deriv % variable)
|
||||
|
||||
|
|
@ -3347,7 +3349,7 @@ contains
|
|||
end if
|
||||
end associate
|
||||
score = score * (deriv % flux_deriv &
|
||||
+ dsigF * mat % atom_density(l) / material_xs % fission &
|
||||
+ dsigF * mat % atom_density(l) / material_xs % nu_fission&
|
||||
* micro_xs(p % event_nuclide) % nu_fission &
|
||||
/ micro_xs(p % event_nuclide) % fission)
|
||||
end associate
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue