OGS
CreateKozenyCarmanModel.cpp
Go to the documentation of this file.
1
10
#include "
CreateKozenyCarmanModel.h
"
11
12
#include "
BaseLib/ConfigTree.h
"
13
#include "
KozenyCarmanModel.h
"
14
#include "
ParameterLib/Utils.h
"
15
16
namespace
MaterialPropertyLib
17
{
18
std::unique_ptr<Property>
createKozenyCarmanModel
(
19
BaseLib::ConfigTree
const
& config,
20
std::vector<std::unique_ptr<ParameterLib::ParameterBase>>
const
& parameters)
21
{
23
config.
checkConfigParameter
(
"type"
,
"KozenyCarman"
);
24
DBUG
(
"Create Kozeny-Carman model."
);
25
26
auto
const
& k0 =
ParameterLib::findParameter<double>
(
28
config.
getConfigParameter
<std::string>(
"initial_permeability"
),
29
parameters, 0,
nullptr
);
30
31
auto
const
& phi0 =
ParameterLib::findParameter<double>
(
33
config.
getConfigParameter
<std::string>(
"initial_porosity"
), parameters,
34
1,
nullptr
);
35
36
return
std::make_unique<KozenyCarmanModel>(k0, phi0);
37
}
38
}
// namespace MaterialPropertyLib
ConfigTree.h
CreateKozenyCarmanModel.h
KozenyCarmanModel.h
DBUG
void DBUG(fmt::format_string< Args... > fmt, Args &&... args)
Definition
Logging.h:30
Utils.h
BaseLib::ConfigTree
Definition
ConfigTree.h:107
BaseLib::ConfigTree::getConfigParameter
T getConfigParameter(std::string const ¶m) const
Definition
ConfigTree-impl.h:41
BaseLib::ConfigTree::checkConfigParameter
void checkConfigParameter(std::string const ¶m, std::string_view const value) const
Definition
ConfigTree.cpp:151
MaterialPropertyLib
Definition
ChemicalSolverInterface.h:21
MaterialPropertyLib::createKozenyCarmanModel
std::unique_ptr< Property > createKozenyCarmanModel(BaseLib::ConfigTree const &config, std::vector< std::unique_ptr< ParameterLib::ParameterBase > > const ¶meters)
Definition
CreateKozenyCarmanModel.cpp:18
ParameterLib::findParameter
OGS_NO_DANGLING Parameter< ParameterDataType > & findParameter(std::string const ¶meter_name, std::vector< std::unique_ptr< ParameterBase > > const ¶meters, int const num_components, MeshLib::Mesh const *const mesh=nullptr)
Definition
Utils.h:102
MaterialLib
MPL
Properties
CreateKozenyCarmanModel.cpp
Generated by
1.12.0