diff --git a/src/elasticity/solvers/ElasticitySolver.cpp b/src/elasticity/solvers/ElasticitySolver.cpp index 3016f2c7d9ea1ac6a49c4a6cd938e247e8c2b9d8..d45e1a3b261ce60a6caf3d4ba70ce96094d3a6ca 100644 --- a/src/elasticity/solvers/ElasticitySolver.cpp +++ b/src/elasticity/solvers/ElasticitySolver.cpp @@ -11,10 +11,14 @@ std::unique_ptr<CardiacSolverT<IElasticity>> GetElasticitySolver() { if (runtype == "Exact") { return std::make_unique<ExactMechanicsSolver>(); - } else if (runtype == "Klotz") { + } + + if (runtype == "Klotz") { // Generate KlotzPressureSolver in src/elasticity/solvers/IterativePressureSolver.hpp return std::make_unique<KlotzPressureSolver>(); - } else if (runtype == "Default") { + } + + if (runtype == "Default") { if (dyn == "Static") { // Generate IterativePressureSolver in src/elasticity/solvers/IterativePressureSolver.hpp return std::make_unique<IterativePressureSolver>(); @@ -23,4 +27,6 @@ std::unique_ptr<CardiacSolverT<IElasticity>> GetElasticitySolver() { return std::make_unique<ElastodynamicTimeIntegrator>(dyn); } } + + Exit("No solver for RunType " + runtype + " implemented") }