From 94d57f686c22dd5e8177f96091f5ea1ab01822b3 Mon Sep 17 00:00:00 2001 From: Joakim Hove Date: Sun, 17 Jun 2018 14:42:14 +0200 Subject: [PATCH] Refactor of connecrions & completions --- opm/autodiff/MultisegmentWell.hpp | 4 ++-- opm/autodiff/MultisegmentWell_impl.hpp | 10 +++++----- opm/autodiff/WellStateFullyImplicitBlackoil.hpp | 6 +++--- opm/core/wells/WellsManager_impl.hpp | 2 +- 4 files changed, 11 insertions(+), 11 deletions(-) diff --git a/opm/autodiff/MultisegmentWell.hpp b/opm/autodiff/MultisegmentWell.hpp index ac55dd610..713a623eb 100644 --- a/opm/autodiff/MultisegmentWell.hpp +++ b/opm/autodiff/MultisegmentWell.hpp @@ -161,8 +161,8 @@ namespace Opm // multi-phase flow model WellSegment::MultiPhaseModelEnum multiphaseModel() const; - // get the SegmentSet from the well_ecl_ - const SegmentSet& segmentSet() const; + // get the WellSegments from the well_ecl_ + const WellSegments& segmentSet() const; // protected member variables from the Base class using Base::well_ecl_; diff --git a/opm/autodiff/MultisegmentWell_impl.hpp b/opm/autodiff/MultisegmentWell_impl.hpp index 916ef2807..0d92a86c0 100644 --- a/opm/autodiff/MultisegmentWell_impl.hpp +++ b/opm/autodiff/MultisegmentWell_impl.hpp @@ -52,11 +52,11 @@ namespace Opm if (has_polymer) { OPM_THROW(std::runtime_error, "polymer is not supported by multisegment well yet"); } - // since we decide to use the SegmentSet from the well parser. we can reuse a lot from it. + // since we decide to use the WellSegments from the well parser. we can reuse a lot from it. // for other facilities needed but not available from parser, we need to process them here // initialize the segment_perforations_ - const ConnectionSet& completion_set = well_ecl_->getConnections(current_step_); + const WellConnections& completion_set = well_ecl_->getConnections(current_step_); for (int perf = 0; perf < number_of_perforations_; ++perf) { const Connection& completion = completion_set.get(perf); const int segment_number = completion.getSegmentNumber(); @@ -792,11 +792,11 @@ namespace Opm template - const SegmentSet& + const WellSegments& MultisegmentWell:: segmentSet() const { - return well_ecl_->getSegmentSet(current_step_); + return well_ecl_->getWellSegments(current_step_); } @@ -808,7 +808,7 @@ namespace Opm MultisegmentWell:: numberOfSegments() const { - return segmentSet().numberSegment(); + return segmentSet().size(); } diff --git a/opm/autodiff/WellStateFullyImplicitBlackoil.hpp b/opm/autodiff/WellStateFullyImplicitBlackoil.hpp index e9b144373..aad21ea2e 100644 --- a/opm/autodiff/WellStateFullyImplicitBlackoil.hpp +++ b/opm/autodiff/WellStateFullyImplicitBlackoil.hpp @@ -547,11 +547,11 @@ namespace Opm segrates_.push_back(wellRates()[np * w + p]); } } else { // it is a multi-segment well - const SegmentSet& segment_set = well_ecl->getSegmentSet(time_step); + const WellSegments& segment_set = well_ecl->getWellSegments(time_step); // assuming the order of the perforations in well_ecl is the same with Wells - const ConnectionSet& completion_set = well_ecl->getConnections(time_step); + const WellConnections& completion_set = well_ecl->getConnections(time_step); // number of segment for this single well - const int well_nseg = segment_set.numberSegment(); + const int well_nseg = segment_set.size(); const int nperf = completion_set.size(); nseg_ += well_nseg; // we need to know for each segment, how many perforation it has and how many segments using it as outlet_segment diff --git a/opm/core/wells/WellsManager_impl.hpp b/opm/core/wells/WellsManager_impl.hpp index 32668e808..88bfb0c19 100644 --- a/opm/core/wells/WellsManager_impl.hpp +++ b/opm/core/wells/WellsManager_impl.hpp @@ -6,7 +6,7 @@ #include #include #include -#include +#include #include #include