mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-01-26 19:46:24 -06:00
fix regression in wells
we need to call WellInterface::getTHPConstraint, not WellBhpThpCalculator::getTHPConstraint
This commit is contained in:
parent
8fc13d4bef
commit
2da1322697
@ -1918,6 +1918,7 @@ namespace Opm
|
||||
this->maxPerfPress(ebos_simulator),
|
||||
this->getRefDensity(),
|
||||
alq_value,
|
||||
this->getTHPConstraint(summary_state),
|
||||
deferred_logger);
|
||||
|
||||
if (bhpAtLimit)
|
||||
@ -1938,6 +1939,7 @@ namespace Opm
|
||||
this->maxPerfPress(ebos_simulator),
|
||||
this->getRefDensity(),
|
||||
alq_value,
|
||||
this->getTHPConstraint(summary_state),
|
||||
deferred_logger);
|
||||
}
|
||||
|
||||
|
@ -2437,6 +2437,7 @@ namespace Opm
|
||||
max_pressure,
|
||||
this->getRho(),
|
||||
alq_value,
|
||||
this->getTHPConstraint(summary_state),
|
||||
deferred_logger);
|
||||
auto v = frates(*bhpAtLimit);
|
||||
if (bhpAtLimit && std::all_of(v.cbegin(), v.cend(), [](double i){ return i <= 0; }))
|
||||
@ -2457,6 +2458,7 @@ namespace Opm
|
||||
max_pressure,
|
||||
this->getRho(),
|
||||
alq_value,
|
||||
this->getTHPConstraint(summary_state),
|
||||
deferred_logger);
|
||||
v = frates(*bhpAtLimit);
|
||||
if(bhpAtLimit && std::all_of(v.cbegin(), v.cend(), [](double i){ return i <= 0; }))
|
||||
|
@ -142,6 +142,7 @@ computeBhpAtThpLimitProd(const std::function<std::vector<double>(const double)>&
|
||||
const double maxPerfPress,
|
||||
const double rho,
|
||||
const double alq_value,
|
||||
const double thp_limit,
|
||||
DeferredLogger& deferred_logger) const
|
||||
{
|
||||
// Given a VFP function returning bhp as a function of phase
|
||||
@ -168,7 +169,6 @@ computeBhpAtThpLimitProd(const std::function<std::vector<double>(const double)>&
|
||||
const auto& controls = well_.wellEcl().productionControls(summary_state);
|
||||
const auto& table = well_.vfpProperties()->getProd()->getTable(controls.vfp_table_number);
|
||||
const double vfp_ref_depth = table.getDatumDepth();
|
||||
const double thp_limit = this->getTHPConstraint(summary_state);
|
||||
const double dp = wellhelpers::computeHydrostaticCorrection(well_.refDepth(), vfp_ref_depth, rho, well_.gravity());
|
||||
|
||||
auto fbhp = [this, &controls, thp_limit, dp, alq_value](const std::vector<double>& rates) {
|
||||
|
@ -67,6 +67,7 @@ public:
|
||||
const double maxPerfPress,
|
||||
const double rho,
|
||||
const double alq_value,
|
||||
const double thp_limit,
|
||||
DeferredLogger& deferred_logger) const;
|
||||
|
||||
//! \brief Compute BHP from THP limit for an injector.
|
||||
|
Loading…
Reference in New Issue
Block a user