From 5000a899f48f24ec4051330267fc1d9b4c56cf05 Mon Sep 17 00:00:00 2001 From: Bryan Herman Date: Sun, 11 Dec 2011 14:05:08 -0500 Subject: [PATCH] fixed mesh object to reflect new changes in master, k-eff looks consistent --- src/cmfd_utils.F90 | 12 ++++++++---- src/main.F90 | 6 +++--- 2 files changed, 11 insertions(+), 7 deletions(-) diff --git a/src/cmfd_utils.F90 b/src/cmfd_utils.F90 index af12d91f64..fdde35d455 100644 --- a/src/cmfd_utils.F90 +++ b/src/cmfd_utils.F90 @@ -155,6 +155,7 @@ contains allocate(m % dimension(n)) allocate(m % origin(n)) allocate(m % width(n)) + allocate(m % upper_right(n)) ! read dimensions in each direction m % dimension = mesh_ % dimension @@ -175,6 +176,9 @@ contains end if m % width = mesh_ % width + ! set upper right coordinate + m % upper_right = m % origin + m % dimension * m % width + ! add mesh to dictionary call dict_add_key(mesh_dict, m % id, 1) @@ -203,8 +207,8 @@ contains t % n_bins(T_MESH) = t % n_bins(T_MESH) + product(m % dimension) ! read and set incoming energy mesh filter - if (len_trim(energy_) > 0) then - call split_string(energy_,words,n_words) + if (len_trim(mesh_ % energy) > 0) then + call split_string(mesh_ % energy,words,n_words) ng = n_words allocate(t % energy_in(n_words)) do j = 1,n_words @@ -227,8 +231,8 @@ contains else if (i == 2) then ! read and set outgoing energy mesh filter - if (len_trim(energy_) > 0) then - call split_string(energy_, words, n_words) + if (len_trim(mesh_ % energy) > 0) then + call split_string(mesh_ % energy, words, n_words) allocate(t % energy_out(n_words)) do j = 1, n_words t % energy_out(j) = str_to_real(words(j)) diff --git a/src/main.F90 b/src/main.F90 index 17d595a020..a08e24eff0 100644 --- a/src/main.F90 +++ b/src/main.F90 @@ -43,10 +43,10 @@ program main if (master) call print_runtime() end if - ! call cmfd calculation - call execute_cmfd() + ! call cmfd calculation + call execute_cmfd() - ! deallocate arrays + ! deallocate arrays call free_memory() contains