23 #ifndef OPM_MULTISEGMENTWELL_ASSEMBLE_HEADER_INCLUDED 24 #define OPM_MULTISEGMENTWELL_ASSEMBLE_HEADER_INCLUDED 26 #include <opm/input/eclipse/Schedule/Well/Well.hpp> 27 #include <opm/material/densead/Evaluation.hpp> 33 template<
class Scalar>
class GroupState;
39 template<
typename Scalar,
typename IndexTraits>
class WellState;
43 template<
class Flu
idSystem,
class Indices>
47 static constexpr
int WQTotal = PrimaryVariables::WQTotal;
48 static constexpr
bool has_wfrac_variable = PrimaryVariables::has_wfrac_variable;
49 static constexpr
bool has_gfrac_variable = PrimaryVariables::has_gfrac_variable;
50 static constexpr
int WFrac = PrimaryVariables::WFrac;
51 static constexpr
int GFrac = PrimaryVariables::GFrac;
52 static constexpr
int SPres = PrimaryVariables::SPres;
55 static constexpr
int numWellEq = Indices::numPhases+1;
56 using Scalar =
typename FluidSystem::Scalar;
57 using IndexTraits =
typename FluidSystem::IndexTraitsType;
59 using EvalWell = DenseAd::Evaluation<Scalar, numWellEq+Indices::numEq>;
69 const Well::InjectionControls& inj_controls,
70 const Well::ProductionControls& prod_controls,
72 const PrimaryVariables& primary_variables,
74 const bool stopped_or_zero_target)
const;
80 const EvalWell& accelerationTerm,
81 Equations& eqns1)
const;
85 const int seg_density,
86 const EvalWell& hydro_pressure_drop_seg,
87 Equations& eqns1)
const;
92 const EvalWell& extra_derivatives,
93 Equations& eqns1)
const;
98 const int outlet_segment_index,
99 const EvalWell& pressure_equation,
100 const EvalWell& outlet_pressure,
101 Equations& eqns)
const;
106 Equations& eqns)
const;
111 const EvalWell& accumulation_term,
112 Equations& eqns1)
const;
116 const int seg_upwind,
118 const EvalWell& segment_rate,
119 Equations& eqns1)
const;
124 const int inlet_upwind,
126 const EvalWell& inlet_rate,
127 Equations& eqns)
const;
131 const int local_perf_index,
133 const EvalWell& cq_s_effective,
134 Equations& eqns)
const;
142 #endif // OPM_STANDARDWELL_ASSEMBLE_HEADER_INCLUDED void assemblePressureEq(const int seg, const int seg_upwind, const int outlet_segment_index, const EvalWell &pressure_equation, const EvalWell &outlet_pressure, Equations &eqns) const
Assemble pressure terms.
Definition: MultisegmentWellAssemble.cpp:269
void assembleOutflowTerm(const int seg, const int seg_upwind, const int comp_idx, const EvalWell &segment_rate, Equations &eqns1) const
Assemble outflow term.
Definition: MultisegmentWellAssemble.cpp:335
void assembleHydroPressureLoss(const int seg, const int seg_density, const EvalWell &hydro_pressure_drop_seg, Equations &eqns1) const
Assemble hydraulic pressure term.
Definition: MultisegmentWellAssemble.cpp:231
Class handling assemble of the equation system for MultisegmentWell.
Definition: MultisegmentWellAssemble.hpp:44
void assembleAccelerationTerm(const int seg_target, const int seg, const int seg_upwing, const EvalWell &accelerationTerm, Equations &eqns1) const
Assemble piece of the acceleration term.
Definition: MultisegmentWellAssemble.cpp:200
void assembleTrivialEq(const int seg, const Scalar value, Equations &eqns) const
Assembles a trivial equation.
Definition: MultisegmentWellAssemble.cpp:299
Definition: MultisegmentWellAssemble.hpp:34
Definition: MultisegmentWellAssemble.hpp:35
This file contains a set of helper functions used by VFPProd / VFPInj.
Definition: blackoilbioeffectsmodules.hh:45
Definition: BlackoilWellModelConstraints.hpp:37
MultisegmentWellAssemble(const WellInterfaceIndices< FluidSystem, Indices > &well)
Constructor initializes reference to well.
Definition: MultisegmentWellAssemble.hpp:63
void assemblePressureEqExtraDerivatives(const int seg, const int seg_upwind, const EvalWell &extra_derivatives, Equations &eqns1) const
Assemble additional derivatives due to reverse flow.
Definition: MultisegmentWellAssemble.cpp:251
Definition: MultisegmentWellAssemble.hpp:38
void assembleInflowTerm(const int seg, const int inlet, const int inlet_upwind, const int comp_idx, const EvalWell &inlet_rate, Equations &eqns) const
Assemble inflow term.
Definition: MultisegmentWellAssemble.cpp:359
void assembleControlEq(const GroupStateHelperType &groupStateHelper, const Well::InjectionControls &inj_controls, const Well::ProductionControls &prod_controls, const Scalar rho, const PrimaryVariables &primary_variables, Equations &eqns, const bool stopped_or_zero_target) const
Assemble control equation.
Definition: MultisegmentWellAssemble.cpp:86
The state of a set of wells, tailored for use by the fully implicit blackoil simulator.
Definition: TemperatureModel.hpp:61
void assembleAccumulationTerm(const int seg, const int comp_idx, const EvalWell &accumulation_term, Equations &eqns1) const
Assemble accumulation term.
Definition: MultisegmentWellAssemble.cpp:317
void assemblePerforationEq(const int seg, const int local_perf_index, const int comp_idx, const EvalWell &cq_s_effective, Equations &eqns) const
Assemble equation for a perforation.
Definition: MultisegmentWellAssemble.cpp:384