diff --git a/src/ace.F90 b/src/ace.F90 index 32894116c3..85f91a8495 100644 --- a/src/ace.F90 +++ b/src/ace.F90 @@ -212,9 +212,9 @@ contains end subroutine read_xs !=============================================================================== -! READ_ACE_BINARY reads a single cross section table in binary format. This -! routine reads the header data for each table and then calls appropriate -! subroutines to parse the actual data. +! READ_ACE_TABLE reads a single cross section table in either ASCII or binary +! format. This routine reads the header data for each table and then calls +! appropriate subroutines to parse the actual data. !=============================================================================== subroutine read_ace_table(index_table, index_list) diff --git a/src/ace_header.F90 b/src/ace_header.F90 index 0c14a1ca5f..3caa5eb563 100644 --- a/src/ace_header.F90 +++ b/src/ace_header.F90 @@ -194,6 +194,9 @@ module ace_header ! Information for S(a,b) use logical :: use_sab ! in S(a,b) energy range? real(8) :: elastic_sab ! microscopic elastic scattering on S(a,b) table + + ! Information for URR probability table use + logical :: use_ptable ! in URR range with probability tables? end type NuclideMicroXS !=============================================================================== diff --git a/src/cross_section.F90 b/src/cross_section.F90 index 367d277cf5..ae58618c5a 100644 --- a/src/cross_section.F90 +++ b/src/cross_section.F90 @@ -129,6 +129,7 @@ contains ! Initialize sab treatment to false micro_xs(index_nuclide) % use_sab = .false. micro_xs(index_nuclide) % elastic_sab = ZERO + micro_xs(index_nuclide) % use_ptable = .false. ! Initialize nuclide cross-sections to zero micro_xs(index_nuclide) % fission = ZERO @@ -284,6 +285,8 @@ contains type(Nuclide), pointer :: nuc => null() type(Reaction), pointer :: rxn => null() + micro_xs(index_nuclide) % use_ptable = .true. + ! copy cross-sections already calculated elastic = micro_xs(index_nuclide) % elastic absorption = micro_xs(index_nuclide) % absorption diff --git a/src/physics.F90 b/src/physics.F90 index 869acc367a..fb35d53d0f 100644 --- a/src/physics.F90 +++ b/src/physics.F90 @@ -331,28 +331,42 @@ contains ! just like any other reaction. Here we loop through the fission ! reactions for the nuclide and see if any of them occur - do i = 1, nuc % n_fission - rxn => nuc % reactions(nuc % index_fission(i)) + if (micro_xs(index_nuclide) % use_ptable) then - ! if energy is below threshold for this reaction, skip it - if (IE < rxn%IE) cycle - - ! add to cumulative probability - if (nuc % has_partial_fission) then - prob = prob + ((ONE-f)*rxn%sigma(IE-rxn%IE+1) & - + f*(rxn%sigma(IE-rxn%IE+2))) - else - prob = prob + micro_xs(index_nuclide) % fission - end if - - ! Create fission bank sites if fission occus + prob = prob + micro_xs(index_nuclide) % fission if (prob > cutoff) then + rxn => nuc % reactions(nuc % index_fission(1)) call create_fission_sites(p, index_nuclide, rxn, .true.) p % alive = .false. MT = rxn % MT return end if - end do + else + + do i = 1, nuc % n_fission + rxn => nuc % reactions(nuc % index_fission(i)) + + ! if energy is below threshold for this reaction, skip it + if (IE < rxn%IE) cycle + + ! add to cumulative probability + if (nuc % has_partial_fission) then + prob = prob + ((ONE-f)*rxn%sigma(IE-rxn%IE+1) & + + f*(rxn%sigma(IE-rxn%IE+2))) + else + prob = prob + micro_xs(index_nuclide) % fission + end if + + ! Create fission bank sites if fission occus + if (prob > cutoff) then + call create_fission_sites(p, index_nuclide, rxn, .true.) + p % alive = .false. + MT = rxn % MT + return + end if + end do + + end if end if end if