-
Notifications
You must be signed in to change notification settings - Fork 96
Well Estimator + Constraint Selector #3735
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: develop
Are you sure you want to change the base?
Conversation
…m for each well, 2) refactor accum/flux/presrelation calcs
…Newton for now, incl well dbg for now, compo1&2d run
… skip calcs if well not open, 3) parallel estimator works on a few cases tested
…initialization - part 1
…new&old logic, add basic basic constraint selection
…tor w/well estimator, 3) split constraint derivatives from well rate calculations, 4) add kernels for active constraint jacgen calcs , 5) needs testing
setDefaultValue( -1 ). | ||
setSizedFromParent( 0 ). | ||
setInputFlag( dataRepository::InputFlags::OPTIONAL ). | ||
setDescription( "Global component densities of the injection stream [moles/m^3 or kg/m^3]" ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I always assumed this to be fractions (mass or mole).
|
||
Group * constraint = nullptr; | ||
if( childKey == viewKeyStruct::minimumBHPConstraintString() ) | ||
{ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm guessing we are expecting only one constraint of each type. Is there a way we can enforce this? Something similar to the NonLinearParameters on the solvers.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
From the user, yes only one constraint of each type, but the code would still select the most limiting constraint. I will put code in to enforce this, and also valid combinations of constraints.
- There maybe more than one constraint of each type for operations like WHP or scaling, where the simulator imposes a constraint based on some allocation scheme, or for WHP, it would implement this as a BHP constraint, or other. Constraints are usually tagged with USER or SIM, where SIM being an internally generated constraint. How/when these SIM constraints get registered still needs to be addressed.
- you can assign inj and prod constraints to a well. This is more of an oil field usecase, cycling, but for geothermal this might be of use for closed loop well, which could have 2 boundary conditions.
/// string key for the maximum volume rate for a injector | ||
static constexpr char const * volumeInjectionConstraintString() { return "VolumeInjectionConstraint"; } | ||
/// string key for the maximum mass rate for a producer | ||
static constexpr char const * massProductionConstraintString() { return "massProductionConstraint"; } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
static constexpr char const * massProductionConstraintString() { return "massProductionConstraint"; } | |
static constexpr char const * massProductionConstraintString() { return "MassProductionConstraint"; } |
/// string key for the maximum mass rate for a producer | ||
static constexpr char const * massProductionConstraintString() { return "massProductionConstraint"; } | ||
/// string key for the maximum mass rate for a injector | ||
static constexpr char const * massInjectionConstraintString() { return "massInjectionConstraint"; } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
static constexpr char const * massInjectionConstraintString() { return "massInjectionConstraint"; } | |
static constexpr char const * massInjectionConstraintString() { return "MassInjectionConstraint"; } |
* @brief This class describes a phase rate constraint used to control a injection well. | ||
*/ | ||
|
||
class PhaseInjectionConstraint : public PhaseConstraint |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How is PhaseInjectionConstraint
different from VolumeInjectionConstraint
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Probably should be called TotalVolume...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
and Phase could be called PhaseVolume
… base, 2) numerous fixes, 3) prod and inj well test cases w & wout estimator
…hp case using converted opm flowtable
Add well estimator solve assuming fixed reservoir conditions
Refactor constraint specification
Introduced concept of well separator internally to remove ambiguity of fluid model quantities encountered when using same fluid model for constraint flashes and well element calculations. No input schema changes. This should be under separate PR to include formal well separator schema
Introduced limiting constraint selector to work with well estimator. At the beginning of the first n Newton Iterations , for each constraint, the well estimator applied and the most limiting constraint selected and set as the active constraint for the remaining Newton iterations.
PR currently has a fair bit of well debug code that will be removed