mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-27 05:35:49 -04:00
Don't cache macroscopic cross sections for depletion reactions
This commit is contained in:
parent
26eedca662
commit
e137187510
3 changed files with 69 additions and 53 deletions
|
|
@ -49,12 +49,6 @@ contains
|
|||
material_xs % absorption = ZERO
|
||||
material_xs % fission = ZERO
|
||||
material_xs % nu_fission = ZERO
|
||||
material_xs % n2n = ZERO
|
||||
material_xs % n3n = ZERO
|
||||
material_xs % n4n = ZERO
|
||||
material_xs % ngamma = ZERO
|
||||
material_xs % np = ZERO
|
||||
material_xs % nalpha = ZERO
|
||||
|
||||
! Exit subroutine if material is void
|
||||
if (p % material == MATERIAL_VOID) return
|
||||
|
|
@ -139,32 +133,6 @@ contains
|
|||
! Add contributions to material macroscopic nu-fission cross section
|
||||
material_xs % nu_fission = material_xs % nu_fission + &
|
||||
atom_density * micro_xs(i_nuclide) % nu_fission
|
||||
|
||||
if (in_active) then
|
||||
! Add contributions to material macroscopic n2n cross section
|
||||
material_xs % n2n = material_xs % n2n + &
|
||||
atom_density * micro_xs(i_nuclide) % n2n
|
||||
|
||||
! Add contributions to material macroscopic n3n cross section
|
||||
material_xs % n3n = material_xs % n3n + &
|
||||
atom_density * micro_xs(i_nuclide) % n3n
|
||||
|
||||
! Add contributions to material macroscopic n4n cross section
|
||||
material_xs % n4n = material_xs % n4n + &
|
||||
atom_density * micro_xs(i_nuclide) % n4n
|
||||
|
||||
! Add contributions to material macroscopic ngamma cross section
|
||||
material_xs % ngamma = material_xs % ngamma + &
|
||||
atom_density * micro_xs(i_nuclide) % ngamma
|
||||
|
||||
! Add contributions to material macroscopic np cross section
|
||||
material_xs % np = material_xs % np + &
|
||||
atom_density * micro_xs(i_nuclide) % np
|
||||
|
||||
! Add contributions to material macroscopic nalpha cross section
|
||||
material_xs % nalpha = material_xs % nalpha + &
|
||||
atom_density * micro_xs(i_nuclide) % nalpha
|
||||
end if
|
||||
end do
|
||||
end associate
|
||||
|
||||
|
|
|
|||
|
|
@ -115,15 +115,15 @@ module nuclide_header
|
|||
real(8) :: total
|
||||
real(8) :: elastic ! If sab_frac is not 1 or 0, then this value is
|
||||
! averaged over bound and non-bound nuclei
|
||||
real(8) :: absorption
|
||||
real(8) :: fission
|
||||
real(8) :: nu_fission
|
||||
real(8) :: n2n
|
||||
real(8) :: n3n
|
||||
real(8) :: n4n
|
||||
real(8) :: ngamma
|
||||
real(8) :: np
|
||||
real(8) :: nalpha
|
||||
real(8) :: absorption ! absorption (disappearance)
|
||||
real(8) :: fission ! fission
|
||||
real(8) :: nu_fission ! neutron production from fission
|
||||
real(8) :: n2n ! (n,2n)
|
||||
real(8) :: n3n ! (n,3n)
|
||||
real(8) :: n4n ! (n,4n)
|
||||
real(8) :: ngamma ! (n,gamma)
|
||||
real(8) :: np ! (n,p)
|
||||
real(8) :: nalpha ! (n,alpha)
|
||||
real(8) :: thermal ! Bound thermal elastic & inelastic scattering
|
||||
real(8) :: thermal_elastic ! Bound thermal elastic scattering
|
||||
|
||||
|
|
@ -154,12 +154,6 @@ module nuclide_header
|
|||
real(8) :: absorption ! macroscopic absorption xs
|
||||
real(8) :: fission ! macroscopic fission xs
|
||||
real(8) :: nu_fission ! macroscopic production xs
|
||||
real(8) :: n2n ! macroscopic (n,2n) xs
|
||||
real(8) :: n3n ! macroscopic (n,3n) xs
|
||||
real(8) :: n4n ! macroscopic (n,4n) xs
|
||||
real(8) :: ngamma ! macroscopic (n,gamma) xs
|
||||
real(8) :: np ! macroscopic (n,p) xs
|
||||
real(8) :: nalpha ! macroscopic (n,alpha) xs
|
||||
end type MaterialMacroXS
|
||||
|
||||
!===============================================================================
|
||||
|
|
|
|||
|
|
@ -1141,7 +1141,16 @@ contains
|
|||
if (i_nuclide > 0) then
|
||||
score = micro_xs(i_nuclide) % n2n * atom_density * flux
|
||||
else
|
||||
score = material_xs % n2n * flux
|
||||
score = ZERO
|
||||
if (p % material /= MATERIAL_VOID) then
|
||||
associate (mat => materials(p % material))
|
||||
do l = 1, materials(p % material) % n_nuclides
|
||||
i_nuc = mat % nuclide(l)
|
||||
atom_density_ = mat % atom_density(l)
|
||||
score = score + micro_xs(i_nuc) % n2n * atom_density_ * flux
|
||||
end do
|
||||
end associate
|
||||
end if
|
||||
end if
|
||||
end if
|
||||
|
||||
|
|
@ -1155,7 +1164,16 @@ contains
|
|||
if (i_nuclide > 0) then
|
||||
score = micro_xs(i_nuclide) % n3n * atom_density * flux
|
||||
else
|
||||
score = material_xs % n3n * flux
|
||||
score = ZERO
|
||||
if (p % material /= MATERIAL_VOID) then
|
||||
associate (mat => materials(p % material))
|
||||
do l = 1, materials(p % material) % n_nuclides
|
||||
i_nuc = mat % nuclide(l)
|
||||
atom_density_ = mat % atom_density(l)
|
||||
score = score + micro_xs(i_nuc) % n3n * atom_density_ * flux
|
||||
end do
|
||||
end associate
|
||||
end if
|
||||
end if
|
||||
end if
|
||||
|
||||
|
|
@ -1169,7 +1187,16 @@ contains
|
|||
if (i_nuclide > 0) then
|
||||
score = micro_xs(i_nuclide) % n4n * atom_density * flux
|
||||
else
|
||||
score = material_xs % n4n * flux
|
||||
score = ZERO
|
||||
if (p % material /= MATERIAL_VOID) then
|
||||
associate (mat => materials(p % material))
|
||||
do l = 1, materials(p % material) % n_nuclides
|
||||
i_nuc = mat % nuclide(l)
|
||||
atom_density_ = mat % atom_density(l)
|
||||
score = score + micro_xs(i_nuc) % n4n * atom_density_ * flux
|
||||
end do
|
||||
end associate
|
||||
end if
|
||||
end if
|
||||
end if
|
||||
|
||||
|
|
@ -1183,7 +1210,16 @@ contains
|
|||
if (i_nuclide > 0) then
|
||||
score = micro_xs(i_nuclide) % np * atom_density * flux
|
||||
else
|
||||
score = material_xs % np * flux
|
||||
score = ZERO
|
||||
if (p % material /= MATERIAL_VOID) then
|
||||
associate (mat => materials(p % material))
|
||||
do l = 1, materials(p % material) % n_nuclides
|
||||
i_nuc = mat % nuclide(l)
|
||||
atom_density_ = mat % atom_density(l)
|
||||
score = score + micro_xs(i_nuc) % np * atom_density_ * flux
|
||||
end do
|
||||
end associate
|
||||
end if
|
||||
end if
|
||||
end if
|
||||
|
||||
|
|
@ -1197,7 +1233,16 @@ contains
|
|||
if (i_nuclide > 0) then
|
||||
score = micro_xs(i_nuclide) % nalpha * atom_density * flux
|
||||
else
|
||||
score = material_xs % nalpha * flux
|
||||
score = ZERO
|
||||
if (p % material /= MATERIAL_VOID) then
|
||||
associate (mat => materials(p % material))
|
||||
do l = 1, materials(p % material) % n_nuclides
|
||||
i_nuc = mat % nuclide(l)
|
||||
atom_density_ = mat % atom_density(l)
|
||||
score = score + micro_xs(i_nuc) % nalpha * atom_density_ * flux
|
||||
end do
|
||||
end associate
|
||||
end if
|
||||
end if
|
||||
end if
|
||||
|
||||
|
|
@ -1211,7 +1256,16 @@ contains
|
|||
if (i_nuclide > 0) then
|
||||
score = micro_xs(i_nuclide) % ngamma * atom_density * flux
|
||||
else
|
||||
score = material_xs % ngamma * flux
|
||||
score = ZERO
|
||||
if (p % material /= MATERIAL_VOID) then
|
||||
associate (mat => materials(p % material))
|
||||
do l = 1, materials(p % material) % n_nuclides
|
||||
i_nuc = mat % nuclide(l)
|
||||
atom_density_ = mat % atom_density(l)
|
||||
score = score + micro_xs(i_nuc) % ngamma * atom_density_ * flux
|
||||
end do
|
||||
end associate
|
||||
end if
|
||||
end if
|
||||
end if
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue