From a9590215dc6dd97625e2f456a1f04d7fc0f58536 Mon Sep 17 00:00:00 2001 From: Arne Morten Kvarving Date: Fri, 26 Aug 2022 08:23:13 +0200 Subject: [PATCH] changed: consistently use std::array --- ebos/eclfluxmodule.hh | 2 +- opm/simulators/wells/MultisegmentWell_impl.hpp | 4 ++-- opm/simulators/wells/StandardWell_impl.hpp | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/ebos/eclfluxmodule.hh b/ebos/eclfluxmodule.hh index 69facab4b..19557e97a 100644 --- a/ebos/eclfluxmodule.hh +++ b/ebos/eclfluxmodule.hh @@ -499,7 +499,7 @@ protected: elemCtx.problem().materialLawParams(elemCtx, interiorDofIdx, /*timeIdx=*/0); - typename FluidState::Scalar kr[numPhases]; + std::array kr; MaterialLaw::relativePermeabilities(kr, matParams, exFluidState); const auto& mob = kr[phaseIdx]/exFluidState.viscosity(phaseIdx); diff --git a/opm/simulators/wells/MultisegmentWell_impl.hpp b/opm/simulators/wells/MultisegmentWell_impl.hpp index 4f9af6d54..c8a71ff20 100644 --- a/opm/simulators/wells/MultisegmentWell_impl.hpp +++ b/opm/simulators/wells/MultisegmentWell_impl.hpp @@ -1148,7 +1148,7 @@ namespace Opm } else { const auto& paramsCell = materialLawManager->connectionMaterialLawParams(satid, cell_idx); - Eval relativePerms[3] = { 0.0, 0.0, 0.0 }; + std::array relativePerms = { 0.0, 0.0, 0.0 }; MaterialLaw::relativePermeabilities(relativePerms, paramsCell, intQuants.fluidState()); // reset the satnumvalue back to original @@ -1200,7 +1200,7 @@ namespace Opm } else { const auto& paramsCell = materialLawManager->connectionMaterialLawParams(satid, cell_idx); - Scalar relativePerms[3] = { 0.0, 0.0, 0.0 }; + std::array relativePerms = { 0.0, 0.0, 0.0 }; MaterialLaw::relativePermeabilities(relativePerms, paramsCell, intQuants.fluidState()); // reset the satnumvalue back to original diff --git a/opm/simulators/wells/StandardWell_impl.hpp b/opm/simulators/wells/StandardWell_impl.hpp index 3194634a1..a0d682fa0 100644 --- a/opm/simulators/wells/StandardWell_impl.hpp +++ b/opm/simulators/wells/StandardWell_impl.hpp @@ -812,7 +812,7 @@ namespace Opm } else { const auto& paramsCell = materialLawManager->connectionMaterialLawParams(satid, cell_idx); - Eval relativePerms[3] = { 0.0, 0.0, 0.0 }; + std::array relativePerms = { 0.0, 0.0, 0.0 }; MaterialLaw::relativePermeabilities(relativePerms, paramsCell, intQuants.fluidState()); // reset the satnumvalue back to original @@ -881,7 +881,7 @@ namespace Opm } else { const auto& paramsCell = materialLawManager->connectionMaterialLawParams(satid, cell_idx); - Eval relativePerms[3] = { 0.0, 0.0, 0.0 }; + std::array relativePerms = { 0.0, 0.0, 0.0 }; MaterialLaw::relativePermeabilities(relativePerms, paramsCell, intQuants.fluidState()); // reset the satnumvalue back to original