Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
dumux-repositories
dumux-lecture
Commits
594ef5a1
Commit
594ef5a1
authored
Nov 03, 2020
by
Ned Coltman
Browse files
[mm][henryproblem] adapt to new material laws
parent
393ec3a5
Changes
2
Hide whitespace changes
Inline
Side-by-side
lecture/mm/henryproblem/henry1p2c/henry1p2cspatialparameters.hh
View file @
594ef5a1
...
...
@@ -27,7 +27,6 @@
#include <dumux/material/spatialparams/fv.hh>
#include <dumux/material/fluidmatrixinteractions/2p/linearmaterial.hh>
#include <dumux/material/fluidmatrixinteractions/2p/efftoabslaw.hh>
namespace
Dumux
{
...
...
@@ -68,9 +67,7 @@ public:
* \param globalPos The global position
*/
PermeabilityType
permeabilityAtPos
(
const
GlobalPosition
&
globalPos
)
const
{
return
perm_
;
}
{
return
perm_
;
}
/*!
* \brief Define the porosity \f$\mathrm{[-]}\f$.
...
...
@@ -78,9 +75,7 @@ public:
* \param globalPos The global position
*/
double
porosityAtPos
(
const
GlobalPosition
&
globalPos
)
const
{
return
porosity_
;
}
{
return
porosity_
;
}
private:
...
...
lecture/mm/henryproblem/henry2p/henry2pspatialparams.hh
View file @
594ef5a1
...
...
@@ -27,8 +27,6 @@
#include <dumux/material/spatialparams/fv.hh>
#include <dumux/material/fluidmatrixinteractions/2p/linearmaterial.hh>
#include <dumux/material/fluidmatrixinteractions/2p/efftoabslaw.hh>
#include <dumux/porousmediumflow/2p/model.hh>
namespace
Dumux
{
...
...
@@ -51,12 +49,10 @@ public FVSpatialParams<FVGridGeometry, Scalar, Henry2pSpatialParams<FVGridGeomet
static
constexpr
int
dimWorld
=
GridView
::
dimensionworld
;
using
GlobalPosition
=
typename
Element
::
Geometry
::
GlobalCoordinate
;
using
PcKrSwCurve
=
FluidMatrix
::
LinearMaterialDefault
<
Scalar
>
;
public:
using
PermeabilityType
=
Scalar
;
//get the material law from the property system
using
EffectiveLaw
=
LinearMaterial
<
Scalar
>
;
using
MaterialLaw
=
EffToAbsLaw
<
EffectiveLaw
>
;
using
MaterialLawParams
=
typename
MaterialLaw
::
Params
;
Henry2pSpatialParams
(
std
::
shared_ptr
<
const
FVGridGeometry
>
fvGridGeometry
)
:
ParentType
(
fvGridGeometry
)
...
...
@@ -72,15 +68,8 @@ public:
std
::
cerr
<<
"Unknown exception thrown!
\n
"
;
exit
(
1
);
}
// residual saturations
materialParams_
.
setSwr
(
0.0
);
materialParams_
.
setSnr
(
0.0
);
// parameters for the linear law
// entry pc and max pc
materialParams_
.
setEntryPc
(
0
);
materialParams_
.
setMaxPc
(
0
);
typename
PcKrSwCurve
::
BasicParams
params
(
0.0
/*pcEntry*/
,
0.0
/*pcMax*/
);
pcKrSwCurve_
=
std
::
make_unique
<
PcKrSwCurve
>
(
params
);
K_
=
1.019368e-9
;
porosity_
=
0.35
;
...
...
@@ -92,9 +81,7 @@ public:
* \param globalPos The global position
*/
PermeabilityType
permeabilityAtPos
(
const
GlobalPosition
&
globalPos
)
const
{
return
K_
;
}
{
return
K_
;
}
/*!
* \brief Define the porosity \f$\mathrm{[-]}\f$.
...
...
@@ -102,22 +89,17 @@ public:
* \param globalPos The global position
*/
double
porosityAtPos
(
const
GlobalPosition
&
globalPos
)
const
{
return
porosity_
;
}
{
return
porosity_
;
}
/*!
* \brief Function for defining the parameters needed by constitutive relationships (kr-sw, pc-sw, etc.).
*
* \param element The current element
* \param fvElemGeom The current finite volume geometry of the element
* \param scvIdx The index of the sub-control volume.
* \param globalPos The global position
* \return the material parameters object
*/
const
MaterialLawParams
&
materialLawParamsAtPos
(
const
GlobalPosition
&
globalPos
)
const
{
return
materialParams_
;
}
auto
fluidMatrixInteractionAtPos
(
const
GlobalPosition
&
globalPos
)
const
{
return
makeFluidMatrixInteraction
(
*
pcKrSwCurve_
);
}
/*!
* \brief Function for defining which phase is to be considered as the wetting phase.
...
...
@@ -127,14 +109,13 @@ public:
*/
template
<
class
FluidSystem
>
int
wettingPhaseAtPos
(
const
GlobalPosition
&
globalPos
)
const
{
return
FluidSystem
::
phase0Idx
;
}
{
return
FluidSystem
::
phase0Idx
;
}
private:
Scalar
K_
;
Scalar
porosity_
;
MaterialLawParams
materialParams_
;
std
::
unique_ptr
<
PcKrSwCurve
>
pcKrSwCurve_
;
};
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment