Give the parallel well info object to the MultisegmentWellEval class as well

This commit is contained in:
Lisa Julia Nebel 2024-09-30 08:55:00 +02:00
parent 655f4011c7
commit 449847da9e
3 changed files with 6 additions and 3 deletions

View File

@ -53,8 +53,9 @@ namespace Opm
template<typename FluidSystem, typename Indices> template<typename FluidSystem, typename Indices>
MultisegmentWellEval<FluidSystem,Indices>:: MultisegmentWellEval<FluidSystem,Indices>::
MultisegmentWellEval(WellInterfaceIndices<FluidSystem,Indices>& baseif) MultisegmentWellEval(WellInterfaceIndices<FluidSystem,Indices>& baseif, const ParallelWellInfo<Scalar>& pw_info)
: MultisegmentWellGeneric<Scalar>(baseif) : MultisegmentWellGeneric<Scalar>(baseif)
, pw_info_(pw_info)
, baseif_(baseif) , baseif_(baseif)
, linSys_(*this) , linSys_(*this)
, primary_variables_(baseif) , primary_variables_(baseif)

View File

@ -26,6 +26,7 @@
#include <opm/simulators/wells/MultisegmentWellGeneric.hpp> #include <opm/simulators/wells/MultisegmentWellGeneric.hpp>
#include <opm/simulators/wells/MultisegmentWellPrimaryVariables.hpp> #include <opm/simulators/wells/MultisegmentWellPrimaryVariables.hpp>
#include <opm/simulators/wells/MultisegmentWellSegments.hpp> #include <opm/simulators/wells/MultisegmentWellSegments.hpp>
#include <opm/simulators/wells/ParallelWellInfo.hpp>
#include <opm/material/densead/Evaluation.hpp> #include <opm/material/densead/Evaluation.hpp>
@ -67,9 +68,10 @@ public:
//! \brief Returns a const reference to equation system. //! \brief Returns a const reference to equation system.
const Equations& linSys() const const Equations& linSys() const
{ return linSys_; } { return linSys_; }
const ParallelWellInfo<Scalar>& pw_info_;
protected: protected:
MultisegmentWellEval(WellInterfaceIndices<FluidSystem,Indices>& baseif); MultisegmentWellEval(WellInterfaceIndices<FluidSystem,Indices>& baseif, const ParallelWellInfo<Scalar>& pw_info);
void initMatrixAndVectors(); void initMatrixAndVectors();

View File

@ -67,7 +67,7 @@ namespace Opm
const int index_of_well, const int index_of_well,
const std::vector<PerforationData<Scalar>>& perf_data) const std::vector<PerforationData<Scalar>>& perf_data)
: Base(well, pw_info, time_step, param, rate_converter, pvtRegionIdx, num_components, num_phases, index_of_well, perf_data) : Base(well, pw_info, time_step, param, rate_converter, pvtRegionIdx, num_components, num_phases, index_of_well, perf_data)
, MSWEval(static_cast<WellInterfaceIndices<FluidSystem,Indices>&>(*this)) , MSWEval(static_cast<WellInterfaceIndices<FluidSystem,Indices>&>(*this), pw_info)
, regularize_(false) , regularize_(false)
, segment_fluid_initial_(this->numberOfSegments(), std::vector<Scalar>(this->num_components_, 0.0)) , segment_fluid_initial_(this->numberOfSegments(), std::vector<Scalar>(this->num_components_, 0.0))
{ {