Skip to content
Snippets Groups Projects
Commit 4d984601 authored by Elias Pipping's avatar Elias Pipping Committed by Elias Pipping
Browse files

Use parset.sub

parent 41e7fbc3
No related branches found
No related tags found
No related merge requests found
...@@ -62,25 +62,24 @@ assemble_nonlinearity( ...@@ -62,25 +62,24 @@ assemble_nonlinearity(
typedef Dune::BlockVector<Dune::FieldVector<double, 1>> SingletonVectorType; typedef Dune::BlockVector<Dune::FieldVector<double, 1>> SingletonVectorType;
// {{{ Assemble terms for the nonlinearity // {{{ Assemble terms for the nonlinearity
auto mu = Dune::make_shared<SingletonVectorType>(size); auto mu = Dune::make_shared<SingletonVectorType>(size);
*mu = parset.get<double>("boundary.friction.mu"); *mu = parset.get<double>("mu");
auto normalStress = Dune::make_shared<SingletonVectorType>(size); auto normalStress = Dune::make_shared<SingletonVectorType>(size);
*normalStress = parset.get<double>("boundary.friction.normalstress"); *normalStress = parset.get<double>("normalstress");
std::string const friction_model = std::string const friction_model = parset.get<std::string>("model");
parset.get<std::string>("boundary.friction.model");
if (friction_model == std::string("Ruina")) { if (friction_model == std::string("Ruina")) {
auto a = Dune::make_shared<SingletonVectorType>(size); auto a = Dune::make_shared<SingletonVectorType>(size);
*a = parset.get<double>("boundary.friction.ruina.a"); *a = parset.get<double>("ruina.a");
auto eta = Dune::make_shared<SingletonVectorType>(size); auto eta = Dune::make_shared<SingletonVectorType>(size);
*eta = parset.get<double>("boundary.friction.eta"); *eta = parset.get<double>("eta");
auto b = Dune::make_shared<SingletonVectorType>(size); auto b = Dune::make_shared<SingletonVectorType>(size);
*b = parset.get<double>("boundary.friction.ruina.b"); *b = parset.get<double>("ruina.b");
auto L = Dune::make_shared<SingletonVectorType>(size); auto L = Dune::make_shared<SingletonVectorType>(size);
*L = parset.get<double>("boundary.friction.ruina.L"); *L = parset.get<double>("ruina.L");
return Dune::make_shared< return Dune::make_shared<
Dune::GlobalRuinaNonlinearity<VectorType, MatrixType> const>( Dune::GlobalRuinaNonlinearity<VectorType, MatrixType> const>(
......
...@@ -251,7 +251,8 @@ int main(int argc, char *argv[]) { ...@@ -251,7 +251,8 @@ int main(int argc, char *argv[]) {
++state_fpi) { ++state_fpi) {
auto myGlobalNonlinearity = auto myGlobalNonlinearity =
assemble_nonlinearity<VectorType, OperatorType>( assemble_nonlinearity<VectorType, OperatorType>(
finestSize, parset, nodalIntegrals, s4_new, h); finestSize, parset.sub("boundary.friction"), nodalIntegrals,
s4_new, h);
MyConvexProblemType const myConvexProblem(stiffnessMatrix, MyConvexProblemType const myConvexProblem(stiffnessMatrix,
*myGlobalNonlinearity, b4); *myGlobalNonlinearity, b4);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment