Skip to content
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

Kernels for poroelastic solvers #1353

Merged
merged 40 commits into from
Mar 18, 2021
Merged

Conversation

castelletto1
Copy link
Contributor

@castelletto1 castelletto1 commented Mar 11, 2021

This PR adds assembly kernels for fully-implicit poroelastic simulation with both single-phase (PoroelasticSolver) and multiphase (MultiphasePoroelasticSolver) flow. Capillary effects are neglected. Flow solvers can be based on either finite volumes (FVM) or hybrid schemes (HybridFVM). For the muliphase flow case the maximum number of components is equal to three).

The kernels assemble:

  • all contributions relative to the discrete linear momentum balance equation (note that an inexact linearization is used at the moment for the body force term)
  • contributions to residual and Jacobian matrix relative to the the accumulation term in mass balance equations

Currently the porosity equation considers a linear poroelastic material and assumes incompressible solid grains (1/N = 0, with N Biot's skeleton modulus):

with the subscript n denoting the discrete time level. The porosity treatment will be generalized introducing a dedicated constitutive model (see #1311).

A preliminary 2d example has been added (PoroElastic_deadoil_3ph_baker_2d.xml).

Currently all integrated tests pass, except for the usual ones on Lassen.

Some issues to be addressed in future PR / PRs:

  1. Exact linerization for body forces
  2. Add capillary effects
  3. Add MGR recipes for (i) multiphase poromechanics with FVM, and (ii) single- and multiphase poromechanics with HybridFVM
  4. Rename PoroelasticSolver to SinglePhasePoroelasticSolver (not done here to avoid new baseline in the integrated tests)
  5. Add benchmark based on SPE10 model 1 [see Camargo et al., IJNAMG (2021)]
  6. Remove the split operator strategy (SIM_FixedStress coupling option) from the single-phase poroelastic solver.

Requires a rebaseline:
https://github.com/GEOSX/integratedTests/pull/124

@castelletto1 castelletto1 marked this pull request as draft March 11, 2021 22:48
@castelletto1 castelletto1 marked this pull request as ready for review March 11, 2021 22:51
@sytuannguyen
Copy link
Contributor

sytuannguyen commented Mar 15, 2021

@castelletto1 @rrsettgast I am interested in poroelastic coupling, so read through your PR and add some comments, Hope this help.

Do you want to add a class for computing the poroelastic constants, i.e. the transformation between the poroelastic constants?

castelletto1 and others added 3 commits March 15, 2021 12:50
Copy link
Collaborator

@CusiniM CusiniM left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is great! Should also integrate very well with what I have been working on.

stack.xLocal[ a ][ i ] = m_X[ localNodeIndex ][ i ];
#endif
stack.u_local[ a ][i] = m_disp[ localNodeIndex ][i];
stack.uhat_local[ a ][i] = m_uhat[ localNodeIndex ][i];
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wonder if we should use disp and deltaDisp like we do for the pressure instead of u and u_hat.

Copy link
Contributor Author

@castelletto1 castelletto1 Mar 15, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree that the naming convention should be improved. However, it should be reflected across all solid mechanics kernels.

// update displacement field
m_solidSolver->applySystemSolution( dofManager, localSolution, scalingFactor, domain );
// update pressure field
m_flowSolver->applySystemSolution( dofManager, localSolution, -scalingFactor, domain );
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

at some point we should fix the signs.

@sytuannguyen
Copy link
Contributor

sytuannguyen commented Mar 16, 2021

@castelletto1 I added some additional comments to the Multiphase class.

Also I have a naive question: if multi phase solver can do the job of single phase solver just by setting 100% saturation to a phase, do we really need single phase solver?

Copy link
Contributor

@klevzoff klevzoff left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good!

/// Number of nodes per element...which is equal to the
/// numTestSupportPointPerElem and numTrialSupportPointPerElem by definition.
static constexpr int numNodesPerElem = Base::numTestSupportPointsPerElem;
static constexpr int numMaxComponentsMultiphasePoroelastic = 3;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We need to address this in a follow-up PR

template< int NUM_SUPPORT_POINTS,
typename GRADIENT_TYPE >
GEOSX_HOST_DEVICE
static real64 symmetricGradientTrace( GRADIENT_TYPE const & gradN,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry I didn't already ask...but would it make more sense to name this traceSymmetricGradient?

@@ -402,7 +402,8 @@ void HyprePreconditioner::createMGR( DofManager const * const dofManager )
std::vector< HYPRE_Int > mgr_level_interp_type;
std::vector< HYPRE_Int > mgr_level_frelax_method;

if( ( m_parameters.mgr.strategy == "Poroelastic" ) | ( m_parameters.mgr.strategy == "Hydrofracture" ) )
if( ( m_parameters.mgr.strategy == LinearSolverParameters::MGR::StrategyType::singlePhasePoroelastic) |
( m_parameters.mgr.strategy == LinearSolverParameters::MGR::StrategyType::hydrofracture ) )
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
( m_parameters.mgr.strategy == LinearSolverParameters::MGR::StrategyType::hydrofracture ) )
( m_parameters.mgr.strategy == LinearSolverParameters::MGR::StrategyType::singlePhaseFractureMechanicsFlow ) )

Should we stop calling it hydrofracture? I think that @CusiniM also had the inclination to rebrand it in the context of a poroelastic problem...but it has a transmissibility that varies with deformation.

What would be an appropriate name for "singlePhasePoroelastic" with deformation dependent transmissibility?

@@ -426,6 +426,7 @@ void SinglePhaseBase::assembleSystem( real64 const time_n,

if( m_poroElasticFlag )
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

still can't get rid of these?

@castelletto1 castelletto1 added ci: run CUDA builds Allows to triggers (costly) CUDA jobs and removed flag: ready for review labels Mar 17, 2021
@CusiniM CusiniM added the flag: requires rebaseline Requires rebaseline branch in integratedTests label Mar 18, 2021
@CusiniM CusiniM merged commit 512a162 into develop Mar 18, 2021
@CusiniM CusiniM deleted the feature/singleKernelPoroelastic branch March 18, 2021 19:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ci: run CUDA builds Allows to triggers (costly) CUDA jobs flag: requires rebaseline Requires rebaseline branch in integratedTests type: feature New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants