diff --git a/ProcessLib/HydroMechanics/HydroMechanicsFEM-impl.h b/ProcessLib/HydroMechanics/HydroMechanicsFEM-impl.h index 0314b9ef73ecb93c14f689158d708e80294ae846..443842ba1c7246b392dda695dac00564186b0bde 100644 --- a/ProcessLib/HydroMechanics/HydroMechanicsFEM-impl.h +++ b/ProcessLib/HydroMechanics/HydroMechanicsFEM-impl.h @@ -826,6 +826,15 @@ std::size_t HydroMechanicsLocalAssembler< if (name == "sigma_ip") { + if (_process_data.initial_stress != nullptr) + { + OGS_FATAL( + "Setting initial conditions for stress from integration " + "point data and from a parameter '{:s}' is not possible " + "simultaneously.", + _process_data.initial_stress->name); + } + return setSigma(values); } if (name == "epsilon_ip") diff --git a/ProcessLib/HydroMechanics/HydroMechanicsProcess.cpp b/ProcessLib/HydroMechanics/HydroMechanicsProcess.cpp index f51e137eef9ee3fa37fb0c76a724069e2ae6fe5f..896af9295be33ce3742ff50f613deffef7b94cbe 100644 --- a/ProcessLib/HydroMechanics/HydroMechanicsProcess.cpp +++ b/ProcessLib/HydroMechanics/HydroMechanicsProcess.cpp @@ -50,7 +50,7 @@ HydroMechanicsProcess<DisplacementDim>::HydroMechanicsProcess( std::make_unique<IntegrationPointWriter>( "sigma_ip", static_cast<int>(mesh.getDimension() == 2 ? 4 : 6) /*n components*/, - 2 /*integration order*/, [this]() { + integration_order, [this]() { // Result containing integration point data for each local // assembler. std::vector<std::vector<double>> result; @@ -70,7 +70,7 @@ HydroMechanicsProcess<DisplacementDim>::HydroMechanicsProcess( std::make_unique<IntegrationPointWriter>( "epsilon_ip", static_cast<int>(mesh.getDimension() == 2 ? 4 : 6) /*n components*/, - 2 /*integration order*/, [this]() { + integration_order, [this]() { // Result containing integration point data for each local // assembler. std::vector<std::vector<double>> result;