Merge pull request #5796 from bska/wbpn-result-type-top-level

Chase API Update
This commit is contained in:
Bård Skaflestad
2024-12-12 09:34:03 +01:00
committed by GitHub
4 changed files with 8 additions and 8 deletions

View File

@@ -2331,7 +2331,7 @@ namespace Opm {
{
auto wbpResult = data::WellBlockAveragePressures{};
using Calculated = typename PAvgCalculator<Scalar>::Result::WBPMode;
using Calculated = typename PAvgCalculatorResult<Scalar>::WBPMode;
using Output = data::WellBlockAvgPress::Quantity;
this->wbpCalculationService_.collectDynamicValues();

View File

@@ -186,15 +186,15 @@ evalCellSource(Evaluator evalCellSrc)
template<class Scalar>
std::size_t Opm::ParallelWBPCalculation<Scalar>::
createCalculator(const Well& well,
createCalculator(const Well& well,
const ParallelWellInfo<Scalar>& parallelWellInfo,
const std::vector<int>& localConnIdx,
EvaluatorFactory makeWellSourceEvaluator)
const std::vector<int>& localConnIdx,
EvaluatorFactory makeWellSourceEvaluator)
{
assert (this->wellConnSrc_.size() == this->localConnSet_.size());
const auto ix = this->calculators_
.setCalculator(well.seqIndex(), std::make_unique<ParallelPAvgCalculator<Scalar>>
.setCalculator(well.seqIndex(), std::make_unique<ParallelPAvgCalculator<Scalar>>
(parallelWellInfo.communication(),
this->cellIndexMap_, well.getConnections()));
@@ -259,7 +259,7 @@ inferBlockAveragePressures(const std::size_t calcIndex,
}
template<class Scalar>
const typename Opm::PAvgCalculator<Scalar>::Result&
const Opm::PAvgCalculatorResult<Scalar>&
Opm::ParallelWBPCalculation<Scalar>::
averagePressures(const std::size_t calcIndex) const
{

View File

@@ -164,7 +164,7 @@ public:
///
/// \return Result set from most recent call to member function \c
/// inferBlockAveragePressures() for \c calcIndex.
const typename PAvgCalculator<Scalar>::Result&
const PAvgCalculatorResult<Scalar>&
averagePressures(const std::size_t calcIndex) const;
private:

View File

@@ -599,7 +599,7 @@ BOOST_AUTO_TEST_CASE(TopOfFormation_Well_OpenConns)
cse.wbpCalcService.inferBlockAveragePressures(calcIndex, controls, gravity, refDepth);
const auto avgPress = cse.wbpCalcService.averagePressures(calcIndex);
using WBPMode = Opm::PAvgCalculator<double>::Result::WBPMode;
using WBPMode = Opm::PAvgCalculatorResult<double>::WBPMode;
BOOST_CHECK_CLOSE(avgPress.value(WBPMode::WBP) , 1254.806625666667, 1.0e-8);
BOOST_CHECK_CLOSE(avgPress.value(WBPMode::WBP4), 1295.348292333333, 1.0e-8);