Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions src/coreComponents/constitutive/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -157,6 +157,7 @@ set( constitutive_headers
permeability/PressurePermeability.hpp
permeability/ProppantPermeability.hpp
permeability/SlipDependentPermeability.hpp
permeability/StrainDependentPermeability.hpp
permeability/WillisRichardsPermeability.hpp
relativePermeability/BrooksCoreyBakerRelativePermeability.hpp
relativePermeability/BrooksCoreyStone2RelativePermeability.hpp
Expand Down Expand Up @@ -308,6 +309,7 @@ set( constitutive_sources
permeability/PressurePermeability.cpp
permeability/ProppantPermeability.cpp
permeability/SlipDependentPermeability.cpp
permeability/StrainDependentPermeability.cpp
permeability/WillisRichardsPermeability.cpp
relativePermeability/BrooksCoreyBakerRelativePermeability.cpp
relativePermeability/BrooksCoreyStone2RelativePermeability.cpp
Expand Down
38 changes: 36 additions & 2 deletions src/coreComponents/constitutive/ConstitutivePassThru.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@
#include "solid/porosity/ProppantPorosity.hpp"
#include "permeability/ConstantPermeability.hpp"
#include "permeability/CarmanKozenyPermeability.hpp"
#include "permeability/StrainDependentPermeability.hpp"
#include "permeability/ExponentialDecayPermeability.hpp"
#include "permeability/ParallelPlatesPermeability.hpp"
#include "permeability/PressurePermeability.hpp"
Expand Down Expand Up @@ -316,8 +317,19 @@ struct ConstitutivePassThru< PorousSolidBase >
PorousSolid< ElasticIsotropic, CarmanKozenyPermeability >,
PorousSolid< ElasticTransverseIsotropic, CarmanKozenyPermeability >,
PorousSolid< ElasticIsotropicPressureDependent, CarmanKozenyPermeability >,
PorousSolid< ElasticOrthotropic, CarmanKozenyPermeability > >::execute( constitutiveRelation,
std::forward< LAMBDA >( lambda ) );
PorousSolid< ElasticOrthotropic, CarmanKozenyPermeability >,
PorousSolid< DruckerPragerExtended, StrainDependentPermeability >,
PorousSolid< ModifiedCamClay, StrainDependentPermeability >,
PorousSolid< DelftEgg, StrainDependentPermeability >,
PorousSolid< DruckerPrager, StrainDependentPermeability >,
PorousSolid< DuvautLionsSolid< DruckerPrager >, StrainDependentPermeability >,
PorousSolid< DuvautLionsSolid< DruckerPragerExtended >, StrainDependentPermeability >,
PorousSolid< DuvautLionsSolid< ModifiedCamClay >, StrainDependentPermeability >,
PorousSolid< ElasticIsotropic, StrainDependentPermeability >,
PorousSolid< ElasticTransverseIsotropic, StrainDependentPermeability >,
PorousSolid< ElasticIsotropicPressureDependent, StrainDependentPermeability >,
PorousSolid< ElasticOrthotropic, StrainDependentPermeability > >::execute( constitutiveRelation,
std::forward< LAMBDA >( lambda ) );
}
};

