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

[GeoMechanicsApplication] Implement well constitutive behaviour for line pressure element #12997

Merged
merged 28 commits into from
Jan 28, 2025
Merged
Show file tree
Hide file tree
Changes from 7 commits
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
399a931
test cases for pressure filter are added
mnabideltares Jan 9, 2025
f5e113b
Added the projected gravity to the body forve vector.
mnabideltares Jan 9, 2025
6ff43bf
Added a new compressibility calculator for filter calculations, which…
rfaasse Jan 9, 2025
4d27652
Documentation is added
mnabideltares Jan 10, 2025
5be7ec0
fix
mnabideltares Jan 10, 2025
55c094e
Modifications based on review
mnabideltares Jan 10, 2025
0b630c8
clang format
mnabideltares Jan 13, 2025
af1d84d
Fix
mnabideltares Jan 13, 2025
e9ffca6
Fixes based on review
mnabideltares Jan 13, 2025
007bf56
Fixes based on review
mnabideltares Jan 14, 2025
f2d2ab7
Fixes based on review
mnabideltares Jan 14, 2025
5448435
fixes in test cases
mnabideltares Jan 15, 2025
1f59195
Documentation for Pw filter element is added
mnabideltares Jan 16, 2025
d8fdbf9
fixes in documentation
mnabideltares Jan 16, 2025
ee012e8
fix
mnabideltares Jan 16, 2025
b3781a2
fix
mnabideltares Jan 16, 2025
0e51c44
fixes in documentation
mnabideltares Jan 16, 2025
e2025ac
changes bases on review
mnabideltares Jan 16, 2025
3df9612
A small fix
mnabideltares Jan 16, 2025
e2e3501
Added documentation for Pw element
mnabideltares Jan 21, 2025
3c2073d
fix in documentation
mnabideltares Jan 23, 2025
c631447
Fixes in documentation
mnabideltares Jan 23, 2025
10a1a9e
doc
mnabideltares Jan 23, 2025
e09b5cc
fix
mnabideltares Jan 23, 2025
42287ba
Merge branch 'master' into geo/12323-implement-pw-well-element-2
mnabideltares Jan 24, 2025
66659d6
fix in documentation
mnabideltares Jan 24, 2025
6f55bb6
fix in readme
mnabideltares Jan 24, 2025
3d680d3
fix in doc
mnabideltares Jan 24, 2025
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
49 changes: 49 additions & 0 deletions applications/GeoMechanicsApplication/custom_elements/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -175,5 +175,54 @@ where
The superscripts $^l$ and $^r$ for Robin boundary condition indicate the left hands side (matrix) and right hand side (vector), respectively. The superscripts $^e$ and $^{ep}$ for $\Omega$ and $\Gamma$ indicate values in the element volume and perpendicular to element boundaries, respectively.


# Pressure Filter Line Element
For laminar flow along the axis of the well and uniformly distributed storage over the length of the well bore (Diersch, 2014)

```math
\pi R^2 \left( \frac{1}{l_w} + \rho_0 g \beta \right) \frac{\partial h}{\partial t} - \pi R^2 K_w \frac{\partial}{\partial y} \left[ f_{\mu} \left( \frac{\partial h}{\partial y} + \chi e \right)\right] = -Q_w \delta \left( y - y_w \right)
```

where

```math
K_w = \frac{R^2 \rho_0 g}{8 \mu_0} \quad \quad \quad \quad f_u = \frac{\mu_0}{\mu} \quad \quad \quad \quad \chi = \frac{\rho - \rho_0}{\rho_0} \quad \quad \quad \quad h = \frac{p}{\rho_0 g} + y
```

- $Q_w$ = pumping rate sink $\mathrm{\left[ m^3/s \right]}$
- $t$ = time $\mathrm{\left[ s \right]}$
- $y$ = vertical coordinate $\mathrm{\left[ m \right]}$
- $y_w$ = location of the discharge point $\mathrm{\left[ m \right]}$
- $h$ = hydraulic head in the well $\mathrm{\left[ m \right]}$
- $l_w$ = total length of liquid filled well bore $\mathrm{\left[ m \right]}$
- $R$ = radius of the well casing $\mathrm{\left[ m \right]}$
- $K_w$ = Hagen-Poiseuille permeability $\mathrm{\left[ m \right]}$
- $\delta$ = Dirichlet delta function $\mathrm{\left[ - \right]}$
- $\beta$ = compressibility of the liquid $\mathrm{\left[ m^2/N \right]}$
- $f_{\mu}$ = viscosity relation function of liquid $\mathrm{\left[ - \right]}$
- $\chi$ = buoyancy coefficient $\mathrm{\left[ - \right]}$
- $e$ = gravitational unit vector $\mathrm{\left[ - \right]}$
- $g$ = gravitational acceleration $\mathrm{\left[ m/s^2 \right]}$
- $\rho_0$ = reference density of the fluid $\mathrm{\left[ kg/m^3 \right]}$
- $\mu_0$ = reference viscosity of the fluid $\mathrm{\left[ Pas \right]}$
- $p$ = liquid pressure $\mathrm{\left[ Pa \right]}$

