corrections to handle the use of network or not and degenrate case
This commit is contained in:
@@ -517,10 +517,10 @@ Opm::RestartIO::Helpers::WindowedArray<int>
|
||||
allocate(const std::vector<int>& inteHead)
|
||||
{
|
||||
using WV = Opm::RestartIO::Helpers::WindowedArray<int>;
|
||||
|
||||
int nitPrWin = std::max(static_cast<int>(entriesPerInobr(inteHead)), 1);
|
||||
return WV {
|
||||
WV::NumWindows{ 1 },
|
||||
WV::WindowSize{ entriesPerInobr(inteHead) }
|
||||
WV::WindowSize{ static_cast<std::size_t>(nitPrWin) }
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -438,8 +438,10 @@ namespace {
|
||||
{
|
||||
writeGroup(sim_step, units, schedule, sumState, inteHD, rstFile);
|
||||
|
||||
//write network data
|
||||
writeNetwork(es, sim_step, units, schedule, sumState, inteHD, rstFile);
|
||||
//write network data if the network option is used
|
||||
if (es.runspec().networkDimensions().maxNONodes() >= 1) {
|
||||
writeNetwork(es, sim_step, units, schedule, sumState, inteHD, rstFile);
|
||||
}
|
||||
|
||||
// Write well and MSW data only when applicable (i.e., when present)
|
||||
const auto& wells = schedule.wellNames(sim_step);
|
||||
|
||||
Reference in New Issue
Block a user