mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
Use well index for segment friction pressure drop
This commit is contained in:
parent
92e31b4ee3
commit
ee1a1c6afc
@ -1930,7 +1930,7 @@ namespace Opm
|
||||
if (frictionalPressureLossConsidered()) {
|
||||
const auto friction_pressure_drop = getFrictionPressureLoss(seg);
|
||||
pressure_equation -= friction_pressure_drop;
|
||||
well_state.segPressDropFriction()[top_segment_index + seg] = friction_pressure_drop.value();
|
||||
well_state.segPressDropFriction(index_of_well_)[seg] = friction_pressure_drop.value();
|
||||
}
|
||||
|
||||
resWell_[seg][SPres] = pressure_equation.value();
|
||||
@ -2705,8 +2705,9 @@ namespace Opm
|
||||
}
|
||||
|
||||
auto seg_press_drop = well_state.segPressDrop(index_of_well_);
|
||||
auto seg_press_friction = well_state.segPressDropFriction(index_of_well_);
|
||||
seg_press_drop[seg] = well_state.segPressDropHydroStatic()[seg] +
|
||||
well_state.segPressDropFriction()[seg] +
|
||||
seg_press_friction[seg] +
|
||||
well_state.segPressDropAcceleration()[seg];
|
||||
}
|
||||
}
|
||||
@ -3261,8 +3262,7 @@ namespace Opm
|
||||
}
|
||||
}
|
||||
pressure_equation = pressure_equation - icd_pressure_drop;
|
||||
auto top_segment_index = well_state.topSegmentIndex(this->index_of_well_);
|
||||
well_state.segPressDropFriction()[top_segment_index + seg] = icd_pressure_drop.value();
|
||||
well_state.segPressDropFriction(index_of_well_)[seg] = icd_pressure_drop.value();
|
||||
|
||||
const int seg_upwind = upwinding_segments_[seg];
|
||||
resWell_[seg][SPres] = pressure_equation.value();
|
||||
|
@ -1159,7 +1159,7 @@ WellState::reportSegmentResults(const PhaseUsage& pu,
|
||||
segpress[Value::Pressure] = this->segPress(well_id)[seg_ix];
|
||||
segpress[Value::PDrop] = this->segPressDrop(well_id)[seg_ix];
|
||||
segpress[Value::PDropHydrostatic] = this->segPressDropHydroStatic()[seg_dof];
|
||||
segpress[Value::PDropFriction] = this->segPressDropFriction()[seg_dof];
|
||||
segpress[Value::PDropFriction] = this->segPressDropFriction(well_id)[seg_ix];
|
||||
segpress[Value::PDropAccel] = this->segPressDropAcceleration()[seg_dof];
|
||||
}
|
||||
|
||||
|
@ -229,14 +229,16 @@ public:
|
||||
return &seg_pressdrop_[top_segment_index];
|
||||
}
|
||||
|
||||
std::vector<double>& segPressDropFriction()
|
||||
double* segPressDropFriction(std::size_t well_index)
|
||||
{
|
||||
return seg_pressdrop_friction_;
|
||||
const int top_segment_index = this->top_segment_index_[well_index];
|
||||
return &seg_pressdrop_friction_[top_segment_index];
|
||||
}
|
||||
|
||||
const std::vector<double>& segPressDropFriction() const
|
||||
const double* segPressDropFriction(std::size_t well_index) const
|
||||
{
|
||||
return seg_pressdrop_friction_;
|
||||
const int top_segment_index = this->top_segment_index_[well_index];
|
||||
return &seg_pressdrop_friction_[top_segment_index];
|
||||
}
|
||||
|
||||
std::vector<double>& segPressDropHydroStatic()
|
||||
|
Loading…
Reference in New Issue
Block a user