reformulated in pressure and preserving mass

```math
\rho^w \left( \frac{1}{\rho^w g l_w} + \beta \right) \frac{\partial p}{\partial t} - \rho^w \frac{\partial}{\partial y} \left[ \frac{R^2}{8 \mu} \left( \frac{\partial p}{\partial y} - \rho^w g \right)\right] = -\frac{\rho^w Q_w}{\pi R^2}
```

The one dimensionalpressure equation with $\alpha = 1$ and $n = 1$ captures the well flow equation.

```math
\rho^w \beta^* \frac{\partial p}{\partial t} - \frac{\partial}{\partial y} \left[ \frac{\rho^w K^*}{\mu} \left( \frac{\partial p}{\partial y} - \rho^w g \right) \right] = - \rho^w Q^*_w
```

where the intrinsic permeability and boundary condition are given by

```math
\beta^* = \frac{1}{\rho^w g l_w} + \beta \quad \quad \quad \quad K^* = \frac{R^2}{8} \quad \quad \quad \quad Q^*_w = \frac{Q_w}{\pi R^2}
```

## Bibliography
Diersch, H.-J. G., 2014. FEFLOW; Finite Element Modeling of Flow, Mass and Heat Transport in Porous and Fractured Media. Springer.
Original file line number Diff line number Diff line change
Expand Up @@ -68,10 +68,8 @@ Matrix FilterCompressibilityCalculator::CalculateCompressibilityMatrix() const
double FilterCompressibilityCalculator::CalculateElasticCapacity(double ProjectedGravity) const
{
const auto& r_properties = mInputProvider.GetElementProperties();
const double result =
1.0 / (r_properties[DENSITY_WATER] * ProjectedGravity * r_properties[FILTER_LENGTH]) +
1.0 / r_properties[BULK_MODULUS_FLUID];
return result;
return 1.0 / (r_properties[DENSITY_WATER] * ProjectedGravity * r_properties[FILTER_LENGTH]) +
1.0 / r_properties[BULK_MODULUS_FLUID];
}

const Properties& FilterCompressibilityCalculator::InputProvider::GetElementProperties() const
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -281,9 +281,8 @@ class KRATOS_API(GEO_MECHANICS_APPLICATION) TransientPwLineElement : public Elem
{
const auto number_integration_points = GetGeometry().IntegrationPointsNumber(GetIntegrationMethod());
GeometryType::JacobiansType J_container{number_integration_points};
for (std::size_t i = 0; i < number_integration_points; ++i) {
J_container[i].resize(GetGeometry().WorkingSpaceDimension(),
GetGeometry().LocalSpaceDimension(), false);
for (auto& container : J_container) {
Copy link
Contributor

Choose a reason for hiding this comment

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

If I'm correct in other parts of the code this is called j:

Suggested change
for (auto& container : J_container) {
for (auto& j : J_container) {

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done

container.resize(GetGeometry().WorkingSpaceDimension(), GetGeometry().LocalSpaceDimension(), false);
}
GetGeometry().Jacobian(J_container, this->GetIntegrationMethod());

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,14 @@
"name" : "GeoLinearElasticPlaneStrain2DLaw"
},
"Variables" : {
"IGNORE_UNDRAINED" : false,
"DENSITY_SOLID" : 2.650000e+03,
"DENSITY_WATER" : 1.000000e+03,
"POROSITY" : 1.000000e-01,
"BULK_MODULUS_SOLID" : 9.000000e+19,
"BULK_MODULUS_FLUID" : 1.000000e+20,
"PERMEABILITY_XX" : 9.084000e-06,
"DYNAMIC_VISCOSITY" : 1.000000e-03,
"BIOT_COEFFICIENT" : 1.000000e+00,
"RETENTION_LAW" : "PressureFilterLaw",
"CROSS_AREA" : 1.0,
"FILTER_LENGTH" : 3.0
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,14 @@
"name" : "GeoIncrementalLinearElastic3DLaw"
},
"Variables" : {
"IGNORE_UNDRAINED" : false,
"DENSITY_SOLID" : 2.650000e+03,
"DENSITY_WATER" : 1.000000e+03,
"POROSITY" : 1.000000e-01,
"BULK_MODULUS_SOLID" : 9.000000e+19,
"BULK_MODULUS_FLUID" : 1.000000e+20,
"PERMEABILITY_XX" : 9.084000e-06,
"DYNAMIC_VISCOSITY" : 1.000000e-03,
"BIOT_COEFFICIENT" : 1.000000e+00,
"RETENTION_LAW" : "PressureFilterLaw",
"CROSS_AREA" : 1.0,
"FILTER_LENGTH" : 3.0
Expand Down
Loading