From 06cba05a51b15588a00ac3cd725d4de43dd68996 Mon Sep 17 00:00:00 2001 From: Vegard Kippe Date: Wed, 13 Sep 2023 09:20:07 +0200 Subject: [PATCH] Store flows if any of the vectors BFLOWI|J|K are requested --- opm/models/discretization/common/tpfalinearizer.hh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/opm/models/discretization/common/tpfalinearizer.hh b/opm/models/discretization/common/tpfalinearizer.hh index e6ad436aed..b556e7792f 100644 --- a/opm/models/discretization/common/tpfalinearizer.hh +++ b/opm/models/discretization/common/tpfalinearizer.hh @@ -527,6 +527,7 @@ private: { OPM_TIMEBLOCK(createFlows); // If FLOWS/FLORES is set in any RPTRST in the schedule, then we initializate the sparse tables + // For now, do the same also if any block flows are requested (TODO: only save requested cells...) const bool anyFlows = simulator_().problem().eclWriter()->eclOutputModule().anyFlows(); const bool anyFlores = simulator_().problem().eclWriter()->eclOutputModule().anyFlores(); if ((!anyFlows || !flowsInfo_.empty()) && (!anyFlores || !floresInfo_.empty())) { @@ -626,7 +627,8 @@ private: // the full system to zero, not just our part. // Instead, that must be called before starting the linearization. - const bool& enableFlows = simulator_().problem().eclWriter()->eclOutputModule().hasFlows(); + const bool& enableFlows = simulator_().problem().eclWriter()->eclOutputModule().hasFlows() || + simulator_().problem().eclWriter()->eclOutputModule().hasBlockFlows(); const bool& enableFlores = simulator_().problem().eclWriter()->eclOutputModule().hasFlores(); const unsigned int numCells = domain.cells.size(); const bool on_full_domain = (numCells == model_().numTotalDof());