Expand Down Expand Up @@ -434,6 +446,17 @@ struct ConstitutivePassThru< CoupledSolidBase >
PorousSolid< ElasticTransverseIsotropic, CarmanKozenyPermeability >,
PorousSolid< ElasticIsotropicPressureDependent, CarmanKozenyPermeability >,
PorousSolid< ElasticOrthotropic, CarmanKozenyPermeability >,
PorousSolid< DruckerPragerExtended, StrainDependentPermeability >,
PorousSolid< ModifiedCamClay, StrainDependentPermeability >,
PorousSolid< DelftEgg, StrainDependentPermeability >,
PorousSolid< DruckerPrager, StrainDependentPermeability >,
PorousSolid< DuvautLionsSolid< DruckerPrager >, StrainDependentPermeability >,
PorousSolid< DuvautLionsSolid< DruckerPragerExtended >, StrainDependentPermeability >,
PorousSolid< DuvautLionsSolid< ModifiedCamClay >, StrainDependentPermeability >,
PorousSolid< ElasticIsotropic, StrainDependentPermeability >,
PorousSolid< ElasticTransverseIsotropic, StrainDependentPermeability >,
PorousSolid< ElasticIsotropicPressureDependent, StrainDependentPermeability >,
PorousSolid< ElasticOrthotropic, StrainDependentPermeability >,
PorousDamageSolid< DamageSpectral< ElasticIsotropic > >,
PorousDamageSolid< DamageVolDev< ElasticIsotropic > >,
PorousDamageSolid< Damage< ElasticIsotropic > > >::execute( constitutiveRelation,
Expand Down Expand Up @@ -472,6 +495,17 @@ struct ConstitutivePassThru< CoupledSolidBase >
PorousSolid< ElasticTransverseIsotropic, CarmanKozenyPermeability >,
PorousSolid< ElasticIsotropicPressureDependent, CarmanKozenyPermeability >,
PorousSolid< ElasticOrthotropic, CarmanKozenyPermeability >,
PorousSolid< DruckerPragerExtended, StrainDependentPermeability >,
PorousSolid< ModifiedCamClay, StrainDependentPermeability >,
PorousSolid< DelftEgg, StrainDependentPermeability >,
PorousSolid< DruckerPrager, StrainDependentPermeability >,
PorousSolid< DuvautLionsSolid< DruckerPrager >, StrainDependentPermeability >,
PorousSolid< DuvautLionsSolid< DruckerPragerExtended >, StrainDependentPermeability >,
PorousSolid< DuvautLionsSolid< ModifiedCamClay >, StrainDependentPermeability >,
PorousSolid< ElasticIsotropic, StrainDependentPermeability >,
PorousSolid< ElasticTransverseIsotropic, StrainDependentPermeability >,
PorousSolid< ElasticIsotropicPressureDependent, StrainDependentPermeability >,
PorousSolid< ElasticOrthotropic, StrainDependentPermeability >,
PorousDamageSolid< DamageSpectral< ElasticIsotropic > >,
PorousDamageSolid< DamageVolDev< ElasticIsotropic > >,
PorousDamageSolid< Damage< ElasticIsotropic > > >::execute( constitutiveRelation,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,14 @@ class PermeabilityBaseUpdate
GEOS_UNUSED_VAR( k, q, pressure, porosity );
}

GEOS_HOST_DEVICE
virtual void updateFromPorosityAndStrain( localIndex const k,
real64 const & volStrain,
real64 const & porosity ) const
{
GEOS_UNUSED_VAR( k, volStrain, porosity );
}

GEOS_HOST_DEVICE
virtual void updateFromAperture( localIndex const k,
localIndex const q,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,14 @@ DECLARE_FIELD( dPerm_dTraction,
WRITE_AND_READ,
"Derivative of rock permeability with respect to the traction vector" );

DECLARE_FIELD( dPerm_dVolStrain,
"dPerm_dVolStrain",
array3d< real64 >,
0,
NOPLOT,
WRITE_AND_READ,
"Derivative of rock permeability with respect to volumetric strain" );

DECLARE_FIELD( permeabilityMultiplier,
"permeabilityMultiplier",
array3d< real64 >,
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,115 @@
/*
* ------------------------------------------------------------------------------------------------------------
* SPDX-License-Identifier: LGPL-2.1-only
*
* Copyright (c) 2016-2024 Lawrence Livermore National Security LLC
* Copyright (c) 2018-2024 TotalEnergies
* Copyright (c) 2018-2024 The Board of Trustees of the Leland Stanford Junior University
* Copyright (c) 2023-2024 Chevron
* Copyright (c) 2019- GEOS/GEOSX Contributors
* All rights reserved
*
* See top level LICENSE, COPYRIGHT, CONTRIBUTORS, NOTICE, and ACKNOWLEDGEMENTS files for details.
* ------------------------------------------------------------------------------------------------------------
*/

/**
* @file StrainDependentPermeability.cpp
*/

#include "StrainDependentPermeability.hpp"

#include "constitutive/permeability/PermeabilityFields.hpp"

namespace geos
{

using namespace dataRepository;

namespace constitutive
{


StrainDependentPermeability::StrainDependentPermeability( string const & name, Group * const parent ):
PermeabilityBase( name, parent )
{
registerWrapper( viewKeyStruct::referencePermeabilityComponentsString(), &m_referencePermeabilityComponents ).
setInputFlag( InputFlags::REQUIRED ).
setRestartFlags( RestartFlags::NO_WRITE ).
setDescription( "Reference xx, yy and zz components of a diagonal permeability tensor." );

registerWrapper( viewKeyStruct::strainDependenceConstantsString(), &m_strainDependenceConstants ).
setInputFlag( InputFlags::REQUIRED ).
setDescription( "Volumetric strain dependence coefficients for each permeability component." );

registerWrapper( viewKeyStruct::referencePermeabilityString(), &m_referencePermeability ).
setApplyDefaultValue( 0.0 ).
setPlotLevel( PlotLevel::LEVEL_0 ).
setDescription( "Reference permeability field" );

registerField< fields::permeability::dPerm_dVolStrain >( &m_dPerm_dVolStrain );
}

std::unique_ptr< ConstitutiveBase >
StrainDependentPermeability::deliverClone( string const & name,
Group * const parent ) const
{
return PermeabilityBase::deliverClone( name, parent );
}

void StrainDependentPermeability::allocateConstitutiveData( Group & parent,
localIndex const numPts )
{
// NOTE: enforcing 1 quadrature point
m_dPerm_dVolStrain.resize( 0, 1, 3 );

m_referencePermeability.resize( 0, 1, 3 );

PermeabilityBase::allocateConstitutiveData( parent, numPts );

integer constexpr numQuad = 1; // NOTE: enforcing 1 quadrature point

for( localIndex ei = 0; ei < parent.size(); ++ei )
{
for( localIndex q = 0; q < numQuad; ++q )
{
m_referencePermeability[ei][q][0] = m_referencePermeabilityComponents[0];
m_referencePermeability[ei][q][1] = m_referencePermeabilityComponents[1];
m_referencePermeability[ei][q][2] = m_referencePermeabilityComponents[2];
}
}
}

void StrainDependentPermeability::initializeState() const
{
localIndex const numE = m_permeability.size( 0 );
integer constexpr numQuad = 1; // NOTE: enforcing 1 quadrature point

auto permView = m_permeability.toView();
real64 const permComponents[3] = { m_referencePermeabilityComponents[0],
m_referencePermeabilityComponents[1],
m_referencePermeabilityComponents[2] };

forAll< parallelDevicePolicy<> >( numE, [=] GEOS_HOST_DEVICE ( localIndex const ei )
{
for( localIndex q = 0; q < numQuad; ++q )
{
for( integer dim=0; dim < 3; ++dim )
{
// The default value is -1 so if it still -1 it needs to be set to something physical
if( permView[ei][q][dim] < 0 )
{
permView[ei][q][dim] = permComponents[dim];
}
}
}
} );
}

void StrainDependentPermeability::postInputInitialization()
{}

REGISTER_CATALOG_ENTRY( ConstitutiveBase, StrainDependentPermeability, string const &, Group * const )

}
} /* namespace geos */
Loading
Loading