Teach output write_tallies about writeable tallies

The tally header will still be written, but no summary,
scores, or filters will be written. Instead, the output
will indicate the tally is internal.
This commit is contained in:
Andrew Johnson 2019-09-19 10:06:58 -05:00
parent e17687d457
commit 0fc57b207b
No known key found for this signature in database
GPG key ID: 253418E91B7F6FEB

View file

@ -638,6 +638,16 @@ write_tallies()
for (auto i_tally = 0; i_tally < model::tallies.size(); ++i_tally) {
const auto& tally {*model::tallies[i_tally]};
// Write header block.
std::string tally_header("TALLY " + std::to_string(tally.id_));
if (!tally.name_.empty()) tally_header += ": " + tally.name_;
tallies_out << header(tally_header) << "\n\n";
if (!tally.writeable_) {
tallies_out << " Internal\n\n";
continue;
}
// Calculate t-value for confidence intervals
double t_value = 1;
if (settings::confidence_intervals) {
@ -645,11 +655,6 @@ write_tallies()
t_value = t_percentile(1 - alpha*0.5, tally.n_realizations_ - 1);
}
// Write header block.
std::string tally_header("TALLY " + std::to_string(tally.id_));
if (!tally.name_.empty()) tally_header += ": " + tally.name_;
tallies_out << header(tally_header) << "\n\n";
// Write derivative information.
if (tally.deriv_ != C_NONE) {
const auto& deriv {model::tally_derivs[tally.deriv_]};