mirror of
https://github.com/OPM/opm-simulators.git
synced 2024-12-30 11:06:55 -06:00
Implement BlackoilWellModel::hasWell() method
This commit is contained in:
parent
591826ea4e
commit
99a61e120b
@ -268,6 +268,7 @@ namespace Opm {
|
||||
bool forceShutWellByNameIfPredictionMode(const std::string& wellname, const double simulation_time);
|
||||
|
||||
double wellPI(int well_index) const;
|
||||
bool hasWell(const std::string& wname);
|
||||
protected:
|
||||
Simulator& ebosSimulator_;
|
||||
|
||||
|
@ -1726,6 +1726,15 @@ namespace Opm {
|
||||
}
|
||||
|
||||
|
||||
template<typename TypeTag>
|
||||
bool
|
||||
BlackoilWellModel<TypeTag>::
|
||||
hasWell(const std::string& wname) {
|
||||
auto iter = std::find_if( this->wells_ecl_.begin(), this->wells_ecl_.end(), [&wname](const Well& well) { return well.name() == wname; });
|
||||
return (iter != this->wells_ecl_.end());
|
||||
}
|
||||
|
||||
|
||||
// convert well data from opm-common to well state from opm-core
|
||||
template<typename TypeTag>
|
||||
void
|
||||
|
Loading…
Reference in New Issue
Block a user