From c6d85b082d166ee8fc04ddda211dfd8a7566a862 Mon Sep 17 00:00:00 2001 From: Paul Romano Date: Tue, 18 Oct 2011 11:38:32 -0400 Subject: [PATCH] Prevent use of outgoing energy filters for certain macro tallies. --- src/input_xml.f90 | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/src/input_xml.f90 b/src/input_xml.f90 index 5fa4d0b935..043c4a5231 100644 --- a/src/input_xml.f90 +++ b/src/input_xml.f90 @@ -745,8 +745,17 @@ contains select case (trim(word)) case ('flux') t % macro_bins(j) % scalar = MACRO_FLUX + if (t % n_bins(T_ENERGYOUT) > 0) then + msg = "Cannot tally flux with an outgoing energy filter." + call fatal_error(msg) + end if case ('total') t % macro_bins(j) % scalar = MACRO_TOTAL + if (t % n_bins(T_ENERGYOUT) > 0) then + msg = "Cannot tally total reaction rate with an outgoing " & + // "energy filter." + call fatal_error(msg) + end if case ('scatter') t % macro_bins(j) % scalar = MACRO_SCATTER case ('nu-scatter') @@ -767,10 +776,26 @@ contains t % macro_bins(j) % scalar = MACRO_N_4N case ('absorption') t % macro_bins(j) % scalar = MACRO_ABSORPTION + if (t % n_bins(T_ENERGYOUT) > 0) then + msg = "Cannot tally absorption rate with an outgoing " & + // "energy filter." + call fatal_error(msg) + end if case ('fission') t % macro_bins(j) % scalar = MACRO_FISSION + if (t % n_bins(T_ENERGYOUT) > 0) then + msg = "Cannot tally fission rate with an outgoing " & + // "energy filter." + call fatal_error(msg) + end if case ('nu-fission') t % macro_bins(j) % scalar = MACRO_NU_FISSION + ! TODO: Add fission energy transfer and remove this + if (t % n_bins(T_ENERGYOUT) > 0) then + msg = "Cannot tally nu-fission rate with an outgoing " & + // "energy filter." + call fatal_error(msg) + end if case default msg = "Unknown macro reaction: " // trim(words(j)) call fatal_error(msg)