mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
getPrimaryVarsDomain: move to BlackoilWellModelGeneric
This commit is contained in:
@@ -387,7 +387,6 @@ template<class Scalar> class WellContributions;
|
|||||||
const Domain& domain);
|
const Domain& domain);
|
||||||
void updateWellControlsDomain(DeferredLogger& deferred_logger, const Domain& domain);
|
void updateWellControlsDomain(DeferredLogger& deferred_logger, const Domain& domain);
|
||||||
|
|
||||||
std::vector<Scalar> getPrimaryVarsDomain(const int domainIdx) const;
|
|
||||||
void setPrimaryVarsDomain(const int domainIdx, const std::vector<Scalar>& vars);
|
void setPrimaryVarsDomain(const int domainIdx, const std::vector<Scalar>& vars);
|
||||||
|
|
||||||
void setupDomains(const std::vector<Domain>& domains);
|
void setupDomains(const std::vector<Domain>& domains);
|
||||||
|
@@ -2056,6 +2056,21 @@ logPrimaryVars() const
|
|||||||
OpmLog::debug(os.str());
|
OpmLog::debug(os.str());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
template<class Scalar>
|
||||||
|
std::vector<Scalar>
|
||||||
|
BlackoilWellModelGeneric<Scalar>::
|
||||||
|
getPrimaryVarsDomain(const int domainIdx) const
|
||||||
|
{
|
||||||
|
std::vector<Scalar> ret;
|
||||||
|
for (const auto& well : this->well_container_generic_) {
|
||||||
|
if (this->well_domain_.at(well->name()) == domainIdx) {
|
||||||
|
const auto& pv = well->getPrimaryVars();
|
||||||
|
ret.insert(ret.end(), pv.begin(), pv.end());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return ret;
|
||||||
|
}
|
||||||
|
|
||||||
template class BlackoilWellModelGeneric<double>;
|
template class BlackoilWellModelGeneric<double>;
|
||||||
|
|
||||||
#if FLOW_INSTANTIATE_FLOAT
|
#if FLOW_INSTANTIATE_FLOAT
|
||||||
|
@@ -220,6 +220,7 @@ public:
|
|||||||
bool wasDynamicallyShutThisTimeStep(const std::string& well_name) const;
|
bool wasDynamicallyShutThisTimeStep(const std::string& well_name) const;
|
||||||
|
|
||||||
void logPrimaryVars() const;
|
void logPrimaryVars() const;
|
||||||
|
std::vector<Scalar> getPrimaryVarsDomain(const int domainIdx) const;
|
||||||
|
|
||||||
template<class Serializer>
|
template<class Serializer>
|
||||||
void serializeOp(Serializer& serializer)
|
void serializeOp(Serializer& serializer)
|
||||||
|
@@ -2985,23 +2985,6 @@ namespace Opm {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
template <typename TypeTag>
|
|
||||||
std::vector<typename BlackoilWellModel<TypeTag>::Scalar>
|
|
||||||
BlackoilWellModel<TypeTag>::
|
|
||||||
getPrimaryVarsDomain(const int domainIdx) const
|
|
||||||
{
|
|
||||||
std::vector<Scalar> ret;
|
|
||||||
for (const auto& well : well_container_) {
|
|
||||||
if (this->well_domain_.at(well->name()) == domainIdx) {
|
|
||||||
const auto& pv = well->getPrimaryVars();
|
|
||||||
ret.insert(ret.end(), pv.begin(), pv.end());
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return ret;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
template <typename TypeTag>
|
template <typename TypeTag>
|
||||||
void
|
void
|
||||||
BlackoilWellModel<TypeTag>::
|
BlackoilWellModel<TypeTag>::
|
||||||
|
Reference in New Issue
Block a user