mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
fixing the errors from rebasing.
This commit is contained in:
parent
60fb868727
commit
b4f4878901
@ -155,16 +155,14 @@ namespace Opm {
|
||||
, segment_mass_flow_rates_(ADB::null())
|
||||
, segment_viscosities_(ADB::null())
|
||||
{
|
||||
// TODO: repeated with the wellOps's initialization, delete one soon.
|
||||
// Count the total number of perforations and segments.
|
||||
const int nw = wells_ms.size();
|
||||
top_well_segments_.resize(nw);
|
||||
const int nw = wells_multisegment_.size();
|
||||
int nperf_total = 0;
|
||||
int nseg_total = 0;
|
||||
top_well_segments_.resize(nw);
|
||||
for (int w = 0; w < nw; ++w) {
|
||||
top_well_segments_[w] = nseg_total;
|
||||
nperf_total += wells_ms[w]->numberOfPerforations();
|
||||
nseg_total += wells_ms[w]->numberOfSegments();
|
||||
nperf_total += wells_multisegment_[w]->numberOfPerforations();
|
||||
nseg_total += wells_multisegment_[w]->numberOfSegments();
|
||||
}
|
||||
|
||||
nperf_total_ = nperf_total;
|
||||
|
@ -106,31 +106,7 @@ struct SetupMSW {
|
||||
const Wells* wells = wells_manager.c_wells();
|
||||
const std::vector<Opm::WellConstPtr>& wells_ecl = ecl_state->getSchedule()->getWells(current_timestep);
|
||||
|
||||
std::vector<Opm::WellMultiSegmentConstPtr> wells_multisegment;
|
||||
wells_multisegment.reserve(wells_ecl.size());
|
||||
for (size_t i = 0; i < wells_ecl.size(); ++i) {
|
||||
// not processing SHUT wells.
|
||||
if (wells_ecl[i]->getStatus(current_timestep) == Opm::WellCommon::SHUT) {
|
||||
continue;
|
||||
}
|
||||
// checking if the well can be found in the wells
|
||||
const std::string& well_name = wells_ecl[i]->name();
|
||||
// number of wells in wells
|
||||
const int nw_wells = wells->number_of_wells;
|
||||
int index_well;
|
||||
for (index_well = 0; index_well < nw_wells; ++index_well) {
|
||||
if (well_name == std::string(wells->name[index_well])) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
// have to be able to be found
|
||||
assert(index_well != nw_wells);
|
||||
|
||||
wells_multisegment.push_back(std::make_shared<Opm::WellMultiSegment>(wells_ecl[i], current_timestep, wells));
|
||||
}
|
||||
|
||||
ms_wells.reset(new Opm::MultisegmentWells(wells_multisegment, wells->number_of_phases));
|
||||
ms_wells.reset(new Opm::MultisegmentWells(wells, wells_ecl, current_timestep));
|
||||
};
|
||||
|
||||
std::shared_ptr<const Opm::MultisegmentWells> ms_wells;
|
||||
|
Loading…
Reference in New Issue
Block a user