diff --git a/src/ace_header.F90 b/src/ace_header.F90 index 0b838fb8c9..3caa5eb563 100644 --- a/src/ace_header.F90 +++ b/src/ace_header.F90 @@ -197,7 +197,6 @@ module ace_header ! Information for URR probability table use logical :: use_ptable ! in URR range with probability tables? - logical :: recalculate ! indicate whether we need to recalculate ptables end type NuclideMicroXS !=============================================================================== diff --git a/src/cross_section.F90 b/src/cross_section.F90 index fbec5221ee..18706fe1e8 100644 --- a/src/cross_section.F90 +++ b/src/cross_section.F90 @@ -168,11 +168,9 @@ contains ! probability tables, we need to determine cross sections from the table if (urr_ptables_on .and. nuc % urr_present) then - if (micro_xs(index_nuclide) % recalculate) then - if (p % E > nuc % urr_data % energy(1) .and. & - p % E < nuc % urr_data % energy(nuc % urr_data % n_energy)) then - call calculate_urr_xs(p, index_nuclide) - end if + if (p % E > nuc % urr_data % energy(1) .and. & + p % E < nuc % urr_data % energy(nuc % urr_data % n_energy)) then + call calculate_urr_xs(p, index_nuclide) end if end if @@ -365,10 +363,6 @@ contains micro_xs(index_nuclide) % fission end if - ! As long as the energy of the neutron doesn't change, we don't need to - ! recalculate probability table data - micro_xs(index_nuclide) % recalculate = .false. - end subroutine calculate_urr_xs !=============================================================================== diff --git a/src/physics.F90 b/src/physics.F90 index 27312d72bb..767dcc2aa5 100644 --- a/src/physics.F90 +++ b/src/physics.F90 @@ -66,9 +66,6 @@ contains ! Initialize number of events to zero n_event = 0 - ! Set recalculate ptables to true by default - micro_xs(:) % recalculate = .true. - ! find energy index, interpolation factor do while (p % alive) @@ -200,10 +197,6 @@ contains ! Reset number of particles banked during collision p % n_bank = 0 - ! Since a collision has occurred, we need to recalculate probability tables - ! for any nuclide - micro_xs(:) % recalculate = .true. - end subroutine collision !=============================================================================== diff --git a/src/utils/core_map.py b/src/utils/core_map.py new file mode 100755 index 0000000000..4b5e7f7b8a --- /dev/null +++ b/src/utils/core_map.py @@ -0,0 +1,36 @@ +#!/usr/bin/env python + +import sys + +import numpy as np +import matplotlib.pyplot as pyplot + +# Get filename and file object +filename = sys.argv[1] +axial_level = int(sys.argv[2]) +fh = open(filename,'r') + +# Read size of mesh +words = fh.readline().split() +nx, ny, nz = [int(item) for item in words] + +# Read values +value_dict = {} +for line in fh: + words = line.split() + i, j, k = [int(item) for item in words[:3]] + value = float(words[3]) + value_dict[i,j,k] = value + +# Set up matrix +matrix = np.array([[value_dict[i+1,j+1,axial_level] for i in range(nx)] + for j in range(ny)]) + +# Make figure +pyplot.pcolor(matrix) +pyplot.colorbar() +pyplot.xlim([0,nx]) +pyplot.ylim([0,ny]) +pyplot.xticks([]) +pyplot.yticks([]) +pyplot.show()