-
Notifications
You must be signed in to change notification settings - Fork 123
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
extending drsdtcon with regimes, and option for GAS/WATER #5418
Conversation
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.
Thanks for the contribution. I only have minor comments.
@@ -123,7 +121,7 @@ drsdtActive(int episodeIdx) const | |||
const auto& oilVaporizationControl = schedule_[episodeIdx].oilvap(); | |||
const bool bothOilGasActive = FluidSystem::phaseIsActive(FluidSystem::oilPhaseIdx) && | |||
FluidSystem::phaseIsActive(FluidSystem::gasPhaseIdx); | |||
return (oilVaporizationControl.drsdtActive() && bothOilGasActive); | |||
return (oilVaporizationControl.drsdtActive()); |
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.
bothOilGasActive is unused
@@ -113,7 +112,6 @@ init(std::size_t numDof, int episodeIdx, const unsigned ntpvt) | |||
if (this->drsdtConvective(episodeIdx)) { |
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.
the resize are duplicated.
@@ -101,8 +101,7 @@ init(std::size_t numDof, int episodeIdx, const unsigned ntpvt) | |||
//TODO We may want to only allocate these properties only if active. | |||
//But since they may be activated at later time we need some more | |||
//intrastructure to handle it | |||
if (FluidSystem::phaseIsActive(FluidSystem::oilPhaseIdx) && | |||
FluidSystem::phaseIsActive(FluidSystem::gasPhaseIdx)) { | |||
|
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 still think we should add a if here, but it should be a bit more fine-tuned. Something like
If (drsdt)
resize: maxDRs and lastRs_ and dRsDtOnlyFreeGas_
if(drvdt)
resize: maxDrv and lastRv
// Note that for so = 0 this gives no limits (inf) for the dissolution rate | ||
// Also we restrict the effect of convective mixing to positive density differences | ||
// i.e. we only allow for fingers moving downward | ||
|
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.
Since we also support gas-water case, maybe adapt the comment?
@@ -174,6 +174,7 @@ class EquilInitializer | |||
const auto& h = FluidSystem::enthalpy(fluidState, phaseIdx, regionIdx); | |||
fluidState.setEnthalpy(phaseIdx, h); | |||
} | |||
|
|||
} |
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.
Nitpick. Please remove the added line.
opm/simulators/flow/FlowProblem.hpp
Outdated
@@ -520,6 +524,8 @@ class FlowProblem : public GetPropType<TypeTag, Properties::BaseProblem> | |||
const auto& schedule = simulator.vanguard().schedule(); | |||
const auto& events = schedule[episodeIdx].events(); | |||
|
|||
|
|||
|
|||
if (episodeIdx >= 0 && events.hasEvent(ScheduleEvents::GEO_MODIFIER)) { |
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.
Nitpick. Please remove the added line.
…g to drsdtcon, fixed indentation and bug in lastRs for gas/water
I will close this since its content is part of #5491 |
Extended the DRSDTCON to include more parameters that controls the regime and rate of convective mixing.
Included a convective term in the transport flux for the brine.
Also works for GAS/WATER (not only GAS/OIL as before)
Has corresponding PR in opm-models (OPM/opm-models#902) and opm-common (OPM/opm-common#4097)