From 93e1263d0ac8b4ee2e4c86939cf2b2e1077a8823 Mon Sep 17 00:00:00 2001 From: Wijtze Pieter Kikstra Date: Tue, 15 Oct 2024 11:21:25 +0200 Subject: [PATCH 01/36] Avoid zero divisions + a lot of printing --- .../small_strain_U_Pw_diff_order_element.cpp | 47 +++++++++++++++---- .../residualbased_block_builder_and_solver.h | 3 ++ .../residualbased_newton_raphson_strategy.h | 6 +++ 3 files changed, 48 insertions(+), 8 deletions(-) diff --git a/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp b/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp index 8c8d588186cd..35fd063a6f52 100644 --- a/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp +++ b/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp @@ -1275,8 +1275,13 @@ void SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingMatrix(MatrixType& r GeoElementUtilities::AssembleUPBlockMatrix(rLeftHandSideMatrix, CouplingMatrix); if (!rVariables.IgnoreUndrained) { - const double SaturationCoefficient = rVariables.DegreeOfSaturation / rVariables.BishopCoefficient; - Matrix CouplingMatrixT = PORE_PRESSURE_SIGN_FACTOR * SaturationCoefficient * + //const double SaturationCoefficient = rVariables.DegreeOfSaturation / rVariables.BishopCoefficient; + //Matrix CouplingMatrixT = PORE_PRESSURE_SIGN_FACTOR * SaturationCoefficient * + // rVariables.VelocityCoefficient * trans(CouplingMatrix); + Matrix CouplingMatrix = GeoTransportEquationUtilities::CalculateCouplingMatrix( + rVariables.B, GetStressStatePolicy().GetVoigtVector(), rVariables.Np, + rVariables.BiotCoefficient, rVariables.DegreeOfSaturation, rVariables.IntegrationCoefficient); + Matrix CouplingMatrixT = PORE_PRESSURE_SIGN_FACTOR * rVariables.VelocityCoefficient * trans(CouplingMatrix); GeoElementUtilities::AssemblePUBlockMatrix(rLeftHandSideMatrix, CouplingMatrixT); } @@ -1329,7 +1334,9 @@ void SmallStrainUPwDiffOrderElement::CalculateAndAddStiffnessForce(VectorType& r Vector stiffness_force = -1.0 * prod(trans(rVariables.B), mStressVector[GPoint]) * rVariables.IntegrationCoefficient; + KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddStiffnessForce ") << "dF = " << stiffness_force << std::endl; GeoElementUtilities::AssembleUBlockVector(rRightHandSideVector, stiffness_force); + KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddStiffnessForce ") << "RHS = " << rRightHandSideVector << std::endl; KRATOS_CATCH("") } @@ -1361,6 +1368,7 @@ void SmallStrainUPwDiffOrderElement::CalculateAndAddMixBodyForce(VectorType& rRi rVariables.IntegrationCoefficientInitialConfiguration; } } + KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddBodyForce ") << "RHS = " << rRightHandSideVector << std::endl; KRATOS_CATCH("") } @@ -1375,13 +1383,26 @@ void SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingTerms(VectorType& rR rVariables.B, GetStressStatePolicy().GetVoigtVector(), rVariables.Np, rVariables.BiotCoefficient, rVariables.BishopCoefficient, rVariables.IntegrationCoefficient); const Vector coupling_force = prod(coupling_matrix, rVariables.PressureVector); + KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingTerms ") << "v = " << rVariables.VelocityVector << std::endl; + KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingTerms ") << "Pw = " << rVariables.PressureVector << std::endl; + KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingTerms ") << "dF = " << coupling_force << std::endl; GeoElementUtilities::AssembleUBlockVector(rRightHandSideVector, coupling_force); + KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingTerms ") << "RHS = " << rRightHandSideVector << std::endl; if (!rVariables.IgnoreUndrained) { - const double SaturationCoefficient = rVariables.DegreeOfSaturation / rVariables.BishopCoefficient; - const Vector coupling_flow = PORE_PRESSURE_SIGN_FACTOR * SaturationCoefficient * + //const double SaturationCoefficient = rVariables.DegreeOfSaturation / rVariables.BishopCoefficient; + //const Vector coupling_flow = PORE_PRESSURE_SIGN_FACTOR * SaturationCoefficient * + // prod(trans(coupling_matrix), rVariables.VelocityVector); + const Matrix coupling_matrix = + (-1.0) * GeoTransportEquationUtilities::CalculateCouplingMatrix( + rVariables.B, GetStressStatePolicy().GetVoigtVector(), rVariables.Np, + rVariables.BiotCoefficient, rVariables.DegreeOfSaturation, rVariables.IntegrationCoefficient); + const Vector coupling_flow = PORE_PRESSURE_SIGN_FACTOR * prod(trans(coupling_matrix), rVariables.VelocityVector); + KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingTerms ") << "v = " << rVariables.VelocityVector << std::endl; + KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingTerms ") << "dQ = " << coupling_flow << std::endl; GeoElementUtilities::AssemblePBlockVector(rRightHandSideVector, coupling_flow); + KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingTerms ") << "RHS = " << rRightHandSideVector << std::endl; } KRATOS_CATCH("") @@ -1395,7 +1416,10 @@ void SmallStrainUPwDiffOrderElement::CalculateAndAddCompressibilityFlow(VectorTy Matrix CompressibilityMatrix = GeoTransportEquationUtilities::CalculateCompressibilityMatrix( rVariables.Np, rVariables.BiotModulusInverse, rVariables.IntegrationCoefficient); Vector CompressibilityFlow = -prod(CompressibilityMatrix, rVariables.PressureDtVector); + KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCompressibilityFlow") << "dPdt= " << rVariables.PressureDtVector << std::endl; + KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCompressibilityFlow") << "dQ = " << CompressibilityFlow << std::endl; GeoElementUtilities::AssemblePBlockVector(rRightHandSideVector, CompressibilityFlow); + KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCompressibilityFlow") << "RHS = " << rRightHandSideVector << std::endl; KRATOS_CATCH("") } @@ -1442,7 +1466,9 @@ void SmallStrainUPwDiffOrderElement::CalculateAndAddPermeabilityFlow(VectorType& const Vector permeability_flow = -prod(permeability_matrix, rVariables.PressureVector); + KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddPermeabilityFlow ") << "dQ = " << permeability_flow << std::endl; GeoElementUtilities::AssemblePBlockVector(rRightHandSideVector, permeability_flow); + KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddPermeabilityFlow ") << "RHS = " << rRightHandSideVector << std::endl; KRATOS_CATCH("") } @@ -1471,10 +1497,15 @@ void SmallStrainUPwDiffOrderElement::CalculateAndAddFluidBodyFlow(VectorType& rR } } - for (SizeType i = 0; i < num_P_nodes; ++i) { - rRightHandSideVector[num_U_nodes * dimension + i] += - inner_prod(row(grad_Np_T_perm, i), body_acceleration); - } + const Vector fluid_body_flow = prod(grad_Np_T_perm, body_acceleration); + GeoElementUtilities::AssemblePBlockVector(rRightHandSideVector, fluid_body_flow); + KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddFluidBodyFlow ") << "dQ = " << fluid_body_flow << std::endl; + + //for (SizeType i = 0; i < num_P_nodes; ++i) { + // rRightHandSideVector[num_U_nodes * dimension + i] += + // inner_prod(row(grad_Np_T_perm, i), body_acceleration); + //} + KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddFluidBodyFlow ") << "RHS = " << rRightHandSideVector << std::endl; KRATOS_CATCH("") } diff --git a/kratos/solving_strategies/builder_and_solvers/residualbased_block_builder_and_solver.h b/kratos/solving_strategies/builder_and_solvers/residualbased_block_builder_and_solver.h index e3711dcd300c..40ab23df36c9 100644 --- a/kratos/solving_strategies/builder_and_solvers/residualbased_block_builder_and_solver.h +++ b/kratos/solving_strategies/builder_and_solvers/residualbased_block_builder_and_solver.h @@ -450,6 +450,8 @@ class ResidualBasedBlockBuilderAndSolver else norm_b = 0.00; + KRATOS_INFO("ResidualBasedBlockBuilderAndSolver") << "Norm RHS = " << norm_b << std::endl; + if (norm_b != 0.00) { //provide physical data as needed if(BaseType::mpLinearSystemSolver->AdditionalPhysicalDataIsNeeded() ) @@ -1193,6 +1195,7 @@ class ResidualBasedBlockBuilderAndSolver virtual void ConstructMasterSlaveConstraintsStructure(ModelPart& rModelPart) { + KRATOS_INFO("ConstructMasterSlaveConstraintsStructure") << "Number of constraints: " << rModelPart.MasterSlaveConstraints().size() << std::endl; if (rModelPart.MasterSlaveConstraints().size() > 0) { Timer::Start("ConstraintsRelationMatrixStructure"); const ProcessInfo& r_current_process_info = rModelPart.GetProcessInfo(); diff --git a/kratos/solving_strategies/strategies/residualbased_newton_raphson_strategy.h b/kratos/solving_strategies/strategies/residualbased_newton_raphson_strategy.h index 69f747077aff..1a6effaf6845 100644 --- a/kratos/solving_strategies/strategies/residualbased_newton_raphson_strategy.h +++ b/kratos/solving_strategies/strategies/residualbased_newton_raphson_strategy.h @@ -938,6 +938,9 @@ class ResidualBasedNewtonRaphsonStrategy //initializing the parameters of the Newton-Raphson cycle unsigned int iteration_number = 1; + KRATOS_INFO_IF("ResidualBasedNewtonRaphsonStrategy", this->GetEchoLevel() > 0) + << "Started iteration " << iteration_number << " of " + << mMaxIterationNumber << " iterations" << std::endl; r_model_part.GetProcessInfo()[NL_ITERATION_NUMBER] = iteration_number; bool residual_is_updated = false; p_scheme->InitializeNonLinIteration(r_model_part, rA, rDx, rb); @@ -991,6 +994,9 @@ class ResidualBasedNewtonRaphsonStrategy while (is_converged == false && iteration_number++ < mMaxIterationNumber) { + KRATOS_INFO_IF("ResidualBasedNewtonRaphsonStrategy", this->GetEchoLevel() > 0) + << "Started iteration " << iteration_number << " of " + << mMaxIterationNumber << " iterations" << std::endl; //setting the number of iteration r_model_part.GetProcessInfo()[NL_ITERATION_NUMBER] = iteration_number; From 6fcc7fa687308abf2dee2bef681153ef21800c70 Mon Sep 17 00:00:00 2001 From: Anne van de Graaf Date: Fri, 25 Oct 2024 17:29:42 +0200 Subject: [PATCH 02/36] Removed an unused variable and some commented out code --- .../custom_elements/small_strain_U_Pw_diff_order_element.cpp | 5 ----- 1 file changed, 5 deletions(-) diff --git a/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp b/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp index 35fd063a6f52..ddd40507af8e 100644 --- a/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp +++ b/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp @@ -1485,7 +1485,6 @@ void SmallStrainUPwDiffOrderElement::CalculateAndAddFluidBodyFlow(VectorType& rR const GeometryType& r_geom = GetGeometry(); const SizeType dimension = r_geom.WorkingSpaceDimension(); const SizeType num_U_nodes = r_geom.PointsNumber(); - const SizeType num_P_nodes = mpPressureGeometry->PointsNumber(); Vector body_acceleration = ZeroVector(dimension); @@ -1501,10 +1500,6 @@ void SmallStrainUPwDiffOrderElement::CalculateAndAddFluidBodyFlow(VectorType& rR GeoElementUtilities::AssemblePBlockVector(rRightHandSideVector, fluid_body_flow); KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddFluidBodyFlow ") << "dQ = " << fluid_body_flow << std::endl; - //for (SizeType i = 0; i < num_P_nodes; ++i) { - // rRightHandSideVector[num_U_nodes * dimension + i] += - // inner_prod(row(grad_Np_T_perm, i), body_acceleration); - //} KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddFluidBodyFlow ") << "RHS = " << rRightHandSideVector << std::endl; KRATOS_CATCH("") From 37758a76c9baa7ac71215fe49476ffae7dcf8edf Mon Sep 17 00:00:00 2001 From: Wijtze Pieter Kikstra Date: Fri, 6 Dec 2024 10:15:50 +0100 Subject: [PATCH 03/36] Fix effective saturation. Commented print statements. --- .../small_strain_U_Pw_diff_order_element.cpp | 87 +++++++++++-------- .../saturated_below_phreatic_level_law.cpp | 60 ++++--------- 2 files changed, 68 insertions(+), 79 deletions(-) diff --git a/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp b/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp index ddd40507af8e..23f2b5b1edee 100644 --- a/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp +++ b/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp @@ -860,7 +860,9 @@ void SmallStrainUPwDiffOrderElement::CalculateAll(MatrixType& rLeftHandSi bool CalculateResidualVectorFlag) { KRATOS_TRY - + if (this->Id() == 1 || this->Id() == 13) { + KRATOS_INFO("Element = ") << this->Id() << std::endl; + } const PropertiesType& rProp = this->GetProperties(); const GeometryType& rGeom = GetGeometry(); const GeometryType::IntegrationPointsArrayType& IntegrationPoints = @@ -1275,14 +1277,14 @@ void SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingMatrix(MatrixType& r GeoElementUtilities::AssembleUPBlockMatrix(rLeftHandSideMatrix, CouplingMatrix); if (!rVariables.IgnoreUndrained) { - //const double SaturationCoefficient = rVariables.DegreeOfSaturation / rVariables.BishopCoefficient; - //Matrix CouplingMatrixT = PORE_PRESSURE_SIGN_FACTOR * SaturationCoefficient * - // rVariables.VelocityCoefficient * trans(CouplingMatrix); + // const double SaturationCoefficient = rVariables.DegreeOfSaturation / rVariables.BishopCoefficient; + // Matrix CouplingMatrixT = PORE_PRESSURE_SIGN_FACTOR * SaturationCoefficient * + // rVariables.VelocityCoefficient * trans(CouplingMatrix); Matrix CouplingMatrix = GeoTransportEquationUtilities::CalculateCouplingMatrix( rVariables.B, GetStressStatePolicy().GetVoigtVector(), rVariables.Np, rVariables.BiotCoefficient, rVariables.DegreeOfSaturation, rVariables.IntegrationCoefficient); - Matrix CouplingMatrixT = PORE_PRESSURE_SIGN_FACTOR * - rVariables.VelocityCoefficient * trans(CouplingMatrix); + Matrix CouplingMatrixT = + PORE_PRESSURE_SIGN_FACTOR * rVariables.VelocityCoefficient * trans(CouplingMatrix); GeoElementUtilities::AssemblePUBlockMatrix(rLeftHandSideMatrix, CouplingMatrixT); } @@ -1334,10 +1336,11 @@ void SmallStrainUPwDiffOrderElement::CalculateAndAddStiffnessForce(VectorType& r Vector stiffness_force = -1.0 * prod(trans(rVariables.B), mStressVector[GPoint]) * rVariables.IntegrationCoefficient; - KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddStiffnessForce ") << "dF = " << stiffness_force << std::endl; GeoElementUtilities::AssembleUBlockVector(rRightHandSideVector, stiffness_force); - KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddStiffnessForce ") << "RHS = " << rRightHandSideVector << std::endl; - + // if ( this->Id() == 1 || this->Id() == 13 ) { + // KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddStiffnessForce ") << "dF = " << stiffness_force << std::endl; + // KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddStiffnessForce ") << "RHS = " << rRightHandSideVector << std::endl; + // } KRATOS_CATCH("") } @@ -1368,7 +1371,9 @@ void SmallStrainUPwDiffOrderElement::CalculateAndAddMixBodyForce(VectorType& rRi rVariables.IntegrationCoefficientInitialConfiguration; } } - KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddBodyForce ") << "RHS = " << rRightHandSideVector << std::endl; + // if ( this->Id() == 1 || this->Id() == 13 ) { + // KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddBodyForce ") << "RHS = " << rRightHandSideVector << std::endl; + // } KRATOS_CATCH("") } @@ -1383,26 +1388,32 @@ void SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingTerms(VectorType& rR rVariables.B, GetStressStatePolicy().GetVoigtVector(), rVariables.Np, rVariables.BiotCoefficient, rVariables.BishopCoefficient, rVariables.IntegrationCoefficient); const Vector coupling_force = prod(coupling_matrix, rVariables.PressureVector); - KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingTerms ") << "v = " << rVariables.VelocityVector << std::endl; - KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingTerms ") << "Pw = " << rVariables.PressureVector << std::endl; - KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingTerms ") << "dF = " << coupling_force << std::endl; GeoElementUtilities::AssembleUBlockVector(rRightHandSideVector, coupling_force); - KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingTerms ") << "RHS = " << rRightHandSideVector << std::endl; + // if ( this->Id() == 1 || this->Id() == 13 ) { + // KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingTerms ") << "v + // = " << rVariables.VelocityVector << std::endl; KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingTerms + // ") << "Pw = " << rVariables.PressureVector << std::endl; KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingTerms + // ") << "dF = " << coupling_force << std::endl; KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingTerms + // ") << "RHS = " << rRightHandSideVector << std::endl; + // } if (!rVariables.IgnoreUndrained) { - //const double SaturationCoefficient = rVariables.DegreeOfSaturation / rVariables.BishopCoefficient; - //const Vector coupling_flow = PORE_PRESSURE_SIGN_FACTOR * SaturationCoefficient * - // prod(trans(coupling_matrix), rVariables.VelocityVector); + // const double SaturationCoefficient = rVariables.DegreeOfSaturation / rVariables.BishopCoefficient; + // const Vector coupling_flow = PORE_PRESSURE_SIGN_FACTOR * SaturationCoefficient * + // prod(trans(coupling_matrix), rVariables.VelocityVector); const Matrix coupling_matrix = (-1.0) * GeoTransportEquationUtilities::CalculateCouplingMatrix( rVariables.B, GetStressStatePolicy().GetVoigtVector(), rVariables.Np, - rVariables.BiotCoefficient, rVariables.DegreeOfSaturation, rVariables.IntegrationCoefficient); - const Vector coupling_flow = PORE_PRESSURE_SIGN_FACTOR * - prod(trans(coupling_matrix), rVariables.VelocityVector); - KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingTerms ") << "v = " << rVariables.VelocityVector << std::endl; - KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingTerms ") << "dQ = " << coupling_flow << std::endl; + rVariables.BiotCoefficient, rVariables.DegreeOfSaturation, + rVariables.IntegrationCoefficient); + const Vector coupling_flow = + PORE_PRESSURE_SIGN_FACTOR * prod(trans(coupling_matrix), rVariables.VelocityVector); GeoElementUtilities::AssemblePBlockVector(rRightHandSideVector, coupling_flow); - KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingTerms ") << "RHS = " << rRightHandSideVector << std::endl; + // if ( this->Id() == 1 || this->Id() == 13 ) { + // KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingTerms ") << "v = " << rVariables.VelocityVector << std::endl; + // KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingTerms ") << "dQ = " << coupling_flow << std::endl; + // KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingTerms ") << "RHS = " << rRightHandSideVector << std::endl; + // } } KRATOS_CATCH("") @@ -1416,11 +1427,12 @@ void SmallStrainUPwDiffOrderElement::CalculateAndAddCompressibilityFlow(VectorTy Matrix CompressibilityMatrix = GeoTransportEquationUtilities::CalculateCompressibilityMatrix( rVariables.Np, rVariables.BiotModulusInverse, rVariables.IntegrationCoefficient); Vector CompressibilityFlow = -prod(CompressibilityMatrix, rVariables.PressureDtVector); - KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCompressibilityFlow") << "dPdt= " << rVariables.PressureDtVector << std::endl; - KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCompressibilityFlow") << "dQ = " << CompressibilityFlow << std::endl; GeoElementUtilities::AssemblePBlockVector(rRightHandSideVector, CompressibilityFlow); - KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCompressibilityFlow") << "RHS = " << rRightHandSideVector << std::endl; - + // if ( this->Id() == 1 || this->Id() == 13 ) { + // KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCompressibilityFlow") << "dPdt= " << rVariables.PressureDtVector << std::endl; + // KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCompressibilityFlow") << "dQ = " << CompressibilityFlow << std::endl; + // KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCompressibilityFlow") << "RHS = " << rRightHandSideVector << std::endl; + // } KRATOS_CATCH("") } @@ -1466,9 +1478,12 @@ void SmallStrainUPwDiffOrderElement::CalculateAndAddPermeabilityFlow(VectorType& const Vector permeability_flow = -prod(permeability_matrix, rVariables.PressureVector); - KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddPermeabilityFlow ") << "dQ = " << permeability_flow << std::endl; GeoElementUtilities::AssemblePBlockVector(rRightHandSideVector, permeability_flow); - KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddPermeabilityFlow ") << "RHS = " << rRightHandSideVector << std::endl; + // if ( this->Id() == 1 || this->Id() == 13 ) { + // KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddPermeabilityFlow ") << "Pw = " << rVariables.PressureVector << std::endl; + // KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddPermeabilityFlow ") << "dQ = " << permeability_flow << std::endl; + // KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddPermeabilityFlow ") << "RHS = " << rRightHandSideVector << std::endl; + // } KRATOS_CATCH("") } @@ -1478,9 +1493,10 @@ void SmallStrainUPwDiffOrderElement::CalculateAndAddFluidBodyFlow(VectorType& rR { KRATOS_TRY - const Matrix grad_Np_T_perm = - rVariables.DynamicViscosityInverse * GetProperties()[DENSITY_WATER] * rVariables.RelativePermeability * - prod(rVariables.DNp_DX, rVariables.IntrinsicPermeability) * rVariables.IntegrationCoefficient; + const Matrix grad_Np_T_perm = rVariables.DynamicViscosityInverse * rVariables.BishopCoefficient * + GetProperties()[DENSITY_WATER] * rVariables.RelativePermeability * + prod(rVariables.DNp_DX, rVariables.IntrinsicPermeability) * + rVariables.IntegrationCoefficient; const GeometryType& r_geom = GetGeometry(); const SizeType dimension = r_geom.WorkingSpaceDimension(); @@ -1498,9 +1514,10 @@ void SmallStrainUPwDiffOrderElement::CalculateAndAddFluidBodyFlow(VectorType& rR const Vector fluid_body_flow = prod(grad_Np_T_perm, body_acceleration); GeoElementUtilities::AssemblePBlockVector(rRightHandSideVector, fluid_body_flow); - KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddFluidBodyFlow ") << "dQ = " << fluid_body_flow << std::endl; - - KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddFluidBodyFlow ") << "RHS = " << rRightHandSideVector << std::endl; + // if ( this->Id() == 1 || this->Id() == 13 ) { + // KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddFluidBodyFlow ") << "dQ = " << fluid_body_flow << std::endl; + // KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddFluidBodyFlow ") << "RHS = " << rRightHandSideVector << std::endl; + // } KRATOS_CATCH("") } diff --git a/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp b/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp index 4bb447ec0c5a..c93253f6d0d2 100644 --- a/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp +++ b/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp @@ -12,12 +12,8 @@ // // System includes -#include - -// External includes - -// Project includes #include "custom_retention/saturated_below_phreatic_level_law.h" +#include namespace Kratos { @@ -37,26 +33,20 @@ SaturatedBelowPhreaticLevelLaw::~SaturatedBelowPhreaticLevelLaw() {} double SaturatedBelowPhreaticLevelLaw::CalculateSaturation(Parameters& rParameters) const { - KRATOS_TRY - - const double& p = rParameters.GetFluidPressure(); - - if (p < 0.0) { + if (rParameters.GetFluidPressure() < 0.0) { return rParameters.GetMaterialProperties()[SATURATED_SATURATION]; } else { return rParameters.GetMaterialProperties()[RESIDUAL_SATURATION]; } - - KRATOS_CATCH("") } double SaturatedBelowPhreaticLevelLaw::CalculateEffectiveSaturation(Parameters& rParameters) const { - KRATOS_TRY + const auto& r_material_properties = rParameters.GetMaterialProperties(); + const auto& sat_max = r_material_properties[SATURATED_SATURATION]; + const auto& sat_min = r_material_properties[RESIDUAL_SATURATION]; - return CalculateSaturation(rParameters); - - KRATOS_CATCH("") + return (CalculateSaturation(rParameters) - sat_min) / (sat_max - sat_min); } double SaturatedBelowPhreaticLevelLaw::CalculateDerivativeOfSaturation(Parameters& rParameters) const @@ -66,80 +56,62 @@ double SaturatedBelowPhreaticLevelLaw::CalculateDerivativeOfSaturation(Parameter double SaturatedBelowPhreaticLevelLaw::CalculateRelativePermeability(Parameters& rParameters) const { - KRATOS_TRY - - const double& p = rParameters.GetFluidPressure(); - - if (p < 0.0) { + if (rParameters.GetFluidPressure() < 0.0) { return 1.0; } else { return rParameters.GetMaterialProperties()[MINIMUM_RELATIVE_PERMEABILITY]; } - - KRATOS_CATCH("") } double SaturatedBelowPhreaticLevelLaw::CalculateBishopCoefficient(Parameters& rParameters) const { - KRATOS_TRY - return CalculateEffectiveSaturation(rParameters); - - KRATOS_CATCH("") } -double& SaturatedBelowPhreaticLevelLaw::CalculateValue(RetentionLaw::Parameters& rParameterValues, - const Variable& rThisVariable, - double& rValue) +double& SaturatedBelowPhreaticLevelLaw::CalculateValue(Parameters& rParameterValues, + const Variable& rThisVariable, + double& rValue) { if (rThisVariable == DEGREE_OF_SATURATION) { rValue = this->CalculateSaturation(rParameterValues); - return rValue; } else if (rThisVariable == EFFECTIVE_SATURATION) { rValue = this->CalculateEffectiveSaturation(rParameterValues); - return rValue; } else if (rThisVariable == BISHOP_COEFFICIENT) { rValue = this->CalculateBishopCoefficient(rParameterValues); - return rValue; } else if (rThisVariable == DERIVATIVE_OF_SATURATION) { rValue = this->CalculateDerivativeOfSaturation(rParameterValues); - return rValue; } else if (rThisVariable == RELATIVE_PERMEABILITY) { rValue = this->CalculateRelativePermeability(rParameterValues); - return rValue; } - return rValue; } -void SaturatedBelowPhreaticLevelLaw::InitializeMaterial(const Properties& rMaterialProperties, - const GeometryType& rElementGeometry, - const Vector& rShapeFunctionsValues) +void SaturatedBelowPhreaticLevelLaw::InitializeMaterial(const Properties&, const GeometryType&, const Vector&) { // nothing is needed } -void SaturatedBelowPhreaticLevelLaw::Initialize(Parameters& rParameters) +void SaturatedBelowPhreaticLevelLaw::Initialize(Parameters&) { // nothing is needed } -void SaturatedBelowPhreaticLevelLaw::InitializeSolutionStep(Parameters& rParameters) +void SaturatedBelowPhreaticLevelLaw::InitializeSolutionStep(Parameters&) { // nothing is needed } -void SaturatedBelowPhreaticLevelLaw::Finalize(Parameters& rParameters) +void SaturatedBelowPhreaticLevelLaw::Finalize(Parameters&) { // nothing is needed } -void SaturatedBelowPhreaticLevelLaw::FinalizeSolutionStep(Parameters& rParameters) +void SaturatedBelowPhreaticLevelLaw::FinalizeSolutionStep(Parameters&) { // nothing is needed } -int SaturatedBelowPhreaticLevelLaw::Check(const Properties& rMaterialProperties, const ProcessInfo& rCurrentProcessInfo) +int SaturatedBelowPhreaticLevelLaw::Check(const Properties& rMaterialProperties, const ProcessInfo&) { KRATOS_ERROR_IF_NOT(rMaterialProperties.Has(SATURATED_SATURATION)) << "SATURATED_SATURATION is not available in material parameters" << std::endl; From 409851fd3065f1b606cdde4523edb7cc710d3b0c Mon Sep 17 00:00:00 2001 From: Wijtze Pieter Kikstra Date: Fri, 6 Dec 2024 17:32:51 +0100 Subject: [PATCH 04/36] start of unit tests for SaturatedBelowPhreaticLevelLaw --- .../saturated_below_phreatic_level_law.cpp | 2 +- ...est_saturated_below_phreatic_level_law.cpp | 75 +++++++++++++++++++ 2 files changed, 76 insertions(+), 1 deletion(-) create mode 100644 applications/GeoMechanicsApplication/tests/cpp_tests/custom_retention/test_saturated_below_phreatic_level_law.cpp diff --git a/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp b/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp index c93253f6d0d2..91c0725925c0 100644 --- a/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp +++ b/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp @@ -49,7 +49,7 @@ double SaturatedBelowPhreaticLevelLaw::CalculateEffectiveSaturation(Parameters& return (CalculateSaturation(rParameters) - sat_min) / (sat_max - sat_min); } -double SaturatedBelowPhreaticLevelLaw::CalculateDerivativeOfSaturation(Parameters& rParameters) const +double SaturatedBelowPhreaticLevelLaw::CalculateDerivativeOfSaturation(Parameters&) const { return 0.0; } diff --git a/applications/GeoMechanicsApplication/tests/cpp_tests/custom_retention/test_saturated_below_phreatic_level_law.cpp b/applications/GeoMechanicsApplication/tests/cpp_tests/custom_retention/test_saturated_below_phreatic_level_law.cpp new file mode 100644 index 000000000000..c68b6afeeba3 --- /dev/null +++ b/applications/GeoMechanicsApplication/tests/cpp_tests/custom_retention/test_saturated_below_phreatic_level_law.cpp @@ -0,0 +1,75 @@ +// KRATOS___ +// // ) ) +// // ___ ___ +// // ____ //___) ) // ) ) +// // / / // // / / +// ((____/ / ((____ ((___/ / MECHANICS +// +// License: geo_mechanics_application/license.txt +// +// Main authors: Wijtze Pieter Kikstra +// + +#include "custom_retention/saturated_below_phreatic_level_law.h" +#include "tests/cpp_tests/geo_mechanics_fast_suite.h" + +namespace +{ + +using namespace Kratos; + + +SaturatedBelowPhreaticLevelLaw CreateSaturatedBelowPhreaticLevelLaw() +{ + return SaturatedBelowPhreaticLevelLaw{}; +} + +} // namespace + +namespace Kratos::Testing +{ + +KRATOS_TEST_CASE_IN_SUITE(SaturatedBelowPhreaticLevelLawReturnsCloneOfCorrectType, KratosGeoMechanicsFastSuiteWithoutKernel) +{ + const auto law = CreateSaturatedBelowPhreaticLevelLaw(); + const auto p_law_clone = law.Clone(); + KRATOS_EXPECT_NE(&law, p_law_clone.get()); + KRATOS_EXPECT_NE(dynamic_cast(p_law_clone.get()), nullptr); +} + +KRATOS_TEST_CASE_IN_SUITE(SaturatedBelowPhreaticLevelLawReturnsSaturation, KratosGeoMechanicsFastSuiteWithoutKernel) +{ + auto law = CreateSaturatedBelowPhreaticLevelLaw(); + Properties properties; + properties.SetValue(SATURATED_SATURATION, 0.9); + properties.SetValue(RESIDUAL_SATURATION, 0.1); + properties.SetValue(MINIMUM_RELATIVE_PERMEABILITY, 0.05); + + auto retention_law_parameters = RetentionLaw::Parameters{properties}; + + retention_law_parameters.SetFluidPressure(-10.0); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateSaturation(retention_law_parameters), 0.9); + double value = 0.0; + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateValue(retention_law_parameters, DEGREE_OF_SATURATION, value), 0.9); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateEffectiveSaturation(retention_law_parameters), 1.0); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateValue(retention_law_parameters, EFFECTIVE_SATURATION, value), 1.0); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateBishopCoefficient(retention_law_parameters), 1.0); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateValue(retention_law_parameters, BISHOP_COEFFICIENT, value), 1.0); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateDerivativeOfSaturation(retention_law_parameters), 0.0); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateValue(retention_law_parameters, DERIVATIVE_OF_SATURATION, value), 0.0); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateRelativePermeability(retention_law_parameters), 1.0); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateValue(retention_law_parameters, RELATIVE_PERMEABILITY, value), 1.0); + + retention_law_parameters.SetFluidPressure(10.0); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateSaturation(retention_law_parameters), 0.1); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateValue(retention_law_parameters, DEGREE_OF_SATURATION, value), 0.1); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateEffectiveSaturation(retention_law_parameters), 0.0); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateValue(retention_law_parameters, EFFECTIVE_SATURATION, value), 0.0); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateBishopCoefficient(retention_law_parameters), 0.0); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateValue(retention_law_parameters, BISHOP_COEFFICIENT, value), 0.0); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateDerivativeOfSaturation(retention_law_parameters), 0.0); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateValue(retention_law_parameters, DERIVATIVE_OF_SATURATION, value), 0.0); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateRelativePermeability(retention_law_parameters), 0.05); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateValue(retention_law_parameters, RELATIVE_PERMEABILITY, value), 0.05); +} +} // namespace Kratos::Testing \ No newline at end of file From bf5bd8d7d13495b162d47ae4fc538dc3fb35e68d Mon Sep 17 00:00:00 2001 From: Wijtze Pieter Kikstra Date: Mon, 9 Dec 2024 09:43:23 +0100 Subject: [PATCH 05/36] Improved error messages for saturated below phreatic level and unit test for the errors. --- .../saturated_below_phreatic_level_law.cpp | 37 +++++++++------- ...est_saturated_below_phreatic_level_law.cpp | 43 +++++++++++++++++-- 2 files changed, 61 insertions(+), 19 deletions(-) diff --git a/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp b/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp index 91c0725925c0..2dd7d151342d 100644 --- a/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp +++ b/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp @@ -14,6 +14,7 @@ // System includes #include "custom_retention/saturated_below_phreatic_level_law.h" #include +#include namespace Kratos { @@ -43,8 +44,8 @@ double SaturatedBelowPhreaticLevelLaw::CalculateSaturation(Parameters& rParamete double SaturatedBelowPhreaticLevelLaw::CalculateEffectiveSaturation(Parameters& rParameters) const { const auto& r_material_properties = rParameters.GetMaterialProperties(); - const auto& sat_max = r_material_properties[SATURATED_SATURATION]; - const auto& sat_min = r_material_properties[RESIDUAL_SATURATION]; + const auto& sat_max = r_material_properties[SATURATED_SATURATION]; + const auto& sat_min = r_material_properties[RESIDUAL_SATURATION]; return (CalculateSaturation(rParameters) - sat_min) / (sat_max - sat_min); } @@ -114,24 +115,28 @@ void SaturatedBelowPhreaticLevelLaw::FinalizeSolutionStep(Parameters&) int SaturatedBelowPhreaticLevelLaw::Check(const Properties& rMaterialProperties, const ProcessInfo&) { KRATOS_ERROR_IF_NOT(rMaterialProperties.Has(SATURATED_SATURATION)) - << "SATURATED_SATURATION is not available in material parameters" << std::endl; - KRATOS_ERROR_IF(rMaterialProperties[SATURATED_SATURATION] < 0.0) - << "SATURATED_SATURATION cannot be less than 0 " << std::endl; + << "SATURATED_SATURATION is not available in the parameters of material " + << rMaterialProperties.Id() << "." << std::endl; + KRATOS_ERROR_IF(rMaterialProperties[SATURATED_SATURATION] < 0.0 || rMaterialProperties[SATURATED_SATURATION] > 1.0) + << "SATURATED_SATURATION (" << rMaterialProperties[SATURATED_SATURATION] + << ") must be in the range [0.0, 1.0] for material " << rMaterialProperties.Id() << "." + << std::endl; KRATOS_ERROR_IF_NOT(rMaterialProperties.Has(RESIDUAL_SATURATION)) - << "RESIDUAL_SATURATION is not available in material parameters" << std::endl; - KRATOS_DEBUG_ERROR_IF_NOT(rMaterialProperties[RESIDUAL_SATURATION] > 0.0) - << "RESIDUAL_SATURATION must be greater than 0 " << std::endl; - KRATOS_ERROR_IF(rMaterialProperties[RESIDUAL_SATURATION] > 1.0) - << "RESIDUAL_SATURATION cannot be greater than 1.0 " << std::endl; - - KRATOS_ERROR_IF(rMaterialProperties[SATURATED_SATURATION] < rMaterialProperties[RESIDUAL_SATURATION]) - << "RESIDUAL_SATURATION cannot be greater than SATURATED_SATURATION " << std::endl; + << "RESIDUAL_SATURATION is not available in the parameters of material " + << rMaterialProperties.Id() << "." << std::endl; + KRATOS_ERROR_IF(rMaterialProperties[RESIDUAL_SATURATION] < 0.0 || rMaterialProperties[RESIDUAL_SATURATION] >= rMaterialProperties[SATURATED_SATURATION]) + << "RESIDUAL_SATURATION (" << rMaterialProperties[RESIDUAL_SATURATION] + << ") must be in the range [0.0, " << rMaterialProperties[SATURATED_SATURATION] + << "> for material " << rMaterialProperties.Id() << "." << std::endl; KRATOS_ERROR_IF_NOT(rMaterialProperties.Has(MINIMUM_RELATIVE_PERMEABILITY)) - << "MINIMUM_RELATIVE_PERMEABILITY is not available in material parameters" << std::endl; - KRATOS_ERROR_IF_NOT((rMaterialProperties[MINIMUM_RELATIVE_PERMEABILITY] > 0.0)) - << "MINIMUM_RELATIVE_PERMEABILITY must be greater than 0 " << std::endl; + << "MINIMUM_RELATIVE_PERMEABILITY is not available in the parameters of material " + << rMaterialProperties.Id() << "." << std::endl; + KRATOS_ERROR_IF(rMaterialProperties[MINIMUM_RELATIVE_PERMEABILITY] < 0.0 || rMaterialProperties[MINIMUM_RELATIVE_PERMEABILITY] > 1.0) + << "MINIMUM_RELATIVE_PERMEABILITY (" << rMaterialProperties[MINIMUM_RELATIVE_PERMEABILITY] + << ") must be in the range [0.0, 1.0] for material " << rMaterialProperties.Id() << "." + << std::endl; return 0; } diff --git a/applications/GeoMechanicsApplication/tests/cpp_tests/custom_retention/test_saturated_below_phreatic_level_law.cpp b/applications/GeoMechanicsApplication/tests/cpp_tests/custom_retention/test_saturated_below_phreatic_level_law.cpp index c68b6afeeba3..4be68d46c713 100644 --- a/applications/GeoMechanicsApplication/tests/cpp_tests/custom_retention/test_saturated_below_phreatic_level_law.cpp +++ b/applications/GeoMechanicsApplication/tests/cpp_tests/custom_retention/test_saturated_below_phreatic_level_law.cpp @@ -18,7 +18,6 @@ namespace using namespace Kratos; - SaturatedBelowPhreaticLevelLaw CreateSaturatedBelowPhreaticLevelLaw() { return SaturatedBelowPhreaticLevelLaw{}; @@ -37,9 +36,9 @@ KRATOS_TEST_CASE_IN_SUITE(SaturatedBelowPhreaticLevelLawReturnsCloneOfCorrectTyp KRATOS_EXPECT_NE(dynamic_cast(p_law_clone.get()), nullptr); } -KRATOS_TEST_CASE_IN_SUITE(SaturatedBelowPhreaticLevelLawReturnsSaturation, KratosGeoMechanicsFastSuiteWithoutKernel) +KRATOS_TEST_CASE_IN_SUITE(SaturatedBelowPhreaticLevelLawReturnsCalculatedValues, KratosGeoMechanicsFastSuiteWithoutKernel) { - auto law = CreateSaturatedBelowPhreaticLevelLaw(); + auto law = CreateSaturatedBelowPhreaticLevelLaw(); Properties properties; properties.SetValue(SATURATED_SATURATION, 0.9); properties.SetValue(RESIDUAL_SATURATION, 0.1); @@ -72,4 +71,42 @@ KRATOS_TEST_CASE_IN_SUITE(SaturatedBelowPhreaticLevelLawReturnsSaturation, Krato KRATOS_EXPECT_DOUBLE_EQ(law.CalculateRelativePermeability(retention_law_parameters), 0.05); KRATOS_EXPECT_DOUBLE_EQ(law.CalculateValue(retention_law_parameters, RELATIVE_PERMEABILITY, value), 0.05); } + +KRATOS_TEST_CASE_IN_SUITE(SaturatedBelowPhreaticLevelLawChecksInputParameters, KratosGeoMechanicsFastSuiteWithoutKernel) +{ + Properties properties; + properties.SetId(1); + const auto process_info = ProcessInfo{}; + auto law = CreateSaturatedBelowPhreaticLevelLaw(); + + KRATOS_EXPECT_EXCEPTION_IS_THROWN( + law.Check(properties, process_info), + "SATURATED_SATURATION is not available in the parameters of material 1."); + properties.SetValue(SATURATED_SATURATION, 1.1); + KRATOS_EXPECT_EXCEPTION_IS_THROWN( + law.Check(properties, process_info), + "SATURATED_SATURATION (1.1) must be in the range [0.0, 1.0] for material 1."); + properties.SetValue(SATURATED_SATURATION, 0.9); + + KRATOS_EXPECT_EXCEPTION_IS_THROWN( + law.Check(properties, process_info), + "RESIDUAL_SATURATION is not available in the parameters of material 1."); + properties.SetValue(RESIDUAL_SATURATION, 1.1); + KRATOS_EXPECT_EXCEPTION_IS_THROWN( + law.Check(properties, process_info), + "RESIDUAL_SATURATION (1.1) must be in the range [0.0, 0.9> for material 1."); + properties.SetValue(RESIDUAL_SATURATION, 0.1); + + KRATOS_EXPECT_EXCEPTION_IS_THROWN( + law.Check(properties, process_info), + "MINIMUM_RELATIVE_PERMEABILITY is not available in the parameters of material 1."); + properties.SetValue(MINIMUM_RELATIVE_PERMEABILITY, 1.1); + KRATOS_EXPECT_EXCEPTION_IS_THROWN( + law.Check(properties, process_info), + "MINIMUM_RELATIVE_PERMEABILITY (1.1) must be in the range [0.0, 1.0] for material 1."); + properties.SetValue(MINIMUM_RELATIVE_PERMEABILITY, 0.05); + + KRATOS_EXPECT_EQ(law.Check(properties, process_info), 0); +} + } // namespace Kratos::Testing \ No newline at end of file From 188099f8cc3162fb16389e5c9834db93bb4d6f44 Mon Sep 17 00:00:00 2001 From: Wijtze Pieter Kikstra Date: Mon, 9 Dec 2024 09:46:29 +0100 Subject: [PATCH 06/36] removed unwanted include --- .../custom_retention/saturated_below_phreatic_level_law.cpp | 1 - 1 file changed, 1 deletion(-) diff --git a/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp b/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp index 2dd7d151342d..29398e525ee5 100644 --- a/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp +++ b/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp @@ -14,7 +14,6 @@ // System includes #include "custom_retention/saturated_below_phreatic_level_law.h" #include -#include namespace Kratos { From 7e10e65b2e87673d2e2666e2cec6320dc65e91c3 Mon Sep 17 00:00:00 2001 From: Wijtze Pieter Kikstra Date: Mon, 9 Dec 2024 11:17:26 +0100 Subject: [PATCH 07/36] ternary operator --- .../custom_retention/saturated_below_phreatic_level_law.cpp | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp b/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp index 29398e525ee5..ef1b47ba258b 100644 --- a/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp +++ b/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp @@ -33,11 +33,7 @@ SaturatedBelowPhreaticLevelLaw::~SaturatedBelowPhreaticLevelLaw() {} double SaturatedBelowPhreaticLevelLaw::CalculateSaturation(Parameters& rParameters) const { - if (rParameters.GetFluidPressure() < 0.0) { - return rParameters.GetMaterialProperties()[SATURATED_SATURATION]; - } else { - return rParameters.GetMaterialProperties()[RESIDUAL_SATURATION]; - } + return (rParameters.GetFluidPressure() < 0.0) ? rParameters.GetMaterialProperties()[SATURATED_SATURATION] : rParameters.GetMaterialProperties()[RESIDUAL_SATURATION]; } double SaturatedBelowPhreaticLevelLaw::CalculateEffectiveSaturation(Parameters& rParameters) const From 85cb890f1f0f071cacab32c9f6bc5ddc0cad38bc Mon Sep 17 00:00:00 2001 From: Wijtze Pieter Kikstra Date: Mon, 9 Dec 2024 11:28:01 +0100 Subject: [PATCH 08/36] Unit test for saturated law --- .../custom_retention/saturated_law.cpp | 33 ++------ .../custom_retention/test_saturated_law.cpp | 80 +++++++++++++++++++ 2 files changed, 85 insertions(+), 28 deletions(-) create mode 100644 applications/GeoMechanicsApplication/tests/cpp_tests/custom_retention/test_saturated_law.cpp diff --git a/applications/GeoMechanicsApplication/custom_retention/saturated_law.cpp b/applications/GeoMechanicsApplication/custom_retention/saturated_law.cpp index ec6ab2bfd3db..258671fe53f3 100644 --- a/applications/GeoMechanicsApplication/custom_retention/saturated_law.cpp +++ b/applications/GeoMechanicsApplication/custom_retention/saturated_law.cpp @@ -14,9 +14,6 @@ // System includes #include -// External includes - -// Project includes #include "custom_retention/saturated_law.h" namespace Kratos @@ -29,17 +26,8 @@ RetentionLaw::Pointer SaturatedLaw::Clone() const double SaturatedLaw::CalculateSaturation(Parameters& rParameters) const { - KRATOS_TRY - const Properties& rMaterialProperties = rParameters.GetMaterialProperties(); - - if (rMaterialProperties.Has(SATURATED_SATURATION)) { - return rMaterialProperties[SATURATED_SATURATION]; - } else { - return 1.0; - } - - KRATOS_CATCH("") + return rMaterialProperties.Has(SATURATED_SATURATION) ? rMaterialProperties[SATURATED_SATURATION]: 1.0; } double SaturatedLaw::CalculateEffectiveSaturation(Parameters& rParameters) const { return 1.0; } @@ -50,11 +38,7 @@ double SaturatedLaw::CalculateRelativePermeability(Parameters& rParameters) cons double SaturatedLaw::CalculateBishopCoefficient(Parameters& rParameters) const { - KRATOS_TRY - return CalculateEffectiveSaturation(rParameters); - - KRATOS_CATCH("") } double& SaturatedLaw::CalculateValue(RetentionLaw::Parameters& rParameterValues, @@ -63,21 +47,15 @@ double& SaturatedLaw::CalculateValue(RetentionLaw::Parameters& rParameterValues, { if (rThisVariable == DEGREE_OF_SATURATION) { rValue = this->CalculateSaturation(rParameterValues); - return rValue; } else if (rThisVariable == EFFECTIVE_SATURATION) { rValue = this->CalculateEffectiveSaturation(rParameterValues); - return rValue; } else if (rThisVariable == BISHOP_COEFFICIENT) { rValue = this->CalculateBishopCoefficient(rParameterValues); - return rValue; } else if (rThisVariable == DERIVATIVE_OF_SATURATION) { rValue = this->CalculateDerivativeOfSaturation(rParameterValues); - return rValue; } else if (rThisVariable == RELATIVE_PERMEABILITY) { rValue = this->CalculateRelativePermeability(rParameterValues); - return rValue; } - return rValue; } @@ -111,11 +89,10 @@ void SaturatedLaw::FinalizeSolutionStep(Parameters& rParameters) int SaturatedLaw::Check(const Properties& rMaterialProperties, const ProcessInfo& rCurrentProcessInfo) { if (rMaterialProperties.Has(SATURATED_SATURATION)) { - KRATOS_ERROR_IF(rMaterialProperties[SATURATED_SATURATION] < 0.0) - << "SATURATED_SATURATION cannot be less than 0 " << std::endl; - - KRATOS_ERROR_IF(rMaterialProperties[SATURATED_SATURATION] > 1.0) - << "SATURATED_SATURATION cannot be greater than 1.0 " << std::endl; + KRATOS_ERROR_IF(rMaterialProperties[SATURATED_SATURATION] < 0.0 || rMaterialProperties[SATURATED_SATURATION] > 1.0) + << "SATURATED_SATURATION (" << rMaterialProperties[SATURATED_SATURATION] + << ") must be in the range [0.0, 1.0] for material " << rMaterialProperties.Id() << "." + << std::endl; } return 0; diff --git a/applications/GeoMechanicsApplication/tests/cpp_tests/custom_retention/test_saturated_law.cpp b/applications/GeoMechanicsApplication/tests/cpp_tests/custom_retention/test_saturated_law.cpp new file mode 100644 index 000000000000..b02a6781b3e6 --- /dev/null +++ b/applications/GeoMechanicsApplication/tests/cpp_tests/custom_retention/test_saturated_law.cpp @@ -0,0 +1,80 @@ +// KRATOS___ +// // ) ) +// // ___ ___ +// // ____ //___) ) // ) ) +// // / / // // / / +// ((____/ / ((____ ((___/ / MECHANICS +// +// License: geo_mechanics_application/license.txt +// +// Main authors: Wijtze Pieter Kikstra +// + +#include "custom_retention/saturated_law.h" +#include "tests/cpp_tests/geo_mechanics_fast_suite.h" + +namespace +{ + +using namespace Kratos; + +SaturatedLaw CreateSaturatedLaw() +{ + return SaturatedLaw{}; +} + +} // namespace + +namespace Kratos::Testing +{ + +KRATOS_TEST_CASE_IN_SUITE(SaturatedLawReturnsCloneOfCorrectType, KratosGeoMechanicsFastSuiteWithoutKernel) +{ + const auto law = CreateSaturatedLaw(); + const auto p_law_clone = law.Clone(); + KRATOS_EXPECT_NE(&law, p_law_clone.get()); + KRATOS_EXPECT_NE(dynamic_cast(p_law_clone.get()), nullptr); +} + +KRATOS_TEST_CASE_IN_SUITE(SaturatedLawReturnsCalculatedValues, KratosGeoMechanicsFastSuiteWithoutKernel) +{ + auto law = CreateSaturatedLaw(); + Properties properties; + auto retention_law_parameters = RetentionLaw::Parameters{properties}; + + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateSaturation(retention_law_parameters), 1.0); + double value = 0.0; + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateValue(retention_law_parameters, DEGREE_OF_SATURATION, value), 1.0); + + properties.SetValue(SATURATED_SATURATION, 0.9); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateSaturation(retention_law_parameters), 0.9); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateValue(retention_law_parameters, DEGREE_OF_SATURATION, value), 0.9); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateEffectiveSaturation(retention_law_parameters), 1.0); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateValue(retention_law_parameters, EFFECTIVE_SATURATION, value), 1.0); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateBishopCoefficient(retention_law_parameters), 1.0); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateValue(retention_law_parameters, BISHOP_COEFFICIENT, value), 1.0); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateDerivativeOfSaturation(retention_law_parameters), 0.0); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateValue(retention_law_parameters, DERIVATIVE_OF_SATURATION, value), 0.0); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateRelativePermeability(retention_law_parameters), 1.0); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateValue(retention_law_parameters, RELATIVE_PERMEABILITY, value), 1.0); +} + +KRATOS_TEST_CASE_IN_SUITE(SaturatedLawChecksInputParameters, KratosGeoMechanicsFastSuiteWithoutKernel) +{ + Properties properties; + properties.SetId(1); + const auto process_info = ProcessInfo{}; + auto law = CreateSaturatedLaw(); + + KRATOS_EXPECT_EQ(law.Check(properties, process_info), 0); + + properties.SetValue(SATURATED_SATURATION, 1.1); + KRATOS_EXPECT_EXCEPTION_IS_THROWN( + law.Check(properties, process_info), + "SATURATED_SATURATION (1.1) must be in the range [0.0, 1.0] for material 1."); + + properties.SetValue(SATURATED_SATURATION, 0.9); + KRATOS_EXPECT_EQ(law.Check(properties, process_info), 0); +} + +} // namespace Kratos::Testing \ No newline at end of file From d31ed6074af2e15570865719a66ad9b0d0f800c4 Mon Sep 17 00:00:00 2001 From: Wijtze Pieter Kikstra Date: Mon, 9 Dec 2024 11:38:18 +0100 Subject: [PATCH 09/36] ternary operator --- .../saturated_below_phreatic_level_law.cpp | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp b/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp index ef1b47ba258b..c501587a89a6 100644 --- a/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp +++ b/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp @@ -33,14 +33,16 @@ SaturatedBelowPhreaticLevelLaw::~SaturatedBelowPhreaticLevelLaw() {} double SaturatedBelowPhreaticLevelLaw::CalculateSaturation(Parameters& rParameters) const { - return (rParameters.GetFluidPressure() < 0.0) ? rParameters.GetMaterialProperties()[SATURATED_SATURATION] : rParameters.GetMaterialProperties()[RESIDUAL_SATURATION]; + return (rParameters.GetFluidPressure() < 0.0) + ? rParameters.GetMaterialProperties()[SATURATED_SATURATION] + : rParameters.GetMaterialProperties()[RESIDUAL_SATURATION]; } double SaturatedBelowPhreaticLevelLaw::CalculateEffectiveSaturation(Parameters& rParameters) const { const auto& r_material_properties = rParameters.GetMaterialProperties(); - const auto& sat_max = r_material_properties[SATURATED_SATURATION]; - const auto& sat_min = r_material_properties[RESIDUAL_SATURATION]; + const auto sat_max = r_material_properties[SATURATED_SATURATION]; + const auto sat_min = r_material_properties[RESIDUAL_SATURATION]; return (CalculateSaturation(rParameters) - sat_min) / (sat_max - sat_min); } @@ -52,11 +54,9 @@ double SaturatedBelowPhreaticLevelLaw::CalculateDerivativeOfSaturation(Parameter double SaturatedBelowPhreaticLevelLaw::CalculateRelativePermeability(Parameters& rParameters) const { - if (rParameters.GetFluidPressure() < 0.0) { - return 1.0; - } else { - return rParameters.GetMaterialProperties()[MINIMUM_RELATIVE_PERMEABILITY]; - } + return rParameters.GetFluidPressure() < 0.0 + ? 1.0 + : rParameters.GetMaterialProperties()[MINIMUM_RELATIVE_PERMEABILITY]; } double SaturatedBelowPhreaticLevelLaw::CalculateBishopCoefficient(Parameters& rParameters) const From c4412d9d4b682840456a7306fae8c7b047a3bda2 Mon Sep 17 00:00:00 2001 From: Wijtze Pieter Kikstra Date: Mon, 9 Dec 2024 14:34:18 +0100 Subject: [PATCH 10/36] Checks and unit tests for Van Genuchten added. --- .../custom_retention/retention_law.cpp | 2 +- .../custom_retention/retention_law.h | 6 - .../custom_retention/saturated_law.cpp | 8 +- .../custom_retention/van_genuchten_law.cpp | 121 ++++++++------- .../custom_retention/test_saturated_law.cpp | 7 +- .../test_van_genuchten_law.cpp | 145 ++++++++++++++++++ 6 files changed, 216 insertions(+), 73 deletions(-) create mode 100644 applications/GeoMechanicsApplication/tests/cpp_tests/custom_retention/test_van_genuchten_law.cpp diff --git a/applications/GeoMechanicsApplication/custom_retention/retention_law.cpp b/applications/GeoMechanicsApplication/custom_retention/retention_law.cpp index 0f58109062b1..7b0d311ae297 100644 --- a/applications/GeoMechanicsApplication/custom_retention/retention_law.cpp +++ b/applications/GeoMechanicsApplication/custom_retention/retention_law.cpp @@ -11,7 +11,7 @@ // /* Project includes */ -#include "custom_retention/saturated_law.h" +#include "custom_retention/retention_law.h" namespace Kratos { diff --git a/applications/GeoMechanicsApplication/custom_retention/retention_law.h b/applications/GeoMechanicsApplication/custom_retention/retention_law.h index 679cdcd31c98..2f9d78880840 100644 --- a/applications/GeoMechanicsApplication/custom_retention/retention_law.h +++ b/applications/GeoMechanicsApplication/custom_retention/retention_law.h @@ -11,12 +11,6 @@ // #pragma once - -/* System includes */ - -/* External includes */ - -/* Project includes */ #include "geometries/geometry.h" #include "includes/define.h" #include "includes/process_info.h" diff --git a/applications/GeoMechanicsApplication/custom_retention/saturated_law.cpp b/applications/GeoMechanicsApplication/custom_retention/saturated_law.cpp index 258671fe53f3..841091b1c9f6 100644 --- a/applications/GeoMechanicsApplication/custom_retention/saturated_law.cpp +++ b/applications/GeoMechanicsApplication/custom_retention/saturated_law.cpp @@ -27,7 +27,7 @@ RetentionLaw::Pointer SaturatedLaw::Clone() const double SaturatedLaw::CalculateSaturation(Parameters& rParameters) const { const Properties& rMaterialProperties = rParameters.GetMaterialProperties(); - return rMaterialProperties.Has(SATURATED_SATURATION) ? rMaterialProperties[SATURATED_SATURATION]: 1.0; + return rMaterialProperties.Has(SATURATED_SATURATION) ? rMaterialProperties[SATURATED_SATURATION] : 1.0; } double SaturatedLaw::CalculateEffectiveSaturation(Parameters& rParameters) const { return 1.0; } @@ -90,9 +90,9 @@ int SaturatedLaw::Check(const Properties& rMaterialProperties, const ProcessInfo { if (rMaterialProperties.Has(SATURATED_SATURATION)) { KRATOS_ERROR_IF(rMaterialProperties[SATURATED_SATURATION] < 0.0 || rMaterialProperties[SATURATED_SATURATION] > 1.0) - << "SATURATED_SATURATION (" << rMaterialProperties[SATURATED_SATURATION] - << ") must be in the range [0.0, 1.0] for material " << rMaterialProperties.Id() << "." - << std::endl; + << "SATURATED_SATURATION (" << rMaterialProperties[SATURATED_SATURATION] + << ") must be in the range [0.0, 1.0] for material " << rMaterialProperties.Id() << "." + << std::endl; } return 0; diff --git a/applications/GeoMechanicsApplication/custom_retention/van_genuchten_law.cpp b/applications/GeoMechanicsApplication/custom_retention/van_genuchten_law.cpp index f71ee4af5cab..b10cc7d5c690 100644 --- a/applications/GeoMechanicsApplication/custom_retention/van_genuchten_law.cpp +++ b/applications/GeoMechanicsApplication/custom_retention/van_genuchten_law.cpp @@ -11,9 +11,6 @@ // Main authors: Vahid Galavi // -// System includes -#include - // Project includes #include "custom_retention/van_genuchten_law.h" @@ -29,17 +26,17 @@ double VanGenuchtenLaw::CalculateSaturation(Parameters& rParameters) const { KRATOS_TRY - const double& p = rParameters.GetFluidPressure(); - const Properties& rMaterialProperties = rParameters.GetMaterialProperties(); + const auto p = rParameters.GetFluidPressure(); + const auto& rMaterialProperties = rParameters.GetMaterialProperties(); if (p > 0.0) { - const double& satMax = rMaterialProperties[SATURATED_SATURATION]; - const double& satMin = rMaterialProperties[RESIDUAL_SATURATION]; - const double& pb = rMaterialProperties[VAN_GENUCHTEN_AIR_ENTRY_PRESSURE]; - const double& gn = rMaterialProperties[VAN_GENUCHTEN_GN]; - const double gc = (1.0 - gn) / gn; + const auto sat_max = rMaterialProperties[SATURATED_SATURATION]; + const auto sat_min = rMaterialProperties[RESIDUAL_SATURATION]; + const auto pb = rMaterialProperties[VAN_GENUCHTEN_AIR_ENTRY_PRESSURE]; + const auto gn = rMaterialProperties[VAN_GENUCHTEN_GN]; + const auto gc = (1.0 - gn) / gn; - return satMin + (satMax - satMin) * pow(1.0 + pow(p / pb, gn), gc); + return sat_min + (sat_max - sat_min) * pow(1.0 + pow(p / pb, gn), gc); } else { return rMaterialProperties[SATURATED_SATURATION]; } @@ -51,9 +48,9 @@ double VanGenuchtenLaw::CalculateEffectiveSaturation(Parameters& rParameters) co { KRATOS_TRY - const auto& rMaterialProperties = rParameters.GetMaterialProperties(); - const double& satMax = rMaterialProperties[SATURATED_SATURATION]; - const double& satMin = rMaterialProperties[RESIDUAL_SATURATION]; + const auto& rMaterialProperties = rParameters.GetMaterialProperties(); + const auto satMax = rMaterialProperties[SATURATED_SATURATION]; + const auto satMin = rMaterialProperties[RESIDUAL_SATURATION]; return (CalculateSaturation(rParameters) - satMin) / (satMax - satMin); @@ -63,18 +60,18 @@ double VanGenuchtenLaw::CalculateEffectiveSaturation(Parameters& rParameters) co double VanGenuchtenLaw::CalculateDerivativeOfSaturation(Parameters& rParameters) const { KRATOS_TRY - const double& p = rParameters.GetFluidPressure(); + const auto p = rParameters.GetFluidPressure(); if (p > 0.0) { - const auto& rMaterialProperties = rParameters.GetMaterialProperties(); - const double& satMax = rMaterialProperties[SATURATED_SATURATION]; - const double& satMin = rMaterialProperties[RESIDUAL_SATURATION]; - const double& pb = rMaterialProperties[VAN_GENUCHTEN_AIR_ENTRY_PRESSURE]; - const double& gn = rMaterialProperties[VAN_GENUCHTEN_GN]; - const double gc = (1.0 - gn) / gn; - - return (satMax - satMin) * gc * pow((1.0 + pow(p / pb, gn)), gc - 1.0) * gn * pow(pb, -gn) * - pow(p, gn - 1.0); + const auto& rMaterialProperties = rParameters.GetMaterialProperties(); + const auto sat_max = rMaterialProperties[SATURATED_SATURATION]; + const auto sat_min = rMaterialProperties[RESIDUAL_SATURATION]; + const auto pb = rMaterialProperties[VAN_GENUCHTEN_AIR_ENTRY_PRESSURE]; + const auto gn = rMaterialProperties[VAN_GENUCHTEN_GN]; + const auto gc = (1.0 - gn) / gn; + + return (sat_max - sat_min) * gc * pow((1.0 + pow(p / pb, gn)), gc - 1.0) * gn * + pow(pb, -gn) * pow(p, gn - 1.0); } else { return 0.0; } @@ -86,13 +83,13 @@ double VanGenuchtenLaw::CalculateRelativePermeability(Parameters& rParameters) c { KRATOS_TRY - const double effSat = CalculateEffectiveSaturation(rParameters); + const auto effSat = CalculateEffectiveSaturation(rParameters); - const auto& rMaterialProperties = rParameters.GetMaterialProperties(); - const double& gl = rMaterialProperties[VAN_GENUCHTEN_GL]; - const double& gn = rMaterialProperties[VAN_GENUCHTEN_GN]; + const auto& rMaterialProperties = rParameters.GetMaterialProperties(); + const auto gl = rMaterialProperties[VAN_GENUCHTEN_GL]; + const auto gn = rMaterialProperties[VAN_GENUCHTEN_GN]; - double relPerm = + const auto relPerm = pow(effSat, gl) * pow(1.0 - pow(1.0 - pow(effSat, gn / (gn - 1.0)), (gn - 1.0) / gn), 2); return std::max(relPerm, rMaterialProperties[MINIMUM_RELATIVE_PERMEABILITY]); @@ -102,11 +99,7 @@ double VanGenuchtenLaw::CalculateRelativePermeability(Parameters& rParameters) c double VanGenuchtenLaw::CalculateBishopCoefficient(Parameters& rParameters) const { - KRATOS_TRY - return CalculateEffectiveSaturation(rParameters); - - KRATOS_CATCH("") } double& VanGenuchtenLaw::CalculateValue(RetentionLaw::Parameters& rParameterValues, @@ -115,19 +108,14 @@ double& VanGenuchtenLaw::CalculateValue(RetentionLaw::Parameters& rParameterValu { if (rThisVariable == DEGREE_OF_SATURATION) { rValue = this->CalculateSaturation(rParameterValues); - return rValue; } else if (rThisVariable == EFFECTIVE_SATURATION) { rValue = this->CalculateEffectiveSaturation(rParameterValues); - return rValue; } else if (rThisVariable == BISHOP_COEFFICIENT) { rValue = this->CalculateBishopCoefficient(rParameterValues); - return rValue; } else if (rThisVariable == DERIVATIVE_OF_SATURATION) { rValue = this->CalculateDerivativeOfSaturation(rParameterValues); - return rValue; } else if (rThisVariable == RELATIVE_PERMEABILITY) { rValue = this->CalculateRelativePermeability(rParameterValues); - return rValue; } return rValue; @@ -163,31 +151,50 @@ void VanGenuchtenLaw::FinalizeSolutionStep(Parameters& rParameters) int VanGenuchtenLaw::Check(const Properties& rMaterialProperties, const ProcessInfo& rCurrentProcessInfo) { KRATOS_ERROR_IF_NOT(rMaterialProperties.Has(SATURATED_SATURATION)) - << "SATURATED_SATURATION is not available in material parameters" << std::endl; - KRATOS_ERROR_IF(rMaterialProperties[SATURATED_SATURATION] < 0.0) - << "SATURATED_SATURATION cannot be less than 0 " << std::endl; - KRATOS_ERROR_IF(rMaterialProperties[SATURATED_SATURATION] > 1.0) - << "SATURATED_SATURATION cannot be greater than 1.0 " << std::endl; + << "SATURATED_SATURATION is not available in the parameters of material " + << rMaterialProperties.Id() << "." << std::endl; + KRATOS_ERROR_IF(rMaterialProperties[SATURATED_SATURATION] < 0.0 || rMaterialProperties[SATURATED_SATURATION] > 1.0) + << "SATURATED_SATURATION (" << rMaterialProperties[SATURATED_SATURATION] + << ") must be in the range [0.0, 1.0] for material " << rMaterialProperties.Id() << "." + << std::endl; KRATOS_ERROR_IF_NOT(rMaterialProperties.Has(RESIDUAL_SATURATION)) - << "RESIDUAL_SATURATION is not available in material parameters" << std::endl; - KRATOS_DEBUG_ERROR_IF_NOT(rMaterialProperties[RESIDUAL_SATURATION] > 0.0) - << "RESIDUAL_SATURATION must be greater than 0 " << std::endl; - KRATOS_ERROR_IF(rMaterialProperties[RESIDUAL_SATURATION] > 1.0) - << "RESIDUAL_SATURATION cannot be greater than 1.0 " << std::endl; + << "RESIDUAL_SATURATION is not available in the parameters of material " + << rMaterialProperties.Id() << "." << std::endl; + KRATOS_ERROR_IF(rMaterialProperties[RESIDUAL_SATURATION] < 0.0 || rMaterialProperties[RESIDUAL_SATURATION] >= rMaterialProperties[SATURATED_SATURATION]) + << "RESIDUAL_SATURATION (" << rMaterialProperties[RESIDUAL_SATURATION] + << ") must be in the range [0.0, " << rMaterialProperties[SATURATED_SATURATION] + << "> for material " << rMaterialProperties.Id() << "." << std::endl; - KRATOS_ERROR_IF(rMaterialProperties[SATURATED_SATURATION] < rMaterialProperties[RESIDUAL_SATURATION]) - << "RESIDUAL_SATURATION cannot be greater than SATURATED_SATURATION " << std::endl; + KRATOS_ERROR_IF_NOT(rMaterialProperties.Has(MINIMUM_RELATIVE_PERMEABILITY)) + << "MINIMUM_RELATIVE_PERMEABILITY is not available in the parameters of material " + << rMaterialProperties.Id() << "." << std::endl; + KRATOS_ERROR_IF(rMaterialProperties[MINIMUM_RELATIVE_PERMEABILITY] < 0.0 || rMaterialProperties[MINIMUM_RELATIVE_PERMEABILITY] > 1.0) + << "MINIMUM_RELATIVE_PERMEABILITY (" << rMaterialProperties[MINIMUM_RELATIVE_PERMEABILITY] + << ") must be in the range [0.0, 1.0] for material " << rMaterialProperties.Id() << "." + << std::endl; KRATOS_ERROR_IF_NOT(rMaterialProperties.Has(VAN_GENUCHTEN_AIR_ENTRY_PRESSURE)) - << "VAN_GENUCHTEN_AIR_ENTRY_PRESSURE is not available in material parameters" << std::endl; + << "VAN_GENUCHTEN_AIR_ENTRY_PRESSURE is not available in the parameters of material " + << rMaterialProperties.Id() << "." << std::endl; KRATOS_ERROR_IF_NOT((rMaterialProperties[VAN_GENUCHTEN_AIR_ENTRY_PRESSURE] > 0.0)) - << "VAN_GENUCHTEN_AIR_ENTRY_PRESSURE must be greater than 0 " << std::endl; - - KRATOS_ERROR_IF_NOT(rMaterialProperties.Has(MINIMUM_RELATIVE_PERMEABILITY)) - << "MINIMUM_RELATIVE_PERMEABILITY is not available in material parameters" << std::endl; - KRATOS_ERROR_IF_NOT((rMaterialProperties[MINIMUM_RELATIVE_PERMEABILITY] > 0.0)) - << "MINIMUM_RELATIVE_PERMEABILITY must be greater than 0 " << std::endl; + << "VAN_GENUCHTEN_AIR_ENTRY_PRESSURE (" + << rMaterialProperties[VAN_GENUCHTEN_AIR_ENTRY_PRESSURE] << ") must be greater than 0 " + << "for material " << rMaterialProperties.Id() << "." << std::endl; + + KRATOS_ERROR_IF_NOT(rMaterialProperties.Has(VAN_GENUCHTEN_GN)) + << "VAN_GENUCHTEN_GN is not available in the parameters of material " + << rMaterialProperties.Id() << "." << std::endl; + KRATOS_ERROR_IF_NOT((rMaterialProperties[VAN_GENUCHTEN_GN] > 0.0)) + << "VAN_GENUCHTEN_GN (" << rMaterialProperties[VAN_GENUCHTEN_GN] << ") must be greater than 0 " + << "for material " << rMaterialProperties.Id() << "." << std::endl; + + KRATOS_ERROR_IF_NOT(rMaterialProperties.Has(VAN_GENUCHTEN_GL)) + << "VAN_GENUCHTEN_GL is not available in the parameters of material " + << rMaterialProperties.Id() << "." << std::endl; + KRATOS_ERROR_IF_NOT((rMaterialProperties[VAN_GENUCHTEN_GL] > 0.0)) + << "VAN_GENUCHTEN_GL (" << rMaterialProperties[VAN_GENUCHTEN_GL] + << ") must be greater than 0 for material " << rMaterialProperties.Id() << "." << std::endl; return 0; } diff --git a/applications/GeoMechanicsApplication/tests/cpp_tests/custom_retention/test_saturated_law.cpp b/applications/GeoMechanicsApplication/tests/cpp_tests/custom_retention/test_saturated_law.cpp index b02a6781b3e6..b1526ced4ab0 100644 --- a/applications/GeoMechanicsApplication/tests/cpp_tests/custom_retention/test_saturated_law.cpp +++ b/applications/GeoMechanicsApplication/tests/cpp_tests/custom_retention/test_saturated_law.cpp @@ -18,10 +18,7 @@ namespace using namespace Kratos; -SaturatedLaw CreateSaturatedLaw() -{ - return SaturatedLaw{}; -} +SaturatedLaw CreateSaturatedLaw() { return SaturatedLaw{}; } } // namespace @@ -40,7 +37,7 @@ KRATOS_TEST_CASE_IN_SUITE(SaturatedLawReturnsCalculatedValues, KratosGeoMechanic { auto law = CreateSaturatedLaw(); Properties properties; - auto retention_law_parameters = RetentionLaw::Parameters{properties}; + auto retention_law_parameters = RetentionLaw::Parameters{properties}; KRATOS_EXPECT_DOUBLE_EQ(law.CalculateSaturation(retention_law_parameters), 1.0); double value = 0.0; diff --git a/applications/GeoMechanicsApplication/tests/cpp_tests/custom_retention/test_van_genuchten_law.cpp b/applications/GeoMechanicsApplication/tests/cpp_tests/custom_retention/test_van_genuchten_law.cpp new file mode 100644 index 000000000000..0692f5225d51 --- /dev/null +++ b/applications/GeoMechanicsApplication/tests/cpp_tests/custom_retention/test_van_genuchten_law.cpp @@ -0,0 +1,145 @@ +// KRATOS___ +// // ) ) +// // ___ ___ +// // ____ //___) ) // ) ) +// // / / // // / / +// ((____/ / ((____ ((___/ / MECHANICS +// +// License: geo_mechanics_application/license.txt +// +// Main authors: Wijtze Pieter Kikstra +// + +#include "custom_retention/van_genuchten_law.h" +#include "tests/cpp_tests/geo_mechanics_fast_suite.h" + +namespace +{ + +using namespace Kratos; + +VanGenuchtenLaw CreateVanGenuchtenLaw() { return VanGenuchtenLaw{}; } + +} // namespace + +namespace Kratos::Testing +{ + +KRATOS_TEST_CASE_IN_SUITE(VanGenuchtenLawReturnsCloneOfCorrectType, KratosGeoMechanicsFastSuiteWithoutKernel) +{ + const auto law = CreateVanGenuchtenLaw(); + const auto p_law_clone = law.Clone(); + KRATOS_EXPECT_NE(&law, p_law_clone.get()); + KRATOS_EXPECT_NE(dynamic_cast(p_law_clone.get()), nullptr); +} + +KRATOS_TEST_CASE_IN_SUITE(VanGenuchtenLawReturnsCalculatedValues, KratosGeoMechanicsFastSuiteWithoutKernel) +{ + auto law = CreateVanGenuchtenLaw(); + Properties properties; + properties.SetValue(SATURATED_SATURATION, 0.9); + properties.SetValue(RESIDUAL_SATURATION, 0.1); + properties.SetValue(MINIMUM_RELATIVE_PERMEABILITY, 0.05); + properties.SetValue(VAN_GENUCHTEN_AIR_ENTRY_PRESSURE, 2.5); + properties.SetValue(VAN_GENUCHTEN_GN, 2.5); + properties.SetValue(VAN_GENUCHTEN_GL, 1.5); + + auto retention_law_parameters = RetentionLaw::Parameters{properties}; + + retention_law_parameters.SetFluidPressure(-10.0); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateSaturation(retention_law_parameters), 0.9); + double value = 0.0; + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateValue(retention_law_parameters, DEGREE_OF_SATURATION, value), 0.9); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateEffectiveSaturation(retention_law_parameters), 1.0); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateValue(retention_law_parameters, EFFECTIVE_SATURATION, value), 1.0); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateBishopCoefficient(retention_law_parameters), 1.0); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateValue(retention_law_parameters, BISHOP_COEFFICIENT, value), 1.0); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateDerivativeOfSaturation(retention_law_parameters), 0.0); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateValue(retention_law_parameters, DERIVATIVE_OF_SATURATION, value), 0.0); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateRelativePermeability(retention_law_parameters), 1.0); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateValue(retention_law_parameters, RELATIVE_PERMEABILITY, value), 1.0); + + // Values below are regression values, avoiding reimplementation here of the Van Genuchten Law + retention_law_parameters.SetFluidPressure(1.5); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateSaturation(retention_law_parameters), 0.79023542376288392); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateValue(retention_law_parameters, DEGREE_OF_SATURATION, value), + 0.79023542376288392); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateEffectiveSaturation(retention_law_parameters), 0.86279427970360489); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateValue(retention_law_parameters, EFFECTIVE_SATURATION, value), + 0.86279427970360489); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateBishopCoefficient(retention_law_parameters), 0.86279427970360489); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateValue(retention_law_parameters, BISHOP_COEFFICIENT, value), + 0.86279427970360489); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateDerivativeOfSaturation(retention_law_parameters), -0.15050611026881838); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateValue(retention_law_parameters, DERIVATIVE_OF_SATURATION, value), + -0.15050611026881838); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateRelativePermeability(retention_law_parameters), 0.28755984470352691); + KRATOS_EXPECT_DOUBLE_EQ(law.CalculateValue(retention_law_parameters, RELATIVE_PERMEABILITY, value), + 0.28755984470352691); +} + +KRATOS_TEST_CASE_IN_SUITE(VanGenuchtenLawChecksInputParameters, KratosGeoMechanicsFastSuiteWithoutKernel) +{ + Properties properties; + properties.SetId(1); + const auto process_info = ProcessInfo{}; + auto law = CreateVanGenuchtenLaw(); + + KRATOS_EXPECT_EXCEPTION_IS_THROWN( + law.Check(properties, process_info), + "SATURATED_SATURATION is not available in the parameters of material 1."); + properties.SetValue(SATURATED_SATURATION, 1.1); + KRATOS_EXPECT_EXCEPTION_IS_THROWN( + law.Check(properties, process_info), + "SATURATED_SATURATION (1.1) must be in the range [0.0, 1.0] for material 1."); + properties.SetValue(SATURATED_SATURATION, 0.9); + + KRATOS_EXPECT_EXCEPTION_IS_THROWN( + law.Check(properties, process_info), + "RESIDUAL_SATURATION is not available in the parameters of material 1."); + properties.SetValue(RESIDUAL_SATURATION, 1.1); + KRATOS_EXPECT_EXCEPTION_IS_THROWN( + law.Check(properties, process_info), + "RESIDUAL_SATURATION (1.1) must be in the range [0.0, 0.9> for material 1."); + properties.SetValue(RESIDUAL_SATURATION, 0.1); + + KRATOS_EXPECT_EXCEPTION_IS_THROWN( + law.Check(properties, process_info), + "MINIMUM_RELATIVE_PERMEABILITY is not available in the parameters of material 1."); + properties.SetValue(MINIMUM_RELATIVE_PERMEABILITY, 1.1); + KRATOS_EXPECT_EXCEPTION_IS_THROWN( + law.Check(properties, process_info), + "MINIMUM_RELATIVE_PERMEABILITY (1.1) must be in the range [0.0, 1.0] for material 1."); + properties.SetValue(MINIMUM_RELATIVE_PERMEABILITY, 0.05); + + KRATOS_EXPECT_EXCEPTION_IS_THROWN( + law.Check(properties, process_info), + "VAN_GENUCHTEN_AIR_ENTRY_PRESSURE is not available in the parameters of material 1."); + properties.SetValue(VAN_GENUCHTEN_AIR_ENTRY_PRESSURE, -4.0); + KRATOS_EXPECT_EXCEPTION_IS_THROWN( + law.Check(properties, process_info), + "VAN_GENUCHTEN_AIR_ENTRY_PRESSURE (-4) must be greater than 0 for material 1."); + properties.SetValue(VAN_GENUCHTEN_AIR_ENTRY_PRESSURE, 4.0); + + KRATOS_EXPECT_EXCEPTION_IS_THROWN( + law.Check(properties, process_info), + "VAN_GENUCHTEN_GN is not available in the parameters of material 1."); + properties.SetValue(VAN_GENUCHTEN_GN, -2.5); + KRATOS_EXPECT_EXCEPTION_IS_THROWN( + law.Check(properties, process_info), + "VAN_GENUCHTEN_GN (-2.5) must be greater than 0 for material 1."); + properties.SetValue(VAN_GENUCHTEN_GN, 2.5); + + KRATOS_EXPECT_EXCEPTION_IS_THROWN( + law.Check(properties, process_info), + "VAN_GENUCHTEN_GL is not available in the parameters of material 1."); + properties.SetValue(VAN_GENUCHTEN_GL, -1.5); + KRATOS_EXPECT_EXCEPTION_IS_THROWN( + law.Check(properties, process_info), + "VAN_GENUCHTEN_GL (-1.5) must be greater than 0 for material 1."); + properties.SetValue(VAN_GENUCHTEN_GL, 1.5); + + KRATOS_EXPECT_EQ(law.Check(properties, process_info), 0); +} + +} // namespace Kratos::Testing \ No newline at end of file From 60eb250069fc89bd84a03ad2f40f113fcfcc51dc Mon Sep 17 00:00:00 2001 From: mnabideltares Date: Mon, 9 Dec 2024 14:49:42 +0100 Subject: [PATCH 11/36] Fixes for partially saturated flow --- .../U_Pw_small_strain_element.cpp | 2 +- .../small_strain_U_Pw_diff_order_element.cpp | 63 ++++--------------- .../saturated_below_phreatic_level_law.cpp | 6 +- 3 files changed, 19 insertions(+), 52 deletions(-) diff --git a/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp b/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp index 0e890df34ecd..42084001aa57 100644 --- a/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp +++ b/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp @@ -1493,7 +1493,7 @@ array_1d UPwSmallStrainElement::CalculateFlu const BoundedMatrix temp_matrix = prod(rVariables.GradNpT, rVariables.PermeabilityMatrix) * rVariables.IntegrationCoefficient; - return rVariables.DynamicViscosityInverse * this->GetProperties()[DENSITY_WATER] * + return rVariables.DynamicViscosityInverse * this->GetProperties()[DENSITY_WATER] * rVariables.BishopCoefficient * rVariables.RelativePermeability * prod(temp_matrix, rVariables.BodyAcceleration); KRATOS_CATCH("") diff --git a/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp b/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp index 23f2b5b1edee..96ab8e233bb0 100644 --- a/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp +++ b/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp @@ -162,6 +162,11 @@ int SmallStrainUPwDiffOrderElement::Check(const ProcessInfo& rCurrentProcessInfo << " in element id: " << this->Id() << std::endl; } + // Check constitutive law + if (mRetentionLawVector.size() > 0) { + return mRetentionLawVector[0]->Check(rProp, rCurrentProcessInfo); + } + return 0; KRATOS_CATCH("") @@ -860,9 +865,7 @@ void SmallStrainUPwDiffOrderElement::CalculateAll(MatrixType& rLeftHandSi bool CalculateResidualVectorFlag) { KRATOS_TRY - if (this->Id() == 1 || this->Id() == 13) { - KRATOS_INFO("Element = ") << this->Id() << std::endl; - } + const PropertiesType& rProp = this->GetProperties(); const GeometryType& rGeom = GetGeometry(); const GeometryType::IntegrationPointsArrayType& IntegrationPoints = @@ -1277,14 +1280,11 @@ void SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingMatrix(MatrixType& r GeoElementUtilities::AssembleUPBlockMatrix(rLeftHandSideMatrix, CouplingMatrix); if (!rVariables.IgnoreUndrained) { - // const double SaturationCoefficient = rVariables.DegreeOfSaturation / rVariables.BishopCoefficient; - // Matrix CouplingMatrixT = PORE_PRESSURE_SIGN_FACTOR * SaturationCoefficient * - // rVariables.VelocityCoefficient * trans(CouplingMatrix); Matrix CouplingMatrix = GeoTransportEquationUtilities::CalculateCouplingMatrix( rVariables.B, GetStressStatePolicy().GetVoigtVector(), rVariables.Np, rVariables.BiotCoefficient, rVariables.DegreeOfSaturation, rVariables.IntegrationCoefficient); - Matrix CouplingMatrixT = - PORE_PRESSURE_SIGN_FACTOR * rVariables.VelocityCoefficient * trans(CouplingMatrix); + Matrix CouplingMatrixT = PORE_PRESSURE_SIGN_FACTOR * + rVariables.VelocityCoefficient * trans(CouplingMatrix); GeoElementUtilities::AssemblePUBlockMatrix(rLeftHandSideMatrix, CouplingMatrixT); } @@ -1337,10 +1337,7 @@ void SmallStrainUPwDiffOrderElement::CalculateAndAddStiffnessForce(VectorType& r Vector stiffness_force = -1.0 * prod(trans(rVariables.B), mStressVector[GPoint]) * rVariables.IntegrationCoefficient; GeoElementUtilities::AssembleUBlockVector(rRightHandSideVector, stiffness_force); - // if ( this->Id() == 1 || this->Id() == 13 ) { - // KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddStiffnessForce ") << "dF = " << stiffness_force << std::endl; - // KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddStiffnessForce ") << "RHS = " << rRightHandSideVector << std::endl; - // } + KRATOS_CATCH("") } @@ -1371,9 +1368,6 @@ void SmallStrainUPwDiffOrderElement::CalculateAndAddMixBodyForce(VectorType& rRi rVariables.IntegrationCoefficientInitialConfiguration; } } - // if ( this->Id() == 1 || this->Id() == 13 ) { - // KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddBodyForce ") << "RHS = " << rRightHandSideVector << std::endl; - // } KRATOS_CATCH("") } @@ -1389,31 +1383,15 @@ void SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingTerms(VectorType& rR rVariables.BiotCoefficient, rVariables.BishopCoefficient, rVariables.IntegrationCoefficient); const Vector coupling_force = prod(coupling_matrix, rVariables.PressureVector); GeoElementUtilities::AssembleUBlockVector(rRightHandSideVector, coupling_force); - // if ( this->Id() == 1 || this->Id() == 13 ) { - // KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingTerms ") << "v - // = " << rVariables.VelocityVector << std::endl; KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingTerms - // ") << "Pw = " << rVariables.PressureVector << std::endl; KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingTerms - // ") << "dF = " << coupling_force << std::endl; KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingTerms - // ") << "RHS = " << rRightHandSideVector << std::endl; - // } if (!rVariables.IgnoreUndrained) { - // const double SaturationCoefficient = rVariables.DegreeOfSaturation / rVariables.BishopCoefficient; - // const Vector coupling_flow = PORE_PRESSURE_SIGN_FACTOR * SaturationCoefficient * - // prod(trans(coupling_matrix), rVariables.VelocityVector); const Matrix coupling_matrix = (-1.0) * GeoTransportEquationUtilities::CalculateCouplingMatrix( rVariables.B, GetStressStatePolicy().GetVoigtVector(), rVariables.Np, - rVariables.BiotCoefficient, rVariables.DegreeOfSaturation, - rVariables.IntegrationCoefficient); - const Vector coupling_flow = - PORE_PRESSURE_SIGN_FACTOR * prod(trans(coupling_matrix), rVariables.VelocityVector); + rVariables.BiotCoefficient, rVariables.DegreeOfSaturation, rVariables.IntegrationCoefficient); + const Vector coupling_flow = PORE_PRESSURE_SIGN_FACTOR * + prod(trans(coupling_matrix), rVariables.VelocityVector); GeoElementUtilities::AssemblePBlockVector(rRightHandSideVector, coupling_flow); - // if ( this->Id() == 1 || this->Id() == 13 ) { - // KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingTerms ") << "v = " << rVariables.VelocityVector << std::endl; - // KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingTerms ") << "dQ = " << coupling_flow << std::endl; - // KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingTerms ") << "RHS = " << rRightHandSideVector << std::endl; - // } } KRATOS_CATCH("") @@ -1428,11 +1406,7 @@ void SmallStrainUPwDiffOrderElement::CalculateAndAddCompressibilityFlow(VectorTy rVariables.Np, rVariables.BiotModulusInverse, rVariables.IntegrationCoefficient); Vector CompressibilityFlow = -prod(CompressibilityMatrix, rVariables.PressureDtVector); GeoElementUtilities::AssemblePBlockVector(rRightHandSideVector, CompressibilityFlow); - // if ( this->Id() == 1 || this->Id() == 13 ) { - // KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCompressibilityFlow") << "dPdt= " << rVariables.PressureDtVector << std::endl; - // KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCompressibilityFlow") << "dQ = " << CompressibilityFlow << std::endl; - // KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddCompressibilityFlow") << "RHS = " << rRightHandSideVector << std::endl; - // } + KRATOS_CATCH("") } @@ -1475,15 +1449,8 @@ void SmallStrainUPwDiffOrderElement::CalculateAndAddPermeabilityFlow(VectorType& -PORE_PRESSURE_SIGN_FACTOR * rVariables.DynamicViscosityInverse * rVariables.RelativePermeability * prod(rVariables.DNp_DX, Matrix(prod(rVariables.IntrinsicPermeability, trans(rVariables.DNp_DX)))) * rVariables.IntegrationCoefficient; - const Vector permeability_flow = -prod(permeability_matrix, rVariables.PressureVector); - GeoElementUtilities::AssemblePBlockVector(rRightHandSideVector, permeability_flow); - // if ( this->Id() == 1 || this->Id() == 13 ) { - // KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddPermeabilityFlow ") << "Pw = " << rVariables.PressureVector << std::endl; - // KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddPermeabilityFlow ") << "dQ = " << permeability_flow << std::endl; - // KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddPermeabilityFlow ") << "RHS = " << rRightHandSideVector << std::endl; - // } KRATOS_CATCH("") } @@ -1514,10 +1481,6 @@ void SmallStrainUPwDiffOrderElement::CalculateAndAddFluidBodyFlow(VectorType& rR const Vector fluid_body_flow = prod(grad_Np_T_perm, body_acceleration); GeoElementUtilities::AssemblePBlockVector(rRightHandSideVector, fluid_body_flow); - // if ( this->Id() == 1 || this->Id() == 13 ) { - // KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddFluidBodyFlow ") << "dQ = " << fluid_body_flow << std::endl; - // KRATOS_INFO("SmallStrainUPwDiffOrderElement::CalculateAndAddFluidBodyFlow ") << "RHS = " << rRightHandSideVector << std::endl; - // } KRATOS_CATCH("") } diff --git a/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp b/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp index c501587a89a6..cc798f5a0a3d 100644 --- a/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp +++ b/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp @@ -12,9 +12,13 @@ // // System includes -#include "custom_retention/saturated_below_phreatic_level_law.h" #include +// External includes + +// Project includes +#include "custom_retention/saturated_below_phreatic_level_law.h" + namespace Kratos { SaturatedBelowPhreaticLevelLaw::SaturatedBelowPhreaticLevelLaw() : RetentionLaw() {} From e203f4cbe7efc2ef23cd81d45b78c110a7aaf3dc Mon Sep 17 00:00:00 2001 From: Wijtze Pieter Kikstra Date: Mon, 9 Dec 2024 15:50:22 +0100 Subject: [PATCH 12/36] Attempt to only place includes there where they are used. --- .../small_strain_U_Pw_diff_order_element.cpp | 11 +++++----- .../custom_retention/retention_law.h | 9 +++------ .../saturated_below_phreatic_level_law.cpp | 7 +------ .../saturated_below_phreatic_level_law.h | 18 +---------------- .../custom_retention/saturated_law.cpp | 4 +--- .../custom_retention/saturated_law.h | 20 ++----------------- .../custom_retention/van_genuchten_law.cpp | 2 +- .../custom_retention/van_genuchten_law.h | 19 +----------------- ...est_saturated_below_phreatic_level_law.cpp | 1 + .../custom_retention/test_saturated_law.cpp | 1 + .../test_van_genuchten_law.cpp | 1 + 11 files changed, 19 insertions(+), 74 deletions(-) diff --git a/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp b/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp index 96ab8e233bb0..3652ca789371 100644 --- a/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp +++ b/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp @@ -1283,8 +1283,8 @@ void SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingMatrix(MatrixType& r Matrix CouplingMatrix = GeoTransportEquationUtilities::CalculateCouplingMatrix( rVariables.B, GetStressStatePolicy().GetVoigtVector(), rVariables.Np, rVariables.BiotCoefficient, rVariables.DegreeOfSaturation, rVariables.IntegrationCoefficient); - Matrix CouplingMatrixT = PORE_PRESSURE_SIGN_FACTOR * - rVariables.VelocityCoefficient * trans(CouplingMatrix); + Matrix CouplingMatrixT = + PORE_PRESSURE_SIGN_FACTOR * rVariables.VelocityCoefficient * trans(CouplingMatrix); GeoElementUtilities::AssemblePUBlockMatrix(rLeftHandSideMatrix, CouplingMatrixT); } @@ -1388,9 +1388,10 @@ void SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingTerms(VectorType& rR const Matrix coupling_matrix = (-1.0) * GeoTransportEquationUtilities::CalculateCouplingMatrix( rVariables.B, GetStressStatePolicy().GetVoigtVector(), rVariables.Np, - rVariables.BiotCoefficient, rVariables.DegreeOfSaturation, rVariables.IntegrationCoefficient); - const Vector coupling_flow = PORE_PRESSURE_SIGN_FACTOR * - prod(trans(coupling_matrix), rVariables.VelocityVector); + rVariables.BiotCoefficient, rVariables.DegreeOfSaturation, + rVariables.IntegrationCoefficient); + const Vector coupling_flow = + PORE_PRESSURE_SIGN_FACTOR * prod(trans(coupling_matrix), rVariables.VelocityVector); GeoElementUtilities::AssemblePBlockVector(rRightHandSideVector, coupling_flow); } diff --git a/applications/GeoMechanicsApplication/custom_retention/retention_law.h b/applications/GeoMechanicsApplication/custom_retention/retention_law.h index 2f9d78880840..be54ff573727 100644 --- a/applications/GeoMechanicsApplication/custom_retention/retention_law.h +++ b/applications/GeoMechanicsApplication/custom_retention/retention_law.h @@ -193,13 +193,10 @@ class KRATOS_API(GEO_MECHANICS_APPLICATION) RetentionLaw return RetentionLaw::HasSameType(*rLHS, *rRHS); } - /// Turn back information as a string. virtual std::string Info() const { return "RetentionLaw"; } - /// Print information about this object. virtual void PrintInfo(std::ostream& rOStream) const { rOStream << Info(); } - /// Print object's data. virtual void PrintData(std::ostream& rOStream) const { rOStream << "RetentionLaw has no data"; } private: @@ -211,10 +208,10 @@ class KRATOS_API(GEO_MECHANICS_APPLICATION) RetentionLaw }; /* Class RetentionLaw */ -/// input stream function +// input stream function inline std::istream& operator>>(std::istream& rIStream, RetentionLaw& rThis); -/// output stream function +// output stream function inline std::ostream& operator<<(std::ostream& rOStream, const RetentionLaw& rThis) { rThis.PrintInfo(rOStream); @@ -224,4 +221,4 @@ inline std::ostream& operator<<(std::ostream& rOStream, const RetentionLaw& rThi return rOStream; } -} /* namespace Kratos.*/ +} /* namespace Kratos.*/ \ No newline at end of file diff --git a/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp b/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp index cc798f5a0a3d..d4b955fcc521 100644 --- a/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp +++ b/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp @@ -11,13 +11,8 @@ // Main authors: Vahid Galavi // -// System includes -#include - -// External includes - -// Project includes #include "custom_retention/saturated_below_phreatic_level_law.h" +#include "geo_mechanics_application_variables.h" namespace Kratos { diff --git a/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.h b/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.h index ea7b6378933a..70b8eaef26ee 100644 --- a/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.h +++ b/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.h @@ -12,20 +12,10 @@ #pragma once -// System includes -#include "includes/define.h" -#include -#include - -// External includes - // Project includes #include "custom_retention/retention_law.h" #include "includes/serializer.h" -// Application includes -#include "geo_mechanics_application_variables.h" - namespace Kratos { /** @@ -38,15 +28,9 @@ namespace Kratos class KRATOS_API(GEO_MECHANICS_APPLICATION) SaturatedBelowPhreaticLevelLaw : public RetentionLaw { public: - /// The base class RetentionLaw type definition - using BaseType = RetentionLaw; - using GeometryType = Geometry; - /// The size type definition - using SizeType = std::size_t; - - /// Counted pointer of SaturatedBelowPhreaticLevelLaw + // Counted pointer of SaturatedBelowPhreaticLevelLaw KRATOS_CLASS_POINTER_DEFINITION(SaturatedBelowPhreaticLevelLaw); SaturatedBelowPhreaticLevelLaw(); diff --git a/applications/GeoMechanicsApplication/custom_retention/saturated_law.cpp b/applications/GeoMechanicsApplication/custom_retention/saturated_law.cpp index 841091b1c9f6..6d6a47915514 100644 --- a/applications/GeoMechanicsApplication/custom_retention/saturated_law.cpp +++ b/applications/GeoMechanicsApplication/custom_retention/saturated_law.cpp @@ -11,10 +11,8 @@ // Main authors: Vahid Galavi // -// System includes -#include - #include "custom_retention/saturated_law.h" +#include "geo_mechanics_application_variables.h" namespace Kratos { diff --git a/applications/GeoMechanicsApplication/custom_retention/saturated_law.h b/applications/GeoMechanicsApplication/custom_retention/saturated_law.h index c37244e55890..70a7a2f7b94c 100644 --- a/applications/GeoMechanicsApplication/custom_retention/saturated_law.h +++ b/applications/GeoMechanicsApplication/custom_retention/saturated_law.h @@ -12,20 +12,10 @@ #pragma once -// System includes -#include "includes/define.h" -#include -#include - -// External includes - -// Project includes #include "custom_retention/retention_law.h" +#include "includes/define.h" #include "includes/serializer.h" -// Application includes -#include "geo_mechanics_application_variables.h" - namespace Kratos { /** @@ -38,15 +28,9 @@ namespace Kratos class KRATOS_API(GEO_MECHANICS_APPLICATION) SaturatedLaw : public RetentionLaw { public: - /// The base class RetentionLaw type definition - using BaseType = RetentionLaw; - using GeometryType = Geometry; - /// The size type definition - using SizeType = std::size_t; - - /// Counted pointer of SaturatedLaw + // Counted pointer of SaturatedLaw KRATOS_CLASS_POINTER_DEFINITION(SaturatedLaw); RetentionLaw::Pointer Clone() const override; diff --git a/applications/GeoMechanicsApplication/custom_retention/van_genuchten_law.cpp b/applications/GeoMechanicsApplication/custom_retention/van_genuchten_law.cpp index b10cc7d5c690..fa6975e0c141 100644 --- a/applications/GeoMechanicsApplication/custom_retention/van_genuchten_law.cpp +++ b/applications/GeoMechanicsApplication/custom_retention/van_genuchten_law.cpp @@ -11,8 +11,8 @@ // Main authors: Vahid Galavi // -// Project includes #include "custom_retention/van_genuchten_law.h" +#include "geo_mechanics_application_variables.h" namespace Kratos { diff --git a/applications/GeoMechanicsApplication/custom_retention/van_genuchten_law.h b/applications/GeoMechanicsApplication/custom_retention/van_genuchten_law.h index 9174370beedf..c7b780f1d04f 100644 --- a/applications/GeoMechanicsApplication/custom_retention/van_genuchten_law.h +++ b/applications/GeoMechanicsApplication/custom_retention/van_genuchten_law.h @@ -12,20 +12,9 @@ #pragma once -// System includes -#include "includes/define.h" -#include -#include - -// External includes - -// Project includes #include "custom_retention/retention_law.h" #include "includes/serializer.h" -// Application includes -#include "geo_mechanics_application_variables.h" - namespace Kratos { /** @@ -38,15 +27,9 @@ namespace Kratos class KRATOS_API(GEO_MECHANICS_APPLICATION) VanGenuchtenLaw : public RetentionLaw { public: - /// The base class RetentionLaw type definition - using BaseType = RetentionLaw; - using GeometryType = Geometry; - /// The size type definition - using SizeType = std::size_t; - - /// Counted pointer of VanGenuchtenLaw + // Counted pointer of VanGenuchtenLaw KRATOS_CLASS_POINTER_DEFINITION(VanGenuchtenLaw); RetentionLaw::Pointer Clone() const override; diff --git a/applications/GeoMechanicsApplication/tests/cpp_tests/custom_retention/test_saturated_below_phreatic_level_law.cpp b/applications/GeoMechanicsApplication/tests/cpp_tests/custom_retention/test_saturated_below_phreatic_level_law.cpp index 4be68d46c713..48d02a0e19ee 100644 --- a/applications/GeoMechanicsApplication/tests/cpp_tests/custom_retention/test_saturated_below_phreatic_level_law.cpp +++ b/applications/GeoMechanicsApplication/tests/cpp_tests/custom_retention/test_saturated_below_phreatic_level_law.cpp @@ -11,6 +11,7 @@ // #include "custom_retention/saturated_below_phreatic_level_law.h" +#include "geo_mechanics_application_variables.h" #include "tests/cpp_tests/geo_mechanics_fast_suite.h" namespace diff --git a/applications/GeoMechanicsApplication/tests/cpp_tests/custom_retention/test_saturated_law.cpp b/applications/GeoMechanicsApplication/tests/cpp_tests/custom_retention/test_saturated_law.cpp index b1526ced4ab0..350d659f66ab 100644 --- a/applications/GeoMechanicsApplication/tests/cpp_tests/custom_retention/test_saturated_law.cpp +++ b/applications/GeoMechanicsApplication/tests/cpp_tests/custom_retention/test_saturated_law.cpp @@ -11,6 +11,7 @@ // #include "custom_retention/saturated_law.h" +#include "geo_mechanics_application_variables.h" #include "tests/cpp_tests/geo_mechanics_fast_suite.h" namespace diff --git a/applications/GeoMechanicsApplication/tests/cpp_tests/custom_retention/test_van_genuchten_law.cpp b/applications/GeoMechanicsApplication/tests/cpp_tests/custom_retention/test_van_genuchten_law.cpp index 0692f5225d51..e8908d80bb17 100644 --- a/applications/GeoMechanicsApplication/tests/cpp_tests/custom_retention/test_van_genuchten_law.cpp +++ b/applications/GeoMechanicsApplication/tests/cpp_tests/custom_retention/test_van_genuchten_law.cpp @@ -11,6 +11,7 @@ // #include "custom_retention/van_genuchten_law.h" +#include "geo_mechanics_application_variables.h" #include "tests/cpp_tests/geo_mechanics_fast_suite.h" namespace From 124346e67f2c9f9bc3f8a90abb1707a6acec3f01 Mon Sep 17 00:00:00 2001 From: Wijtze Pieter Kikstra Date: Mon, 9 Dec 2024 16:32:04 +0100 Subject: [PATCH 13/36] Cleanup attempts --- .../custom_retention/retention_law.h | 48 +++++-------------- .../saturated_below_phreatic_level_law.cpp | 7 +-- .../saturated_below_phreatic_level_law.h | 3 +- .../custom_retention/saturated_law.h | 7 +-- .../custom_retention/van_genuchten_law.cpp | 2 +- .../custom_retention/van_genuchten_law.h | 7 +-- 6 files changed, 21 insertions(+), 53 deletions(-) diff --git a/applications/GeoMechanicsApplication/custom_retention/retention_law.h b/applications/GeoMechanicsApplication/custom_retention/retention_law.h index be54ff573727..4eb69a25ba4b 100644 --- a/applications/GeoMechanicsApplication/custom_retention/retention_law.h +++ b/applications/GeoMechanicsApplication/custom_retention/retention_law.h @@ -27,17 +27,9 @@ namespace Kratos class KRATOS_API(GEO_MECHANICS_APPLICATION) RetentionLaw { public: - /** - * Type definitions - * NOTE: geometries are assumed to be of type Node for all problems - */ - using ProcessInfoType = ProcessInfo; - using SizeType = std::size_t; - using GeometryType = Geometry; + using GeometryType = Geometry; - /** - * Counted pointer of RetentionLaw - */ + // Counted pointer of RetentionLaw KRATOS_CLASS_POINTER_DEFINITION(RetentionLaw); class Parameters @@ -46,19 +38,7 @@ class KRATOS_API(GEO_MECHANICS_APPLICATION) RetentionLaw /** * Structure "Parameters" to be used by the element to pass the parameters into the retention law * - - * KINEMATIC PARAMETERS: - - *** NOTE: Pointers are used only to point to a certain variable, - * no "new" or "malloc" can be used for this Parameters *** - - * MATERIAL PROPERTIES: - * @param mrMaterialProperties reference to the material's Properties object (input data) - - * PROCESS PROPERTIES: - * @param mrCurrentProcessInfo reference to current ProcessInfo instance (input data) - - */ + */ public: explicit Parameters(const Properties& rMaterialProperties) @@ -70,7 +50,7 @@ class KRATOS_API(GEO_MECHANICS_APPLICATION) RetentionLaw void SetFluidPressure(double FluidPressure) { mFluidPressure = FluidPressure; }; - double GetFluidPressure() const + [[nodiscard]] double GetFluidPressure() const { KRATOS_ERROR_IF_NOT(mFluidPressure.has_value()) << "Fluid pressure is not yet set in the retention " @@ -78,7 +58,10 @@ class KRATOS_API(GEO_MECHANICS_APPLICATION) RetentionLaw return mFluidPressure.value(); } - const Properties& GetMaterialProperties() const { return mrMaterialProperties; } + [[nodiscard]] const Properties& GetMaterialProperties() const + { + return mrMaterialProperties; + } private: std::optional mFluidPressure; @@ -97,11 +80,11 @@ class KRATOS_API(GEO_MECHANICS_APPLICATION) RetentionLaw * RetentionLaw::Pointer p_clone(new RetentionLaw()); * return p_clone; */ - virtual RetentionLaw::Pointer Clone() const = 0; + [[nodiscard]] virtual Pointer Clone() const = 0; /** * @brief Calculates the value of a specified variable (double) - * @param rParameterValues the needed parameters for the CL calculation + * @param rParameters the needed parameters for the CL calculation * @param rThisVariable the variable to be returned * @param rValue a reference to the returned value * @param rValue output: the value of the specified variable @@ -124,7 +107,7 @@ class KRATOS_API(GEO_MECHANICS_APPLICATION) RetentionLaw * attributes of the retention law * @param rMaterialProperties the Properties instance of the current element * @param rElementGeometry the geometry of the current element - * @param rCurrentProcessInfo process info + * @param rShapeFunctionsValues shape function values */ virtual void InitializeMaterial(const Properties& rMaterialProperties, const GeometryType& rElementGeometry, @@ -156,7 +139,6 @@ class KRATOS_API(GEO_MECHANICS_APPLICATION) RetentionLaw * @param rMaterialProperties the Properties instance of the current element * @param rElementGeometry the geometry of the current element * @param rShapeFunctionsValues the shape functions values in the current integration point - * @param the current ProcessInfo instance */ virtual void ResetMaterial(const Properties& rMaterialProperties, const GeometryType& rElementGeometry, @@ -167,7 +149,6 @@ class KRATOS_API(GEO_MECHANICS_APPLICATION) RetentionLaw * needed on the input provided. Checks can be "expensive" as the function * is designed to catch user's errors. * @param rMaterialProperties - * @param rElementGeometry * @param rCurrentProcessInfo * @return */ @@ -190,10 +171,10 @@ class KRATOS_API(GEO_MECHANICS_APPLICATION) RetentionLaw */ inline static bool HasSameType(const RetentionLaw* rLHS, const RetentionLaw* rRHS) { - return RetentionLaw::HasSameType(*rLHS, *rRHS); + return HasSameType(*rLHS, *rRHS); } - virtual std::string Info() const { return "RetentionLaw"; } + [[nodiscard]] virtual std::string Info() const { return "RetentionLaw"; } virtual void PrintInfo(std::ostream& rOStream) const { rOStream << Info(); } @@ -208,9 +189,6 @@ class KRATOS_API(GEO_MECHANICS_APPLICATION) RetentionLaw }; /* Class RetentionLaw */ -// input stream function -inline std::istream& operator>>(std::istream& rIStream, RetentionLaw& rThis); - // output stream function inline std::ostream& operator<<(std::ostream& rOStream, const RetentionLaw& rThis) { diff --git a/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp b/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp index d4b955fcc521..31c7798ba591 100644 --- a/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp +++ b/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp @@ -18,17 +18,14 @@ namespace Kratos { SaturatedBelowPhreaticLevelLaw::SaturatedBelowPhreaticLevelLaw() : RetentionLaw() {} -SaturatedBelowPhreaticLevelLaw::SaturatedBelowPhreaticLevelLaw(const SaturatedBelowPhreaticLevelLaw& rOther) - : RetentionLaw(rOther) -{ -} +SaturatedBelowPhreaticLevelLaw::SaturatedBelowPhreaticLevelLaw(const SaturatedBelowPhreaticLevelLaw& rOther) = default; RetentionLaw::Pointer SaturatedBelowPhreaticLevelLaw::Clone() const { return Kratos::make_shared(*this); } -SaturatedBelowPhreaticLevelLaw::~SaturatedBelowPhreaticLevelLaw() {} +SaturatedBelowPhreaticLevelLaw::~SaturatedBelowPhreaticLevelLaw() = default; double SaturatedBelowPhreaticLevelLaw::CalculateSaturation(Parameters& rParameters) const { diff --git a/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.h b/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.h index 70b8eaef26ee..d8bcd0542b82 100644 --- a/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.h +++ b/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.h @@ -35,7 +35,7 @@ class KRATOS_API(GEO_MECHANICS_APPLICATION) SaturatedBelowPhreaticLevelLaw : pub SaturatedBelowPhreaticLevelLaw(); - RetentionLaw::Pointer Clone() const override; + [[nodiscard]] RetentionLaw::Pointer Clone() const override; SaturatedBelowPhreaticLevelLaw(const SaturatedBelowPhreaticLevelLaw& rOther); @@ -78,7 +78,6 @@ class KRATOS_API(GEO_MECHANICS_APPLICATION) SaturatedBelowPhreaticLevelLaw : pub * @brief This function provides the place to perform checks on the completeness of the input. * @details It is designed to be called only once (or anyway, not often) typically at the beginning of the calculations, so to verify that nothing is missing from the input or that no common error is found. * @param rMaterialProperties The properties of the material - * @param rElementGeometry The geometry of the element * @param rCurrentProcessInfo The current process info instance * @return 0 if OK, 1 otherwise */ diff --git a/applications/GeoMechanicsApplication/custom_retention/saturated_law.h b/applications/GeoMechanicsApplication/custom_retention/saturated_law.h index 70a7a2f7b94c..8bb753d61d30 100644 --- a/applications/GeoMechanicsApplication/custom_retention/saturated_law.h +++ b/applications/GeoMechanicsApplication/custom_retention/saturated_law.h @@ -33,7 +33,7 @@ class KRATOS_API(GEO_MECHANICS_APPLICATION) SaturatedLaw : public RetentionLaw // Counted pointer of SaturatedLaw KRATOS_CLASS_POINTER_DEFINITION(SaturatedLaw); - RetentionLaw::Pointer Clone() const override; + [[nodiscard]] RetentionLaw::Pointer Clone() const override; void InitializeMaterial(const Properties& rMaterialProperties, const GeometryType& rElementGeometry, @@ -64,15 +64,12 @@ class KRATOS_API(GEO_MECHANICS_APPLICATION) SaturatedLaw : public RetentionLaw * @param rValue a reference to the returned value * @return rValue output: the value of the specified variable */ - double& CalculateValue(RetentionLaw::Parameters& rParameterValues, - const Variable& rThisVariable, - double& rValue) override; + double& CalculateValue(Parameters& rParameterValues, const Variable& rThisVariable, double& rValue) override; /** * @brief This function provides the place to perform checks on the completeness of the input. * @details It is designed to be called only once (or anyway, not often) typically at the beginning of the calculations, so to verify that nothing is missing from the input or that no common error is found. * @param rMaterialProperties The properties of the material - * @param rElementGeometry The geometry of the element * @param rCurrentProcessInfo The current process info instance * @return 0 if OK, 1 otherwise */ diff --git a/applications/GeoMechanicsApplication/custom_retention/van_genuchten_law.cpp b/applications/GeoMechanicsApplication/custom_retention/van_genuchten_law.cpp index fa6975e0c141..6801a90cbe29 100644 --- a/applications/GeoMechanicsApplication/custom_retention/van_genuchten_law.cpp +++ b/applications/GeoMechanicsApplication/custom_retention/van_genuchten_law.cpp @@ -128,7 +128,7 @@ void VanGenuchtenLaw::InitializeMaterial(const Properties& rMaterialProperties // nothing is needed } -void VanGenuchtenLaw::Initialize(Parameters& rParameters) +void VanGenuchtenLaw::Initialize(Parameters&) { // nothing is needed } diff --git a/applications/GeoMechanicsApplication/custom_retention/van_genuchten_law.h b/applications/GeoMechanicsApplication/custom_retention/van_genuchten_law.h index c7b780f1d04f..bdefa87e619e 100644 --- a/applications/GeoMechanicsApplication/custom_retention/van_genuchten_law.h +++ b/applications/GeoMechanicsApplication/custom_retention/van_genuchten_law.h @@ -32,7 +32,7 @@ class KRATOS_API(GEO_MECHANICS_APPLICATION) VanGenuchtenLaw : public RetentionLa // Counted pointer of VanGenuchtenLaw KRATOS_CLASS_POINTER_DEFINITION(VanGenuchtenLaw); - RetentionLaw::Pointer Clone() const override; + [[nodiscard]] RetentionLaw::Pointer Clone() const override; void InitializeMaterial(const Properties& rMaterialProperties, const GeometryType& rElementGeometry, @@ -63,15 +63,12 @@ class KRATOS_API(GEO_MECHANICS_APPLICATION) VanGenuchtenLaw : public RetentionLa * @param rValue a reference to the returned value * @return rValue output: the value of the specified variable */ - double& CalculateValue(RetentionLaw::Parameters& rParameterValues, - const Variable& rThisVariable, - double& rValue) override; + double& CalculateValue(Parameters& rParameterValues, const Variable& rThisVariable, double& rValue) override; /** * @brief This function provides the place to perform checks on the completeness of the input. * @details It is designed to be called only once (or anyway, not often) typically at the beginning of the calculations, so to verify that nothing is missing from the input or that no common error is found. * @param rMaterialProperties The properties of the material - * @param rElementGeometry The geometry of the element * @param rCurrentProcessInfo The current process info instance * @return 0 if OK, 1 otherwise */ From 62f388d3ac8fb09519b0edcbba47dc3621657a95 Mon Sep 17 00:00:00 2001 From: Wijtze Pieter Kikstra Date: Mon, 9 Dec 2024 16:57:17 +0100 Subject: [PATCH 14/36] Trying to get rid of empty functions. --- .../custom_elements/U_Pw_base_element.cpp | 2 - .../U_Pw_small_strain_element.cpp | 4 -- .../U_Pw_small_strain_interface_element.cpp | 6 --- .../small_strain_U_Pw_diff_order_element.cpp | 4 -- .../custom_elements/transient_Pw_element.cpp | 26 ----------- .../transient_Pw_interface_element.cpp | 24 +---------- .../transient_Pw_line_element.h | 19 -------- .../custom_retention/retention_law.cpp | 34 --------------- .../custom_retention/retention_law.h | 43 ------------------- .../saturated_below_phreatic_level_law.cpp | 25 ----------- .../saturated_below_phreatic_level_law.h | 12 ------ .../custom_retention/saturated_law.cpp | 27 ------------ .../custom_retention/saturated_law.h | 12 ------ .../custom_retention/van_genuchten_law.cpp | 31 +------------ .../custom_retention/van_genuchten_law.h | 12 ------ 15 files changed, 3 insertions(+), 278 deletions(-) diff --git a/applications/GeoMechanicsApplication/custom_elements/U_Pw_base_element.cpp b/applications/GeoMechanicsApplication/custom_elements/U_Pw_base_element.cpp index a5e3ffbad047..6140c3e8837a 100644 --- a/applications/GeoMechanicsApplication/custom_elements/U_Pw_base_element.cpp +++ b/applications/GeoMechanicsApplication/custom_elements/U_Pw_base_element.cpp @@ -137,8 +137,6 @@ void UPwBaseElement::Initialize(const ProcessInfo& rCurrentProcessInfo) mRetentionLawVector.resize(number_of_integration_points); for (unsigned int i = 0; i < mRetentionLawVector.size(); ++i) { mRetentionLawVector[i] = RetentionLawFactory::Clone(r_properties); - mRetentionLawVector[i]->InitializeMaterial( - r_properties, r_geometry, row(r_geometry.ShapeFunctionsValues(mThisIntegrationMethod), i)); } if (mStressVector.size() != number_of_integration_points) { diff --git a/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp b/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp index 42084001aa57..319efadf8b8e 100644 --- a/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp +++ b/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp @@ -283,8 +283,6 @@ void UPwSmallStrainElement::InitializeSolutionStep(const Proces noalias(Variables.StressVector) = mStressVector[GPoint]; ConstitutiveParameters.SetStressVector(Variables.StressVector); mConstitutiveLawVector[GPoint]->InitializeMaterialResponseCauchy(ConstitutiveParameters); - - mRetentionLawVector[GPoint]->InitializeSolutionStep(RetentionParameters); } // Reset hydraulic discharge @@ -434,8 +432,6 @@ void UPwSmallStrainElement::FinalizeSolutionStep(const ProcessI mStateVariablesFinalized[GPoint] = mConstitutiveLawVector[GPoint]->GetValue(STATE_VARIABLES, mStateVariablesFinalized[GPoint]); - mRetentionLawVector[GPoint]->FinalizeSolutionStep(RetentionParameters); - if (rCurrentProcessInfo[NODAL_SMOOTHING]) this->SaveGPStress(StressContainer, mStressVector[GPoint], GPoint); } diff --git a/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_interface_element.cpp b/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_interface_element.cpp index 5a815b97e38e..9e9afd330870 100644 --- a/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_interface_element.cpp +++ b/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_interface_element.cpp @@ -206,9 +206,6 @@ void UPwSmallStrainInterfaceElement::InitializeSolutionStep(con noalias(StressVector) = mStressVector[GPoint]; ConstitutiveParameters.SetStressVector(StressVector); mConstitutiveLawVector[GPoint]->InitializeMaterialResponseCauchy(ConstitutiveParameters); - - // Initialize retention law - mRetentionLawVector[GPoint]->InitializeSolutionStep(RetentionParameters); } KRATOS_CATCH("") @@ -279,9 +276,6 @@ void UPwSmallStrainInterfaceElement::FinalizeSolutionStep(const mStateVariablesFinalized[GPoint] = mConstitutiveLawVector[GPoint]->GetValue(STATE_VARIABLES, mStateVariablesFinalized[GPoint]); - - // retention law - mRetentionLawVector[GPoint]->FinalizeSolutionStep(RetentionParameters); } if (rCurrentProcessInfo[NODAL_SMOOTHING]) this->ExtrapolateGPValues(JointWidthContainer); diff --git a/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp b/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp index 3652ca789371..cdcacecbbb3e 100644 --- a/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp +++ b/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp @@ -209,8 +209,6 @@ void SmallStrainUPwDiffOrderElement::InitializeSolutionStep(const ProcessInfo& r noalias(Variables.StressVector) = mStressVector[GPoint]; ConstitutiveParameters.SetStressVector(Variables.StressVector); mConstitutiveLawVector[GPoint]->InitializeMaterialResponseCauchy(ConstitutiveParameters); - - mRetentionLawVector[GPoint]->InitializeSolutionStep(RetentionParameters); } KRATOS_CATCH("") @@ -286,8 +284,6 @@ void SmallStrainUPwDiffOrderElement::FinalizeSolutionStep(const ProcessInfo& rCu mConstitutiveLawVector[GPoint]->FinalizeMaterialResponseCauchy(ConstitutiveParameters); mStateVariablesFinalized[GPoint] = mConstitutiveLawVector[GPoint]->GetValue(STATE_VARIABLES, mStateVariablesFinalized[GPoint]); - - mRetentionLawVector[GPoint]->FinalizeSolutionStep(RetentionParameters); } // Assign pressure values to the intermediate nodes for post-processing diff --git a/applications/GeoMechanicsApplication/custom_elements/transient_Pw_element.cpp b/applications/GeoMechanicsApplication/custom_elements/transient_Pw_element.cpp index ffc103bbe2db..07f60f231d6b 100644 --- a/applications/GeoMechanicsApplication/custom_elements/transient_Pw_element.cpp +++ b/applications/GeoMechanicsApplication/custom_elements/transient_Pw_element.cpp @@ -137,8 +137,6 @@ void TransientPwElement::Initialize(const ProcessInfo& rCurrent if (mRetentionLawVector.size() != NumGPoints) mRetentionLawVector.resize(NumGPoints); for (unsigned int i = 0; i < mRetentionLawVector.size(); ++i) { mRetentionLawVector[i] = RetentionLawFactory::Clone(Prop); - mRetentionLawVector[i]->InitializeMaterial( - Prop, Geom, row(Geom.ShapeFunctionsValues(this->GetIntegrationMethod()), i)); } mIsInitialised = true; @@ -264,18 +262,6 @@ void TransientPwElement::InitializeSolutionStep(const ProcessIn if (!mIsInitialised) this->Initialize(rCurrentProcessInfo); - // Defining necessary variables - const GeometryType& Geom = this->GetGeometry(); - const unsigned int NumGPoints = Geom.IntegrationPointsNumber(this->GetIntegrationMethod()); - - RetentionLaw::Parameters RetentionParameters(this->GetProperties()); - - // Loop over integration points - for (unsigned int GPoint = 0; GPoint < NumGPoints; ++GPoint) { - // Initialize retention law - mRetentionLawVector[GPoint]->InitializeSolutionStep(RetentionParameters); - } - // reset hydraulic discharge this->ResetHydraulicDischarge(); @@ -301,18 +287,6 @@ void TransientPwElement::FinalizeSolutionStep(const ProcessInfo this->CalculateHydraulicDischarge(rCurrentProcessInfo); - // Defining necessary variables - const GeometryType& Geom = this->GetGeometry(); - const unsigned int NumGPoints = Geom.IntegrationPointsNumber(this->GetIntegrationMethod()); - - RetentionLaw::Parameters RetentionParameters(this->GetProperties()); - - // Loop over integration points - for (unsigned int GPoint = 0; GPoint < NumGPoints; ++GPoint) { - // retention law - mRetentionLawVector[GPoint]->FinalizeSolutionStep(RetentionParameters); - } - KRATOS_CATCH("") } diff --git a/applications/GeoMechanicsApplication/custom_elements/transient_Pw_interface_element.cpp b/applications/GeoMechanicsApplication/custom_elements/transient_Pw_interface_element.cpp index 88e984d28542..93976fcf0614 100644 --- a/applications/GeoMechanicsApplication/custom_elements/transient_Pw_interface_element.cpp +++ b/applications/GeoMechanicsApplication/custom_elements/transient_Pw_interface_element.cpp @@ -146,33 +146,13 @@ void TransientPwInterfaceElement::CalculateMassMatrix(MatrixTyp template void TransientPwInterfaceElement::InitializeSolutionStep(const ProcessInfo&) { - KRATOS_TRY - - RetentionLaw::Parameters RetentionParameters(this->GetProperties()); - - // Loop over integration points - for (unsigned int GPoint = 0; GPoint < mRetentionLawVector.size(); ++GPoint) { - // Initialize retention law - mRetentionLawVector[GPoint]->InitializeSolutionStep(RetentionParameters); - } - - KRATOS_CATCH("") + // Intentionally empty } template void TransientPwInterfaceElement::FinalizeSolutionStep(const ProcessInfo&) { - KRATOS_TRY - - RetentionLaw::Parameters RetentionParameters(this->GetProperties()); - - // Loop over integration points - for (unsigned int GPoint = 0; GPoint < mRetentionLawVector.size(); ++GPoint) { - // retention law - mRetentionLawVector[GPoint]->FinalizeSolutionStep(RetentionParameters); - } - - KRATOS_CATCH("") + // Intentionally empty } template diff --git a/applications/GeoMechanicsApplication/custom_elements/transient_Pw_line_element.h b/applications/GeoMechanicsApplication/custom_elements/transient_Pw_line_element.h index 168ac01c9dce..f19eef8fd289 100644 --- a/applications/GeoMechanicsApplication/custom_elements/transient_Pw_line_element.h +++ b/applications/GeoMechanicsApplication/custom_elements/transient_Pw_line_element.h @@ -77,25 +77,6 @@ class KRATOS_API(GEO_MECHANICS_APPLICATION) TransientPwLineElement : public Elem for (unsigned int i = 0; i < mRetentionLawVector.size(); ++i) { mRetentionLawVector[i] = RetentionLawFactory::Clone(GetProperties()); - mRetentionLawVector[i]->InitializeMaterial( - GetProperties(), GetGeometry(), - row(GetGeometry().ShapeFunctionsValues(GetIntegrationMethod()), i)); - } - } - - void InitializeSolutionStep(const ProcessInfo&) override - { - RetentionLaw::Parameters RetentionParameters(this->GetProperties()); - for (const auto& retention_law : mRetentionLawVector) { - retention_law->InitializeSolutionStep(RetentionParameters); - } - } - - void FinalizeSolutionStep(const ProcessInfo&) override - { - RetentionLaw::Parameters RetentionParameters(this->GetProperties()); - for (const auto& retention_law : mRetentionLawVector) { - retention_law->FinalizeSolutionStep(RetentionParameters); } } diff --git a/applications/GeoMechanicsApplication/custom_retention/retention_law.cpp b/applications/GeoMechanicsApplication/custom_retention/retention_law.cpp index 7b0d311ae297..06bd9ef2aeb4 100644 --- a/applications/GeoMechanicsApplication/custom_retention/retention_law.cpp +++ b/applications/GeoMechanicsApplication/custom_retention/retention_law.cpp @@ -16,40 +16,6 @@ namespace Kratos { -void RetentionLaw::InitializeMaterial(const Properties& rMaterialProperties, - const GeometryType& rElementGeometry, - const Vector& rShapeFunctionsValues) -{ - // nothing -} - -void RetentionLaw::Initialize(Parameters& rParameters) -{ - // nothing -} - -void RetentionLaw::InitializeSolutionStep(Parameters& rParameters) -{ - // nothing -} - -void RetentionLaw::FinalizeSolutionStep(Parameters& rParameters) -{ - // nothing -} - -void RetentionLaw::Finalize(Parameters& rParameters) -{ - // nothing -} - -void RetentionLaw::ResetMaterial(const Properties& rMaterialProperties, - const GeometryType& rElementGeometry, - const Vector& rShapeFunctionsValues) -{ - // nothing -} - void RetentionLaw::save(Serializer& rSerializer) const { // there is no member variables to be saved diff --git a/applications/GeoMechanicsApplication/custom_retention/retention_law.h b/applications/GeoMechanicsApplication/custom_retention/retention_law.h index 4eb69a25ba4b..9d060df13fd1 100644 --- a/applications/GeoMechanicsApplication/custom_retention/retention_law.h +++ b/applications/GeoMechanicsApplication/custom_retention/retention_law.h @@ -101,49 +101,6 @@ class KRATOS_API(GEO_MECHANICS_APPLICATION) RetentionLaw virtual double CalculateBishopCoefficient(Parameters& rParameters) const = 0; - /** - * This is to be called at the very beginning of the calculation - * (e.g. from InitializeElement) in order to initialize all relevant - * attributes of the retention law - * @param rMaterialProperties the Properties instance of the current element - * @param rElementGeometry the geometry of the current element - * @param rShapeFunctionsValues shape function values - */ - virtual void InitializeMaterial(const Properties& rMaterialProperties, - const GeometryType& rElementGeometry, - const Vector& rShapeFunctionsValues); - - virtual void Initialize(Parameters& rParameters); - - /** - * to be called at the beginning of each solution step - * (e.g. from Element::InitializeSolutionStep) - */ - virtual void InitializeSolutionStep(Parameters& rParameters); - - /** - * to be called at the end of each solution step - * (e.g. from Element::FinalizeSolutionStep) - */ - virtual void FinalizeSolutionStep(Parameters& rParameters); - - /** - * Finalize the material response in terms of Cauchy stresses - * @see Parameters - */ - virtual void Finalize(Parameters& rParameters); - - /** - * This can be used in order to reset all internal variables of the - * retention law (e.g. if a model should be reset to its reference state) - * @param rMaterialProperties the Properties instance of the current element - * @param rElementGeometry the geometry of the current element - * @param rShapeFunctionsValues the shape functions values in the current integration point - */ - virtual void ResetMaterial(const Properties& rMaterialProperties, - const GeometryType& rElementGeometry, - const Vector& rShapeFunctionsValues); - /** * This function is designed to be called once to perform all the checks * needed on the input provided. Checks can be "expensive" as the function diff --git a/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp b/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp index 31c7798ba591..a1623e048283 100644 --- a/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp +++ b/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.cpp @@ -78,31 +78,6 @@ double& SaturatedBelowPhreaticLevelLaw::CalculateValue(Parameters& r return rValue; } -void SaturatedBelowPhreaticLevelLaw::InitializeMaterial(const Properties&, const GeometryType&, const Vector&) -{ - // nothing is needed -} - -void SaturatedBelowPhreaticLevelLaw::Initialize(Parameters&) -{ - // nothing is needed -} - -void SaturatedBelowPhreaticLevelLaw::InitializeSolutionStep(Parameters&) -{ - // nothing is needed -} - -void SaturatedBelowPhreaticLevelLaw::Finalize(Parameters&) -{ - // nothing is needed -} - -void SaturatedBelowPhreaticLevelLaw::FinalizeSolutionStep(Parameters&) -{ - // nothing is needed -} - int SaturatedBelowPhreaticLevelLaw::Check(const Properties& rMaterialProperties, const ProcessInfo&) { KRATOS_ERROR_IF_NOT(rMaterialProperties.Has(SATURATED_SATURATION)) diff --git a/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.h b/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.h index d8bcd0542b82..acfc16dadd89 100644 --- a/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.h +++ b/applications/GeoMechanicsApplication/custom_retention/saturated_below_phreatic_level_law.h @@ -41,14 +41,6 @@ class KRATOS_API(GEO_MECHANICS_APPLICATION) SaturatedBelowPhreaticLevelLaw : pub ~SaturatedBelowPhreaticLevelLaw() override; - void InitializeMaterial(const Properties& rMaterialProperties, - const GeometryType& rElementGeometry, - const Vector& rShapeFunctionsValues) override; - - void Initialize(Parameters& rParameters) override; - - void InitializeSolutionStep(Parameters& rParameters) override; - double CalculateSaturation(Parameters& rParameters) const override; double CalculateEffectiveSaturation(Parameters& rParameters) const override; @@ -59,10 +51,6 @@ class KRATOS_API(GEO_MECHANICS_APPLICATION) SaturatedBelowPhreaticLevelLaw : pub double CalculateBishopCoefficient(Parameters& rParameters) const override; - void Finalize(Parameters& rParameters) override; - - void FinalizeSolutionStep(Parameters& rParameters) override; - /** * @brief It calculates the value of a specified variable (double case) * @param rParameterValues the needed parameters for the CL calculation diff --git a/applications/GeoMechanicsApplication/custom_retention/saturated_law.cpp b/applications/GeoMechanicsApplication/custom_retention/saturated_law.cpp index 6d6a47915514..fc2a01b3670b 100644 --- a/applications/GeoMechanicsApplication/custom_retention/saturated_law.cpp +++ b/applications/GeoMechanicsApplication/custom_retention/saturated_law.cpp @@ -57,33 +57,6 @@ double& SaturatedLaw::CalculateValue(RetentionLaw::Parameters& rParameterValues, return rValue; } -void SaturatedLaw::InitializeMaterial(const Properties& rMaterialProperties, - const GeometryType& rElementGeometry, - const Vector& rShapeFunctionsValues) -{ - // nothing is needed -} - -void SaturatedLaw::Initialize(Parameters& rParameters) -{ - // nothing is needed -} - -void SaturatedLaw::InitializeSolutionStep(Parameters& rParameters) -{ - // nothing is needed -} - -void SaturatedLaw::Finalize(Parameters& rParameters) -{ - // nothing is needed -} - -void SaturatedLaw::FinalizeSolutionStep(Parameters& rParameters) -{ - // nothing is needed -} - int SaturatedLaw::Check(const Properties& rMaterialProperties, const ProcessInfo& rCurrentProcessInfo) { if (rMaterialProperties.Has(SATURATED_SATURATION)) { diff --git a/applications/GeoMechanicsApplication/custom_retention/saturated_law.h b/applications/GeoMechanicsApplication/custom_retention/saturated_law.h index 8bb753d61d30..611e926341db 100644 --- a/applications/GeoMechanicsApplication/custom_retention/saturated_law.h +++ b/applications/GeoMechanicsApplication/custom_retention/saturated_law.h @@ -35,14 +35,6 @@ class KRATOS_API(GEO_MECHANICS_APPLICATION) SaturatedLaw : public RetentionLaw [[nodiscard]] RetentionLaw::Pointer Clone() const override; - void InitializeMaterial(const Properties& rMaterialProperties, - const GeometryType& rElementGeometry, - const Vector& rShapeFunctionsValues) override; - - void Initialize(Parameters& rParameters) override; - - void InitializeSolutionStep(Parameters& rParameters) override; - double CalculateSaturation(Parameters& rParameters) const override; double CalculateEffectiveSaturation(Parameters& rParameters) const override; @@ -53,10 +45,6 @@ class KRATOS_API(GEO_MECHANICS_APPLICATION) SaturatedLaw : public RetentionLaw double CalculateBishopCoefficient(Parameters& rParameters) const override; - void Finalize(Parameters& rParameters) override; - - void FinalizeSolutionStep(Parameters& rParameters) override; - /** * @brief It calculates the value of a specified variable (double case) * @param rParameterValues the needed parameters for the CL calculation diff --git a/applications/GeoMechanicsApplication/custom_retention/van_genuchten_law.cpp b/applications/GeoMechanicsApplication/custom_retention/van_genuchten_law.cpp index 6801a90cbe29..3ae85226e215 100644 --- a/applications/GeoMechanicsApplication/custom_retention/van_genuchten_law.cpp +++ b/applications/GeoMechanicsApplication/custom_retention/van_genuchten_law.cpp @@ -102,9 +102,7 @@ double VanGenuchtenLaw::CalculateBishopCoefficient(Parameters& rParameters) cons return CalculateEffectiveSaturation(rParameters); } -double& VanGenuchtenLaw::CalculateValue(RetentionLaw::Parameters& rParameterValues, - const Variable& rThisVariable, - double& rValue) +double& VanGenuchtenLaw::CalculateValue(Parameters& rParameterValues, const Variable& rThisVariable, double& rValue) { if (rThisVariable == DEGREE_OF_SATURATION) { rValue = this->CalculateSaturation(rParameterValues); @@ -121,33 +119,6 @@ double& VanGenuchtenLaw::CalculateValue(RetentionLaw::Parameters& rParameterValu return rValue; } -void VanGenuchtenLaw::InitializeMaterial(const Properties& rMaterialProperties, - const GeometryType& rElementGeometry, - const Vector& rShapeFunctionsValues) -{ - // nothing is needed -} - -void VanGenuchtenLaw::Initialize(Parameters&) -{ - // nothing is needed -} - -void VanGenuchtenLaw::InitializeSolutionStep(Parameters& rParameters) -{ - // nothing is needed -} - -void VanGenuchtenLaw::Finalize(Parameters& rParameters) -{ - // nothing is needed -} - -void VanGenuchtenLaw::FinalizeSolutionStep(Parameters& rParameters) -{ - // nothing is needed -} - int VanGenuchtenLaw::Check(const Properties& rMaterialProperties, const ProcessInfo& rCurrentProcessInfo) { KRATOS_ERROR_IF_NOT(rMaterialProperties.Has(SATURATED_SATURATION)) diff --git a/applications/GeoMechanicsApplication/custom_retention/van_genuchten_law.h b/applications/GeoMechanicsApplication/custom_retention/van_genuchten_law.h index bdefa87e619e..ca008a74c8e9 100644 --- a/applications/GeoMechanicsApplication/custom_retention/van_genuchten_law.h +++ b/applications/GeoMechanicsApplication/custom_retention/van_genuchten_law.h @@ -34,14 +34,6 @@ class KRATOS_API(GEO_MECHANICS_APPLICATION) VanGenuchtenLaw : public RetentionLa [[nodiscard]] RetentionLaw::Pointer Clone() const override; - void InitializeMaterial(const Properties& rMaterialProperties, - const GeometryType& rElementGeometry, - const Vector& rShapeFunctionsValues) override; - - void Initialize(Parameters& rParameters) override; - - void InitializeSolutionStep(Parameters& rParameters) override; - double CalculateSaturation(Parameters& rParameters) const override; double CalculateEffectiveSaturation(Parameters& rParameters) const override; @@ -52,10 +44,6 @@ class KRATOS_API(GEO_MECHANICS_APPLICATION) VanGenuchtenLaw : public RetentionLa double CalculateBishopCoefficient(Parameters& rParameters) const override; - void Finalize(Parameters& rParameters) override; - - void FinalizeSolutionStep(Parameters& rParameters) override; - /** * @brief It calculates the value of a specified variable (double case) * @param rParameterValues the needed parameters for the CL calculation From 28ff1695afb501ed89998ad13514db9be7c083bd Mon Sep 17 00:00:00 2001 From: Wijtze Pieter Kikstra Date: Mon, 9 Dec 2024 17:05:52 +0100 Subject: [PATCH 15/36] Remove added print statements from core --- .../residualbased_block_builder_and_solver.h | 3 --- .../strategies/residualbased_newton_raphson_strategy.h | 6 ------ 2 files changed, 9 deletions(-) diff --git a/kratos/solving_strategies/builder_and_solvers/residualbased_block_builder_and_solver.h b/kratos/solving_strategies/builder_and_solvers/residualbased_block_builder_and_solver.h index 40ab23df36c9..e3711dcd300c 100644 --- a/kratos/solving_strategies/builder_and_solvers/residualbased_block_builder_and_solver.h +++ b/kratos/solving_strategies/builder_and_solvers/residualbased_block_builder_and_solver.h @@ -450,8 +450,6 @@ class ResidualBasedBlockBuilderAndSolver else norm_b = 0.00; - KRATOS_INFO("ResidualBasedBlockBuilderAndSolver") << "Norm RHS = " << norm_b << std::endl; - if (norm_b != 0.00) { //provide physical data as needed if(BaseType::mpLinearSystemSolver->AdditionalPhysicalDataIsNeeded() ) @@ -1195,7 +1193,6 @@ class ResidualBasedBlockBuilderAndSolver virtual void ConstructMasterSlaveConstraintsStructure(ModelPart& rModelPart) { - KRATOS_INFO("ConstructMasterSlaveConstraintsStructure") << "Number of constraints: " << rModelPart.MasterSlaveConstraints().size() << std::endl; if (rModelPart.MasterSlaveConstraints().size() > 0) { Timer::Start("ConstraintsRelationMatrixStructure"); const ProcessInfo& r_current_process_info = rModelPart.GetProcessInfo(); diff --git a/kratos/solving_strategies/strategies/residualbased_newton_raphson_strategy.h b/kratos/solving_strategies/strategies/residualbased_newton_raphson_strategy.h index 1a6effaf6845..69f747077aff 100644 --- a/kratos/solving_strategies/strategies/residualbased_newton_raphson_strategy.h +++ b/kratos/solving_strategies/strategies/residualbased_newton_raphson_strategy.h @@ -938,9 +938,6 @@ class ResidualBasedNewtonRaphsonStrategy //initializing the parameters of the Newton-Raphson cycle unsigned int iteration_number = 1; - KRATOS_INFO_IF("ResidualBasedNewtonRaphsonStrategy", this->GetEchoLevel() > 0) - << "Started iteration " << iteration_number << " of " - << mMaxIterationNumber << " iterations" << std::endl; r_model_part.GetProcessInfo()[NL_ITERATION_NUMBER] = iteration_number; bool residual_is_updated = false; p_scheme->InitializeNonLinIteration(r_model_part, rA, rDx, rb); @@ -994,9 +991,6 @@ class ResidualBasedNewtonRaphsonStrategy while (is_converged == false && iteration_number++ < mMaxIterationNumber) { - KRATOS_INFO_IF("ResidualBasedNewtonRaphsonStrategy", this->GetEchoLevel() > 0) - << "Started iteration " << iteration_number << " of " - << mMaxIterationNumber << " iterations" << std::endl; //setting the number of iteration r_model_part.GetProcessInfo()[NL_ITERATION_NUMBER] = iteration_number; From 6574b787d706ae93143ba675f4f8509370e2ecfa Mon Sep 17 00:00:00 2001 From: Wijtze Pieter Kikstra Date: Tue, 10 Dec 2024 11:46:17 +0100 Subject: [PATCH 16/36] sonar cloud remarks and naming style corrections --- .../custom_elements/U_Pw_base_element.cpp | 9 +- .../small_strain_U_Pw_diff_order_element.cpp | 550 +++++++++--------- .../transient_Pw_line_element.h | 4 +- 3 files changed, 272 insertions(+), 291 deletions(-) diff --git a/applications/GeoMechanicsApplication/custom_elements/U_Pw_base_element.cpp b/applications/GeoMechanicsApplication/custom_elements/U_Pw_base_element.cpp index 6140c3e8837a..f27964482d6d 100644 --- a/applications/GeoMechanicsApplication/custom_elements/U_Pw_base_element.cpp +++ b/applications/GeoMechanicsApplication/custom_elements/U_Pw_base_element.cpp @@ -135,8 +135,8 @@ void UPwBaseElement::Initialize(const ProcessInfo& rCurrentProcessInfo) } mRetentionLawVector.resize(number_of_integration_points); - for (unsigned int i = 0; i < mRetentionLawVector.size(); ++i) { - mRetentionLawVector[i] = RetentionLawFactory::Clone(r_properties); + for (auto& r_retention_law : mRetentionLawVector) { + r_retention_law = RetentionLawFactory::Clone(r_properties); } if (mStressVector.size() != number_of_integration_points) { @@ -149,9 +149,8 @@ void UPwBaseElement::Initialize(const ProcessInfo& rCurrentProcessInfo) mStateVariablesFinalized.resize(number_of_integration_points); for (unsigned int i = 0; i < mConstitutiveLawVector.size(); ++i) { - int nStateVariables = 0; - nStateVariables = mConstitutiveLawVector[i]->GetValue(NUMBER_OF_UMAT_STATE_VARIABLES, nStateVariables); - if (nStateVariables > 0) { + if (auto nStateVariables = 0; + mConstitutiveLawVector[i]->GetValue(NUMBER_OF_UMAT_STATE_VARIABLES, nStateVariables) > 0) { mConstitutiveLawVector[i]->SetValue(STATE_VARIABLES, mStateVariablesFinalized[i], rCurrentProcessInfo); } } diff --git a/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp b/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp index cdcacecbbb3e..9a8c818a0b50 100644 --- a/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp +++ b/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp @@ -24,7 +24,6 @@ // Application includes #include "custom_elements/small_strain_U_Pw_diff_order_element.hpp" -#include "custom_retention/retention_law_factory.h" #include "custom_utilities/constitutive_law_utilities.hpp" #include "custom_utilities/dof_utilities.h" #include "custom_utilities/element_utilities.hpp" @@ -56,9 +55,9 @@ int SmallStrainUPwDiffOrderElement::Check(const ProcessInfo& rCurrentProcessInfo { KRATOS_TRY - const GeometryType& rGeom = GetGeometry(); + const auto& r_geom = GetGeometry(); - if (rGeom.DomainSize() < 1.0e-15) + if (r_geom.DomainSize() < 1.0e-15) KRATOS_ERROR << "DomainSize < 1.0e-15 for the element " << this->Id() << std::endl; // check pressure geometry pointer @@ -66,39 +65,39 @@ int SmallStrainUPwDiffOrderElement::Check(const ProcessInfo& rCurrentProcessInfo // verify that the variables are correctly initialized // Verify specific properties - const PropertiesType& rProp = this->GetProperties(); + const auto& r_prop = this->GetProperties(); - if (!rProp.Has(IGNORE_UNDRAINED)) + if (!r_prop.Has(IGNORE_UNDRAINED)) KRATOS_ERROR << "IGNORE_UNDRAINED does not exist in the parameter list" << this->Id() << std::endl; - if (!rProp[IGNORE_UNDRAINED]) { - if (!rProp.Has(PERMEABILITY_XX) || rProp[PERMEABILITY_XX] < 0.0) + if (!r_prop[IGNORE_UNDRAINED]) { + if (!r_prop.Has(PERMEABILITY_XX) || r_prop[PERMEABILITY_XX] < 0.0) KRATOS_ERROR << "PERMEABILITY_XX has Key zero, is not defined or " "has an invalid value at element" << this->Id() << std::endl; - if (!rProp.Has(PERMEABILITY_YY) || rProp[PERMEABILITY_YY] < 0.0) + if (!r_prop.Has(PERMEABILITY_YY) || r_prop[PERMEABILITY_YY] < 0.0) KRATOS_ERROR << "PERMEABILITY_YY has Key zero, is not defined or " "has an invalid value at element" << this->Id() << std::endl; - if (!rProp.Has(PERMEABILITY_XY) || rProp[PERMEABILITY_XY] < 0.0) + if (!r_prop.Has(PERMEABILITY_XY) || r_prop[PERMEABILITY_XY] < 0.0) KRATOS_ERROR << "PERMEABILITY_XY has Key zero, is not defined or " "has an invalid value at element" << this->Id() << std::endl; - if (rGeom.WorkingSpaceDimension() > 2) { - if (!rProp.Has(PERMEABILITY_ZZ) || rProp[PERMEABILITY_ZZ] < 0.0) + if (r_geom.WorkingSpaceDimension() > 2) { + if (!r_prop.Has(PERMEABILITY_ZZ) || r_prop[PERMEABILITY_ZZ] < 0.0) KRATOS_ERROR << "PERMEABILITY_ZZ has Key zero, is not defined " "or has an invalid value at element" << this->Id() << std::endl; - if (!rProp.Has(PERMEABILITY_YZ) || rProp[PERMEABILITY_YZ] < 0.0) + if (!r_prop.Has(PERMEABILITY_YZ) || r_prop[PERMEABILITY_YZ] < 0.0) KRATOS_ERROR << "PERMEABILITY_YZ has Key zero, is not defined " "or has an invalid value at element" << this->Id() << std::endl; - if (!rProp.Has(PERMEABILITY_ZX) || rProp[PERMEABILITY_ZX] < 0.0) + if (!r_prop.Has(PERMEABILITY_ZX) || r_prop[PERMEABILITY_ZX] < 0.0) KRATOS_ERROR << "PERMEABILITY_ZX has Key zero, is not defined " "or has an invalid value at element" << this->Id() << std::endl; @@ -106,65 +105,56 @@ int SmallStrainUPwDiffOrderElement::Check(const ProcessInfo& rCurrentProcessInfo } // verify that the dofs exist - for (unsigned int i = 0; i < rGeom.size(); ++i) { - if (!rGeom[i].SolutionStepsDataHas(DISPLACEMENT)) - KRATOS_ERROR << "missing variable DISPLACEMENT on node " << rGeom[i].Id() << std::endl; - - if (!rGeom[i].HasDofFor(DISPLACEMENT_X) || !rGeom[i].HasDofFor(DISPLACEMENT_Y) || - !rGeom[i].HasDofFor(DISPLACEMENT_Z)) - KRATOS_ERROR << "missing one of the dofs for the variable " - "DISPLACEMENT on node " - << rGeom[i].Id() << std::endl; - - if (!rGeom[i].SolutionStepsDataHas(WATER_PRESSURE)) - KRATOS_ERROR << "missing variable WATER_PRESSURE on node " << rGeom[i].Id() << std::endl; - - if (!rGeom[i].HasDofFor(WATER_PRESSURE)) - KRATOS_ERROR << "missing the dof for the variable WATER_PRESSURE " - "on node " - << rGeom[i].Id() << std::endl; + for (auto& r_node : r_geom) { + if (!r_node.SolutionStepsDataHas(DISPLACEMENT)) + KRATOS_ERROR << "missing variable DISPLACEMENT on node " << r_node.Id() << std::endl; + + if (!r_node.HasDofFor(DISPLACEMENT_X) || !r_node.HasDofFor(DISPLACEMENT_Y) || !r_node.HasDofFor(DISPLACEMENT_Z)) + KRATOS_ERROR << "missing one of the dofs for the variable DISPLACEMENT on node " + << r_node.Id() << std::endl; + + if (!r_node.SolutionStepsDataHas(WATER_PRESSURE)) + KRATOS_ERROR << "missing variable WATER_PRESSURE on node " << r_node.Id() << std::endl; + + if (!r_node.HasDofFor(WATER_PRESSURE)) + KRATOS_ERROR << "missing the dof for the variable WATER_PRESSURE on node " << r_node.Id() + << std::endl; } // Verify that the constitutive law exists - KRATOS_ERROR_IF_NOT(rProp.Has(CONSTITUTIVE_LAW)) - << "Constitutive law not provided for property " << rProp.Id() << std::endl; + KRATOS_ERROR_IF_NOT(r_prop.Has(CONSTITUTIVE_LAW)) + << "Constitutive law not provided for property " << r_prop.Id() << std::endl; // verify compatibility with the constitutive law ConstitutiveLaw::Features LawFeatures; - rProp.GetValue(CONSTITUTIVE_LAW)->GetLawFeatures(LawFeatures); + r_prop.GetValue(CONSTITUTIVE_LAW)->GetLawFeatures(LawFeatures); - bool correct_strain_measure = false; - for (unsigned int i = 0; i < LawFeatures.mStrainMeasures.size(); ++i) { - if (LawFeatures.mStrainMeasures[i] == ConstitutiveLaw::StrainMeasure_Infinitesimal) - correct_strain_measure = true; - } + KRATOS_ERROR_IF(std::find(LawFeatures.mStrainMeasures.cbegin(), LawFeatures.mStrainMeasures.cend(), + ConstitutiveLaw::StrainMeasure_Infinitesimal) == + LawFeatures.mStrainMeasures.cend()) + << "In element " << this->Id() + << " the constitutive law is not compatible with the element " + "type StrainMeasure_Infinitesimal." + << std::endl; - if (!correct_strain_measure) - KRATOS_ERROR << "constitutive law is not compatible with the element " - "type StrainMeasure_Infinitesimal " - << this->Id() << std::endl; - - rProp.GetValue(CONSTITUTIVE_LAW)->Check(rProp, rGeom, rCurrentProcessInfo); + r_prop.GetValue(CONSTITUTIVE_LAW)->Check(r_prop, r_geom, rCurrentProcessInfo); // Verify that the constitutive law has the correct dimension const SizeType strainSize = this->GetProperties().GetValue(CONSTITUTIVE_LAW)->GetStrainSize(); - if (rGeom.WorkingSpaceDimension() > 2) { + if (r_geom.WorkingSpaceDimension() > 2) { KRATOS_ERROR_IF_NOT(strainSize == VOIGT_SIZE_3D) - << "Wrong constitutive law used. This is a 3D element! expected " - "strain size is " - << VOIGT_SIZE_3D << " But received: " << strainSize << " in element id: " << this->Id() - << std::endl; + << "Wrong constitutive law used. This is a 3D element! expected strain size is " << VOIGT_SIZE_3D + << " But received: " << strainSize << " in element id: " << this->Id() << std::endl; } else { KRATOS_ERROR_IF_NOT(strainSize == VOIGT_SIZE_2D_PLANE_STRAIN) - << "Wrong constitutive law used. This is a 2D element! expected " - "strain size is " + << "Wrong constitutive law used. This is a 2D element! expected strain size is " << VOIGT_SIZE_2D_PLANE_STRAIN << " But received: " << strainSize << " in element id: " << this->Id() << std::endl; } // Check constitutive law - if (mRetentionLawVector.size() > 0) { - return mRetentionLawVector[0]->Check(rProp, rCurrentProcessInfo); + if (!mRetentionLawVector.empty()) { + return mRetentionLawVector[0]->Check(r_prop, rCurrentProcessInfo); } return 0; @@ -185,8 +175,6 @@ void SmallStrainUPwDiffOrderElement::InitializeSolutionStep(const ProcessInfo& r ElementVariables Variables; this->InitializeElementVariables(Variables, rCurrentProcessInfo); - RetentionLaw::Parameters RetentionParameters(GetProperties()); - const auto b_matrices = CalculateBMatrices(Variables.DNu_DXContainer, Variables.NuContainer); const auto deformation_gradients = CalculateDeformationGradients(); const auto determinants_of_deformation_gradients = @@ -257,8 +245,6 @@ void SmallStrainUPwDiffOrderElement::FinalizeSolutionStep(const ProcessInfo& rCu ElementVariables Variables; this->InitializeElementVariables(Variables, rCurrentProcessInfo); - RetentionLaw::Parameters RetentionParameters(GetProperties()); - const auto b_matrices = CalculateBMatrices(Variables.DNu_DXContainer, Variables.NuContainer); const auto deformation_gradients = CalculateDeformationGradients(); const auto determinants_of_deformation_gradients = @@ -297,177 +283,177 @@ void SmallStrainUPwDiffOrderElement::AssignPressureToIntermediateNodes() // Assign pressure values to the intermediate nodes for post-processing KRATOS_TRY - GeometryType& rGeom = GetGeometry(); - const SizeType NumUNodes = rGeom.PointsNumber(); - const SizeType NumDim = rGeom.WorkingSpaceDimension(); + GeometryType& r_geom = GetGeometry(); + const SizeType num_u_nodes = r_geom.PointsNumber(); + const SizeType n_dim = r_geom.WorkingSpaceDimension(); - switch (NumUNodes) { + switch (num_u_nodes) { case 6: // 2D T6P3 { - const double p0 = rGeom[0].FastGetSolutionStepValue(WATER_PRESSURE); - const double p1 = rGeom[1].FastGetSolutionStepValue(WATER_PRESSURE); - const double p2 = rGeom[2].FastGetSolutionStepValue(WATER_PRESSURE); - ThreadSafeNodeWrite(rGeom[3], WATER_PRESSURE, 0.5 * (p0 + p1)); - ThreadSafeNodeWrite(rGeom[4], WATER_PRESSURE, 0.5 * (p1 + p2)); - ThreadSafeNodeWrite(rGeom[5], WATER_PRESSURE, 0.5 * (p2 + p0)); + const double p0 = r_geom[0].FastGetSolutionStepValue(WATER_PRESSURE); + const double p1 = r_geom[1].FastGetSolutionStepValue(WATER_PRESSURE); + const double p2 = r_geom[2].FastGetSolutionStepValue(WATER_PRESSURE); + ThreadSafeNodeWrite(r_geom[3], WATER_PRESSURE, 0.5 * (p0 + p1)); + ThreadSafeNodeWrite(r_geom[4], WATER_PRESSURE, 0.5 * (p1 + p2)); + ThreadSafeNodeWrite(r_geom[5], WATER_PRESSURE, 0.5 * (p2 + p0)); break; } case 8: // 2D Q8P4 { - const double p0 = rGeom[0].FastGetSolutionStepValue(WATER_PRESSURE); - const double p1 = rGeom[1].FastGetSolutionStepValue(WATER_PRESSURE); - const double p2 = rGeom[2].FastGetSolutionStepValue(WATER_PRESSURE); - const double p3 = rGeom[3].FastGetSolutionStepValue(WATER_PRESSURE); - ThreadSafeNodeWrite(rGeom[4], WATER_PRESSURE, 0.5 * (p0 + p1)); - ThreadSafeNodeWrite(rGeom[5], WATER_PRESSURE, 0.5 * (p1 + p2)); - ThreadSafeNodeWrite(rGeom[6], WATER_PRESSURE, 0.5 * (p2 + p3)); - ThreadSafeNodeWrite(rGeom[7], WATER_PRESSURE, 0.5 * (p3 + p0)); + const double p0 = r_geom[0].FastGetSolutionStepValue(WATER_PRESSURE); + const double p1 = r_geom[1].FastGetSolutionStepValue(WATER_PRESSURE); + const double p2 = r_geom[2].FastGetSolutionStepValue(WATER_PRESSURE); + const double p3 = r_geom[3].FastGetSolutionStepValue(WATER_PRESSURE); + ThreadSafeNodeWrite(r_geom[4], WATER_PRESSURE, 0.5 * (p0 + p1)); + ThreadSafeNodeWrite(r_geom[5], WATER_PRESSURE, 0.5 * (p1 + p2)); + ThreadSafeNodeWrite(r_geom[6], WATER_PRESSURE, 0.5 * (p2 + p3)); + ThreadSafeNodeWrite(r_geom[7], WATER_PRESSURE, 0.5 * (p3 + p0)); break; } case 9: // 2D Q9P4 { - const double p0 = rGeom[0].FastGetSolutionStepValue(WATER_PRESSURE); - const double p1 = rGeom[1].FastGetSolutionStepValue(WATER_PRESSURE); - const double p2 = rGeom[2].FastGetSolutionStepValue(WATER_PRESSURE); - const double p3 = rGeom[3].FastGetSolutionStepValue(WATER_PRESSURE); - ThreadSafeNodeWrite(rGeom[4], WATER_PRESSURE, 0.5 * (p0 + p1)); - ThreadSafeNodeWrite(rGeom[5], WATER_PRESSURE, 0.5 * (p1 + p2)); - ThreadSafeNodeWrite(rGeom[6], WATER_PRESSURE, 0.5 * (p2 + p3)); - ThreadSafeNodeWrite(rGeom[7], WATER_PRESSURE, 0.5 * (p3 + p0)); - ThreadSafeNodeWrite(rGeom[8], WATER_PRESSURE, 0.25 * (p0 + p1 + p2 + p3)); + const double p0 = r_geom[0].FastGetSolutionStepValue(WATER_PRESSURE); + const double p1 = r_geom[1].FastGetSolutionStepValue(WATER_PRESSURE); + const double p2 = r_geom[2].FastGetSolutionStepValue(WATER_PRESSURE); + const double p3 = r_geom[3].FastGetSolutionStepValue(WATER_PRESSURE); + ThreadSafeNodeWrite(r_geom[4], WATER_PRESSURE, 0.5 * (p0 + p1)); + ThreadSafeNodeWrite(r_geom[5], WATER_PRESSURE, 0.5 * (p1 + p2)); + ThreadSafeNodeWrite(r_geom[6], WATER_PRESSURE, 0.5 * (p2 + p3)); + ThreadSafeNodeWrite(r_geom[7], WATER_PRESSURE, 0.5 * (p3 + p0)); + ThreadSafeNodeWrite(r_geom[8], WATER_PRESSURE, 0.25 * (p0 + p1 + p2 + p3)); break; } case 10: // 3D T10P4 //2D T10P6 { - if (NumDim == 3) { - const double p0 = rGeom[0].FastGetSolutionStepValue(WATER_PRESSURE); - const double p1 = rGeom[1].FastGetSolutionStepValue(WATER_PRESSURE); - const double p2 = rGeom[2].FastGetSolutionStepValue(WATER_PRESSURE); - const double p3 = rGeom[3].FastGetSolutionStepValue(WATER_PRESSURE); - ThreadSafeNodeWrite(rGeom[4], WATER_PRESSURE, 0.5 * (p0 + p1)); - ThreadSafeNodeWrite(rGeom[5], WATER_PRESSURE, 0.5 * (p1 + p2)); - ThreadSafeNodeWrite(rGeom[6], WATER_PRESSURE, 0.5 * (p2 + p0)); - ThreadSafeNodeWrite(rGeom[7], WATER_PRESSURE, 0.5 * (p0 + p3)); - ThreadSafeNodeWrite(rGeom[8], WATER_PRESSURE, 0.5 * (p1 + p3)); - ThreadSafeNodeWrite(rGeom[9], WATER_PRESSURE, 0.5 * (p2 + p3)); - } else if (NumDim == 2) { + if (n_dim == 3) { + const double p0 = r_geom[0].FastGetSolutionStepValue(WATER_PRESSURE); + const double p1 = r_geom[1].FastGetSolutionStepValue(WATER_PRESSURE); + const double p2 = r_geom[2].FastGetSolutionStepValue(WATER_PRESSURE); + const double p3 = r_geom[3].FastGetSolutionStepValue(WATER_PRESSURE); + ThreadSafeNodeWrite(r_geom[4], WATER_PRESSURE, 0.5 * (p0 + p1)); + ThreadSafeNodeWrite(r_geom[5], WATER_PRESSURE, 0.5 * (p1 + p2)); + ThreadSafeNodeWrite(r_geom[6], WATER_PRESSURE, 0.5 * (p2 + p0)); + ThreadSafeNodeWrite(r_geom[7], WATER_PRESSURE, 0.5 * (p0 + p3)); + ThreadSafeNodeWrite(r_geom[8], WATER_PRESSURE, 0.5 * (p1 + p3)); + ThreadSafeNodeWrite(r_geom[9], WATER_PRESSURE, 0.5 * (p2 + p3)); + } else if (n_dim == 2) { constexpr double c1 = 1.0 / 9.0; - const double p0 = rGeom[0].FastGetSolutionStepValue(WATER_PRESSURE); - const double p1 = rGeom[1].FastGetSolutionStepValue(WATER_PRESSURE); - const double p2 = rGeom[2].FastGetSolutionStepValue(WATER_PRESSURE); - const double p3 = rGeom[3].FastGetSolutionStepValue(WATER_PRESSURE); - const double p4 = rGeom[4].FastGetSolutionStepValue(WATER_PRESSURE); - const double p5 = rGeom[5].FastGetSolutionStepValue(WATER_PRESSURE); - ThreadSafeNodeWrite(rGeom[0], WATER_PRESSURE, p0); - ThreadSafeNodeWrite(rGeom[1], WATER_PRESSURE, p1); - ThreadSafeNodeWrite(rGeom[2], WATER_PRESSURE, p2); - ThreadSafeNodeWrite(rGeom[3], WATER_PRESSURE, (2.0 * p0 - p1 + 8.0 * p3) * c1); - ThreadSafeNodeWrite(rGeom[4], WATER_PRESSURE, (2.0 * p1 - p0 + 8.0 * p3) * c1); - ThreadSafeNodeWrite(rGeom[5], WATER_PRESSURE, (2.0 * p1 - p2 + 8.0 * p4) * c1); - ThreadSafeNodeWrite(rGeom[6], WATER_PRESSURE, (2.0 * p2 - p1 + 8.0 * p4) * c1); - ThreadSafeNodeWrite(rGeom[7], WATER_PRESSURE, (2.0 * p2 - p0 + 8.0 * p5) * c1); - ThreadSafeNodeWrite(rGeom[8], WATER_PRESSURE, (2.0 * p0 - p2 + 8.0 * p5) * c1); - ThreadSafeNodeWrite(rGeom[9], WATER_PRESSURE, (4.0 * (p3 + p4 + p5) - (p0 + p1 + p2)) * c1); + const double p0 = r_geom[0].FastGetSolutionStepValue(WATER_PRESSURE); + const double p1 = r_geom[1].FastGetSolutionStepValue(WATER_PRESSURE); + const double p2 = r_geom[2].FastGetSolutionStepValue(WATER_PRESSURE); + const double p3 = r_geom[3].FastGetSolutionStepValue(WATER_PRESSURE); + const double p4 = r_geom[4].FastGetSolutionStepValue(WATER_PRESSURE); + const double p5 = r_geom[5].FastGetSolutionStepValue(WATER_PRESSURE); + ThreadSafeNodeWrite(r_geom[0], WATER_PRESSURE, p0); + ThreadSafeNodeWrite(r_geom[1], WATER_PRESSURE, p1); + ThreadSafeNodeWrite(r_geom[2], WATER_PRESSURE, p2); + ThreadSafeNodeWrite(r_geom[3], WATER_PRESSURE, (2.0 * p0 - p1 + 8.0 * p3) * c1); + ThreadSafeNodeWrite(r_geom[4], WATER_PRESSURE, (2.0 * p1 - p0 + 8.0 * p3) * c1); + ThreadSafeNodeWrite(r_geom[5], WATER_PRESSURE, (2.0 * p1 - p2 + 8.0 * p4) * c1); + ThreadSafeNodeWrite(r_geom[6], WATER_PRESSURE, (2.0 * p2 - p1 + 8.0 * p4) * c1); + ThreadSafeNodeWrite(r_geom[7], WATER_PRESSURE, (2.0 * p2 - p0 + 8.0 * p5) * c1); + ThreadSafeNodeWrite(r_geom[8], WATER_PRESSURE, (2.0 * p0 - p2 + 8.0 * p5) * c1); + ThreadSafeNodeWrite(r_geom[9], WATER_PRESSURE, (4.0 * (p3 + p4 + p5) - (p0 + p1 + p2)) * c1); } break; } case 15: // 2D T15P10 { constexpr double c1 = 0.0390625; - const double p0 = rGeom[0].FastGetSolutionStepValue(WATER_PRESSURE); - const double p1 = rGeom[1].FastGetSolutionStepValue(WATER_PRESSURE); - const double p2 = rGeom[2].FastGetSolutionStepValue(WATER_PRESSURE); - const double p3 = rGeom[3].FastGetSolutionStepValue(WATER_PRESSURE); - const double p4 = rGeom[4].FastGetSolutionStepValue(WATER_PRESSURE); - const double p5 = rGeom[5].FastGetSolutionStepValue(WATER_PRESSURE); - const double p6 = rGeom[6].FastGetSolutionStepValue(WATER_PRESSURE); - const double p7 = rGeom[7].FastGetSolutionStepValue(WATER_PRESSURE); - const double p8 = rGeom[8].FastGetSolutionStepValue(WATER_PRESSURE); - const double p9 = rGeom[9].FastGetSolutionStepValue(WATER_PRESSURE); - ThreadSafeNodeWrite(rGeom[0], WATER_PRESSURE, p0); - ThreadSafeNodeWrite(rGeom[1], WATER_PRESSURE, p1); - ThreadSafeNodeWrite(rGeom[2], WATER_PRESSURE, p2); - ThreadSafeNodeWrite(rGeom[3], WATER_PRESSURE, (3.0 * p0 + p1 + 27.0 * p3 - 5.4 * p4) * c1); - ThreadSafeNodeWrite(rGeom[4], WATER_PRESSURE, (14.4 * (p3 + p4) - 1.6 * (p0 + p1)) * c1); - ThreadSafeNodeWrite(rGeom[5], WATER_PRESSURE, (3.0 * p1 + p0 + 27.0 * p4 - 5.4 * p3) * c1); - ThreadSafeNodeWrite(rGeom[6], WATER_PRESSURE, (3.0 * p1 + p2 + 27.0 * p5 - 5.4 * p6) * c1); - ThreadSafeNodeWrite(rGeom[7], WATER_PRESSURE, (14.4 * (p5 + p6) - 1.6 * (p1 + p2)) * c1); - ThreadSafeNodeWrite(rGeom[8], WATER_PRESSURE, (3.0 * p2 + p1 + 27.0 * p6 - 5.4 * p5) * c1); - ThreadSafeNodeWrite(rGeom[9], WATER_PRESSURE, (3.0 * p2 + p0 + 27.0 * p7 - 5.4 * p8) * c1); - ThreadSafeNodeWrite(rGeom[10], WATER_PRESSURE, (14.4 * (p7 + p8) - 1.6 * (p0 + p2)) * c1); - ThreadSafeNodeWrite(rGeom[11], WATER_PRESSURE, (3.0 * p0 + p2 + 27.0 * p8 - 5.4 * p7) * c1); + const double p0 = r_geom[0].FastGetSolutionStepValue(WATER_PRESSURE); + const double p1 = r_geom[1].FastGetSolutionStepValue(WATER_PRESSURE); + const double p2 = r_geom[2].FastGetSolutionStepValue(WATER_PRESSURE); + const double p3 = r_geom[3].FastGetSolutionStepValue(WATER_PRESSURE); + const double p4 = r_geom[4].FastGetSolutionStepValue(WATER_PRESSURE); + const double p5 = r_geom[5].FastGetSolutionStepValue(WATER_PRESSURE); + const double p6 = r_geom[6].FastGetSolutionStepValue(WATER_PRESSURE); + const double p7 = r_geom[7].FastGetSolutionStepValue(WATER_PRESSURE); + const double p8 = r_geom[8].FastGetSolutionStepValue(WATER_PRESSURE); + const double p9 = r_geom[9].FastGetSolutionStepValue(WATER_PRESSURE); + ThreadSafeNodeWrite(r_geom[0], WATER_PRESSURE, p0); + ThreadSafeNodeWrite(r_geom[1], WATER_PRESSURE, p1); + ThreadSafeNodeWrite(r_geom[2], WATER_PRESSURE, p2); + ThreadSafeNodeWrite(r_geom[3], WATER_PRESSURE, (3.0 * p0 + p1 + 27.0 * p3 - 5.4 * p4) * c1); + ThreadSafeNodeWrite(r_geom[4], WATER_PRESSURE, (14.4 * (p3 + p4) - 1.6 * (p0 + p1)) * c1); + ThreadSafeNodeWrite(r_geom[5], WATER_PRESSURE, (3.0 * p1 + p0 + 27.0 * p4 - 5.4 * p3) * c1); + ThreadSafeNodeWrite(r_geom[6], WATER_PRESSURE, (3.0 * p1 + p2 + 27.0 * p5 - 5.4 * p6) * c1); + ThreadSafeNodeWrite(r_geom[7], WATER_PRESSURE, (14.4 * (p5 + p6) - 1.6 * (p1 + p2)) * c1); + ThreadSafeNodeWrite(r_geom[8], WATER_PRESSURE, (3.0 * p2 + p1 + 27.0 * p6 - 5.4 * p5) * c1); + ThreadSafeNodeWrite(r_geom[9], WATER_PRESSURE, (3.0 * p2 + p0 + 27.0 * p7 - 5.4 * p8) * c1); + ThreadSafeNodeWrite(r_geom[10], WATER_PRESSURE, (14.4 * (p7 + p8) - 1.6 * (p0 + p2)) * c1); + ThreadSafeNodeWrite(r_geom[11], WATER_PRESSURE, (3.0 * p0 + p2 + 27.0 * p8 - 5.4 * p7) * c1); ThreadSafeNodeWrite( - rGeom[12], WATER_PRESSURE, + r_geom[12], WATER_PRESSURE, (p1 + p2 + 7.2 * (p3 + p8) - 3.6 * (p4 + p7) - 1.8 * (p5 + p6) + 21.6 * p9 - 1.6 * p0) * c1); ThreadSafeNodeWrite( - rGeom[13], WATER_PRESSURE, + r_geom[13], WATER_PRESSURE, (p0 + p2 + 7.2 * (p4 + p5) - 3.6 * (p3 + p6) - 1.8 * (p7 + p8) + 21.6 * p9 - 1.6 * p1) * c1); ThreadSafeNodeWrite( - rGeom[14], WATER_PRESSURE, + r_geom[14], WATER_PRESSURE, (p0 + p1 + 7.2 * (p6 + p7) - 3.6 * (p5 + p8) - 1.8 * (p3 + p4) + 21.6 * p9 - 1.6 * p2) * c1); break; } case 20: // 3D H20P8 { - const double p0 = rGeom[0].FastGetSolutionStepValue(WATER_PRESSURE); - const double p1 = rGeom[1].FastGetSolutionStepValue(WATER_PRESSURE); - const double p2 = rGeom[2].FastGetSolutionStepValue(WATER_PRESSURE); - const double p3 = rGeom[3].FastGetSolutionStepValue(WATER_PRESSURE); - const double p4 = rGeom[4].FastGetSolutionStepValue(WATER_PRESSURE); - const double p5 = rGeom[5].FastGetSolutionStepValue(WATER_PRESSURE); - const double p6 = rGeom[6].FastGetSolutionStepValue(WATER_PRESSURE); - const double p7 = rGeom[7].FastGetSolutionStepValue(WATER_PRESSURE); + const double p0 = r_geom[0].FastGetSolutionStepValue(WATER_PRESSURE); + const double p1 = r_geom[1].FastGetSolutionStepValue(WATER_PRESSURE); + const double p2 = r_geom[2].FastGetSolutionStepValue(WATER_PRESSURE); + const double p3 = r_geom[3].FastGetSolutionStepValue(WATER_PRESSURE); + const double p4 = r_geom[4].FastGetSolutionStepValue(WATER_PRESSURE); + const double p5 = r_geom[5].FastGetSolutionStepValue(WATER_PRESSURE); + const double p6 = r_geom[6].FastGetSolutionStepValue(WATER_PRESSURE); + const double p7 = r_geom[7].FastGetSolutionStepValue(WATER_PRESSURE); // edges -- bottom - ThreadSafeNodeWrite(rGeom[8], WATER_PRESSURE, 0.5 * (p0 + p1)); - ThreadSafeNodeWrite(rGeom[9], WATER_PRESSURE, 0.5 * (p1 + p2)); - ThreadSafeNodeWrite(rGeom[10], WATER_PRESSURE, 0.5 * (p2 + p3)); - ThreadSafeNodeWrite(rGeom[11], WATER_PRESSURE, 0.5 * (p3 + p0)); + ThreadSafeNodeWrite(r_geom[8], WATER_PRESSURE, 0.5 * (p0 + p1)); + ThreadSafeNodeWrite(r_geom[9], WATER_PRESSURE, 0.5 * (p1 + p2)); + ThreadSafeNodeWrite(r_geom[10], WATER_PRESSURE, 0.5 * (p2 + p3)); + ThreadSafeNodeWrite(r_geom[11], WATER_PRESSURE, 0.5 * (p3 + p0)); // edges -- middle - ThreadSafeNodeWrite(rGeom[12], WATER_PRESSURE, 0.5 * (p4 + p0)); - ThreadSafeNodeWrite(rGeom[13], WATER_PRESSURE, 0.5 * (p5 + p1)); - ThreadSafeNodeWrite(rGeom[14], WATER_PRESSURE, 0.5 * (p6 + p2)); - ThreadSafeNodeWrite(rGeom[15], WATER_PRESSURE, 0.5 * (p7 + p3)); + ThreadSafeNodeWrite(r_geom[12], WATER_PRESSURE, 0.5 * (p4 + p0)); + ThreadSafeNodeWrite(r_geom[13], WATER_PRESSURE, 0.5 * (p5 + p1)); + ThreadSafeNodeWrite(r_geom[14], WATER_PRESSURE, 0.5 * (p6 + p2)); + ThreadSafeNodeWrite(r_geom[15], WATER_PRESSURE, 0.5 * (p7 + p3)); // edges -- top - ThreadSafeNodeWrite(rGeom[16], WATER_PRESSURE, 0.5 * (p4 + p5)); - ThreadSafeNodeWrite(rGeom[17], WATER_PRESSURE, 0.5 * (p5 + p6)); - ThreadSafeNodeWrite(rGeom[18], WATER_PRESSURE, 0.5 * (p6 + p7)); - ThreadSafeNodeWrite(rGeom[19], WATER_PRESSURE, 0.5 * (p7 + p4)); + ThreadSafeNodeWrite(r_geom[16], WATER_PRESSURE, 0.5 * (p4 + p5)); + ThreadSafeNodeWrite(r_geom[17], WATER_PRESSURE, 0.5 * (p5 + p6)); + ThreadSafeNodeWrite(r_geom[18], WATER_PRESSURE, 0.5 * (p6 + p7)); + ThreadSafeNodeWrite(r_geom[19], WATER_PRESSURE, 0.5 * (p7 + p4)); break; } case 27: // 3D H27P8 { - const double p0 = rGeom[0].FastGetSolutionStepValue(WATER_PRESSURE); - const double p1 = rGeom[1].FastGetSolutionStepValue(WATER_PRESSURE); - const double p2 = rGeom[2].FastGetSolutionStepValue(WATER_PRESSURE); - const double p3 = rGeom[3].FastGetSolutionStepValue(WATER_PRESSURE); - const double p4 = rGeom[4].FastGetSolutionStepValue(WATER_PRESSURE); - const double p5 = rGeom[5].FastGetSolutionStepValue(WATER_PRESSURE); - const double p6 = rGeom[6].FastGetSolutionStepValue(WATER_PRESSURE); - const double p7 = rGeom[7].FastGetSolutionStepValue(WATER_PRESSURE); + const double p0 = r_geom[0].FastGetSolutionStepValue(WATER_PRESSURE); + const double p1 = r_geom[1].FastGetSolutionStepValue(WATER_PRESSURE); + const double p2 = r_geom[2].FastGetSolutionStepValue(WATER_PRESSURE); + const double p3 = r_geom[3].FastGetSolutionStepValue(WATER_PRESSURE); + const double p4 = r_geom[4].FastGetSolutionStepValue(WATER_PRESSURE); + const double p5 = r_geom[5].FastGetSolutionStepValue(WATER_PRESSURE); + const double p6 = r_geom[6].FastGetSolutionStepValue(WATER_PRESSURE); + const double p7 = r_geom[7].FastGetSolutionStepValue(WATER_PRESSURE); // edges -- bottom - ThreadSafeNodeWrite(rGeom[8], WATER_PRESSURE, 0.5 * (p0 + p1)); - ThreadSafeNodeWrite(rGeom[9], WATER_PRESSURE, 0.5 * (p1 + p2)); - ThreadSafeNodeWrite(rGeom[10], WATER_PRESSURE, 0.5 * (p2 + p3)); - ThreadSafeNodeWrite(rGeom[11], WATER_PRESSURE, 0.5 * (p3 + p0)); + ThreadSafeNodeWrite(r_geom[8], WATER_PRESSURE, 0.5 * (p0 + p1)); + ThreadSafeNodeWrite(r_geom[9], WATER_PRESSURE, 0.5 * (p1 + p2)); + ThreadSafeNodeWrite(r_geom[10], WATER_PRESSURE, 0.5 * (p2 + p3)); + ThreadSafeNodeWrite(r_geom[11], WATER_PRESSURE, 0.5 * (p3 + p0)); // edges -- middle - ThreadSafeNodeWrite(rGeom[12], WATER_PRESSURE, 0.5 * (p4 + p0)); - ThreadSafeNodeWrite(rGeom[13], WATER_PRESSURE, 0.5 * (p5 + p1)); - ThreadSafeNodeWrite(rGeom[14], WATER_PRESSURE, 0.5 * (p6 + p2)); - ThreadSafeNodeWrite(rGeom[15], WATER_PRESSURE, 0.5 * (p7 + p3)); + ThreadSafeNodeWrite(r_geom[12], WATER_PRESSURE, 0.5 * (p4 + p0)); + ThreadSafeNodeWrite(r_geom[13], WATER_PRESSURE, 0.5 * (p5 + p1)); + ThreadSafeNodeWrite(r_geom[14], WATER_PRESSURE, 0.5 * (p6 + p2)); + ThreadSafeNodeWrite(r_geom[15], WATER_PRESSURE, 0.5 * (p7 + p3)); // edges -- top - ThreadSafeNodeWrite(rGeom[16], WATER_PRESSURE, 0.5 * (p4 + p5)); - ThreadSafeNodeWrite(rGeom[17], WATER_PRESSURE, 0.5 * (p5 + p6)); - ThreadSafeNodeWrite(rGeom[18], WATER_PRESSURE, 0.5 * (p6 + p7)); - ThreadSafeNodeWrite(rGeom[19], WATER_PRESSURE, 0.5 * (p7 + p0)); + ThreadSafeNodeWrite(r_geom[16], WATER_PRESSURE, 0.5 * (p4 + p5)); + ThreadSafeNodeWrite(r_geom[17], WATER_PRESSURE, 0.5 * (p5 + p6)); + ThreadSafeNodeWrite(r_geom[18], WATER_PRESSURE, 0.5 * (p6 + p7)); + ThreadSafeNodeWrite(r_geom[19], WATER_PRESSURE, 0.5 * (p7 + p0)); // face centers - ThreadSafeNodeWrite(rGeom[20], WATER_PRESSURE, 0.25 * (p0 + p1 + p2 + p3)); - ThreadSafeNodeWrite(rGeom[21], WATER_PRESSURE, 0.25 * (p0 + p1 + p4 + p5)); - ThreadSafeNodeWrite(rGeom[22], WATER_PRESSURE, 0.25 * (p1 + p2 + p5 + p6)); - ThreadSafeNodeWrite(rGeom[23], WATER_PRESSURE, 0.25 * (p2 + p3 + p6 + p7)); - ThreadSafeNodeWrite(rGeom[24], WATER_PRESSURE, 0.25 * (p3 + p0 + p7 + p4)); - ThreadSafeNodeWrite(rGeom[25], WATER_PRESSURE, 0.25 * (p4 + p5 + p6 + p7)); + ThreadSafeNodeWrite(r_geom[20], WATER_PRESSURE, 0.25 * (p0 + p1 + p2 + p3)); + ThreadSafeNodeWrite(r_geom[21], WATER_PRESSURE, 0.25 * (p0 + p1 + p4 + p5)); + ThreadSafeNodeWrite(r_geom[22], WATER_PRESSURE, 0.25 * (p1 + p2 + p5 + p6)); + ThreadSafeNodeWrite(r_geom[23], WATER_PRESSURE, 0.25 * (p2 + p3 + p6 + p7)); + ThreadSafeNodeWrite(r_geom[24], WATER_PRESSURE, 0.25 * (p3 + p0 + p7 + p4)); + ThreadSafeNodeWrite(r_geom[25], WATER_PRESSURE, 0.25 * (p4 + p5 + p6 + p7)); // element center - ThreadSafeNodeWrite(rGeom[26], WATER_PRESSURE, 0.125 * (p0 + p1 + p2 + p3 + p4 + p5 + p6 + p7)); + ThreadSafeNodeWrite(r_geom[26], WATER_PRESSURE, 0.125 * (p0 + p1 + p2 + p3 + p4 + p5 + p6 + p7)); break; } default: @@ -527,8 +513,8 @@ void SmallStrainUPwDiffOrderElement::CalculateOnIntegrationPoints(const Variable { KRATOS_TRY - const GeometryType& rGeom = GetGeometry(); - const auto number_of_integration_points = rGeom.IntegrationPointsNumber(this->GetIntegrationMethod()); + const GeometryType& r_geom = GetGeometry(); + const auto number_of_integration_points = r_geom.IntegrationPointsNumber(this->GetIntegrationMethod()); rOutput.resize(number_of_integration_points); @@ -604,41 +590,41 @@ void SmallStrainUPwDiffOrderElement::CalculateOnIntegrationPoints(const Variable mRetentionLawVector[GPoint]->CalculateRelativePermeability(RetentionParameters); } } else if (rVariable == HYDRAULIC_HEAD) { - const double NumericalLimit = std::numeric_limits::epsilon(); - const PropertiesType& rProp = this->GetProperties(); + constexpr double NumericalLimit = std::numeric_limits::epsilon(); + const PropertiesType& r_prop = this->GetProperties(); // Defining the shape functions, the Jacobian and the shape functions local gradients Containers - const Matrix& NContainer = rGeom.ShapeFunctionsValues(this->GetIntegrationMethod()); - const SizeType NumUNodes = rGeom.PointsNumber(); + const Matrix& NContainer = r_geom.ShapeFunctionsValues(this->GetIntegrationMethod()); + const SizeType num_u_nodes = r_geom.PointsNumber(); // Defining necessary variables - Vector NodalHydraulicHead = ZeroVector(NumUNodes); - for (unsigned int node = 0; node < NumUNodes; ++node) { + Vector NodalHydraulicHead = ZeroVector(num_u_nodes); + for (unsigned int node = 0; node < num_u_nodes; ++node) { Vector NodeVolumeAcceleration(3); - noalias(NodeVolumeAcceleration) = rGeom[node].FastGetSolutionStepValue(VOLUME_ACCELERATION, 0); + noalias(NodeVolumeAcceleration) = r_geom[node].FastGetSolutionStepValue(VOLUME_ACCELERATION, 0); const double g = norm_2(NodeVolumeAcceleration); if (g > NumericalLimit) { - const double FluidWeight = g * rProp[DENSITY_WATER]; + const auto fluid_weight = g * r_prop[DENSITY_WATER]; Vector NodeCoordinates(3); - noalias(NodeCoordinates) = rGeom[node].Coordinates(); + noalias(NodeCoordinates) = r_geom[node].Coordinates(); Vector NodeVolumeAccelerationUnitVector(3); noalias(NodeVolumeAccelerationUnitVector) = NodeVolumeAcceleration / g; - const double WaterPressure = rGeom[node].FastGetSolutionStepValue(WATER_PRESSURE); + const auto water_pressure = r_geom[node].FastGetSolutionStepValue(WATER_PRESSURE); NodalHydraulicHead[node] = -inner_prod(NodeCoordinates, NodeVolumeAccelerationUnitVector) - - PORE_PRESSURE_SIGN_FACTOR * WaterPressure / FluidWeight; + PORE_PRESSURE_SIGN_FACTOR * water_pressure / fluid_weight; } else { NodalHydraulicHead[node] = 0.0; } } for (unsigned int GPoint = 0; GPoint < number_of_integration_points; GPoint++) { - double HydraulicHead = 0.0; - for (unsigned int node = 0; node < NumUNodes; ++node) - HydraulicHead += NContainer(GPoint, node) * NodalHydraulicHead[node]; + double hydraulic_head = 0.0; + for (unsigned int node = 0; node < num_u_nodes; ++node) + hydraulic_head += NContainer(GPoint, node) * NodalHydraulicHead[node]; - rOutput[GPoint] = HydraulicHead; + rOutput[GPoint] = hydraulic_head; } } else { for (unsigned int i = 0; i < number_of_integration_points; ++i) { @@ -713,8 +699,7 @@ void SmallStrainUPwDiffOrderElement::CalculateOnIntegrationPoints(const Variable for (unsigned int idim = 0; idim < Dim; ++idim) FluidFlux[idim] = AuxFluidFlux[idim]; - if (rOutput[GPoint].size() != 3) rOutput[GPoint].resize(3, false); - + rOutput[GPoint].resize(3, false); rOutput[GPoint] = FluidFlux; } } @@ -728,9 +713,9 @@ void SmallStrainUPwDiffOrderElement::CalculateOnIntegrationPoints(const Variable { KRATOS_TRY - const GeometryType& rGeom = GetGeometry(); + const GeometryType& r_geom = GetGeometry(); - rOutput.resize(rGeom.IntegrationPointsNumber(this->GetIntegrationMethod())); + rOutput.resize(r_geom.IntegrationPointsNumber(this->GetIntegrationMethod())); if (rVariable == CAUCHY_STRESS_VECTOR) { for (unsigned int GPoint = 0; GPoint < mConstitutiveLawVector.size(); ++GPoint) { @@ -743,7 +728,7 @@ void SmallStrainUPwDiffOrderElement::CalculateOnIntegrationPoints(const Variable ElementVariables Variables; this->InitializeElementVariables(Variables, rCurrentProcessInfo); - ConstitutiveLaw::Parameters ConstitutiveParameters(rGeom, GetProperties(), rCurrentProcessInfo); + ConstitutiveLaw::Parameters ConstitutiveParameters(r_geom, GetProperties(), rCurrentProcessInfo); ConstitutiveParameters.Set(ConstitutiveLaw::COMPUTE_CONSTITUTIVE_TENSOR); ConstitutiveParameters.Set(ConstitutiveLaw::USE_ELEMENT_PROVIDED_STRAIN); @@ -862,12 +847,12 @@ void SmallStrainUPwDiffOrderElement::CalculateAll(MatrixType& rLeftHandSi { KRATOS_TRY - const PropertiesType& rProp = this->GetProperties(); - const GeometryType& rGeom = GetGeometry(); - const GeometryType::IntegrationPointsArrayType& IntegrationPoints = - rGeom.IntegrationPoints(this->GetIntegrationMethod()); + const PropertiesType& r_prop = this->GetProperties(); + const GeometryType& r_geom = GetGeometry(); + const GeometryType::IntegrationPointsArrayType& r_integration_points = + r_geom.IntegrationPoints(this->GetIntegrationMethod()); - ConstitutiveLaw::Parameters ConstitutiveParameters(rGeom, rProp, rCurrentProcessInfo); + ConstitutiveLaw::Parameters ConstitutiveParameters(r_geom, r_prop, rCurrentProcessInfo); // Stiffness matrix is needed to calculate Biot coefficient ConstitutiveParameters.Set(ConstitutiveLaw::COMPUTE_CONSTITUTIVE_TENSOR); @@ -877,17 +862,15 @@ void SmallStrainUPwDiffOrderElement::CalculateAll(MatrixType& rLeftHandSi ElementVariables Variables; this->InitializeElementVariables(Variables, rCurrentProcessInfo); - RetentionLaw::Parameters RetentionParameters(rProp); - const auto b_matrices = CalculateBMatrices(Variables.DNu_DXContainer, Variables.NuContainer); const auto integration_coefficients = - this->CalculateIntegrationCoefficients(IntegrationPoints, Variables.detJuContainer); + this->CalculateIntegrationCoefficients(r_integration_points, Variables.detJuContainer); - const auto det_Js_initial_configuration = - GeoEquationOfMotionUtilities::CalculateDetJsInitialConfiguration(rGeom, this->GetIntegrationMethod()); + const auto det_Js_initial_configuration = GeoEquationOfMotionUtilities::CalculateDetJsInitialConfiguration( + r_geom, this->GetIntegrationMethod()); const auto integration_coefficients_on_initial_configuration = - this->CalculateIntegrationCoefficients(IntegrationPoints, det_Js_initial_configuration); + this->CalculateIntegrationCoefficients(r_integration_points, det_Js_initial_configuration); const auto deformation_gradients = CalculateDeformationGradients(); auto strain_vectors = StressStrainUtilities::CalculateStrains( @@ -904,7 +887,7 @@ void SmallStrainUPwDiffOrderElement::CalculateAll(MatrixType& rLeftHandSi const auto degrees_of_saturation = CalculateDegreesOfSaturation(fluid_pressures); const auto derivatives_of_saturation = CalculateDerivativesOfSaturation(fluid_pressures); const auto biot_moduli_inverse = GeoTransportEquationUtilities::CalculateInverseBiotModuli( - biot_coefficients, degrees_of_saturation, derivatives_of_saturation, rProp); + biot_coefficients, degrees_of_saturation, derivatives_of_saturation, r_prop); auto relative_permeability_values = CalculateRelativePermeabilityValues(fluid_pressures); const auto permeability_update_factors = GetOptionalPermeabilityUpdateFactors(strain_vectors); std::transform(permeability_update_factors.cbegin(), permeability_update_factors.cend(), @@ -913,7 +896,7 @@ void SmallStrainUPwDiffOrderElement::CalculateAll(MatrixType& rLeftHandSi const auto bishop_coefficients = CalculateBishopCoefficients(fluid_pressures); - for (unsigned int GPoint = 0; GPoint < IntegrationPoints.size(); ++GPoint) { + for (unsigned int GPoint = 0; GPoint < r_integration_points.size(); ++GPoint) { this->CalculateKinematics(Variables, GPoint); Variables.B = b_matrices[GPoint]; Variables.F = deformation_gradients[GPoint]; @@ -982,20 +965,20 @@ void SmallStrainUPwDiffOrderElement::CalculateMaterialStiffnessMatrix(MatrixType { KRATOS_TRY - const GeometryType& rGeom = GetGeometry(); + const GeometryType& r_geom = GetGeometry(); // Definition of variables ElementVariables Variables; this->InitializeElementVariables(Variables, rCurrentProcessInfo); // Create constitutive law parameters: - ConstitutiveLaw::Parameters ConstitutiveParameters(rGeom, GetProperties(), rCurrentProcessInfo); + ConstitutiveLaw::Parameters ConstitutiveParameters(r_geom, GetProperties(), rCurrentProcessInfo); ConstitutiveParameters.GetOptions().Set(ConstitutiveLaw::USE_ELEMENT_PROVIDED_STRAIN); ConstitutiveParameters.GetOptions().Set(ConstitutiveLaw::COMPUTE_CONSTITUTIVE_TENSOR); // Loop over integration points - const GeometryType::IntegrationPointsArrayType& IntegrationPoints = - rGeom.IntegrationPoints(this->GetIntegrationMethod()); + const GeometryType::IntegrationPointsArrayType& r_integration_points = + r_geom.IntegrationPoints(this->GetIntegrationMethod()); const auto b_matrices = CalculateBMatrices(Variables.DNu_DXContainer, Variables.NuContainer); const auto deformation_gradients = CalculateDeformationGradients(); @@ -1007,7 +990,7 @@ void SmallStrainUPwDiffOrderElement::CalculateMaterialStiffnessMatrix(MatrixType Variables.NuContainer, Variables.DNu_DXContainer, strain_vectors, mStressVector, constitutive_matrices); const auto integration_coefficients = - this->CalculateIntegrationCoefficients(IntegrationPoints, Variables.detJuContainer); + this->CalculateIntegrationCoefficients(r_integration_points, Variables.detJuContainer); const auto stiffness_matrix = GeoEquationOfMotionUtilities::CalculateStiffnessMatrix( b_matrices, constitutive_matrices, integration_coefficients); @@ -1022,31 +1005,31 @@ void SmallStrainUPwDiffOrderElement::InitializeElementVariables(ElementVariables { KRATOS_TRY - const GeometryType& rGeom = GetGeometry(); - const SizeType NumUNodes = rGeom.PointsNumber(); - const SizeType NumPNodes = mpPressureGeometry->PointsNumber(); - const SizeType NumGPoints = rGeom.IntegrationPointsNumber(this->GetIntegrationMethod()); - const SizeType Dim = rGeom.WorkingSpaceDimension(); + const GeometryType& r_geom = GetGeometry(); + const SizeType num_u_nodes = r_geom.PointsNumber(); + const SizeType num_p_nodes = mpPressureGeometry->PointsNumber(); + const SizeType num_g_points = r_geom.IntegrationPointsNumber(this->GetIntegrationMethod()); + const SizeType n_dim = r_geom.WorkingSpaceDimension(); // Variables at all integration points - rVariables.NuContainer.resize(NumGPoints, NumUNodes, false); - rVariables.NuContainer = rGeom.ShapeFunctionsValues(this->GetIntegrationMethod()); + rVariables.NuContainer.resize(num_g_points, num_u_nodes, false); + rVariables.NuContainer = r_geom.ShapeFunctionsValues(this->GetIntegrationMethod()); - rVariables.NpContainer.resize(NumGPoints, NumPNodes, false); + rVariables.NpContainer.resize(num_g_points, num_p_nodes, false); rVariables.NpContainer = mpPressureGeometry->ShapeFunctionsValues(this->GetIntegrationMethod()); - rVariables.Nu.resize(NumUNodes, false); - rVariables.Np.resize(NumPNodes, false); + rVariables.Nu.resize(num_u_nodes, false); + rVariables.Np.resize(num_p_nodes, false); - rVariables.DNu_DXContainer.resize(NumGPoints, false); - for (SizeType i = 0; i < NumGPoints; ++i) - ((rVariables.DNu_DXContainer)[i]).resize(NumUNodes, Dim, false); - rVariables.DNu_DX.resize(NumUNodes, Dim, false); - rVariables.DNu_DXInitialConfiguration.resize(NumUNodes, Dim, false); - rVariables.detJuContainer.resize(NumGPoints, false); + rVariables.DNu_DXContainer.resize(num_g_points, false); + for (SizeType i = 0; i < num_g_points; ++i) + ((rVariables.DNu_DXContainer)[i]).resize(num_u_nodes, n_dim, false); + rVariables.DNu_DX.resize(num_u_nodes, n_dim, false); + rVariables.DNu_DXInitialConfiguration.resize(num_u_nodes, n_dim, false); + rVariables.detJuContainer.resize(num_g_points, false); try { - rGeom.ShapeFunctionsIntegrationPointsGradients( + r_geom.ShapeFunctionsIntegrationPointsGradients( rVariables.DNu_DXContainer, rVariables.detJuContainer, this->GetIntegrationMethod()); } catch (Kratos::Exception& e) { KRATOS_INFO("Original error message") << e.what() << std::endl; @@ -1060,11 +1043,11 @@ void SmallStrainUPwDiffOrderElement::InitializeElementVariables(ElementVariables << this->Id() << std::endl; } - (rVariables.DNp_DXContainer).resize(NumGPoints, false); - for (SizeType i = 0; i < NumGPoints; ++i) - ((rVariables.DNp_DXContainer)[i]).resize(NumPNodes, Dim, false); - (rVariables.DNp_DX).resize(NumPNodes, Dim, false); - Vector detJpContainer = ZeroVector(NumGPoints); + (rVariables.DNp_DXContainer).resize(num_g_points, false); + for (SizeType i = 0; i < num_g_points; ++i) + ((rVariables.DNp_DXContainer)[i]).resize(num_p_nodes, n_dim, false); + (rVariables.DNp_DX).resize(num_p_nodes, n_dim, false); + Vector detJpContainer = ZeroVector(num_g_points); try { mpPressureGeometry->ShapeFunctionsIntegrationPointsGradients( @@ -1084,8 +1067,8 @@ void SmallStrainUPwDiffOrderElement::InitializeElementVariables(ElementVariables // Variables computed at each integration point const SizeType VoigtSize = this->GetStressStatePolicy().GetVoigtSize(); - rVariables.B.resize(VoigtSize, NumUNodes * Dim, false); - noalias(rVariables.B) = ZeroMatrix(VoigtSize, NumUNodes * Dim); + rVariables.B.resize(VoigtSize, num_u_nodes * n_dim, false); + noalias(rVariables.B) = ZeroMatrix(VoigtSize, num_u_nodes * n_dim); rVariables.StrainVector.resize(VoigtSize, false); rVariables.ConstitutiveMatrix.resize(VoigtSize, VoigtSize, false); @@ -1093,8 +1076,8 @@ void SmallStrainUPwDiffOrderElement::InitializeElementVariables(ElementVariables rVariables.StressVector.resize(VoigtSize, false); // Needed parameters for consistency with the general constitutive law - rVariables.F.resize(Dim, Dim, false); - noalias(rVariables.F) = identity_matrix(Dim); + rVariables.F.resize(n_dim, n_dim, false); + noalias(rVariables.F) = identity_matrix(n_dim); // Nodal variables this->InitializeNodalVariables(rVariables); @@ -1118,43 +1101,43 @@ void SmallStrainUPwDiffOrderElement::InitializeNodalVariables(ElementVariables& { KRATOS_TRY - const GeometryType& rGeom = GetGeometry(); - const SizeType Dim = rGeom.WorkingSpaceDimension(); - const SizeType NumUNodes = rGeom.PointsNumber(); - const SizeType NumPNodes = mpPressureGeometry->PointsNumber(); + const GeometryType& r_geom = GetGeometry(); + const SizeType n_dim = r_geom.WorkingSpaceDimension(); + const SizeType num_u_nodes = r_geom.PointsNumber(); + const SizeType num_p_nodes = mpPressureGeometry->PointsNumber(); Vector BodyAccelerationAux = ZeroVector(3); - rVariables.BodyAcceleration.resize(NumUNodes * Dim, false); - rVariables.DisplacementVector.resize(NumUNodes * Dim, false); - rVariables.VelocityVector.resize(NumUNodes * Dim, false); + rVariables.BodyAcceleration.resize(num_u_nodes * n_dim, false); + rVariables.DisplacementVector.resize(num_u_nodes * n_dim, false); + rVariables.VelocityVector.resize(num_u_nodes * n_dim, false); - for (SizeType i = 0; i < NumUNodes; ++i) { - SizeType Local_i = i * Dim; - BodyAccelerationAux = rGeom[i].FastGetSolutionStepValue(VOLUME_ACCELERATION); + for (SizeType i = 0; i < num_u_nodes; ++i) { + SizeType Local_i = i * n_dim; + BodyAccelerationAux = r_geom[i].FastGetSolutionStepValue(VOLUME_ACCELERATION); rVariables.BodyAcceleration[Local_i] = BodyAccelerationAux[0]; - rVariables.DisplacementVector[Local_i] = rGeom[i].FastGetSolutionStepValue(DISPLACEMENT_X); - rVariables.VelocityVector[Local_i] = rGeom[i].FastGetSolutionStepValue(VELOCITY_X); + rVariables.DisplacementVector[Local_i] = r_geom[i].FastGetSolutionStepValue(DISPLACEMENT_X); + rVariables.VelocityVector[Local_i] = r_geom[i].FastGetSolutionStepValue(VELOCITY_X); rVariables.BodyAcceleration[Local_i + 1] = BodyAccelerationAux[1]; - rVariables.DisplacementVector[Local_i + 1] = rGeom[i].FastGetSolutionStepValue(DISPLACEMENT_Y); - rVariables.VelocityVector[Local_i + 1] = rGeom[i].FastGetSolutionStepValue(VELOCITY_Y); + rVariables.DisplacementVector[Local_i + 1] = r_geom[i].FastGetSolutionStepValue(DISPLACEMENT_Y); + rVariables.VelocityVector[Local_i + 1] = r_geom[i].FastGetSolutionStepValue(VELOCITY_Y); - if (Dim > 2) { + if (n_dim > 2) { rVariables.BodyAcceleration[Local_i + 2] = BodyAccelerationAux[2]; - rVariables.DisplacementVector[Local_i + 2] = rGeom[i].FastGetSolutionStepValue(DISPLACEMENT_Z); - rVariables.VelocityVector[Local_i + 2] = rGeom[i].FastGetSolutionStepValue(VELOCITY_Z); + rVariables.DisplacementVector[Local_i + 2] = r_geom[i].FastGetSolutionStepValue(DISPLACEMENT_Z); + rVariables.VelocityVector[Local_i + 2] = r_geom[i].FastGetSolutionStepValue(VELOCITY_Z); } } - rVariables.PressureVector.resize(NumPNodes, false); - rVariables.PressureDtVector.resize(NumPNodes, false); - rVariables.DeltaPressureVector.resize(NumPNodes, false); - for (SizeType i = 0; i < NumPNodes; ++i) { - rVariables.PressureVector[i] = rGeom[i].FastGetSolutionStepValue(WATER_PRESSURE); - rVariables.PressureDtVector[i] = rGeom[i].FastGetSolutionStepValue(DT_WATER_PRESSURE); - rVariables.DeltaPressureVector[i] = rGeom[i].FastGetSolutionStepValue(WATER_PRESSURE) - - rGeom[i].FastGetSolutionStepValue(WATER_PRESSURE, 1); + rVariables.PressureVector.resize(num_p_nodes, false); + rVariables.PressureDtVector.resize(num_p_nodes, false); + rVariables.DeltaPressureVector.resize(num_p_nodes, false); + for (SizeType i = 0; i < num_p_nodes; ++i) { + rVariables.PressureVector[i] = r_geom[i].FastGetSolutionStepValue(WATER_PRESSURE); + rVariables.PressureDtVector[i] = r_geom[i].FastGetSolutionStepValue(DT_WATER_PRESSURE); + rVariables.DeltaPressureVector[i] = r_geom[i].FastGetSolutionStepValue(WATER_PRESSURE) - + r_geom[i].FastGetSolutionStepValue(WATER_PRESSURE, 1); } KRATOS_CATCH("") @@ -1195,7 +1178,6 @@ void SmallStrainUPwDiffOrderElement::InitializeProperties(ElementVariables& rVar } void SmallStrainUPwDiffOrderElement::CalculateKinematics(ElementVariables& rVariables, unsigned int GPoint) - { KRATOS_TRY @@ -1270,10 +1252,10 @@ void SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingMatrix(MatrixType& r { KRATOS_TRY - Matrix CouplingMatrix = GeoTransportEquationUtilities::CalculateCouplingMatrix( + Matrix coupling_matrix = GeoTransportEquationUtilities::CalculateCouplingMatrix( rVariables.B, GetStressStatePolicy().GetVoigtVector(), rVariables.Np, rVariables.BiotCoefficient, rVariables.BishopCoefficient, rVariables.IntegrationCoefficient); - GeoElementUtilities::AssembleUPBlockMatrix(rLeftHandSideMatrix, CouplingMatrix); + GeoElementUtilities::AssembleUPBlockMatrix(rLeftHandSideMatrix, coupling_matrix); if (!rVariables.IgnoreUndrained) { Matrix CouplingMatrix = GeoTransportEquationUtilities::CalculateCouplingMatrix( @@ -1373,21 +1355,21 @@ void SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingTerms(VectorType& rR { KRATOS_TRY - const Matrix coupling_matrix = + const Matrix u_coupling_matrix = (-1.0) * GeoTransportEquationUtilities::CalculateCouplingMatrix( rVariables.B, GetStressStatePolicy().GetVoigtVector(), rVariables.Np, rVariables.BiotCoefficient, rVariables.BishopCoefficient, rVariables.IntegrationCoefficient); - const Vector coupling_force = prod(coupling_matrix, rVariables.PressureVector); + const Vector coupling_force = prod(u_coupling_matrix, rVariables.PressureVector); GeoElementUtilities::AssembleUBlockVector(rRightHandSideVector, coupling_force); if (!rVariables.IgnoreUndrained) { - const Matrix coupling_matrix = + const Matrix p_coupling_matrix = (-1.0) * GeoTransportEquationUtilities::CalculateCouplingMatrix( rVariables.B, GetStressStatePolicy().GetVoigtVector(), rVariables.Np, rVariables.BiotCoefficient, rVariables.DegreeOfSaturation, rVariables.IntegrationCoefficient); const Vector coupling_flow = - PORE_PRESSURE_SIGN_FACTOR * prod(trans(coupling_matrix), rVariables.VelocityVector); + PORE_PRESSURE_SIGN_FACTOR * prod(trans(p_coupling_matrix), rVariables.VelocityVector); GeoElementUtilities::AssemblePBlockVector(rRightHandSideVector, coupling_flow); } @@ -1399,9 +1381,9 @@ void SmallStrainUPwDiffOrderElement::CalculateAndAddCompressibilityFlow(VectorTy { KRATOS_TRY - Matrix CompressibilityMatrix = GeoTransportEquationUtilities::CalculateCompressibilityMatrix( + Matrix compressibility_matrix = GeoTransportEquationUtilities::CalculateCompressibilityMatrix( rVariables.Np, rVariables.BiotModulusInverse, rVariables.IntegrationCoefficient); - Vector CompressibilityFlow = -prod(CompressibilityMatrix, rVariables.PressureDtVector); + Vector CompressibilityFlow = -prod(compressibility_matrix, rVariables.PressureDtVector); GeoElementUtilities::AssemblePBlockVector(rRightHandSideVector, CompressibilityFlow); KRATOS_CATCH("") diff --git a/applications/GeoMechanicsApplication/custom_elements/transient_Pw_line_element.h b/applications/GeoMechanicsApplication/custom_elements/transient_Pw_line_element.h index f19eef8fd289..0b62c7713622 100644 --- a/applications/GeoMechanicsApplication/custom_elements/transient_Pw_line_element.h +++ b/applications/GeoMechanicsApplication/custom_elements/transient_Pw_line_element.h @@ -75,8 +75,8 @@ class KRATOS_API(GEO_MECHANICS_APPLICATION) TransientPwLineElement : public Elem { mRetentionLawVector.resize(GetGeometry().IntegrationPointsNumber(GetIntegrationMethod())); - for (unsigned int i = 0; i < mRetentionLawVector.size(); ++i) { - mRetentionLawVector[i] = RetentionLawFactory::Clone(GetProperties()); + for (auto& r_retention_law : mRetentionLawVector) { + r_retention_law = RetentionLawFactory::Clone(GetProperties()); } } From c5871a291c6c7ffbaf701d470247a19608360616 Mon Sep 17 00:00:00 2001 From: Wijtze Pieter Kikstra Date: Tue, 10 Dec 2024 16:20:13 +0100 Subject: [PATCH 17/36] Coupling matrix computation without potential zero division also in small_strain_upw. --- .../U_Pw_small_strain_element.cpp | 17 +++++++++-------- .../small_strain_U_Pw_diff_order_element.cpp | 19 ++++++++++--------- 2 files changed, 19 insertions(+), 17 deletions(-) diff --git a/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp b/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp index 319efadf8b8e..cc90e84e760c 100644 --- a/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp +++ b/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp @@ -1276,17 +1276,18 @@ void UPwSmallStrainElement::CalculateAndAddCouplingMatrix(Matri { KRATOS_TRY - const auto coupling_matrix = GeoTransportEquationUtilities::CalculateCouplingMatrix( - rVariables.B, this->GetStressStatePolicy().GetVoigtVector(), rVariables.Np, + const Matrix coupling_matrix_up = GeoTransportEquationUtilities::CalculateCouplingMatrix( + rVariables.B, GetStressStatePolicy().GetVoigtVector(), rVariables.Np, rVariables.BiotCoefficient, rVariables.BishopCoefficient, rVariables.IntegrationCoefficient); - GeoElementUtilities::AssembleUPBlockMatrix(rLeftHandSideMatrix, coupling_matrix); + GeoElementUtilities::AssembleUPBlockMatrix(rLeftHandSideMatrix, coupling_matrix_up); if (!rVariables.IgnoreUndrained) { - const double SaturationCoefficient = rVariables.DegreeOfSaturation / rVariables.BishopCoefficient; - const BoundedMatrix transposed_coupling_matrix = - PORE_PRESSURE_SIGN_FACTOR * SaturationCoefficient * rVariables.VelocityCoefficient * - trans(coupling_matrix); - GeoElementUtilities::AssemblePUBlockMatrix(rLeftHandSideMatrix, transposed_coupling_matrix); + const Matrix coupling_matrix_pu = GeoTransportEquationUtilities::CalculateCouplingMatrix( + rVariables.B, GetStressStatePolicy().GetVoigtVector(), rVariables.Np, + rVariables.BiotCoefficient, rVariables.DegreeOfSaturation, rVariables.IntegrationCoefficient); + GeoElementUtilities::AssemblePUBlockMatrix( + rLeftHandSideMatrix, + PORE_PRESSURE_SIGN_FACTOR * rVariables.VelocityCoefficient * trans(coupling_matrix_pu)); } KRATOS_CATCH("") diff --git a/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp b/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp index 9a8c818a0b50..bfa6529e631b 100644 --- a/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp +++ b/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp @@ -109,7 +109,8 @@ int SmallStrainUPwDiffOrderElement::Check(const ProcessInfo& rCurrentProcessInfo if (!r_node.SolutionStepsDataHas(DISPLACEMENT)) KRATOS_ERROR << "missing variable DISPLACEMENT on node " << r_node.Id() << std::endl; - if (!r_node.HasDofFor(DISPLACEMENT_X) || !r_node.HasDofFor(DISPLACEMENT_Y) || !r_node.HasDofFor(DISPLACEMENT_Z)) + if (!r_node.HasDofFor(DISPLACEMENT_X) || !r_node.HasDofFor(DISPLACEMENT_Y) || + !r_node.HasDofFor(DISPLACEMENT_Z)) KRATOS_ERROR << "missing one of the dofs for the variable DISPLACEMENT on node " << r_node.Id() << std::endl; @@ -117,8 +118,8 @@ int SmallStrainUPwDiffOrderElement::Check(const ProcessInfo& rCurrentProcessInfo KRATOS_ERROR << "missing variable WATER_PRESSURE on node " << r_node.Id() << std::endl; if (!r_node.HasDofFor(WATER_PRESSURE)) - KRATOS_ERROR << "missing the dof for the variable WATER_PRESSURE on node " << r_node.Id() - << std::endl; + KRATOS_ERROR << "missing the dof for the variable WATER_PRESSURE on node " + << r_node.Id() << std::endl; } // Verify that the constitutive law exists @@ -1252,18 +1253,18 @@ void SmallStrainUPwDiffOrderElement::CalculateAndAddCouplingMatrix(MatrixType& r { KRATOS_TRY - Matrix coupling_matrix = GeoTransportEquationUtilities::CalculateCouplingMatrix( + const Matrix coupling_matrix_up = GeoTransportEquationUtilities::CalculateCouplingMatrix( rVariables.B, GetStressStatePolicy().GetVoigtVector(), rVariables.Np, rVariables.BiotCoefficient, rVariables.BishopCoefficient, rVariables.IntegrationCoefficient); - GeoElementUtilities::AssembleUPBlockMatrix(rLeftHandSideMatrix, coupling_matrix); + GeoElementUtilities::AssembleUPBlockMatrix(rLeftHandSideMatrix, coupling_matrix_up); if (!rVariables.IgnoreUndrained) { - Matrix CouplingMatrix = GeoTransportEquationUtilities::CalculateCouplingMatrix( + const Matrix coupling_matrix_pu = GeoTransportEquationUtilities::CalculateCouplingMatrix( rVariables.B, GetStressStatePolicy().GetVoigtVector(), rVariables.Np, rVariables.BiotCoefficient, rVariables.DegreeOfSaturation, rVariables.IntegrationCoefficient); - Matrix CouplingMatrixT = - PORE_PRESSURE_SIGN_FACTOR * rVariables.VelocityCoefficient * trans(CouplingMatrix); - GeoElementUtilities::AssemblePUBlockMatrix(rLeftHandSideMatrix, CouplingMatrixT); + GeoElementUtilities::AssemblePUBlockMatrix( + rLeftHandSideMatrix, + PORE_PRESSURE_SIGN_FACTOR * rVariables.VelocityCoefficient * trans(coupling_matrix_pu)); } KRATOS_CATCH("") From ef050879455cc506e7ecf791618c033b82487e65 Mon Sep 17 00:00:00 2001 From: Wijtze Pieter Kikstra Date: Tue, 10 Dec 2024 16:59:52 +0100 Subject: [PATCH 18/36] Also avoid zero division in RHS setup of coupling terms. --- .../U_Pw_small_strain_element.cpp | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp b/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp index cc90e84e760c..b2488aa018fd 100644 --- a/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp +++ b/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp @@ -1386,15 +1386,18 @@ void UPwSmallStrainElement::CalculateAndAddCouplingTerms(Vector rVariables.B, this->GetStressStatePolicy().GetVoigtVector(), rVariables.Np, rVariables.BiotCoefficient, rVariables.BishopCoefficient, rVariables.IntegrationCoefficient); - const array_1d coupling_terms = prod(coupling_matrix, rVariables.PressureVector); - GeoElementUtilities::AssembleUBlockVector(rRightHandSideVector, coupling_terms); + const array_1d coupling_force = prod(coupling_matrix, rVariables.PressureVector); + GeoElementUtilities::AssembleUBlockVector(rRightHandSideVector, coupling_force); if (!rVariables.IgnoreUndrained) { - const double SaturationCoefficient = rVariables.DegreeOfSaturation / rVariables.BishopCoefficient; - const array_1d transposed_coupling_matrix = - PORE_PRESSURE_SIGN_FACTOR * SaturationCoefficient * - prod(trans(coupling_matrix), rVariables.VelocityVector); - GeoElementUtilities::AssemblePBlockVector(rRightHandSideVector, transposed_coupling_matrix); + const Matrix p_coupling_matrix = + (-1.0) * GeoTransportEquationUtilities::CalculateCouplingMatrix( + rVariables.B, GetStressStatePolicy().GetVoigtVector(), rVariables.Np, + rVariables.BiotCoefficient, rVariables.DegreeOfSaturation, + rVariables.IntegrationCoefficient); + const array_1d coupling_flow = + PORE_PRESSURE_SIGN_FACTOR * prod(trans(p_coupling_matrix), rVariables.VelocityVector); + GeoElementUtilities::AssemblePBlockVector(rRightHandSideVector, coupling_flow); } KRATOS_CATCH("") From 2a98e5cf41d330e8d8899dbb9cf0b27f4f56b71e Mon Sep 17 00:00:00 2001 From: Wijtze Pieter Kikstra Date: Wed, 11 Dec 2024 14:15:09 +0100 Subject: [PATCH 19/36] van Genuchten gl >= 0, clean unused parameters from tests, some geometry loops. --- .../custom_elements/U_Pw_small_strain_element.cpp | 8 +++----- .../small_strain_U_Pw_diff_order_element.cpp | 4 ++-- .../custom_retention/van_genuchten_law.cpp | 2 +- .../MaterialParameters_stage1.json | 9 ++------- .../MaterialParameters_stage1.json | 9 ++------- 5 files changed, 10 insertions(+), 22 deletions(-) diff --git a/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp b/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp index b2488aa018fd..71758b6258bf 100644 --- a/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp +++ b/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp @@ -297,9 +297,8 @@ void UPwSmallStrainElement::ResetHydraulicDischarge() KRATOS_TRY // Reset hydraulic discharge - GeometryType& rGeom = this->GetGeometry(); - for (unsigned int i = 0; i < TNumNodes; ++i) { - ThreadSafeNodeWrite(rGeom[i], HYDRAULIC_DISCHARGE, 0.0); + for (auto& r_node : this->GetGeometry()) { + ThreadSafeNodeWrite(r_node, HYDRAULIC_DISCHARGE, 0.0); } KRATOS_CATCH("") @@ -355,8 +354,7 @@ void UPwSmallStrainElement::InitializeNonLinearIteration(const { KRATOS_TRY - const GeometryType& rGeom = this->GetGeometry(); - ConstitutiveLaw::Parameters ConstitutiveParameters(rGeom, this->GetProperties(), rCurrentProcessInfo); + ConstitutiveLaw::Parameters ConstitutiveParameters(this->GetGeometry(), this->GetProperties(), rCurrentProcessInfo); ConstitutiveParameters.Set(ConstitutiveLaw::COMPUTE_STRESS); ConstitutiveParameters.Set(ConstitutiveLaw::USE_ELEMENT_PROVIDED_STRAIN); ConstitutiveParameters.Set(ConstitutiveLaw::INITIALIZE_MATERIAL_RESPONSE); // Note: this is for nonlocal damage diff --git a/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp b/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp index bfa6529e631b..d84f400e32e8 100644 --- a/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp +++ b/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp @@ -105,7 +105,7 @@ int SmallStrainUPwDiffOrderElement::Check(const ProcessInfo& rCurrentProcessInfo } // verify that the dofs exist - for (auto& r_node : r_geom) { + for (const auto& r_node : r_geom) { if (!r_node.SolutionStepsDataHas(DISPLACEMENT)) KRATOS_ERROR << "missing variable DISPLACEMENT on node " << r_node.Id() << std::endl; @@ -153,7 +153,7 @@ int SmallStrainUPwDiffOrderElement::Check(const ProcessInfo& rCurrentProcessInfo << " in element id: " << this->Id() << std::endl; } - // Check constitutive law + // Check retention law if (!mRetentionLawVector.empty()) { return mRetentionLawVector[0]->Check(r_prop, rCurrentProcessInfo); } diff --git a/applications/GeoMechanicsApplication/custom_retention/van_genuchten_law.cpp b/applications/GeoMechanicsApplication/custom_retention/van_genuchten_law.cpp index 3ae85226e215..822209c4c325 100644 --- a/applications/GeoMechanicsApplication/custom_retention/van_genuchten_law.cpp +++ b/applications/GeoMechanicsApplication/custom_retention/van_genuchten_law.cpp @@ -163,7 +163,7 @@ int VanGenuchtenLaw::Check(const Properties& rMaterialProperties, const ProcessI KRATOS_ERROR_IF_NOT(rMaterialProperties.Has(VAN_GENUCHTEN_GL)) << "VAN_GENUCHTEN_GL is not available in the parameters of material " << rMaterialProperties.Id() << "." << std::endl; - KRATOS_ERROR_IF_NOT((rMaterialProperties[VAN_GENUCHTEN_GL] > 0.0)) + KRATOS_ERROR_IF_NOT((rMaterialProperties[VAN_GENUCHTEN_GL] >= 0.0)) << "VAN_GENUCHTEN_GL (" << rMaterialProperties[VAN_GENUCHTEN_GL] << ") must be greater than 0 for material " << rMaterialProperties.Id() << "." << std::endl; diff --git a/applications/GeoMechanicsApplication/tests/test_Transient_Case_A1_2D3N.gid/MaterialParameters_stage1.json b/applications/GeoMechanicsApplication/tests/test_Transient_Case_A1_2D3N.gid/MaterialParameters_stage1.json index 6c034d079b48..32295e74fc15 100644 --- a/applications/GeoMechanicsApplication/tests/test_Transient_Case_A1_2D3N.gid/MaterialParameters_stage1.json +++ b/applications/GeoMechanicsApplication/tests/test_Transient_Case_A1_2D3N.gid/MaterialParameters_stage1.json @@ -21,13 +21,8 @@ "DYNAMIC_VISCOSITY" : 9.81, "THICKNESS" : 1.0, "BIOT_COEFFICIENT" : 1.0, - "RETENTION_LAW" : "SaturatedLaw", - "SATURATED_SATURATION" : 1.0, - "RESIDUAL_SATURATION" : 0.06203, - "VAN_GENUCHTEN_AIR_ENTRY_PRESSURE" : 4.379464286, - "VAN_GENUCHTEN_GN" : 2.286, - "VAN_GENUCHTEN_GL" : 0, - "MINIMUM_RELATIVE_PERMEABILITY" : 0.0001 + "RETENTION_LAW" : "SaturatedLaw", + "SATURATED_SATURATION" : 1.0 }, "Tables": {} } diff --git a/applications/GeoMechanicsApplication/tests/test_Transient_Case_A1_2D6N.gid/MaterialParameters_stage1.json b/applications/GeoMechanicsApplication/tests/test_Transient_Case_A1_2D6N.gid/MaterialParameters_stage1.json index 6c034d079b48..32295e74fc15 100644 --- a/applications/GeoMechanicsApplication/tests/test_Transient_Case_A1_2D6N.gid/MaterialParameters_stage1.json +++ b/applications/GeoMechanicsApplication/tests/test_Transient_Case_A1_2D6N.gid/MaterialParameters_stage1.json @@ -21,13 +21,8 @@ "DYNAMIC_VISCOSITY" : 9.81, "THICKNESS" : 1.0, "BIOT_COEFFICIENT" : 1.0, - "RETENTION_LAW" : "SaturatedLaw", - "SATURATED_SATURATION" : 1.0, - "RESIDUAL_SATURATION" : 0.06203, - "VAN_GENUCHTEN_AIR_ENTRY_PRESSURE" : 4.379464286, - "VAN_GENUCHTEN_GN" : 2.286, - "VAN_GENUCHTEN_GL" : 0, - "MINIMUM_RELATIVE_PERMEABILITY" : 0.0001 + "RETENTION_LAW" : "SaturatedLaw", + "SATURATED_SATURATION" : 1.0 }, "Tables": {} } From 83debf84eee6f4fcfbac87a3a4d1da5bf4ebc329 Mon Sep 17 00:00:00 2001 From: Wijtze Pieter Kikstra Date: Wed, 11 Dec 2024 17:09:57 +0100 Subject: [PATCH 20/36] IgnoreUndrained setup of LHS and RHS made symmetric. --- .../custom_elements/U_Pw_small_strain_element.cpp | 9 +++++---- .../small_strain_U_Pw_diff_order_element.cpp | 7 ++++--- 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp b/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp index 71758b6258bf..f6b1531adbcd 100644 --- a/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp +++ b/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp @@ -1240,17 +1240,18 @@ void UPwSmallStrainElement::CalculateAndAddLHS(MatrixType& rLef KRATOS_TRY this->CalculateAndAddStiffnessMatrix(rLeftHandSideMatrix, rVariables); - this->CalculateAndAddCompressibilityMatrix(rLeftHandSideMatrix, rVariables); - if (!rVariables.IgnoreUndrained) { - this->CalculateAndAddCouplingMatrix(rLeftHandSideMatrix, rVariables); + this->CalculateAndAddCouplingMatrix(rLeftHandSideMatrix, rVariables); + if (!rVariables.IgnoreUndrained) { const auto permeability_matrix = GeoTransportEquationUtilities::CalculatePermeabilityMatrix( rVariables.GradNpT, rVariables.DynamicViscosityInverse, rVariables.PermeabilityMatrix, rVariables.RelativePermeability, rVariables.IntegrationCoefficient); GeoElementUtilities::AssemblePPBlockMatrix(rLeftHandSideMatrix, permeability_matrix); - } + + this->CalculateAndAddCompressibilityMatrix(rLeftHandSideMatrix, rVariables); +} KRATOS_CATCH("") } diff --git a/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp b/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp index d84f400e32e8..dacfb6bdf588 100644 --- a/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp +++ b/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp @@ -1221,15 +1221,16 @@ void SmallStrainUPwDiffOrderElement::CalculateAndAddLHS(MatrixType& rLeftH KRATOS_TRY this->CalculateAndAddStiffnessMatrix(rLeftHandSideMatrix, rVariables); - this->CalculateAndAddCompressibilityMatrix(rLeftHandSideMatrix, rVariables); - if (!rVariables.IgnoreUndrained) { - this->CalculateAndAddCouplingMatrix(rLeftHandSideMatrix, rVariables); + this->CalculateAndAddCouplingMatrix(rLeftHandSideMatrix, rVariables); + if (!rVariables.IgnoreUndrained) { const auto permeability_matrix = GeoTransportEquationUtilities::CalculatePermeabilityMatrix( rVariables.DNp_DX, rVariables.DynamicViscosityInverse, rVariables.IntrinsicPermeability, rVariables.RelativePermeability, rVariables.IntegrationCoefficient); GeoElementUtilities::AssemblePPBlockMatrix(rLeftHandSideMatrix, permeability_matrix); + + this->CalculateAndAddCompressibilityMatrix(rLeftHandSideMatrix, rVariables); } KRATOS_CATCH("") From 04ce103ff4014d1867d2dc4f042dbb3fbb6ff313 Mon Sep 17 00:00:00 2001 From: Wijtze Pieter Kikstra Date: Thu, 12 Dec 2024 13:25:32 +0100 Subject: [PATCH 21/36] No water solution intended in these tests, made IGNORE_UNDRAINED consistent. --- .../tests/Interface/interface_on_beam/MaterialParameters.json | 4 ++-- .../Interface/weak_interface_on_beam/MaterialParameters.json | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/applications/GeoMechanicsApplication/tests/Interface/interface_on_beam/MaterialParameters.json b/applications/GeoMechanicsApplication/tests/Interface/interface_on_beam/MaterialParameters.json index 7e6612f8d59e..a495c0291ba9 100644 --- a/applications/GeoMechanicsApplication/tests/Interface/interface_on_beam/MaterialParameters.json +++ b/applications/GeoMechanicsApplication/tests/Interface/interface_on_beam/MaterialParameters.json @@ -47,7 +47,7 @@ "name" : "SmallStrainUDSM2DInterfaceLaw" }, "Variables": { - "IGNORE_UNDRAINED" : false, + "IGNORE_UNDRAINED" : true, "DENSITY_SOLID" : 2.0e3, "DENSITY_WATER" : 1.0e3, "POROSITY" : 0.3, @@ -78,7 +78,7 @@ "name" : "SmallStrainUDSM2DInterfaceLaw" }, "Variables": { - "IGNORE_UNDRAINED" : false, + "IGNORE_UNDRAINED" : true, "DENSITY_SOLID" : 2.0e3, "DENSITY_WATER" : 1.0e3, "POROSITY" : 0.3, diff --git a/applications/GeoMechanicsApplication/tests/Interface/weak_interface_on_beam/MaterialParameters.json b/applications/GeoMechanicsApplication/tests/Interface/weak_interface_on_beam/MaterialParameters.json index 1d09e969c7f0..0b7f1e22f148 100644 --- a/applications/GeoMechanicsApplication/tests/Interface/weak_interface_on_beam/MaterialParameters.json +++ b/applications/GeoMechanicsApplication/tests/Interface/weak_interface_on_beam/MaterialParameters.json @@ -47,7 +47,7 @@ "name" : "SmallStrainUDSM2DInterfaceLaw" }, "Variables": { - "IGNORE_UNDRAINED" : false, + "IGNORE_UNDRAINED" : true, "DENSITY_SOLID" : 2.0e3, "DENSITY_WATER" : 1.0e3, "POROSITY" : 0.3, @@ -78,7 +78,7 @@ "name" : "SmallStrainUDSM2DInterfaceLaw" }, "Variables": { - "IGNORE_UNDRAINED" : false, + "IGNORE_UNDRAINED" : true, "DENSITY_SOLID" : 2.0e3, "DENSITY_WATER" : 1.0e3, "POROSITY" : 0.3, From dd719ebee7786221590140fe03eee5e1848cf760 Mon Sep 17 00:00:00 2001 From: mnabideltares Date: Thu, 12 Dec 2024 14:30:21 +0100 Subject: [PATCH 22/36] Added test cases for Pw 2D3N and 2D6N, with documentation --- .../tests/test_GeoMechanicsApplication.py | 4 +- .../tests/test_partial_saturation.py | 103 +++++ .../tests/test_partially_saturated/README.md | 16 + ...w_phreatic_level_pw_triangle6n_results.png | Bin 0 -> 55953 bytes .../MaterialParameters_stage1.json | 34 ++ .../MaterialParameters_stage2.json | 34 ++ .../ProjectParameters_stage1.json | 191 +++++++++ .../ProjectParameters_stage2.json | 173 ++++++++ .../kolom.mdpa | 206 +++++++++ .../MaterialParameters_stage1.json | 34 ++ .../MaterialParameters_stage2.json | 34 ++ .../ProjectParameters_stage1.json | 191 +++++++++ .../ProjectParameters_stage2.json | 173 ++++++++ .../kolom.mdpa | 393 ++++++++++++++++++ 14 files changed, 1585 insertions(+), 1 deletion(-) create mode 100644 applications/GeoMechanicsApplication/tests/test_partial_saturation.py create mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/README.md create mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/documentation_data/test_saturated_below_phreatic_level_pw_triangle6n_results.png create mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/MaterialParameters_stage1.json create mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/MaterialParameters_stage2.json create mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/ProjectParameters_stage1.json create mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/ProjectParameters_stage2.json create mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/kolom.mdpa create mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/MaterialParameters_stage1.json create mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/MaterialParameters_stage2.json create mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/ProjectParameters_stage1.json create mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/ProjectParameters_stage2.json create mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/kolom.mdpa diff --git a/applications/GeoMechanicsApplication/tests/test_GeoMechanicsApplication.py b/applications/GeoMechanicsApplication/tests/test_GeoMechanicsApplication.py index bd80f661a99c..6920cee8d98f 100644 --- a/applications/GeoMechanicsApplication/tests/test_GeoMechanicsApplication.py +++ b/applications/GeoMechanicsApplication/tests/test_GeoMechanicsApplication.py @@ -42,6 +42,7 @@ from test_rotation_with_moving_load import KratosGeoMechanicsRotationWithMovingLoadTests from test_time_integration import KratosGeoMechanicsTimeIntegrationTests from c_phi_reduction_process import KratosGeoMechanicsCPhiReductionProcess +from test_partial_saturation import KratosGeoMechanicsPartialSaturation from test_conditions import KratosGeoMechanicsConditionTests from test_prescribed_derivatives import KratosGeoMechanicsPrescribedDerivatives @@ -124,7 +125,8 @@ def AssembleTestSuites(): KratosGeoMechanicsTransientThermalTests, KratosGeoMechanicsTimeIntegrationTests, KratosGeoMechanicsTransientPressureLineElementTests, - KratosGeoMechanicsTransientPressurePointFluxTests + KratosGeoMechanicsTransientPressurePointFluxTests, + KratosGeoMechanicsPartialSaturation ] night_test_cases.extend(small_test_cases) diff --git a/applications/GeoMechanicsApplication/tests/test_partial_saturation.py b/applications/GeoMechanicsApplication/tests/test_partial_saturation.py new file mode 100644 index 000000000000..69582938cabb --- /dev/null +++ b/applications/GeoMechanicsApplication/tests/test_partial_saturation.py @@ -0,0 +1,103 @@ +# from KratosMultiphysics import * as Kratos + +import sys +import os + +import KratosMultiphysics as Kratos +import KratosMultiphysics.GeoMechanicsApplication as KratosGeo +import KratosMultiphysics.GeoMechanicsApplication.geomechanics_analysis as analysis + +import KratosMultiphysics.KratosUnittest as KratosUnittest + +import test_helper + +class KratosGeoMechanicsPartialSaturation(KratosUnittest.TestCase): + """ + This class contains benchmark tests which are checked with the analytical solution + """ + + def setUp(self): + # Code here will be placed BEFORE every test in this TestCase. + pass + + def tearDown(self): + # Code here will be placed AFTER every test in this TestCase. + pass + + def __test_saturated_below_phreatic_level_pw(self, test_name): + """ + test 1D consolidation on elastic soil. + + :return: + """ + from math import fabs + #from analytical_solutions import calculate_column_saturated_under_phreatic_level + + # define number of stages + n_stages = 2 + + # get the parameter file names for all stages + #test_name = test_name + file_path = test_helper.get_file_path(os.path.join('.', 'test_partially_saturated', test_name)) + parameter_file_names = [os.path.join(file_path, 'ProjectParameters_stage' + str(i + 1) + '.json') for i in + range(n_stages)] + + # set stage parameters + parameters_stages = [None] * n_stages + os.chdir(file_path) + for idx, parameter_file_name in enumerate(parameter_file_names): + with open(parameter_file_name, 'r') as parameter_file: + parameters_stages[idx] = Kratos.Parameters(parameter_file.read()) + + model = Kratos.Model() + stages = [analysis.GeoMechanicsAnalysis(model, stage_parameters) for stage_parameters in parameters_stages] + + # run stages and get water pressure/displacement results per stage + stage_water_pressure = [None] * n_stages + for idx, stage in enumerate(stages): + stage.Run() + stage_water_pressure[idx] = test_helper.get_water_pressure(stage) + + # get y coords of all the nodes + coords = test_helper.get_nodal_coordinates(stages[1]) + y_coords = [coord[1] for coord in coords] + + + + # calculate water pressure analytical solution for all stages and calculate the error + #rmse_stages = [None] * (n_stages - 1) + rel_p_stage = [self.__calculate_column_saturated_under_phreatic_level(y_coord) for y_coord in y_coords] + print(rel_p_stage) + + errors_stage = [stage_water_pressure[1][node_idx] - rel_p for node_idx, rel_p in + enumerate(rel_p_stage)] + rmse_stages = (sum([error ** 2 for error in errors_stage]) / len(errors_stage)) ** 0.5 + + # assert if average error in all stages is below 1 percent + accuracy = 1.0e-7 + self.assertLess(rmse_stages, accuracy) + + + + + def test_saturated_below_phreatic_level_pw_triangle3N(self): + self.__test_saturated_below_phreatic_level_pw('test_saturated_below_phreatic_level_pw_triangle3N') + + def test_saturated_below_phreatic_level_pw_triangle6N(self): + self.__test_saturated_below_phreatic_level_pw('test_saturated_below_phreatic_level_pw_triangle6N') + + + + def __calculate_column_saturated_under_phreatic_level(self, y_coord): + water_density = 1019.367991845056 + gravity = 9.81 + phreatic_level = -2.0 + result = gravity * water_density * (y_coord - phreatic_level) + result = min([result, 0.0]) + return result + return 0.0 + + + +if __name__ == '__main__': + KratosUnittest.main() diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/README.md b/applications/GeoMechanicsApplication/tests/test_partially_saturated/README.md new file mode 100644 index 000000000000..88be89123b95 --- /dev/null +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/README.md @@ -0,0 +1,16 @@ +# Test Cases for partially saturated flow +## Saturated below phreatic level + +**Author:** [Mohamed Nabi](https://github.com/mnabideltares) + +**Source files:** [Partially saturated flow](https://github.com/KratosMultiphysics/Kratos/tree/master/applications/GeoMechanicsApplication/tests/test_partially_saturated) + +## Case Specification +In this test case, a column of 1 x 5 m soil is considered (set between -5 m and 0 m). A phreatic line is set at the level of $y = -2$ m. The water pore pressure is field is then calculated. +The simulation is done on a double stage process and a steady state Pw element is considered. This test is conducted for various configurations, including 2D3N and 2D6N elements. The pressure distribution along the column is then evaluated with its alalytical result. + +## Results + +The picture below illustrates the pressure contours resulting from the simulation (as an example the 2D6N test is shown below). + +Pressure field for case of saturation below phreatic level at stage 2 \ No newline at end of file diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/documentation_data/test_saturated_below_phreatic_level_pw_triangle6n_results.png b/applications/GeoMechanicsApplication/tests/test_partially_saturated/documentation_data/test_saturated_below_phreatic_level_pw_triangle6n_results.png new file mode 100644 index 0000000000000000000000000000000000000000..00bac40d18d9e11b1b8e8341e941c77485f01fb3 GIT binary patch literal 55953 zcmcG%c|4Tu7e7ubQdE*sNo6Nn(ITQ$wrmxWEmR7V6pd{>p~aFtTTwE!A{DZYl6`v~ z3WZU!G>NG(Xl4xGbB~!Zo{!Jx_xk=`zuzCdD))U~%Q@#d*ZaKBxh}U%jvijlx1NuS zi)*>wk%MMjTnmHYPbkk4_({dVR0H^n+tci@4p(;51_JzN(OGRHZ7!}Ck;^6>7Q_E} zFCMY-G~baWNfJpl>$VNvJ(U;8 zcce*rx75n$Fp(ptw@Kf>s+%6llc;x1T2jd-&e?%mFa1caJN?R&W-{5UnY{bsm80J6 zG|gt3NyCSRriPJJ6fOyMHXa6ePD=I3CJGTVO}p-E#l;oa=2+2uj~n`55+caOWxv7o z&l^=PuKk_&1s8B}g$FIy@MexRh3?O?Iv0;=1o0T_}h97O(+f0A5I8bx8t=plh%^K#-7w}_OR$k~+IYd#AsY9E7 z^X;M8PCOOnq6V@X-YuIUxZMRmrYd;h%iF5b@XmETBVEm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Z@Yrvmi83 z0~$+Ho}Ft^^+J5G&5{zn?@x0y`1?Hdq^IT?EWj=V;HiOkZX~L%YP_k{c@dL5cJCe+@A;;b6>4vf!Bgc1(o?|-6R#ARm2b2DW>1Y=3A@+)~?8N!A~62oUYZ%2Q>rnIQB2vEm;@iE0TQFgp-cqWT|150HKrU?9Mm zg8%6W0Y|gUX0`UfMXeyJ0q$qB4Z)E(-9aIPe|cWjr4tB_kQX;G&f==XOut*0*WhRH h&42X95w$(A{QdFks)d7?2dz86%MR^iO|kNg|1SxF4W Date: Thu, 12 Dec 2024 14:34:36 +0100 Subject: [PATCH 23/36] fix for Readme --- .../tests/test_partially_saturated/README.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/README.md b/applications/GeoMechanicsApplication/tests/test_partially_saturated/README.md index 88be89123b95..04b58b7f2eee 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/README.md +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/README.md @@ -6,11 +6,11 @@ **Source files:** [Partially saturated flow](https://github.com/KratosMultiphysics/Kratos/tree/master/applications/GeoMechanicsApplication/tests/test_partially_saturated) ## Case Specification -In this test case, a column of 1 x 5 m soil is considered (set between -5 m and 0 m). A phreatic line is set at the level of $y = -2$ m. The water pore pressure is field is then calculated. -The simulation is done on a double stage process and a steady state Pw element is considered. This test is conducted for various configurations, including 2D3N and 2D6N elements. The pressure distribution along the column is then evaluated with its alalytical result. +In this test case, a column of 1 x 5 m soil is considered (set between -5 m and 0 m). A phreatic line is set at the level of $y = -2$ m. The water pore pressure field is then calculated. +The simulation is done on a double stage process and a steady state Pw element is considered. This test is conducted for various configurations, including 2D3N and 2D6N triangular elements. The pressure distribution along the column is then evaluated with its alalytical result. ## Results The picture below illustrates the pressure contours resulting from the simulation (as an example the 2D6N test is shown below). -Pressure field for case of saturation below phreatic level at stage 2 \ No newline at end of file +Pressure field for case of saturation below phreatic level at stage 2 \ No newline at end of file From 03c1ba779b4a672479dbd582258ac6c090ae3f20 Mon Sep 17 00:00:00 2001 From: mnabideltares Date: Thu, 12 Dec 2024 15:40:38 +0100 Subject: [PATCH 24/36] A test xase for U-Pw diff order 2D6N is added --- .../tests/test_partial_saturation.py | 6 +- .../tests/test_partially_saturated/README.md | 4 +- .../MaterialParameters_stage1.json | 34 ++ .../MaterialParameters_stage2.json | 34 ++ .../ProjectParameters_stage1.json | 204 +++++++++ .../ProjectParameters_stage2.json | 186 +++++++++ .../kolom.mdpa | 393 ++++++++++++++++++ 7 files changed, 856 insertions(+), 5 deletions(-) create mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/MaterialParameters_stage1.json create mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/MaterialParameters_stage2.json create mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/ProjectParameters_stage1.json create mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/ProjectParameters_stage2.json create mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/kolom.mdpa diff --git a/applications/GeoMechanicsApplication/tests/test_partial_saturation.py b/applications/GeoMechanicsApplication/tests/test_partial_saturation.py index 69582938cabb..12b06e44e814 100644 --- a/applications/GeoMechanicsApplication/tests/test_partial_saturation.py +++ b/applications/GeoMechanicsApplication/tests/test_partial_saturation.py @@ -76,9 +76,7 @@ def __test_saturated_below_phreatic_level_pw(self, test_name): # assert if average error in all stages is below 1 percent accuracy = 1.0e-7 self.assertLess(rmse_stages, accuracy) - - - + def test_saturated_below_phreatic_level_pw_triangle3N(self): self.__test_saturated_below_phreatic_level_pw('test_saturated_below_phreatic_level_pw_triangle3N') @@ -86,6 +84,8 @@ def test_saturated_below_phreatic_level_pw_triangle3N(self): def test_saturated_below_phreatic_level_pw_triangle6N(self): self.__test_saturated_below_phreatic_level_pw('test_saturated_below_phreatic_level_pw_triangle6N') + def test_saturated_below_phreatic_level_upw_difforder_triangle6n(self): + self.__test_saturated_below_phreatic_level_pw('test_saturated_below_phreatic_level_upw_difforder_triangle6n') def __calculate_column_saturated_under_phreatic_level(self, y_coord): diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/README.md b/applications/GeoMechanicsApplication/tests/test_partially_saturated/README.md index 04b58b7f2eee..13caa0829ff5 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/README.md +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/README.md @@ -7,10 +7,10 @@ ## Case Specification In this test case, a column of 1 x 5 m soil is considered (set between -5 m and 0 m). A phreatic line is set at the level of $y = -2$ m. The water pore pressure field is then calculated. -The simulation is done on a double stage process and a steady state Pw element is considered. This test is conducted for various configurations, including 2D3N and 2D6N triangular elements. The pressure distribution along the column is then evaluated with its alalytical result. +The simulation is done on a double stage process, and steady state Pw and U-Pw elements are considered. This test is conducted for various configurations, including 2D3N (for Pw) and 2D6N(for Pw and U-Pw) triangular elements. The pressure distribution along the column is then evaluated with its alalytical result. ## Results -The picture below illustrates the pressure contours resulting from the simulation (as an example the 2D6N test is shown below). +The picture below illustrates the pressure contours resulting from the simulation (as an example the 2D6N for Pw is shown below). Pressure field for case of saturation below phreatic level at stage 2 \ No newline at end of file diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/MaterialParameters_stage1.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/MaterialParameters_stage1.json new file mode 100644 index 000000000000..4e17eff51bb2 --- /dev/null +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/MaterialParameters_stage1.json @@ -0,0 +1,34 @@ +{ + "properties": [ + { + "properties_id": 0, + "model_part_name": "PorousDomain.Parts_Solid_Grond", + "Material": { + "constitutive_law": { + "name": "GeoLinearElasticPlaneStrain2DLaw" + }, + "Variables": { + "IGNORE_UNDRAINED": true, + "BIOT_COEFFICIENT": 1.0, + "DENSITY_SOLID": 2038.735983690112, + "DENSITY_WATER": 1019.367991845056, + "POROSITY": 0.3, + "BULK_MODULUS_SOLID": 20000000000.0, + "BULK_MODULUS_FLUID": 2200000000.0, + "PERMEABILITY_XX": 1.157E-05, + "PERMEABILITY_YY": 1.157E-05, + "PERMEABILITY_XY": 0.0, + "DYNAMIC_VISCOSITY": 0.001, + "RETENTION_LAW": "SaturatedBelowPhreaticLevelLaw", + "RESIDUAL_SATURATION": 0.001, + "SATURATED_SATURATION": 1.0, + "MINIMUM_RELATIVE_PERMEABILITY": 0.001, + "K0_MAIN_DIRECTION": 1, + "K0_NC": 0.6, + "YOUNG_MODULUS": 1000000000.0, + "POISSON_RATIO": 0.2 + } + } + } + ] +} diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/MaterialParameters_stage2.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/MaterialParameters_stage2.json new file mode 100644 index 000000000000..0fc3dc1d4f8d --- /dev/null +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/MaterialParameters_stage2.json @@ -0,0 +1,34 @@ +{ + "properties": [ + { + "properties_id": 0, + "model_part_name": "PorousDomain.Parts_Solid_Grond", + "Material": { + "constitutive_law": { + "name": "GeoLinearElasticPlaneStrain2DLaw" + }, + "Variables": { + "IGNORE_UNDRAINED": false, + "BIOT_COEFFICIENT": 1.0, + "DENSITY_SOLID": 2038.735983690112, + "DENSITY_WATER": 1019.367991845056, + "POROSITY": 0.3, + "BULK_MODULUS_SOLID": 20000000000.0, + "BULK_MODULUS_FLUID": 2200000000.0, + "PERMEABILITY_XX": 1.157E-05, + "PERMEABILITY_YY": 1.157E-05, + "PERMEABILITY_XY": 0.0, + "DYNAMIC_VISCOSITY": 0.001, + "RETENTION_LAW": "SaturatedBelowPhreaticLevelLaw", + "RESIDUAL_SATURATION": 0.001, + "SATURATED_SATURATION": 1.0, + "MINIMUM_RELATIVE_PERMEABILITY": 0.001, + "K0_MAIN_DIRECTION": 1, + "K0_NC": 0.6, + "YOUNG_MODULUS": 1000000000.0, + "POISSON_RATIO": 0.2 + } + } + } + ] +} diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/ProjectParameters_stage1.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/ProjectParameters_stage1.json new file mode 100644 index 000000000000..e36bb23f0a2f --- /dev/null +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/ProjectParameters_stage1.json @@ -0,0 +1,204 @@ +{ + "problem_data": { + "problem_name" : "test_saturated_below_phreatic_level_upw_difforder_triangle6n_stage1", + "start_time" : -0.1, + "end_time" : 0.0, + "echo_level" : 1, + "parallel_type" : "OpenMP", + "number_of_threads" : 1 + }, + "solver_settings": { + "solver_type" : "U_Pw", + "model_part_name" : "PorousDomain", + "domain_size" : 2, + "model_import_settings": { + "input_type" : "mdpa", + "input_filename" : "kolom" + }, + "material_import_settings": { + "materials_filename" : "MaterialParameters_stage1.json" + }, + "time_stepping": { + "time_step" : 0.1, + "max_delta_time_factor" : 1.0 + }, + "buffer_size" : 2, + "echo_level" : 1, + "clear_storage" : false, + "compute_reactions" : true, + "reform_dofs_at_each_step" : false, + "nodal_smoothing" : false, + "block_builder" : true, + "solution_type" : "Quasi-Static", + "scheme_type" : "Newmark", + "reset_displacements" : true, + "strategy_type" : "newton_raphson", + "convergence_criterion" : "water_pressure_criterion", + "water_pressure_relative_tolerance": 0.0001, + "water_pressure_absolute_tolerance": 1E-09, + "displacement_relative_tolerance" : 0.001, + "displacement_absolute_tolerance" : 1E-09, + "residual_relative_tolerance" : 0.0001, + "residual_absolute_tolerance" : 1E-09, + "min_iterations" : 6, + "max_iterations" : 30, + "number_cycles" : 1, + "reduction_factor" : 1.0, + "increase_factor" : 1.0, + "desired_iterations" : 4, + "max_radius_factor" : 10.0, + "min_radius_factor" : 0.1, + "calculate_reactions" : true, + "max_line_search_iterations" : 5, + "first_alpha_value" : 0.5, + "second_alpha_value" : 1.0, + "min_alpha" : 0.1, + "max_alpha" : 2.0, + "line_search_tolerance" : 0.5, + "rotation_dofs" : true, + "linear_solver_settings": { + "solver_type" : "LinearSolversApplication.sparse_lu", + "scaling" : true + }, + "problem_domain_sub_model_part_list": ["Parts_Solid_Grond"], + "processes_sub_model_part_list" : ["gravity", "WATER_PRESSURE_Initial", "WATER_PRESSURE_Bottom", "WATER_PRESSURE_Top"], + "body_domain_sub_model_part_list" : ["Parts_Solid_Grond"], + "newmark_beta" : 0.25, + "newmark_gamma" : 0.5, + "newmark_theta" : 0.5, + "rayleigh_m" : 0.0, + "rayleigh_k" : 0.0, + "move_mesh_flag" : false + }, + "output_processes": { + "gid_output": [ + { + "python_module" : "gid_output_process", + "kratos_module" : "KratosMultiphysics", + "process_name" : "GiDOutputProcess", + "Parameters": { + "model_part_name" : "PorousDomain.porous_computational_model_part", + "output_name" : "stage1", + "postprocess_parameters": { + "result_file_configuration": { + "gidpost_flags": { + "WriteDeformedMeshFlag": "WriteUndeformed", + "WriteConditionsFlag" : "WriteElementsOnly", + "GiDPostMode" : "GiD_PostAscii", + "MultiFileFlag" : "SingleFile" + }, + "file_label" : "step", + "output_control_type" : "step", + "output_interval" : 1, + "body_output" : true, + "node_output" : false, + "skin_output" : false, + "plane_output" : [], + "nodal_results" : ["DISPLACEMENT", "TOTAL_DISPLACEMENT", "WATER_PRESSURE", "VOLUME_ACCELERATION", + "LINE_LOAD_Y", "TOTAL_STRESS_TENSOR", "CAUCHY_STRESS_TENSOR"], + "gauss_point_results" : ["GREEN_LAGRANGE_STRAIN_TENSOR", "ENGINEERING_STRAIN_TENSOR", "VON_MISES_STRESS", + "FLUID_FLUX_VECTOR", "HYDRAULIC_HEAD", "DEGREE_OF_SATURATION"] + }, + "point_data_configuration" : [] + } + } + } + ] + }, + "processes": { + "constraints_process_list": [ + { + "python_module" : "apply_scalar_constraint_table_process", + "kratos_module" : "KratosMultiphysics.GeoMechanicsApplication", + "process_name" : "ApplyScalarConstraintTableProcess", + "Parameters": { + "model_part_name" : "PorousDomain.WATER_PRESSURE_Initial", + "variable_name" : "WATER_PRESSURE", + "is_fixed" : false, + "table" : 0, + "fluid_pressure_type" : "Phreatic_Multi_Line", + "gravity_direction" : 1, + "out_of_plane_direction" : 2, + "x_coordinates" : [ 0.0, 1.0], + "y_coordinates" : [-2.0, -2.0], + "z_coordinates" : [ 0.0, 0.0], + "specific_weight" : 10000.0 + } + }, + { + "python_module" : "apply_scalar_constraint_table_process", + "kratos_module" : "KratosMultiphysics.GeoMechanicsApplication", + "process_name" : "ApplyScalarConstraintTableProcess", + "Parameters": { + "model_part_name" : "PorousDomain.WATER_PRESSURE_Bottom", + "variable_name" : "WATER_PRESSURE", + "is_fixed" : true, + "table" : 0, + "fluid_pressure_type" : "Phreatic_Multi_Line", + "gravity_direction" : 1, + "out_of_plane_direction" : 2, + "x_coordinates" : [ 0.0, 1.0], + "y_coordinates" : [-2.0, -2.0], + "z_coordinates" : [ 0.0, 0.0], + "specific_weight" : 10000.0 + } + }, + { + "python_module" : "apply_scalar_constraint_table_process", + "kratos_module" : "KratosMultiphysics.GeoMechanicsApplication", + "process_name" : "ApplyScalarConstraintTableProcess", + "Parameters": { + "model_part_name" : "PorousDomain.WATER_PRESSURE_Top", + "variable_name" : "WATER_PRESSURE", + "is_fixed" : true, + "table" : 0, + "fluid_pressure_type" : "Phreatic_Multi_Line", + "gravity_direction" : 1, + "out_of_plane_direction" : 2, + "x_coordinates" : [ 0.0, 1.0], + "y_coordinates" : [-2.0, -2.0], + "z_coordinates" : [ 0.0, 0.0], + "specific_weight" : 10000.0 + } + }, + { + "python_module" : "apply_vector_constraint_table_process", + "kratos_module" : "KratosMultiphysics.GeoMechanicsApplication", + "process_name" : "ApplyVectorConstraintTableProcess", + "Parameters": { + "model_part_name" : "PorousDomain.gravity", + "variable_name" : "DISPLACEMENT", + "active" : [true, true, true], + "is_fixed" : [true, true, true], + "value" : [0.0, 0.0, 0.0], + "table" : [0, 0, 0] + } + } + ], + "loads_process_list": [ + { + "python_module" : "apply_vector_constraint_table_process", + "kratos_module" : "KratosMultiphysics.GeoMechanicsApplication", + "process_name" : "ApplyVectorConstraintTableProcess", + "Parameters": { + "model_part_name" : "PorousDomain.gravity", + "variable_name" : "VOLUME_ACCELERATION", + "active" : [false, true, false], + "value" : [0.0, -9.81, 0.0], + "table" : [0, 0, 0] + } + } + ], + "auxiliar_process_list": [ + { + "python_module" : "geo_extrapolate_integration_point_values_to_nodes_process", + "kratos_module" : "KratosMultiphysics.GeoMechanicsApplication", + "process_name" : "GeoExtrapolateIntegrationPointValuesToNodesProcess", + "Parameters": { + "model_part_name" : "PorousDomain", + "list_of_variables" : ["TOTAL_STRESS_TENSOR", "CAUCHY_STRESS_TENSOR"] + } + } + ] + } +} diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/ProjectParameters_stage2.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/ProjectParameters_stage2.json new file mode 100644 index 000000000000..6d28f109786c --- /dev/null +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/ProjectParameters_stage2.json @@ -0,0 +1,186 @@ +{ + "problem_data": { + "problem_name" : "test_saturated_below_phreatic_level_upw_difforder_triangle6n_stage2", + "start_time" : 0.0, + "end_time" : 1.0, + "echo_level" : 1, + "parallel_type" : "OpenMP", + "number_of_threads" : 1 + }, + "solver_settings": { + "solver_type" : "U_Pw", + "model_part_name" : "PorousDomain", + "domain_size" : 2, + "model_import_settings": { + "input_type" : "mdpa", + "input_filename" : "kolom_stage2" + }, + "material_import_settings": { + "materials_filename" : "MaterialParameters_stage2.json" + }, + "time_stepping": { + "time_step" : 0.1, + "max_delta_time_factor" : 1.0 + }, + "buffer_size" : 2, + "echo_level" : 1, + "clear_storage" : false, + "compute_reactions" : true, + "reform_dofs_at_each_step" : false, + "nodal_smoothing" : false, + "block_builder" : true, + "solution_type" : "Quasi-Static", + "scheme_type" : "Newmark", + "reset_displacements" : false, + "strategy_type" : "newton_raphson", + "convergence_criterion" : "water_pressure_criterion", + "water_pressure_relative_tolerance": 0.0001, + "water_pressure_absolute_tolerance": 1E-09, + "displacement_relative_tolerance" : 0.0001, + "displacement_absolute_tolerance" : 1E-09, + "residual_relative_tolerance" : 0.0001, + "residual_absolute_tolerance" : 1E-09, + "min_iterations" : 6, + "max_iterations" : 30, + "number_cycles" : 1, + "reduction_factor" : 1.0, + "increase_factor" : 1.0, + "desired_iterations" : 4, + "max_radius_factor" : 10.0, + "min_radius_factor" : 0.1, + "calculate_reactions" : true, + "max_line_search_iterations" : 5, + "first_alpha_value" : 0.5, + "second_alpha_value" : 1.0, + "min_alpha" : 0.1, + "max_alpha" : 2.0, + "line_search_tolerance" : 0.5, + "rotation_dofs" : true, + "linear_solver_settings": { + "solver_type" : "LinearSolversApplication.sparse_lu", + "scaling" : true + }, + "problem_domain_sub_model_part_list": ["Parts_Solid_Grond" ], + "processes_sub_model_part_list" : ["gravity", "WATER_PRESSURE_Bottom", "WATER_PRESSURE_Top"], + "body_domain_sub_model_part_list" : ["Parts_Solid_Grond" ], + "newmark_beta" : 0.25, + "newmark_gamma" : 0.5, + "newmark_theta" : 0.5, + "rayleigh_m" : 0.0, + "rayleigh_k" : 0.0, + "move_mesh_flag" : false + }, + "output_processes": { + "gid_output": [ + { + "python_module" : "gid_output_process", + "kratos_module" : "KratosMultiphysics", + "process_name" : "GiDOutputProcess", + "Parameters": { + "model_part_name" : "PorousDomain.porous_computational_model_part", + "output_name" : "stage2", + "postprocess_parameters": { + "result_file_configuration": { + "gidpost_flags": { + "WriteDeformedMeshFlag": "WriteUndeformed", + "WriteConditionsFlag" : "WriteElementsOnly", + "GiDPostMode" : "GiD_PostAscii", + "MultiFileFlag" : "SingleFile" + }, + "file_label" : "step", + "output_control_type" : "step", + "output_interval" : 1, + "body_output" : true, + "node_output" : false, + "skin_output" : false, + "plane_output" : [], + "nodal_results" : ["DISPLACEMENT", "TOTAL_DISPLACEMENT", "WATER_PRESSURE", "VOLUME_ACCELERATION", + "LINE_LOAD_Y", "TOTAL_STRESS_TENSOR", "CAUCHY_STRESS_TENSOR"], + "gauss_point_results" : ["GREEN_LAGRANGE_STRAIN_TENSOR", "ENGINEERING_STRAIN_TENSOR", "VON_MISES_STRESS", + "FLUID_FLUX_VECTOR", "HYDRAULIC_HEAD", "DEGREE_OF_SATURATION"] + }, + "point_data_configuration" : [] + } + } + } + ] + }, + "processes": { + "constraints_process_list": [ + { + "python_module" : "apply_scalar_constraint_table_process", + "kratos_module" : "KratosMultiphysics.GeoMechanicsApplication", + "process_name" : "ApplyScalarConstraintTableProcess", + "Parameters": { + "model_part_name" : "PorousDomain.WATER_PRESSURE_Bottom", + "variable_name" : "WATER_PRESSURE", + "is_fixed" : true, + "table" : 0, + "fluid_pressure_type" : "Phreatic_Multi_Line", + "gravity_direction" : 1, + "out_of_plane_direction" : 2, + "x_coordinates" : [ 0.0, 1.0], + "y_coordinates" : [-2.0, -2.0], + "z_coordinates" : [ 0.0, 0.0], + "specific_weight" : 10000.0 + } + }, + { + "python_module" : "apply_scalar_constraint_table_process", + "kratos_module" : "KratosMultiphysics.GeoMechanicsApplication", + "process_name" : "ApplyScalarConstraintTableProcess", + "Parameters": { + "model_part_name" : "PorousDomain.WATER_PRESSURE_Top", + "variable_name" : "WATER_PRESSURE", + "is_fixed" : true, + "table" : 0, + "fluid_pressure_type" : "Phreatic_Multi_Line", + "gravity_direction" : 1, + "out_of_plane_direction" : 2, + "x_coordinates" : [ 0.0, 1.0], + "y_coordinates" : [-2.0, -2.0], + "z_coordinates" : [ 0.0, 0.0], + "specific_weight" : 10000.0 + } + }, + { + "python_module" : "apply_vector_constraint_table_process", + "kratos_module" : "KratosMultiphysics.GeoMechanicsApplication", + "process_name" : "ApplyVectorConstraintTableProcess", + "Parameters": { + "model_part_name" : "PorousDomain.gravity", + "variable_name" : "DISPLACEMENT", + "active" : [true, true, true], + "is_fixed" : [true, true, true], + "value" : [0.0, 0.0, 0.0], + "table" : [0, 0, 0] + } + } + ], + "loads_process_list": [ + { + "python_module" : "apply_vector_constraint_table_process", + "kratos_module" : "KratosMultiphysics.GeoMechanicsApplication", + "process_name" : "ApplyVectorConstraintTableProcess", + "Parameters": { + "model_part_name" : "PorousDomain.gravity", + "variable_name" : "VOLUME_ACCELERATION", + "active" : [false, true, false], + "value" : [0.0, -9.81, 0.0], + "table" : [0, 0, 0] + } + } + ], + "auxiliar_process_list": [ + { + "python_module" : "geo_extrapolate_integration_point_values_to_nodes_process", + "kratos_module" : "KratosMultiphysics.GeoMechanicsApplication", + "process_name" : "GeoExtrapolateIntegrationPointValuesToNodesProcess", + "Parameters": { + "model_part_name" : "PorousDomain", + "list_of_variables" : ["TOTAL_STRESS_TENSOR", "CAUCHY_STRESS_TENSOR"] + } + } + ] + } +} diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/kolom.mdpa b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/kolom.mdpa new file mode 100644 index 000000000000..fc3ff8c95ae3 --- /dev/null +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/kolom.mdpa @@ -0,0 +1,393 @@ +Begin ModelPartData +// VARIABLE_NAME value +End ModelPartData + +Begin Properties 0 +End Properties + +Begin Nodes + 1 0.0000000000 -5.0000000000 0.0000000000 + 2 1.0000000000 -5.0000000000 0.0000000000 + 3 0.0000000000 -4.5000000000 0.0000000000 + 4 1.0000000000 -4.5000000000 0.0000000000 + 5 0.0000000000 -4.0000000000 0.0000000000 + 6 1.0000000000 -4.0000000000 0.0000000000 + 7 0.0000000000 -3.5000000000 0.0000000000 + 8 1.0000000000 -3.5000000000 0.0000000000 + 9 0.0000000000 -3.0000000000 0.0000000000 + 10 1.0000000000 -3.0000000000 0.0000000000 + 11 0.0000000000 -2.5000000000 0.0000000000 + 12 1.0000000000 -2.5000000000 0.0000000000 + 13 0.0000000000 -2.0000000000 0.0000000000 + 14 1.0000000000 -2.0000000000 0.0000000000 + 15 0.0000000000 -1.5000000000 0.0000000000 + 16 1.0000000000 -1.5000000000 0.0000000000 + 17 0.0000000000 -1.0000000000 0.0000000000 + 18 1.0000000000 -1.0000000000 0.0000000000 + 19 0.0000000000 -0.5000000000 0.0000000000 + 20 1.0000000000 -0.5000000000 0.0000000000 + 21 0.0000000000 0.0000000000 0.0000000000 + 22 1.0000000000 0.0000000000 0.0000000000 + 23 0.0000000000 -4.7500000000 0.0000000000 + 24 0.0000000000 -4.2500000000 0.0000000000 + 25 0.0000000000 -3.7500000000 0.0000000000 + 26 0.0000000000 -3.2500000000 0.0000000000 + 27 0.0000000000 -2.7500000000 0.0000000000 + 28 0.0000000000 -2.2500000000 0.0000000000 + 29 0.0000000000 -1.7500000000 0.0000000000 + 30 0.0000000000 -1.2500000000 0.0000000000 + 31 0.0000000000 -0.7500000000 0.0000000000 + 32 0.0000000000 -0.2500000000 0.0000000000 + 33 1.0000000000 -4.7500000000 0.0000000000 + 34 1.0000000000 -4.2500000000 0.0000000000 + 35 1.0000000000 -3.7500000000 0.0000000000 + 36 1.0000000000 -3.2500000000 0.0000000000 + 37 1.0000000000 -2.7500000000 0.0000000000 + 38 1.0000000000 -2.2500000000 0.0000000000 + 39 1.0000000000 -1.7500000000 0.0000000000 + 40 1.0000000000 -1.2500000000 0.0000000000 + 41 1.0000000000 -0.7500000000 0.0000000000 + 42 1.0000000000 -0.2500000000 0.0000000000 + 43 0.5000000000 -5.0000000000 0.0000000000 + 44 0.5000000000 -4.7500000000 0.0000000000 + 45 0.5000000000 -4.5000000000 0.0000000000 + 46 0.5000000000 -4.2500000000 0.0000000000 + 47 0.5000000000 -4.0000000000 0.0000000000 + 48 0.5000000000 -3.7500000000 0.0000000000 + 49 0.5000000000 -3.5000000000 0.0000000000 + 50 0.5000000000 -3.2500000000 0.0000000000 + 51 0.5000000000 -3.0000000000 0.0000000000 + 52 0.5000000000 -2.7500000000 0.0000000000 + 53 0.5000000000 -2.5000000000 0.0000000000 + 54 0.5000000000 -2.2500000000 0.0000000000 + 55 0.5000000000 -2.0000000000 0.0000000000 + 56 0.5000000000 -1.7500000000 0.0000000000 + 57 0.5000000000 -1.5000000000 0.0000000000 + 58 0.5000000000 -1.2500000000 0.0000000000 + 59 0.5000000000 -1.0000000000 0.0000000000 + 60 0.5000000000 -0.7500000000 0.0000000000 + 61 0.5000000000 -0.5000000000 0.0000000000 + 62 0.5000000000 -0.2500000000 0.0000000000 + 63 0.5000000000 0.0000000000 0.0000000000 +End Nodes + + +Begin Elements SteadyStatePwElement2D6N // GUI group identifier: Grond + 1 0 1 2 4 43 33 44 + 2 0 4 3 1 45 23 44 + 3 0 3 4 6 45 34 46 + 4 0 6 5 3 47 24 46 + 5 0 5 6 8 47 35 48 + 6 0 8 7 5 49 25 48 + 7 0 7 8 10 49 36 50 + 8 0 10 9 7 51 26 50 + 9 0 9 10 12 51 37 52 + 10 0 12 11 9 53 27 52 + 11 0 11 12 14 53 38 54 + 12 0 14 13 11 55 28 54 + 13 0 13 14 16 55 39 56 + 14 0 16 15 13 57 29 56 + 15 0 15 16 18 57 40 58 + 16 0 18 17 15 59 30 58 + 17 0 17 18 20 59 41 60 + 18 0 20 19 17 61 31 60 + 19 0 19 20 22 61 42 62 + 20 0 22 21 19 63 32 62 +End Elements + +Begin SubModelPart Parts_Solid_Grond // Group Grond // Subtree Parts_Solid + Begin SubModelPartNodes + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + 15 + 16 + 17 + 18 + 19 + 20 + 21 + 22 + 23 + 24 + 25 + 26 + 27 + 28 + 29 + 30 + 31 + 32 + 33 + 34 + 35 + 36 + 37 + 38 + 39 + 40 + 41 + 42 + 43 + 44 + 45 + 46 + 47 + 48 + 49 + 50 + 51 + 52 + 53 + 54 + 55 + 56 + 57 + 58 + 59 + 60 + 61 + 62 + 63 + End SubModelPartNodes + Begin SubModelPartElements + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + 15 + 16 + 17 + 18 + 19 + 20 + End SubModelPartElements +End SubModelPart + +Begin SubModelPart gravity + Begin SubModelPartNodes + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + 15 + 16 + 17 + 18 + 19 + 20 + 21 + 22 + 23 + 24 + 25 + 26 + 27 + 28 + 29 + 30 + 31 + 32 + 33 + 34 + 35 + 36 + 37 + 38 + 39 + 40 + 41 + 42 + 43 + 44 + 45 + 46 + 47 + 48 + 49 + 50 + 51 + 52 + 53 + 54 + 55 + 56 + 57 + 58 + 59 + 60 + 61 + 62 + 63 + End SubModelPartNodes +End SubModelPart + +Begin SubModelPart DISPLACEMENT_Bottom // Group Bottom // Subtree DISPLACEMENT + Begin SubModelPartNodes + 1 + 2 + 43 + End SubModelPartNodes +End SubModelPart + +Begin SubModelPart DISPLACEMENT_Sides // Group Sides // Subtree DISPLACEMENT + Begin SubModelPartNodes + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + 15 + 16 + 17 + 18 + 19 + 20 + 21 + 22 + 23 + 24 + 25 + 26 + 27 + 28 + 29 + 30 + 31 + 32 + 33 + 34 + 35 + 36 + 37 + 38 + 39 + 40 + 41 + 42 + End SubModelPartNodes +End SubModelPart + +Begin SubModelPart WATER_PRESSURE_Initial + Begin SubModelPartNodes + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + 15 + 16 + 17 + 18 + 19 + 20 + 21 + 22 + 23 + 24 + 25 + 26 + 27 + 28 + 29 + 30 + 31 + 32 + 33 + 34 + 35 + 36 + 37 + 38 + 39 + 40 + 41 + 42 + 43 + 44 + 45 + 46 + 47 + 48 + 49 + 50 + 51 + 52 + 53 + 54 + 55 + 56 + 57 + 58 + 59 + 60 + 61 + 62 + 63 + End SubModelPartNodes +End SubModelPart + +Begin SubModelPart WATER_PRESSURE_Top + Begin SubModelPartNodes + 21 + 22 + 63 + End SubModelPartNodes +End SubModelPart + +Begin SubModelPart WATER_PRESSURE_Bottom + Begin SubModelPartNodes + 1 + 2 + 43 + End SubModelPartNodes +End SubModelPart From fb3b09eceb0e86623dac21264ebba244b3c4f5bb Mon Sep 17 00:00:00 2001 From: Wijtze Pieter Kikstra Date: Thu, 12 Dec 2024 15:52:54 +0100 Subject: [PATCH 25/36] fix of revision 60eb250069fc89bd84a03ad2f40f113fcfcc51dc changed results of transient groundwater flow test. New results. --- .../tests/test_transient_groundwater_flow.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/applications/GeoMechanicsApplication/tests/test_transient_groundwater_flow.py b/applications/GeoMechanicsApplication/tests/test_transient_groundwater_flow.py index 8ed90589da34..897b69ea1876 100644 --- a/applications/GeoMechanicsApplication/tests/test_transient_groundwater_flow.py +++ b/applications/GeoMechanicsApplication/tests/test_transient_groundwater_flow.py @@ -26,7 +26,7 @@ def test_Transient_Case_B1_2D3N(self): p_height_1_72_m = water_pressure_stage_2[32] - self.assertAlmostEqual(1.9762325593327588, p_height_1_72_m, 3) + self.assertAlmostEqual(1.8902712667818171, p_height_1_72_m, 3) def test_Transient_Case_A1_2D3N(self): test_name = 'test_Transient_Case_A1_2D3N' @@ -37,7 +37,7 @@ def test_Transient_Case_A1_2D3N(self): p_height_1_72_m = water_pressure_stage_2[32] - self.assertAlmostEqual(3.7224838666844984, p_height_1_72_m) + self.assertAlmostEqual(3.730389835521539, p_height_1_72_m) def test_Transient_Case_A1_2D6N(self): test_name = 'test_Transient_Case_A1_2D6N' @@ -48,7 +48,7 @@ def test_Transient_Case_A1_2D6N(self): p_height_1_72_m = water_pressure[87] - self.assertAlmostEqual(2.6423560731957005, p_height_1_72_m) + self.assertAlmostEqual(2.617220832597392, p_height_1_72_m) if __name__ == '__main__': From eb14f80431b41c8ebf9f123f6769ee0ae7337b63 Mon Sep 17 00:00:00 2001 From: mnabideltares Date: Thu, 12 Dec 2024 15:53:54 +0100 Subject: [PATCH 26/36] 2 tests are added for U-Pw small strain element --- .../tests/test_partial_saturation.py | 6 + .../tests/test_partially_saturated/README.md | 7 +- .../MaterialParameters_stage1.json | 34 ++ .../MaterialParameters_stage2.json | 34 ++ .../ProjectParameters_stage1.json | 204 +++++++++ .../ProjectParameters_stage2.json | 186 +++++++++ .../kolom.mdpa | 206 +++++++++ .../MaterialParameters_stage1.json | 34 ++ .../MaterialParameters_stage2.json | 34 ++ .../ProjectParameters_stage1.json | 204 +++++++++ .../ProjectParameters_stage2.json | 186 +++++++++ .../kolom.mdpa | 393 ++++++++++++++++++ 12 files changed, 1527 insertions(+), 1 deletion(-) create mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/MaterialParameters_stage1.json create mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/MaterialParameters_stage2.json create mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/ProjectParameters_stage1.json create mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/ProjectParameters_stage2.json create mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/kolom.mdpa create mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/MaterialParameters_stage1.json create mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/MaterialParameters_stage2.json create mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/ProjectParameters_stage1.json create mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/ProjectParameters_stage2.json create mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/kolom.mdpa diff --git a/applications/GeoMechanicsApplication/tests/test_partial_saturation.py b/applications/GeoMechanicsApplication/tests/test_partial_saturation.py index 12b06e44e814..f96c08333190 100644 --- a/applications/GeoMechanicsApplication/tests/test_partial_saturation.py +++ b/applications/GeoMechanicsApplication/tests/test_partial_saturation.py @@ -86,6 +86,12 @@ def test_saturated_below_phreatic_level_pw_triangle6N(self): def test_saturated_below_phreatic_level_upw_difforder_triangle6n(self): self.__test_saturated_below_phreatic_level_pw('test_saturated_below_phreatic_level_upw_difforder_triangle6n') + + def test_saturated_below_phreatic_level_upw_smallstrain_triangle3n(self): + self.__test_saturated_below_phreatic_level_pw('test_saturated_below_phreatic_level_upw_smallstrain_triangle3n') + + def test_saturated_below_phreatic_level_upw_smallstrain_triangle6n(self): + self.__test_saturated_below_phreatic_level_pw('test_saturated_below_phreatic_level_upw_smallstrain_triangle6n') def __calculate_column_saturated_under_phreatic_level(self, y_coord): diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/README.md b/applications/GeoMechanicsApplication/tests/test_partially_saturated/README.md index 13caa0829ff5..922c5b84734f 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/README.md +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/README.md @@ -7,7 +7,12 @@ ## Case Specification In this test case, a column of 1 x 5 m soil is considered (set between -5 m and 0 m). A phreatic line is set at the level of $y = -2$ m. The water pore pressure field is then calculated. -The simulation is done on a double stage process, and steady state Pw and U-Pw elements are considered. This test is conducted for various configurations, including 2D3N (for Pw) and 2D6N(for Pw and U-Pw) triangular elements. The pressure distribution along the column is then evaluated with its alalytical result. +The simulation is done on a double stage process, and steady state Pw and U-Pw elements are considered. This test is conducted for various configurations, including + +- 2D3N: for Pw and U-Pw small strain elements +- 2D6N: for Pw and U-Pw small strain and U-Pw different order elements. + +The pressure distribution along the column is then evaluated with its alalytical result. ## Results diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/MaterialParameters_stage1.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/MaterialParameters_stage1.json new file mode 100644 index 000000000000..4e17eff51bb2 --- /dev/null +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/MaterialParameters_stage1.json @@ -0,0 +1,34 @@ +{ + "properties": [ + { + "properties_id": 0, + "model_part_name": "PorousDomain.Parts_Solid_Grond", + "Material": { + "constitutive_law": { + "name": "GeoLinearElasticPlaneStrain2DLaw" + }, + "Variables": { + "IGNORE_UNDRAINED": true, + "BIOT_COEFFICIENT": 1.0, + "DENSITY_SOLID": 2038.735983690112, + "DENSITY_WATER": 1019.367991845056, + "POROSITY": 0.3, + "BULK_MODULUS_SOLID": 20000000000.0, + "BULK_MODULUS_FLUID": 2200000000.0, + "PERMEABILITY_XX": 1.157E-05, + "PERMEABILITY_YY": 1.157E-05, + "PERMEABILITY_XY": 0.0, + "DYNAMIC_VISCOSITY": 0.001, + "RETENTION_LAW": "SaturatedBelowPhreaticLevelLaw", + "RESIDUAL_SATURATION": 0.001, + "SATURATED_SATURATION": 1.0, + "MINIMUM_RELATIVE_PERMEABILITY": 0.001, + "K0_MAIN_DIRECTION": 1, + "K0_NC": 0.6, + "YOUNG_MODULUS": 1000000000.0, + "POISSON_RATIO": 0.2 + } + } + } + ] +} diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/MaterialParameters_stage2.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/MaterialParameters_stage2.json new file mode 100644 index 000000000000..0fc3dc1d4f8d --- /dev/null +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/MaterialParameters_stage2.json @@ -0,0 +1,34 @@ +{ + "properties": [ + { + "properties_id": 0, + "model_part_name": "PorousDomain.Parts_Solid_Grond", + "Material": { + "constitutive_law": { + "name": "GeoLinearElasticPlaneStrain2DLaw" + }, + "Variables": { + "IGNORE_UNDRAINED": false, + "BIOT_COEFFICIENT": 1.0, + "DENSITY_SOLID": 2038.735983690112, + "DENSITY_WATER": 1019.367991845056, + "POROSITY": 0.3, + "BULK_MODULUS_SOLID": 20000000000.0, + "BULK_MODULUS_FLUID": 2200000000.0, + "PERMEABILITY_XX": 1.157E-05, + "PERMEABILITY_YY": 1.157E-05, + "PERMEABILITY_XY": 0.0, + "DYNAMIC_VISCOSITY": 0.001, + "RETENTION_LAW": "SaturatedBelowPhreaticLevelLaw", + "RESIDUAL_SATURATION": 0.001, + "SATURATED_SATURATION": 1.0, + "MINIMUM_RELATIVE_PERMEABILITY": 0.001, + "K0_MAIN_DIRECTION": 1, + "K0_NC": 0.6, + "YOUNG_MODULUS": 1000000000.0, + "POISSON_RATIO": 0.2 + } + } + } + ] +} diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/ProjectParameters_stage1.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/ProjectParameters_stage1.json new file mode 100644 index 000000000000..d586a269d45d --- /dev/null +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/ProjectParameters_stage1.json @@ -0,0 +1,204 @@ +{ + "problem_data": { + "problem_name" : "test_saturated_below_phreatic_level_upw_smallstrain_triangle3n_stage1", + "start_time" : -0.1, + "end_time" : 0.0, + "echo_level" : 1, + "parallel_type" : "OpenMP", + "number_of_threads" : 1 + }, + "solver_settings": { + "solver_type" : "U_Pw", + "model_part_name" : "PorousDomain", + "domain_size" : 2, + "model_import_settings": { + "input_type" : "mdpa", + "input_filename" : "kolom" + }, + "material_import_settings": { + "materials_filename" : "MaterialParameters_stage1.json" + }, + "time_stepping": { + "time_step" : 0.1, + "max_delta_time_factor" : 1.0 + }, + "buffer_size" : 2, + "echo_level" : 1, + "clear_storage" : false, + "compute_reactions" : true, + "reform_dofs_at_each_step" : false, + "nodal_smoothing" : false, + "block_builder" : true, + "solution_type" : "Quasi-Static", + "scheme_type" : "Newmark", + "reset_displacements" : true, + "strategy_type" : "newton_raphson", + "convergence_criterion" : "water_pressure_criterion", + "water_pressure_relative_tolerance": 0.0001, + "water_pressure_absolute_tolerance": 1E-09, + "displacement_relative_tolerance" : 0.001, + "displacement_absolute_tolerance" : 1E-09, + "residual_relative_tolerance" : 0.0001, + "residual_absolute_tolerance" : 1E-09, + "min_iterations" : 6, + "max_iterations" : 30, + "number_cycles" : 1, + "reduction_factor" : 1.0, + "increase_factor" : 1.0, + "desired_iterations" : 4, + "max_radius_factor" : 10.0, + "min_radius_factor" : 0.1, + "calculate_reactions" : true, + "max_line_search_iterations" : 5, + "first_alpha_value" : 0.5, + "second_alpha_value" : 1.0, + "min_alpha" : 0.1, + "max_alpha" : 2.0, + "line_search_tolerance" : 0.5, + "rotation_dofs" : true, + "linear_solver_settings": { + "solver_type" : "LinearSolversApplication.sparse_lu", + "scaling" : true + }, + "problem_domain_sub_model_part_list": ["Parts_Solid_Grond"], + "processes_sub_model_part_list" : ["gravity", "WATER_PRESSURE_Initial", "WATER_PRESSURE_Bottom", "WATER_PRESSURE_Top"], + "body_domain_sub_model_part_list" : ["Parts_Solid_Grond"], + "newmark_beta" : 0.25, + "newmark_gamma" : 0.5, + "newmark_theta" : 0.5, + "rayleigh_m" : 0.0, + "rayleigh_k" : 0.0, + "move_mesh_flag" : false + }, + "output_processes": { + "gid_output": [ + { + "python_module" : "gid_output_process", + "kratos_module" : "KratosMultiphysics", + "process_name" : "GiDOutputProcess", + "Parameters": { + "model_part_name" : "PorousDomain.porous_computational_model_part", + "output_name" : "stage1", + "postprocess_parameters": { + "result_file_configuration": { + "gidpost_flags": { + "WriteDeformedMeshFlag": "WriteUndeformed", + "WriteConditionsFlag" : "WriteElementsOnly", + "GiDPostMode" : "GiD_PostAscii", + "MultiFileFlag" : "SingleFile" + }, + "file_label" : "step", + "output_control_type" : "step", + "output_interval" : 1, + "body_output" : true, + "node_output" : false, + "skin_output" : false, + "plane_output" : [], + "nodal_results" : ["DISPLACEMENT", "TOTAL_DISPLACEMENT", "WATER_PRESSURE", "VOLUME_ACCELERATION", + "LINE_LOAD_Y", "TOTAL_STRESS_TENSOR", "CAUCHY_STRESS_TENSOR"], + "gauss_point_results" : ["GREEN_LAGRANGE_STRAIN_TENSOR", "ENGINEERING_STRAIN_TENSOR", "VON_MISES_STRESS", + "FLUID_FLUX_VECTOR", "HYDRAULIC_HEAD", "DEGREE_OF_SATURATION"] + }, + "point_data_configuration" : [] + } + } + } + ] + }, + "processes": { + "constraints_process_list": [ + { + "python_module" : "apply_scalar_constraint_table_process", + "kratos_module" : "KratosMultiphysics.GeoMechanicsApplication", + "process_name" : "ApplyScalarConstraintTableProcess", + "Parameters": { + "model_part_name" : "PorousDomain.WATER_PRESSURE_Initial", + "variable_name" : "WATER_PRESSURE", + "is_fixed" : false, + "table" : 0, + "fluid_pressure_type" : "Phreatic_Multi_Line", + "gravity_direction" : 1, + "out_of_plane_direction" : 2, + "x_coordinates" : [ 0.0, 1.0], + "y_coordinates" : [-2.0, -2.0], + "z_coordinates" : [ 0.0, 0.0], + "specific_weight" : 10000.0 + } + }, + { + "python_module" : "apply_scalar_constraint_table_process", + "kratos_module" : "KratosMultiphysics.GeoMechanicsApplication", + "process_name" : "ApplyScalarConstraintTableProcess", + "Parameters": { + "model_part_name" : "PorousDomain.WATER_PRESSURE_Bottom", + "variable_name" : "WATER_PRESSURE", + "is_fixed" : true, + "table" : 0, + "fluid_pressure_type" : "Phreatic_Multi_Line", + "gravity_direction" : 1, + "out_of_plane_direction" : 2, + "x_coordinates" : [ 0.0, 1.0], + "y_coordinates" : [-2.0, -2.0], + "z_coordinates" : [ 0.0, 0.0], + "specific_weight" : 10000.0 + } + }, + { + "python_module" : "apply_scalar_constraint_table_process", + "kratos_module" : "KratosMultiphysics.GeoMechanicsApplication", + "process_name" : "ApplyScalarConstraintTableProcess", + "Parameters": { + "model_part_name" : "PorousDomain.WATER_PRESSURE_Top", + "variable_name" : "WATER_PRESSURE", + "is_fixed" : true, + "table" : 0, + "fluid_pressure_type" : "Phreatic_Multi_Line", + "gravity_direction" : 1, + "out_of_plane_direction" : 2, + "x_coordinates" : [ 0.0, 1.0], + "y_coordinates" : [-2.0, -2.0], + "z_coordinates" : [ 0.0, 0.0], + "specific_weight" : 10000.0 + } + }, + { + "python_module" : "apply_vector_constraint_table_process", + "kratos_module" : "KratosMultiphysics.GeoMechanicsApplication", + "process_name" : "ApplyVectorConstraintTableProcess", + "Parameters": { + "model_part_name" : "PorousDomain.gravity", + "variable_name" : "DISPLACEMENT", + "active" : [true, true, true], + "is_fixed" : [true, true, true], + "value" : [0.0, 0.0, 0.0], + "table" : [0, 0, 0] + } + } + ], + "loads_process_list": [ + { + "python_module" : "apply_vector_constraint_table_process", + "kratos_module" : "KratosMultiphysics.GeoMechanicsApplication", + "process_name" : "ApplyVectorConstraintTableProcess", + "Parameters": { + "model_part_name" : "PorousDomain.gravity", + "variable_name" : "VOLUME_ACCELERATION", + "active" : [false, true, false], + "value" : [0.0, -9.81, 0.0], + "table" : [0, 0, 0] + } + } + ], + "auxiliar_process_list": [ + { + "python_module" : "geo_extrapolate_integration_point_values_to_nodes_process", + "kratos_module" : "KratosMultiphysics.GeoMechanicsApplication", + "process_name" : "GeoExtrapolateIntegrationPointValuesToNodesProcess", + "Parameters": { + "model_part_name" : "PorousDomain", + "list_of_variables" : ["TOTAL_STRESS_TENSOR", "CAUCHY_STRESS_TENSOR"] + } + } + ] + } +} diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/ProjectParameters_stage2.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/ProjectParameters_stage2.json new file mode 100644 index 000000000000..7ad300dacb06 --- /dev/null +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/ProjectParameters_stage2.json @@ -0,0 +1,186 @@ +{ + "problem_data": { + "problem_name" : "test_saturated_below_phreatic_level_upw_smallstrain_triangle3n_stage2", + "start_time" : 0.0, + "end_time" : 1.0, + "echo_level" : 1, + "parallel_type" : "OpenMP", + "number_of_threads" : 1 + }, + "solver_settings": { + "solver_type" : "U_Pw", + "model_part_name" : "PorousDomain", + "domain_size" : 2, + "model_import_settings": { + "input_type" : "mdpa", + "input_filename" : "kolom_stage2" + }, + "material_import_settings": { + "materials_filename" : "MaterialParameters_stage2.json" + }, + "time_stepping": { + "time_step" : 0.1, + "max_delta_time_factor" : 1.0 + }, + "buffer_size" : 2, + "echo_level" : 1, + "clear_storage" : false, + "compute_reactions" : true, + "reform_dofs_at_each_step" : false, + "nodal_smoothing" : false, + "block_builder" : true, + "solution_type" : "Quasi-Static", + "scheme_type" : "Newmark", + "reset_displacements" : false, + "strategy_type" : "newton_raphson", + "convergence_criterion" : "water_pressure_criterion", + "water_pressure_relative_tolerance": 0.0001, + "water_pressure_absolute_tolerance": 1E-09, + "displacement_relative_tolerance" : 0.0001, + "displacement_absolute_tolerance" : 1E-09, + "residual_relative_tolerance" : 0.0001, + "residual_absolute_tolerance" : 1E-09, + "min_iterations" : 6, + "max_iterations" : 30, + "number_cycles" : 1, + "reduction_factor" : 1.0, + "increase_factor" : 1.0, + "desired_iterations" : 4, + "max_radius_factor" : 10.0, + "min_radius_factor" : 0.1, + "calculate_reactions" : true, + "max_line_search_iterations" : 5, + "first_alpha_value" : 0.5, + "second_alpha_value" : 1.0, + "min_alpha" : 0.1, + "max_alpha" : 2.0, + "line_search_tolerance" : 0.5, + "rotation_dofs" : true, + "linear_solver_settings": { + "solver_type" : "LinearSolversApplication.sparse_lu", + "scaling" : true + }, + "problem_domain_sub_model_part_list": ["Parts_Solid_Grond" ], + "processes_sub_model_part_list" : ["gravity", "WATER_PRESSURE_Bottom", "WATER_PRESSURE_Top"], + "body_domain_sub_model_part_list" : ["Parts_Solid_Grond" ], + "newmark_beta" : 0.25, + "newmark_gamma" : 0.5, + "newmark_theta" : 0.5, + "rayleigh_m" : 0.0, + "rayleigh_k" : 0.0, + "move_mesh_flag" : false + }, + "output_processes": { + "gid_output": [ + { + "python_module" : "gid_output_process", + "kratos_module" : "KratosMultiphysics", + "process_name" : "GiDOutputProcess", + "Parameters": { + "model_part_name" : "PorousDomain.porous_computational_model_part", + "output_name" : "stage2", + "postprocess_parameters": { + "result_file_configuration": { + "gidpost_flags": { + "WriteDeformedMeshFlag": "WriteUndeformed", + "WriteConditionsFlag" : "WriteElementsOnly", + "GiDPostMode" : "GiD_PostAscii", + "MultiFileFlag" : "SingleFile" + }, + "file_label" : "step", + "output_control_type" : "step", + "output_interval" : 1, + "body_output" : true, + "node_output" : false, + "skin_output" : false, + "plane_output" : [], + "nodal_results" : ["DISPLACEMENT", "TOTAL_DISPLACEMENT", "WATER_PRESSURE", "VOLUME_ACCELERATION", + "LINE_LOAD_Y", "TOTAL_STRESS_TENSOR", "CAUCHY_STRESS_TENSOR"], + "gauss_point_results" : ["GREEN_LAGRANGE_STRAIN_TENSOR", "ENGINEERING_STRAIN_TENSOR", "VON_MISES_STRESS", + "FLUID_FLUX_VECTOR", "HYDRAULIC_HEAD", "DEGREE_OF_SATURATION"] + }, + "point_data_configuration" : [] + } + } + } + ] + }, + "processes": { + "constraints_process_list": [ + { + "python_module" : "apply_scalar_constraint_table_process", + "kratos_module" : "KratosMultiphysics.GeoMechanicsApplication", + "process_name" : "ApplyScalarConstraintTableProcess", + "Parameters": { + "model_part_name" : "PorousDomain.WATER_PRESSURE_Bottom", + "variable_name" : "WATER_PRESSURE", + "is_fixed" : true, + "table" : 0, + "fluid_pressure_type" : "Phreatic_Multi_Line", + "gravity_direction" : 1, + "out_of_plane_direction" : 2, + "x_coordinates" : [ 0.0, 1.0], + "y_coordinates" : [-2.0, -2.0], + "z_coordinates" : [ 0.0, 0.0], + "specific_weight" : 10000.0 + } + }, + { + "python_module" : "apply_scalar_constraint_table_process", + "kratos_module" : "KratosMultiphysics.GeoMechanicsApplication", + "process_name" : "ApplyScalarConstraintTableProcess", + "Parameters": { + "model_part_name" : "PorousDomain.WATER_PRESSURE_Top", + "variable_name" : "WATER_PRESSURE", + "is_fixed" : true, + "table" : 0, + "fluid_pressure_type" : "Phreatic_Multi_Line", + "gravity_direction" : 1, + "out_of_plane_direction" : 2, + "x_coordinates" : [ 0.0, 1.0], + "y_coordinates" : [-2.0, -2.0], + "z_coordinates" : [ 0.0, 0.0], + "specific_weight" : 10000.0 + } + }, + { + "python_module" : "apply_vector_constraint_table_process", + "kratos_module" : "KratosMultiphysics.GeoMechanicsApplication", + "process_name" : "ApplyVectorConstraintTableProcess", + "Parameters": { + "model_part_name" : "PorousDomain.gravity", + "variable_name" : "DISPLACEMENT", + "active" : [true, true, true], + "is_fixed" : [true, true, true], + "value" : [0.0, 0.0, 0.0], + "table" : [0, 0, 0] + } + } + ], + "loads_process_list": [ + { + "python_module" : "apply_vector_constraint_table_process", + "kratos_module" : "KratosMultiphysics.GeoMechanicsApplication", + "process_name" : "ApplyVectorConstraintTableProcess", + "Parameters": { + "model_part_name" : "PorousDomain.gravity", + "variable_name" : "VOLUME_ACCELERATION", + "active" : [false, true, false], + "value" : [0.0, -9.81, 0.0], + "table" : [0, 0, 0] + } + } + ], + "auxiliar_process_list": [ + { + "python_module" : "geo_extrapolate_integration_point_values_to_nodes_process", + "kratos_module" : "KratosMultiphysics.GeoMechanicsApplication", + "process_name" : "GeoExtrapolateIntegrationPointValuesToNodesProcess", + "Parameters": { + "model_part_name" : "PorousDomain", + "list_of_variables" : ["TOTAL_STRESS_TENSOR", "CAUCHY_STRESS_TENSOR"] + } + } + ] + } +} diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/kolom.mdpa b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/kolom.mdpa new file mode 100644 index 000000000000..f6e16007f1df --- /dev/null +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/kolom.mdpa @@ -0,0 +1,206 @@ +Begin ModelPartData +// VARIABLE_NAME value +End ModelPartData + +Begin Properties 0 +End Properties + +Begin Nodes + 1 0.0000000000 -5.0000000000 0.0000000000 + 2 1.0000000000 -5.0000000000 0.0000000000 + 3 0.0000000000 -4.5000000000 0.0000000000 + 4 1.0000000000 -4.5000000000 0.0000000000 + 5 0.0000000000 -4.0000000000 0.0000000000 + 6 1.0000000000 -4.0000000000 0.0000000000 + 7 0.0000000000 -3.5000000000 0.0000000000 + 8 1.0000000000 -3.5000000000 0.0000000000 + 9 0.0000000000 -3.0000000000 0.0000000000 + 10 1.0000000000 -3.0000000000 0.0000000000 + 11 0.0000000000 -2.5000000000 0.0000000000 + 12 1.0000000000 -2.5000000000 0.0000000000 + 13 0.0000000000 -2.0000000000 0.0000000000 + 14 1.0000000000 -2.0000000000 0.0000000000 + 15 0.0000000000 -1.5000000000 0.0000000000 + 16 1.0000000000 -1.5000000000 0.0000000000 + 17 0.0000000000 -1.0000000000 0.0000000000 + 18 1.0000000000 -1.0000000000 0.0000000000 + 19 0.0000000000 -0.5000000000 0.0000000000 + 20 1.0000000000 -0.5000000000 0.0000000000 + 21 0.0000000000 0.0000000000 0.0000000000 + 22 1.0000000000 0.0000000000 0.0000000000 +End Nodes + + +Begin Elements UPwSmallStrainElement2D3N // GUI group identifier: Grond + 1 0 1 2 4 + 2 0 4 3 1 + 3 0 3 4 6 + 4 0 6 5 3 + 5 0 5 6 8 + 6 0 8 7 5 + 7 0 7 8 10 + 8 0 10 9 7 + 9 0 9 10 12 + 10 0 12 11 9 + 11 0 11 12 14 + 12 0 14 13 11 + 13 0 13 14 16 + 14 0 16 15 13 + 15 0 15 16 18 + 16 0 18 17 15 + 17 0 17 18 20 + 18 0 20 19 17 + 19 0 19 20 22 + 20 0 22 21 19 +End Elements + +Begin SubModelPart Parts_Solid_Grond // Group Grond // Subtree Parts_Solid + Begin SubModelPartNodes + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + 15 + 16 + 17 + 18 + 19 + 20 + 21 + 22 + End SubModelPartNodes + Begin SubModelPartElements + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + 15 + 16 + 17 + 18 + 19 + 20 + End SubModelPartElements +End SubModelPart + +Begin SubModelPart gravity + Begin SubModelPartNodes + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + 15 + 16 + 17 + 18 + 19 + 20 + 21 + 22 + End SubModelPartNodes +End SubModelPart + +Begin SubModelPart DISPLACEMENT_Bottom // Group Bottom // Subtree DISPLACEMENT + Begin SubModelPartNodes + 1 + 2 + End SubModelPartNodes +End SubModelPart + +Begin SubModelPart DISPLACEMENT_Sides // Group Sides // Subtree DISPLACEMENT + Begin SubModelPartNodes + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + 15 + 16 + 17 + 18 + 19 + 20 + 21 + 22 + End SubModelPartNodes +End SubModelPart + +Begin SubModelPart WATER_PRESSURE_Initial + Begin SubModelPartNodes + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + 15 + 16 + 17 + 18 + 19 + 20 + 21 + 22 + End SubModelPartNodes +End SubModelPart + +Begin SubModelPart WATER_PRESSURE_Top + Begin SubModelPartNodes + 21 + 22 + End SubModelPartNodes +End SubModelPart + +Begin SubModelPart WATER_PRESSURE_Bottom + Begin SubModelPartNodes + 1 + 2 + End SubModelPartNodes +End SubModelPart diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/MaterialParameters_stage1.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/MaterialParameters_stage1.json new file mode 100644 index 000000000000..4e17eff51bb2 --- /dev/null +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/MaterialParameters_stage1.json @@ -0,0 +1,34 @@ +{ + "properties": [ + { + "properties_id": 0, + "model_part_name": "PorousDomain.Parts_Solid_Grond", + "Material": { + "constitutive_law": { + "name": "GeoLinearElasticPlaneStrain2DLaw" + }, + "Variables": { + "IGNORE_UNDRAINED": true, + "BIOT_COEFFICIENT": 1.0, + "DENSITY_SOLID": 2038.735983690112, + "DENSITY_WATER": 1019.367991845056, + "POROSITY": 0.3, + "BULK_MODULUS_SOLID": 20000000000.0, + "BULK_MODULUS_FLUID": 2200000000.0, + "PERMEABILITY_XX": 1.157E-05, + "PERMEABILITY_YY": 1.157E-05, + "PERMEABILITY_XY": 0.0, + "DYNAMIC_VISCOSITY": 0.001, + "RETENTION_LAW": "SaturatedBelowPhreaticLevelLaw", + "RESIDUAL_SATURATION": 0.001, + "SATURATED_SATURATION": 1.0, + "MINIMUM_RELATIVE_PERMEABILITY": 0.001, + "K0_MAIN_DIRECTION": 1, + "K0_NC": 0.6, + "YOUNG_MODULUS": 1000000000.0, + "POISSON_RATIO": 0.2 + } + } + } + ] +} diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/MaterialParameters_stage2.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/MaterialParameters_stage2.json new file mode 100644 index 000000000000..0fc3dc1d4f8d --- /dev/null +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/MaterialParameters_stage2.json @@ -0,0 +1,34 @@ +{ + "properties": [ + { + "properties_id": 0, + "model_part_name": "PorousDomain.Parts_Solid_Grond", + "Material": { + "constitutive_law": { + "name": "GeoLinearElasticPlaneStrain2DLaw" + }, + "Variables": { + "IGNORE_UNDRAINED": false, + "BIOT_COEFFICIENT": 1.0, + "DENSITY_SOLID": 2038.735983690112, + "DENSITY_WATER": 1019.367991845056, + "POROSITY": 0.3, + "BULK_MODULUS_SOLID": 20000000000.0, + "BULK_MODULUS_FLUID": 2200000000.0, + "PERMEABILITY_XX": 1.157E-05, + "PERMEABILITY_YY": 1.157E-05, + "PERMEABILITY_XY": 0.0, + "DYNAMIC_VISCOSITY": 0.001, + "RETENTION_LAW": "SaturatedBelowPhreaticLevelLaw", + "RESIDUAL_SATURATION": 0.001, + "SATURATED_SATURATION": 1.0, + "MINIMUM_RELATIVE_PERMEABILITY": 0.001, + "K0_MAIN_DIRECTION": 1, + "K0_NC": 0.6, + "YOUNG_MODULUS": 1000000000.0, + "POISSON_RATIO": 0.2 + } + } + } + ] +} diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/ProjectParameters_stage1.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/ProjectParameters_stage1.json new file mode 100644 index 000000000000..d586a269d45d --- /dev/null +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/ProjectParameters_stage1.json @@ -0,0 +1,204 @@ +{ + "problem_data": { + "problem_name" : "test_saturated_below_phreatic_level_upw_smallstrain_triangle3n_stage1", + "start_time" : -0.1, + "end_time" : 0.0, + "echo_level" : 1, + "parallel_type" : "OpenMP", + "number_of_threads" : 1 + }, + "solver_settings": { + "solver_type" : "U_Pw", + "model_part_name" : "PorousDomain", + "domain_size" : 2, + "model_import_settings": { + "input_type" : "mdpa", + "input_filename" : "kolom" + }, + "material_import_settings": { + "materials_filename" : "MaterialParameters_stage1.json" + }, + "time_stepping": { + "time_step" : 0.1, + "max_delta_time_factor" : 1.0 + }, + "buffer_size" : 2, + "echo_level" : 1, + "clear_storage" : false, + "compute_reactions" : true, + "reform_dofs_at_each_step" : false, + "nodal_smoothing" : false, + "block_builder" : true, + "solution_type" : "Quasi-Static", + "scheme_type" : "Newmark", + "reset_displacements" : true, + "strategy_type" : "newton_raphson", + "convergence_criterion" : "water_pressure_criterion", + "water_pressure_relative_tolerance": 0.0001, + "water_pressure_absolute_tolerance": 1E-09, + "displacement_relative_tolerance" : 0.001, + "displacement_absolute_tolerance" : 1E-09, + "residual_relative_tolerance" : 0.0001, + "residual_absolute_tolerance" : 1E-09, + "min_iterations" : 6, + "max_iterations" : 30, + "number_cycles" : 1, + "reduction_factor" : 1.0, + "increase_factor" : 1.0, + "desired_iterations" : 4, + "max_radius_factor" : 10.0, + "min_radius_factor" : 0.1, + "calculate_reactions" : true, + "max_line_search_iterations" : 5, + "first_alpha_value" : 0.5, + "second_alpha_value" : 1.0, + "min_alpha" : 0.1, + "max_alpha" : 2.0, + "line_search_tolerance" : 0.5, + "rotation_dofs" : true, + "linear_solver_settings": { + "solver_type" : "LinearSolversApplication.sparse_lu", + "scaling" : true + }, + "problem_domain_sub_model_part_list": ["Parts_Solid_Grond"], + "processes_sub_model_part_list" : ["gravity", "WATER_PRESSURE_Initial", "WATER_PRESSURE_Bottom", "WATER_PRESSURE_Top"], + "body_domain_sub_model_part_list" : ["Parts_Solid_Grond"], + "newmark_beta" : 0.25, + "newmark_gamma" : 0.5, + "newmark_theta" : 0.5, + "rayleigh_m" : 0.0, + "rayleigh_k" : 0.0, + "move_mesh_flag" : false + }, + "output_processes": { + "gid_output": [ + { + "python_module" : "gid_output_process", + "kratos_module" : "KratosMultiphysics", + "process_name" : "GiDOutputProcess", + "Parameters": { + "model_part_name" : "PorousDomain.porous_computational_model_part", + "output_name" : "stage1", + "postprocess_parameters": { + "result_file_configuration": { + "gidpost_flags": { + "WriteDeformedMeshFlag": "WriteUndeformed", + "WriteConditionsFlag" : "WriteElementsOnly", + "GiDPostMode" : "GiD_PostAscii", + "MultiFileFlag" : "SingleFile" + }, + "file_label" : "step", + "output_control_type" : "step", + "output_interval" : 1, + "body_output" : true, + "node_output" : false, + "skin_output" : false, + "plane_output" : [], + "nodal_results" : ["DISPLACEMENT", "TOTAL_DISPLACEMENT", "WATER_PRESSURE", "VOLUME_ACCELERATION", + "LINE_LOAD_Y", "TOTAL_STRESS_TENSOR", "CAUCHY_STRESS_TENSOR"], + "gauss_point_results" : ["GREEN_LAGRANGE_STRAIN_TENSOR", "ENGINEERING_STRAIN_TENSOR", "VON_MISES_STRESS", + "FLUID_FLUX_VECTOR", "HYDRAULIC_HEAD", "DEGREE_OF_SATURATION"] + }, + "point_data_configuration" : [] + } + } + } + ] + }, + "processes": { + "constraints_process_list": [ + { + "python_module" : "apply_scalar_constraint_table_process", + "kratos_module" : "KratosMultiphysics.GeoMechanicsApplication", + "process_name" : "ApplyScalarConstraintTableProcess", + "Parameters": { + "model_part_name" : "PorousDomain.WATER_PRESSURE_Initial", + "variable_name" : "WATER_PRESSURE", + "is_fixed" : false, + "table" : 0, + "fluid_pressure_type" : "Phreatic_Multi_Line", + "gravity_direction" : 1, + "out_of_plane_direction" : 2, + "x_coordinates" : [ 0.0, 1.0], + "y_coordinates" : [-2.0, -2.0], + "z_coordinates" : [ 0.0, 0.0], + "specific_weight" : 10000.0 + } + }, + { + "python_module" : "apply_scalar_constraint_table_process", + "kratos_module" : "KratosMultiphysics.GeoMechanicsApplication", + "process_name" : "ApplyScalarConstraintTableProcess", + "Parameters": { + "model_part_name" : "PorousDomain.WATER_PRESSURE_Bottom", + "variable_name" : "WATER_PRESSURE", + "is_fixed" : true, + "table" : 0, + "fluid_pressure_type" : "Phreatic_Multi_Line", + "gravity_direction" : 1, + "out_of_plane_direction" : 2, + "x_coordinates" : [ 0.0, 1.0], + "y_coordinates" : [-2.0, -2.0], + "z_coordinates" : [ 0.0, 0.0], + "specific_weight" : 10000.0 + } + }, + { + "python_module" : "apply_scalar_constraint_table_process", + "kratos_module" : "KratosMultiphysics.GeoMechanicsApplication", + "process_name" : "ApplyScalarConstraintTableProcess", + "Parameters": { + "model_part_name" : "PorousDomain.WATER_PRESSURE_Top", + "variable_name" : "WATER_PRESSURE", + "is_fixed" : true, + "table" : 0, + "fluid_pressure_type" : "Phreatic_Multi_Line", + "gravity_direction" : 1, + "out_of_plane_direction" : 2, + "x_coordinates" : [ 0.0, 1.0], + "y_coordinates" : [-2.0, -2.0], + "z_coordinates" : [ 0.0, 0.0], + "specific_weight" : 10000.0 + } + }, + { + "python_module" : "apply_vector_constraint_table_process", + "kratos_module" : "KratosMultiphysics.GeoMechanicsApplication", + "process_name" : "ApplyVectorConstraintTableProcess", + "Parameters": { + "model_part_name" : "PorousDomain.gravity", + "variable_name" : "DISPLACEMENT", + "active" : [true, true, true], + "is_fixed" : [true, true, true], + "value" : [0.0, 0.0, 0.0], + "table" : [0, 0, 0] + } + } + ], + "loads_process_list": [ + { + "python_module" : "apply_vector_constraint_table_process", + "kratos_module" : "KratosMultiphysics.GeoMechanicsApplication", + "process_name" : "ApplyVectorConstraintTableProcess", + "Parameters": { + "model_part_name" : "PorousDomain.gravity", + "variable_name" : "VOLUME_ACCELERATION", + "active" : [false, true, false], + "value" : [0.0, -9.81, 0.0], + "table" : [0, 0, 0] + } + } + ], + "auxiliar_process_list": [ + { + "python_module" : "geo_extrapolate_integration_point_values_to_nodes_process", + "kratos_module" : "KratosMultiphysics.GeoMechanicsApplication", + "process_name" : "GeoExtrapolateIntegrationPointValuesToNodesProcess", + "Parameters": { + "model_part_name" : "PorousDomain", + "list_of_variables" : ["TOTAL_STRESS_TENSOR", "CAUCHY_STRESS_TENSOR"] + } + } + ] + } +} diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/ProjectParameters_stage2.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/ProjectParameters_stage2.json new file mode 100644 index 000000000000..9e3f992eacb8 --- /dev/null +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/ProjectParameters_stage2.json @@ -0,0 +1,186 @@ +{ + "problem_data": { + "problem_name" : "test_saturated_below_phreatic_level_upw_smallstrain_triangle6n_stage2", + "start_time" : 0.0, + "end_time" : 1.0, + "echo_level" : 1, + "parallel_type" : "OpenMP", + "number_of_threads" : 1 + }, + "solver_settings": { + "solver_type" : "U_Pw", + "model_part_name" : "PorousDomain", + "domain_size" : 2, + "model_import_settings": { + "input_type" : "mdpa", + "input_filename" : "kolom_stage2" + }, + "material_import_settings": { + "materials_filename" : "MaterialParameters_stage2.json" + }, + "time_stepping": { + "time_step" : 0.1, + "max_delta_time_factor" : 1.0 + }, + "buffer_size" : 2, + "echo_level" : 1, + "clear_storage" : false, + "compute_reactions" : true, + "reform_dofs_at_each_step" : false, + "nodal_smoothing" : false, + "block_builder" : true, + "solution_type" : "Quasi-Static", + "scheme_type" : "Newmark", + "reset_displacements" : false, + "strategy_type" : "newton_raphson", + "convergence_criterion" : "water_pressure_criterion", + "water_pressure_relative_tolerance": 0.0001, + "water_pressure_absolute_tolerance": 1E-09, + "displacement_relative_tolerance" : 0.0001, + "displacement_absolute_tolerance" : 1E-09, + "residual_relative_tolerance" : 0.0001, + "residual_absolute_tolerance" : 1E-09, + "min_iterations" : 6, + "max_iterations" : 30, + "number_cycles" : 1, + "reduction_factor" : 1.0, + "increase_factor" : 1.0, + "desired_iterations" : 4, + "max_radius_factor" : 10.0, + "min_radius_factor" : 0.1, + "calculate_reactions" : true, + "max_line_search_iterations" : 5, + "first_alpha_value" : 0.5, + "second_alpha_value" : 1.0, + "min_alpha" : 0.1, + "max_alpha" : 2.0, + "line_search_tolerance" : 0.5, + "rotation_dofs" : true, + "linear_solver_settings": { + "solver_type" : "LinearSolversApplication.sparse_lu", + "scaling" : true + }, + "problem_domain_sub_model_part_list": ["Parts_Solid_Grond" ], + "processes_sub_model_part_list" : ["gravity", "WATER_PRESSURE_Bottom", "WATER_PRESSURE_Top"], + "body_domain_sub_model_part_list" : ["Parts_Solid_Grond" ], + "newmark_beta" : 0.25, + "newmark_gamma" : 0.5, + "newmark_theta" : 0.5, + "rayleigh_m" : 0.0, + "rayleigh_k" : 0.0, + "move_mesh_flag" : false + }, + "output_processes": { + "gid_output": [ + { + "python_module" : "gid_output_process", + "kratos_module" : "KratosMultiphysics", + "process_name" : "GiDOutputProcess", + "Parameters": { + "model_part_name" : "PorousDomain.porous_computational_model_part", + "output_name" : "stage2", + "postprocess_parameters": { + "result_file_configuration": { + "gidpost_flags": { + "WriteDeformedMeshFlag": "WriteUndeformed", + "WriteConditionsFlag" : "WriteElementsOnly", + "GiDPostMode" : "GiD_PostAscii", + "MultiFileFlag" : "SingleFile" + }, + "file_label" : "step", + "output_control_type" : "step", + "output_interval" : 1, + "body_output" : true, + "node_output" : false, + "skin_output" : false, + "plane_output" : [], + "nodal_results" : ["DISPLACEMENT", "TOTAL_DISPLACEMENT", "WATER_PRESSURE", "VOLUME_ACCELERATION", + "LINE_LOAD_Y", "TOTAL_STRESS_TENSOR", "CAUCHY_STRESS_TENSOR"], + "gauss_point_results" : ["GREEN_LAGRANGE_STRAIN_TENSOR", "ENGINEERING_STRAIN_TENSOR", "VON_MISES_STRESS", + "FLUID_FLUX_VECTOR", "HYDRAULIC_HEAD", "DEGREE_OF_SATURATION"] + }, + "point_data_configuration" : [] + } + } + } + ] + }, + "processes": { + "constraints_process_list": [ + { + "python_module" : "apply_scalar_constraint_table_process", + "kratos_module" : "KratosMultiphysics.GeoMechanicsApplication", + "process_name" : "ApplyScalarConstraintTableProcess", + "Parameters": { + "model_part_name" : "PorousDomain.WATER_PRESSURE_Bottom", + "variable_name" : "WATER_PRESSURE", + "is_fixed" : true, + "table" : 0, + "fluid_pressure_type" : "Phreatic_Multi_Line", + "gravity_direction" : 1, + "out_of_plane_direction" : 2, + "x_coordinates" : [ 0.0, 1.0], + "y_coordinates" : [-2.0, -2.0], + "z_coordinates" : [ 0.0, 0.0], + "specific_weight" : 10000.0 + } + }, + { + "python_module" : "apply_scalar_constraint_table_process", + "kratos_module" : "KratosMultiphysics.GeoMechanicsApplication", + "process_name" : "ApplyScalarConstraintTableProcess", + "Parameters": { + "model_part_name" : "PorousDomain.WATER_PRESSURE_Top", + "variable_name" : "WATER_PRESSURE", + "is_fixed" : true, + "table" : 0, + "fluid_pressure_type" : "Phreatic_Multi_Line", + "gravity_direction" : 1, + "out_of_plane_direction" : 2, + "x_coordinates" : [ 0.0, 1.0], + "y_coordinates" : [-2.0, -2.0], + "z_coordinates" : [ 0.0, 0.0], + "specific_weight" : 10000.0 + } + }, + { + "python_module" : "apply_vector_constraint_table_process", + "kratos_module" : "KratosMultiphysics.GeoMechanicsApplication", + "process_name" : "ApplyVectorConstraintTableProcess", + "Parameters": { + "model_part_name" : "PorousDomain.gravity", + "variable_name" : "DISPLACEMENT", + "active" : [true, true, true], + "is_fixed" : [true, true, true], + "value" : [0.0, 0.0, 0.0], + "table" : [0, 0, 0] + } + } + ], + "loads_process_list": [ + { + "python_module" : "apply_vector_constraint_table_process", + "kratos_module" : "KratosMultiphysics.GeoMechanicsApplication", + "process_name" : "ApplyVectorConstraintTableProcess", + "Parameters": { + "model_part_name" : "PorousDomain.gravity", + "variable_name" : "VOLUME_ACCELERATION", + "active" : [false, true, false], + "value" : [0.0, -9.81, 0.0], + "table" : [0, 0, 0] + } + } + ], + "auxiliar_process_list": [ + { + "python_module" : "geo_extrapolate_integration_point_values_to_nodes_process", + "kratos_module" : "KratosMultiphysics.GeoMechanicsApplication", + "process_name" : "GeoExtrapolateIntegrationPointValuesToNodesProcess", + "Parameters": { + "model_part_name" : "PorousDomain", + "list_of_variables" : ["TOTAL_STRESS_TENSOR", "CAUCHY_STRESS_TENSOR"] + } + } + ] + } +} diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/kolom.mdpa b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/kolom.mdpa new file mode 100644 index 000000000000..0a051af8658a --- /dev/null +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/kolom.mdpa @@ -0,0 +1,393 @@ +Begin ModelPartData +// VARIABLE_NAME value +End ModelPartData + +Begin Properties 0 +End Properties + +Begin Nodes + 1 0.0000000000 -5.0000000000 0.0000000000 + 2 1.0000000000 -5.0000000000 0.0000000000 + 3 0.0000000000 -4.5000000000 0.0000000000 + 4 1.0000000000 -4.5000000000 0.0000000000 + 5 0.0000000000 -4.0000000000 0.0000000000 + 6 1.0000000000 -4.0000000000 0.0000000000 + 7 0.0000000000 -3.5000000000 0.0000000000 + 8 1.0000000000 -3.5000000000 0.0000000000 + 9 0.0000000000 -3.0000000000 0.0000000000 + 10 1.0000000000 -3.0000000000 0.0000000000 + 11 0.0000000000 -2.5000000000 0.0000000000 + 12 1.0000000000 -2.5000000000 0.0000000000 + 13 0.0000000000 -2.0000000000 0.0000000000 + 14 1.0000000000 -2.0000000000 0.0000000000 + 15 0.0000000000 -1.5000000000 0.0000000000 + 16 1.0000000000 -1.5000000000 0.0000000000 + 17 0.0000000000 -1.0000000000 0.0000000000 + 18 1.0000000000 -1.0000000000 0.0000000000 + 19 0.0000000000 -0.5000000000 0.0000000000 + 20 1.0000000000 -0.5000000000 0.0000000000 + 21 0.0000000000 0.0000000000 0.0000000000 + 22 1.0000000000 0.0000000000 0.0000000000 + 23 0.0000000000 -4.7500000000 0.0000000000 + 24 0.0000000000 -4.2500000000 0.0000000000 + 25 0.0000000000 -3.7500000000 0.0000000000 + 26 0.0000000000 -3.2500000000 0.0000000000 + 27 0.0000000000 -2.7500000000 0.0000000000 + 28 0.0000000000 -2.2500000000 0.0000000000 + 29 0.0000000000 -1.7500000000 0.0000000000 + 30 0.0000000000 -1.2500000000 0.0000000000 + 31 0.0000000000 -0.7500000000 0.0000000000 + 32 0.0000000000 -0.2500000000 0.0000000000 + 33 1.0000000000 -4.7500000000 0.0000000000 + 34 1.0000000000 -4.2500000000 0.0000000000 + 35 1.0000000000 -3.7500000000 0.0000000000 + 36 1.0000000000 -3.2500000000 0.0000000000 + 37 1.0000000000 -2.7500000000 0.0000000000 + 38 1.0000000000 -2.2500000000 0.0000000000 + 39 1.0000000000 -1.7500000000 0.0000000000 + 40 1.0000000000 -1.2500000000 0.0000000000 + 41 1.0000000000 -0.7500000000 0.0000000000 + 42 1.0000000000 -0.2500000000 0.0000000000 + 43 0.5000000000 -5.0000000000 0.0000000000 + 44 0.5000000000 -4.7500000000 0.0000000000 + 45 0.5000000000 -4.5000000000 0.0000000000 + 46 0.5000000000 -4.2500000000 0.0000000000 + 47 0.5000000000 -4.0000000000 0.0000000000 + 48 0.5000000000 -3.7500000000 0.0000000000 + 49 0.5000000000 -3.5000000000 0.0000000000 + 50 0.5000000000 -3.2500000000 0.0000000000 + 51 0.5000000000 -3.0000000000 0.0000000000 + 52 0.5000000000 -2.7500000000 0.0000000000 + 53 0.5000000000 -2.5000000000 0.0000000000 + 54 0.5000000000 -2.2500000000 0.0000000000 + 55 0.5000000000 -2.0000000000 0.0000000000 + 56 0.5000000000 -1.7500000000 0.0000000000 + 57 0.5000000000 -1.5000000000 0.0000000000 + 58 0.5000000000 -1.2500000000 0.0000000000 + 59 0.5000000000 -1.0000000000 0.0000000000 + 60 0.5000000000 -0.7500000000 0.0000000000 + 61 0.5000000000 -0.5000000000 0.0000000000 + 62 0.5000000000 -0.2500000000 0.0000000000 + 63 0.5000000000 0.0000000000 0.0000000000 +End Nodes + + +Begin Elements UPwSmallStrainElement2D6N // GUI group identifier: Grond + 1 0 1 2 4 43 33 44 + 2 0 4 3 1 45 23 44 + 3 0 3 4 6 45 34 46 + 4 0 6 5 3 47 24 46 + 5 0 5 6 8 47 35 48 + 6 0 8 7 5 49 25 48 + 7 0 7 8 10 49 36 50 + 8 0 10 9 7 51 26 50 + 9 0 9 10 12 51 37 52 + 10 0 12 11 9 53 27 52 + 11 0 11 12 14 53 38 54 + 12 0 14 13 11 55 28 54 + 13 0 13 14 16 55 39 56 + 14 0 16 15 13 57 29 56 + 15 0 15 16 18 57 40 58 + 16 0 18 17 15 59 30 58 + 17 0 17 18 20 59 41 60 + 18 0 20 19 17 61 31 60 + 19 0 19 20 22 61 42 62 + 20 0 22 21 19 63 32 62 +End Elements + +Begin SubModelPart Parts_Solid_Grond // Group Grond // Subtree Parts_Solid + Begin SubModelPartNodes + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + 15 + 16 + 17 + 18 + 19 + 20 + 21 + 22 + 23 + 24 + 25 + 26 + 27 + 28 + 29 + 30 + 31 + 32 + 33 + 34 + 35 + 36 + 37 + 38 + 39 + 40 + 41 + 42 + 43 + 44 + 45 + 46 + 47 + 48 + 49 + 50 + 51 + 52 + 53 + 54 + 55 + 56 + 57 + 58 + 59 + 60 + 61 + 62 + 63 + End SubModelPartNodes + Begin SubModelPartElements + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + 15 + 16 + 17 + 18 + 19 + 20 + End SubModelPartElements +End SubModelPart + +Begin SubModelPart gravity + Begin SubModelPartNodes + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + 15 + 16 + 17 + 18 + 19 + 20 + 21 + 22 + 23 + 24 + 25 + 26 + 27 + 28 + 29 + 30 + 31 + 32 + 33 + 34 + 35 + 36 + 37 + 38 + 39 + 40 + 41 + 42 + 43 + 44 + 45 + 46 + 47 + 48 + 49 + 50 + 51 + 52 + 53 + 54 + 55 + 56 + 57 + 58 + 59 + 60 + 61 + 62 + 63 + End SubModelPartNodes +End SubModelPart + +Begin SubModelPart DISPLACEMENT_Bottom // Group Bottom // Subtree DISPLACEMENT + Begin SubModelPartNodes + 1 + 2 + 43 + End SubModelPartNodes +End SubModelPart + +Begin SubModelPart DISPLACEMENT_Sides // Group Sides // Subtree DISPLACEMENT + Begin SubModelPartNodes + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + 15 + 16 + 17 + 18 + 19 + 20 + 21 + 22 + 23 + 24 + 25 + 26 + 27 + 28 + 29 + 30 + 31 + 32 + 33 + 34 + 35 + 36 + 37 + 38 + 39 + 40 + 41 + 42 + End SubModelPartNodes +End SubModelPart + +Begin SubModelPart WATER_PRESSURE_Initial + Begin SubModelPartNodes + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + 15 + 16 + 17 + 18 + 19 + 20 + 21 + 22 + 23 + 24 + 25 + 26 + 27 + 28 + 29 + 30 + 31 + 32 + 33 + 34 + 35 + 36 + 37 + 38 + 39 + 40 + 41 + 42 + 43 + 44 + 45 + 46 + 47 + 48 + 49 + 50 + 51 + 52 + 53 + 54 + 55 + 56 + 57 + 58 + 59 + 60 + 61 + 62 + 63 + End SubModelPartNodes +End SubModelPart + +Begin SubModelPart WATER_PRESSURE_Top + Begin SubModelPartNodes + 21 + 22 + 63 + End SubModelPartNodes +End SubModelPart + +Begin SubModelPart WATER_PRESSURE_Bottom + Begin SubModelPartNodes + 1 + 2 + 43 + End SubModelPartNodes +End SubModelPart From 437df1fd265b8d448626a318b3c7b6945ba3c4bb Mon Sep 17 00:00:00 2001 From: mnabideltares Date: Thu, 12 Dec 2024 16:17:42 +0100 Subject: [PATCH 27/36] fixes --- .../tests/test_partial_saturation.py | 7 ++----- .../MaterialParameters_stage2.json | 4 ++-- .../MaterialParameters_stage2.json | 4 ++-- 3 files changed, 6 insertions(+), 9 deletions(-) diff --git a/applications/GeoMechanicsApplication/tests/test_partial_saturation.py b/applications/GeoMechanicsApplication/tests/test_partial_saturation.py index f96c08333190..ac7a567a8cd8 100644 --- a/applications/GeoMechanicsApplication/tests/test_partial_saturation.py +++ b/applications/GeoMechanicsApplication/tests/test_partial_saturation.py @@ -99,11 +99,8 @@ def __calculate_column_saturated_under_phreatic_level(self, y_coord): gravity = 9.81 phreatic_level = -2.0 result = gravity * water_density * (y_coord - phreatic_level) - result = min([result, 0.0]) - return result - return 0.0 - - + return min([result, 0.0]) + if __name__ == '__main__': KratosUnittest.main() diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/MaterialParameters_stage2.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/MaterialParameters_stage2.json index 284f0c48764c..7b064caac938 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/MaterialParameters_stage2.json +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/MaterialParameters_stage2.json @@ -17,10 +17,10 @@ "BULK_MODULUS_FLUID": 2200000000.0, "PERMEABILITY_XX": 1.157E-05, "PERMEABILITY_YY": 1.157E-05, - "PERMEABILITY_XY": 0.0, + "PERMEABILITY_XY": 0.001, "DYNAMIC_VISCOSITY": 0.001, "RETENTION_LAW": "SaturatedBelowPhreaticLevelLaw", - "RESIDUAL_SATURATION": 0.0e-3, + "RESIDUAL_SATURATION": 0.001, "SATURATED_SATURATION": 1.0, "MINIMUM_RELATIVE_PERMEABILITY": 0.0, "K0_MAIN_DIRECTION": 1, diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/MaterialParameters_stage2.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/MaterialParameters_stage2.json index 284f0c48764c..0fc3dc1d4f8d 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/MaterialParameters_stage2.json +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/MaterialParameters_stage2.json @@ -20,9 +20,9 @@ "PERMEABILITY_XY": 0.0, "DYNAMIC_VISCOSITY": 0.001, "RETENTION_LAW": "SaturatedBelowPhreaticLevelLaw", - "RESIDUAL_SATURATION": 0.0e-3, + "RESIDUAL_SATURATION": 0.001, "SATURATED_SATURATION": 1.0, - "MINIMUM_RELATIVE_PERMEABILITY": 0.0, + "MINIMUM_RELATIVE_PERMEABILITY": 0.001, "K0_MAIN_DIRECTION": 1, "K0_NC": 0.6, "YOUNG_MODULUS": 1000000000.0, From bd43cc408606e13e8708c18863dd6a0606712bc5 Mon Sep 17 00:00:00 2001 From: mnabideltares Date: Thu, 12 Dec 2024 16:20:55 +0100 Subject: [PATCH 28/36] fix --- .../MaterialParameters_stage2.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/MaterialParameters_stage2.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/MaterialParameters_stage2.json index 7b064caac938..0fc3dc1d4f8d 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/MaterialParameters_stage2.json +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/MaterialParameters_stage2.json @@ -17,12 +17,12 @@ "BULK_MODULUS_FLUID": 2200000000.0, "PERMEABILITY_XX": 1.157E-05, "PERMEABILITY_YY": 1.157E-05, - "PERMEABILITY_XY": 0.001, + "PERMEABILITY_XY": 0.0, "DYNAMIC_VISCOSITY": 0.001, "RETENTION_LAW": "SaturatedBelowPhreaticLevelLaw", "RESIDUAL_SATURATION": 0.001, "SATURATED_SATURATION": 1.0, - "MINIMUM_RELATIVE_PERMEABILITY": 0.0, + "MINIMUM_RELATIVE_PERMEABILITY": 0.001, "K0_MAIN_DIRECTION": 1, "K0_NC": 0.6, "YOUNG_MODULUS": 1000000000.0, From 162c3f44d7d6a4d09061f5c1e91284d47b09e361 Mon Sep 17 00:00:00 2001 From: Wijtze Pieter Kikstra Date: Mon, 16 Dec 2024 09:24:21 +0100 Subject: [PATCH 29/36] Sonar Cloud unused stuff complaint resolved --- .../tests/test_partial_saturation.py | 23 ++----------------- 1 file changed, 2 insertions(+), 21 deletions(-) diff --git a/applications/GeoMechanicsApplication/tests/test_partial_saturation.py b/applications/GeoMechanicsApplication/tests/test_partial_saturation.py index ac7a567a8cd8..21b86a1174b0 100644 --- a/applications/GeoMechanicsApplication/tests/test_partial_saturation.py +++ b/applications/GeoMechanicsApplication/tests/test_partial_saturation.py @@ -1,10 +1,6 @@ -# from KratosMultiphysics import * as Kratos - -import sys import os import KratosMultiphysics as Kratos -import KratosMultiphysics.GeoMechanicsApplication as KratosGeo import KratosMultiphysics.GeoMechanicsApplication.geomechanics_analysis as analysis import KratosMultiphysics.KratosUnittest as KratosUnittest @@ -25,19 +21,9 @@ def tearDown(self): pass def __test_saturated_below_phreatic_level_pw(self, test_name): - """ - test 1D consolidation on elastic soil. - - :return: - """ - from math import fabs - #from analytical_solutions import calculate_column_saturated_under_phreatic_level - - # define number of stages n_stages = 2 # get the parameter file names for all stages - #test_name = test_name file_path = test_helper.get_file_path(os.path.join('.', 'test_partially_saturated', test_name)) parameter_file_names = [os.path.join(file_path, 'ProjectParameters_stage' + str(i + 1) + '.json') for i in range(n_stages)] @@ -61,11 +47,8 @@ def __test_saturated_below_phreatic_level_pw(self, test_name): # get y coords of all the nodes coords = test_helper.get_nodal_coordinates(stages[1]) y_coords = [coord[1] for coord in coords] - - # calculate water pressure analytical solution for all stages and calculate the error - #rmse_stages = [None] * (n_stages - 1) rel_p_stage = [self.__calculate_column_saturated_under_phreatic_level(y_coord) for y_coord in y_coords] print(rel_p_stage) @@ -77,7 +60,6 @@ def __test_saturated_below_phreatic_level_pw(self, test_name): accuracy = 1.0e-7 self.assertLess(rmse_stages, accuracy) - def test_saturated_below_phreatic_level_pw_triangle3N(self): self.__test_saturated_below_phreatic_level_pw('test_saturated_below_phreatic_level_pw_triangle3N') @@ -93,12 +75,11 @@ def test_saturated_below_phreatic_level_upw_smallstrain_triangle3n(self): def test_saturated_below_phreatic_level_upw_smallstrain_triangle6n(self): self.__test_saturated_below_phreatic_level_pw('test_saturated_below_phreatic_level_upw_smallstrain_triangle6n') - def __calculate_column_saturated_under_phreatic_level(self, y_coord): water_density = 1019.367991845056 - gravity = 9.81 + gravity = -9.81 phreatic_level = -2.0 - result = gravity * water_density * (y_coord - phreatic_level) + result = gravity * water_density * (phreatic_level - y_coord) return min([result, 0.0]) From f7c026177b76291b7658fef4aa67f41e620c4da9 Mon Sep 17 00:00:00 2001 From: Wijtze Pieter Kikstra Date: Mon, 16 Dec 2024 09:57:10 +0100 Subject: [PATCH 30/36] Removed unused retention parameters ( review Gennady ) --- .../custom_elements/U_Pw_small_strain_element.cpp | 2 -- .../custom_elements/U_Pw_small_strain_interface_element.cpp | 4 ---- 2 files changed, 6 deletions(-) diff --git a/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp b/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp index f6b1531adbcd..711690395c86 100644 --- a/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp +++ b/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp @@ -258,8 +258,6 @@ void UPwSmallStrainElement::InitializeSolutionStep(const Proces ElementVariables Variables; this->InitializeElementVariables(Variables, rCurrentProcessInfo); - RetentionLaw::Parameters RetentionParameters(this->GetProperties()); - const auto b_matrices = CalculateBMatrices(Variables.DN_DXContainer, Variables.NContainer); const auto deformation_gradients = CalculateDeformationGradients(); const auto determinants_of_deformation_gradients = diff --git a/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_interface_element.cpp b/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_interface_element.cpp index 9e9afd330870..da678158304a 100644 --- a/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_interface_element.cpp +++ b/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_interface_element.cpp @@ -192,8 +192,6 @@ void UPwSmallStrainInterfaceElement::InitializeSolutionStep(con unsigned int NumGPoints = mConstitutiveLawVector.size(); std::vector JointWidthContainer(NumGPoints); - RetentionLaw::Parameters RetentionParameters(this->GetProperties()); - // Loop over integration points for (unsigned int GPoint = 0; GPoint < NumGPoints; ++GPoint) { InterfaceElementUtilities::CalculateNuMatrix(Nu, NContainer, GPoint); @@ -250,8 +248,6 @@ void UPwSmallStrainInterfaceElement::FinalizeSolutionStep(const unsigned int NumGPoints = mConstitutiveLawVector.size(); std::vector JointWidthContainer(NumGPoints); - RetentionLaw::Parameters RetentionParameters(this->GetProperties()); - // Loop over integration points for (unsigned int GPoint = 0; GPoint < NumGPoints; ++GPoint) { InterfaceElementUtilities::CalculateNuMatrix(Nu, NContainer, GPoint); From be608a3a05100e964e1a391b00ecbe229a399633 Mon Sep 17 00:00:00 2001 From: Wijtze Pieter Kikstra Date: Mon, 16 Dec 2024 12:08:08 +0100 Subject: [PATCH 31/36] std::transform for pressure getting ( review comment of Gennady ) --- .../small_strain_U_Pw_diff_order_element.cpp | 207 ++++++++---------- .../small_strain_U_Pw_diff_order_element.hpp | 1 + 2 files changed, 87 insertions(+), 121 deletions(-) diff --git a/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp b/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp index dacfb6bdf588..4605084cf953 100644 --- a/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp +++ b/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp @@ -279,6 +279,16 @@ void SmallStrainUPwDiffOrderElement::FinalizeSolutionStep(const ProcessInfo& rCu KRATOS_CATCH("") } +Vector SmallStrainUPwDiffOrderElement::GetPressures(const size_t n_nodes) +{ + GeometryType& r_geom = GetGeometry(); + Vector pressure(n_nodes); + std::transform(r_geom.begin(), r_geom.begin()+n_nodes, pressure.begin(), [](const auto& node) { + return node.FastGetSolutionStepValue(WATER_PRESSURE); + }); + return pressure; +} + void SmallStrainUPwDiffOrderElement::AssignPressureToIntermediateNodes() { // Assign pressure values to the intermediate nodes for post-processing @@ -291,170 +301,125 @@ void SmallStrainUPwDiffOrderElement::AssignPressureToIntermediateNodes() switch (num_u_nodes) { case 6: // 2D T6P3 { - const double p0 = r_geom[0].FastGetSolutionStepValue(WATER_PRESSURE); - const double p1 = r_geom[1].FastGetSolutionStepValue(WATER_PRESSURE); - const double p2 = r_geom[2].FastGetSolutionStepValue(WATER_PRESSURE); - ThreadSafeNodeWrite(r_geom[3], WATER_PRESSURE, 0.5 * (p0 + p1)); - ThreadSafeNodeWrite(r_geom[4], WATER_PRESSURE, 0.5 * (p1 + p2)); - ThreadSafeNodeWrite(r_geom[5], WATER_PRESSURE, 0.5 * (p2 + p0)); + const Vector p = GetPressures(3); + ThreadSafeNodeWrite(r_geom[3], WATER_PRESSURE, 0.5 * (p[0] + p[1])); + ThreadSafeNodeWrite(r_geom[4], WATER_PRESSURE, 0.5 * (p[1] + p[2])); + ThreadSafeNodeWrite(r_geom[5], WATER_PRESSURE, 0.5 * (p[2] + p[0])); break; } case 8: // 2D Q8P4 { - const double p0 = r_geom[0].FastGetSolutionStepValue(WATER_PRESSURE); - const double p1 = r_geom[1].FastGetSolutionStepValue(WATER_PRESSURE); - const double p2 = r_geom[2].FastGetSolutionStepValue(WATER_PRESSURE); - const double p3 = r_geom[3].FastGetSolutionStepValue(WATER_PRESSURE); - ThreadSafeNodeWrite(r_geom[4], WATER_PRESSURE, 0.5 * (p0 + p1)); - ThreadSafeNodeWrite(r_geom[5], WATER_PRESSURE, 0.5 * (p1 + p2)); - ThreadSafeNodeWrite(r_geom[6], WATER_PRESSURE, 0.5 * (p2 + p3)); - ThreadSafeNodeWrite(r_geom[7], WATER_PRESSURE, 0.5 * (p3 + p0)); + const Vector p = GetPressures(4); + ThreadSafeNodeWrite(r_geom[4], WATER_PRESSURE, 0.5 * (p[0] + p[1])); + ThreadSafeNodeWrite(r_geom[5], WATER_PRESSURE, 0.5 * (p[1] + p[2])); + ThreadSafeNodeWrite(r_geom[6], WATER_PRESSURE, 0.5 * (p[2] + p[3])); + ThreadSafeNodeWrite(r_geom[7], WATER_PRESSURE, 0.5 * (p[3] + p[0])); break; } case 9: // 2D Q9P4 { - const double p0 = r_geom[0].FastGetSolutionStepValue(WATER_PRESSURE); - const double p1 = r_geom[1].FastGetSolutionStepValue(WATER_PRESSURE); - const double p2 = r_geom[2].FastGetSolutionStepValue(WATER_PRESSURE); - const double p3 = r_geom[3].FastGetSolutionStepValue(WATER_PRESSURE); - ThreadSafeNodeWrite(r_geom[4], WATER_PRESSURE, 0.5 * (p0 + p1)); - ThreadSafeNodeWrite(r_geom[5], WATER_PRESSURE, 0.5 * (p1 + p2)); - ThreadSafeNodeWrite(r_geom[6], WATER_PRESSURE, 0.5 * (p2 + p3)); - ThreadSafeNodeWrite(r_geom[7], WATER_PRESSURE, 0.5 * (p3 + p0)); - ThreadSafeNodeWrite(r_geom[8], WATER_PRESSURE, 0.25 * (p0 + p1 + p2 + p3)); + const Vector p = GetPressures(4); + ThreadSafeNodeWrite(r_geom[4], WATER_PRESSURE, 0.5 * (p[0] + p[1])); + ThreadSafeNodeWrite(r_geom[5], WATER_PRESSURE, 0.5 * (p[1] + p[2])); + ThreadSafeNodeWrite(r_geom[6], WATER_PRESSURE, 0.5 * (p[2] + p[3])); + ThreadSafeNodeWrite(r_geom[7], WATER_PRESSURE, 0.5 * (p[3] + p[0])); + ThreadSafeNodeWrite(r_geom[8], WATER_PRESSURE, 0.25 * (p[0] + p[1] + p[2] + p[3])); break; } case 10: // 3D T10P4 //2D T10P6 { if (n_dim == 3) { - const double p0 = r_geom[0].FastGetSolutionStepValue(WATER_PRESSURE); - const double p1 = r_geom[1].FastGetSolutionStepValue(WATER_PRESSURE); - const double p2 = r_geom[2].FastGetSolutionStepValue(WATER_PRESSURE); - const double p3 = r_geom[3].FastGetSolutionStepValue(WATER_PRESSURE); - ThreadSafeNodeWrite(r_geom[4], WATER_PRESSURE, 0.5 * (p0 + p1)); - ThreadSafeNodeWrite(r_geom[5], WATER_PRESSURE, 0.5 * (p1 + p2)); - ThreadSafeNodeWrite(r_geom[6], WATER_PRESSURE, 0.5 * (p2 + p0)); - ThreadSafeNodeWrite(r_geom[7], WATER_PRESSURE, 0.5 * (p0 + p3)); - ThreadSafeNodeWrite(r_geom[8], WATER_PRESSURE, 0.5 * (p1 + p3)); - ThreadSafeNodeWrite(r_geom[9], WATER_PRESSURE, 0.5 * (p2 + p3)); + const Vector p = GetPressures(4); + ThreadSafeNodeWrite(r_geom[4], WATER_PRESSURE, 0.5 * (p[0] + p[1])); + ThreadSafeNodeWrite(r_geom[5], WATER_PRESSURE, 0.5 * (p[1] + p[2])); + ThreadSafeNodeWrite(r_geom[6], WATER_PRESSURE, 0.5 * (p[2] + p[0])); + ThreadSafeNodeWrite(r_geom[7], WATER_PRESSURE, 0.5 * (p[0] + p[3])); + ThreadSafeNodeWrite(r_geom[8], WATER_PRESSURE, 0.5 * (p[1] + p[3])); + ThreadSafeNodeWrite(r_geom[9], WATER_PRESSURE, 0.5 * (p[2] + p[3])); } else if (n_dim == 2) { constexpr double c1 = 1.0 / 9.0; - const double p0 = r_geom[0].FastGetSolutionStepValue(WATER_PRESSURE); - const double p1 = r_geom[1].FastGetSolutionStepValue(WATER_PRESSURE); - const double p2 = r_geom[2].FastGetSolutionStepValue(WATER_PRESSURE); - const double p3 = r_geom[3].FastGetSolutionStepValue(WATER_PRESSURE); - const double p4 = r_geom[4].FastGetSolutionStepValue(WATER_PRESSURE); - const double p5 = r_geom[5].FastGetSolutionStepValue(WATER_PRESSURE); - ThreadSafeNodeWrite(r_geom[0], WATER_PRESSURE, p0); - ThreadSafeNodeWrite(r_geom[1], WATER_PRESSURE, p1); - ThreadSafeNodeWrite(r_geom[2], WATER_PRESSURE, p2); - ThreadSafeNodeWrite(r_geom[3], WATER_PRESSURE, (2.0 * p0 - p1 + 8.0 * p3) * c1); - ThreadSafeNodeWrite(r_geom[4], WATER_PRESSURE, (2.0 * p1 - p0 + 8.0 * p3) * c1); - ThreadSafeNodeWrite(r_geom[5], WATER_PRESSURE, (2.0 * p1 - p2 + 8.0 * p4) * c1); - ThreadSafeNodeWrite(r_geom[6], WATER_PRESSURE, (2.0 * p2 - p1 + 8.0 * p4) * c1); - ThreadSafeNodeWrite(r_geom[7], WATER_PRESSURE, (2.0 * p2 - p0 + 8.0 * p5) * c1); - ThreadSafeNodeWrite(r_geom[8], WATER_PRESSURE, (2.0 * p0 - p2 + 8.0 * p5) * c1); - ThreadSafeNodeWrite(r_geom[9], WATER_PRESSURE, (4.0 * (p3 + p4 + p5) - (p0 + p1 + p2)) * c1); + const Vector p = GetPressures(6); + ThreadSafeNodeWrite(r_geom[3], WATER_PRESSURE, (2.0 * p[0] - p[1] + 8.0 * p[3]) * c1); + ThreadSafeNodeWrite(r_geom[4], WATER_PRESSURE, (2.0 * p[1] - p[0] + 8.0 * p[3]) * c1); + ThreadSafeNodeWrite(r_geom[5], WATER_PRESSURE, (2.0 * p[1] - p[2] + 8.0 * p[4]) * c1); + ThreadSafeNodeWrite(r_geom[6], WATER_PRESSURE, (2.0 * p[2] - p[1] + 8.0 * p[4]) * c1); + ThreadSafeNodeWrite(r_geom[7], WATER_PRESSURE, (2.0 * p[2] - p[0] + 8.0 * p[5]) * c1); + ThreadSafeNodeWrite(r_geom[8], WATER_PRESSURE, (2.0 * p[0] - p[2] + 8.0 * p[5]) * c1); + ThreadSafeNodeWrite(r_geom[9], WATER_PRESSURE, (4.0 * (p[3] + p[4] + p[5]) - (p[0] + p[1] + p[2])) * c1); } break; } case 15: // 2D T15P10 { constexpr double c1 = 0.0390625; - const double p0 = r_geom[0].FastGetSolutionStepValue(WATER_PRESSURE); - const double p1 = r_geom[1].FastGetSolutionStepValue(WATER_PRESSURE); - const double p2 = r_geom[2].FastGetSolutionStepValue(WATER_PRESSURE); - const double p3 = r_geom[3].FastGetSolutionStepValue(WATER_PRESSURE); - const double p4 = r_geom[4].FastGetSolutionStepValue(WATER_PRESSURE); - const double p5 = r_geom[5].FastGetSolutionStepValue(WATER_PRESSURE); - const double p6 = r_geom[6].FastGetSolutionStepValue(WATER_PRESSURE); - const double p7 = r_geom[7].FastGetSolutionStepValue(WATER_PRESSURE); - const double p8 = r_geom[8].FastGetSolutionStepValue(WATER_PRESSURE); - const double p9 = r_geom[9].FastGetSolutionStepValue(WATER_PRESSURE); - ThreadSafeNodeWrite(r_geom[0], WATER_PRESSURE, p0); - ThreadSafeNodeWrite(r_geom[1], WATER_PRESSURE, p1); - ThreadSafeNodeWrite(r_geom[2], WATER_PRESSURE, p2); - ThreadSafeNodeWrite(r_geom[3], WATER_PRESSURE, (3.0 * p0 + p1 + 27.0 * p3 - 5.4 * p4) * c1); - ThreadSafeNodeWrite(r_geom[4], WATER_PRESSURE, (14.4 * (p3 + p4) - 1.6 * (p0 + p1)) * c1); - ThreadSafeNodeWrite(r_geom[5], WATER_PRESSURE, (3.0 * p1 + p0 + 27.0 * p4 - 5.4 * p3) * c1); - ThreadSafeNodeWrite(r_geom[6], WATER_PRESSURE, (3.0 * p1 + p2 + 27.0 * p5 - 5.4 * p6) * c1); - ThreadSafeNodeWrite(r_geom[7], WATER_PRESSURE, (14.4 * (p5 + p6) - 1.6 * (p1 + p2)) * c1); - ThreadSafeNodeWrite(r_geom[8], WATER_PRESSURE, (3.0 * p2 + p1 + 27.0 * p6 - 5.4 * p5) * c1); - ThreadSafeNodeWrite(r_geom[9], WATER_PRESSURE, (3.0 * p2 + p0 + 27.0 * p7 - 5.4 * p8) * c1); - ThreadSafeNodeWrite(r_geom[10], WATER_PRESSURE, (14.4 * (p7 + p8) - 1.6 * (p0 + p2)) * c1); - ThreadSafeNodeWrite(r_geom[11], WATER_PRESSURE, (3.0 * p0 + p2 + 27.0 * p8 - 5.4 * p7) * c1); + const Vector p = GetPressures(10); + ThreadSafeNodeWrite(r_geom[3], WATER_PRESSURE, (3.0 * p[0] + p[1] + 27.0 * p[3] - 5.4 * p[4]) * c1); + ThreadSafeNodeWrite(r_geom[4], WATER_PRESSURE, (14.4 * (p[3] + p[4]) - 1.6 * (p[0] + p[1])) * c1); + ThreadSafeNodeWrite(r_geom[5], WATER_PRESSURE, (3.0 * p[1] + p[0] + 27.0 * p[4] - 5.4 * p[3]) * c1); + ThreadSafeNodeWrite(r_geom[6], WATER_PRESSURE, (3.0 * p[1] + p[2] + 27.0 * p[5] - 5.4 * p[6]) * c1); + ThreadSafeNodeWrite(r_geom[7], WATER_PRESSURE, (14.4 * (p[5] + p[6]) - 1.6 * (p[1] + p[2])) * c1); + ThreadSafeNodeWrite(r_geom[8], WATER_PRESSURE, (3.0 * p[2] + p[1] + 27.0 * p[6] - 5.4 * p[5]) * c1); + ThreadSafeNodeWrite(r_geom[9], WATER_PRESSURE, (3.0 * p[2] + p[0] + 27.0 * p[7] - 5.4 * p[8]) * c1); + ThreadSafeNodeWrite(r_geom[10], WATER_PRESSURE, (14.4 * (p[7] + p[8]) - 1.6 * (p[0] + p[2])) * c1); + ThreadSafeNodeWrite(r_geom[11], WATER_PRESSURE, (3.0 * p[0] + p[2] + 27.0 * p[8] - 5.4 * p[7]) * c1); ThreadSafeNodeWrite( r_geom[12], WATER_PRESSURE, - (p1 + p2 + 7.2 * (p3 + p8) - 3.6 * (p4 + p7) - 1.8 * (p5 + p6) + 21.6 * p9 - 1.6 * p0) * c1); + (p[1] + p[2] + 7.2 * (p[3] + p[8]) - 3.6 * (p[4] + p[7]) - 1.8 * (p[5] + p[6]) + 21.6 * p[9] - 1.6 * p[0]) * c1); ThreadSafeNodeWrite( r_geom[13], WATER_PRESSURE, - (p0 + p2 + 7.2 * (p4 + p5) - 3.6 * (p3 + p6) - 1.8 * (p7 + p8) + 21.6 * p9 - 1.6 * p1) * c1); + (p[0] + p[2] + 7.2 * (p[4] + p[5]) - 3.6 * (p[3] + p[6]) - 1.8 * (p[7] + p[8]) + 21.6 * p[9] - 1.6 * p[1]) * c1); ThreadSafeNodeWrite( r_geom[14], WATER_PRESSURE, - (p0 + p1 + 7.2 * (p6 + p7) - 3.6 * (p5 + p8) - 1.8 * (p3 + p4) + 21.6 * p9 - 1.6 * p2) * c1); + (p[0] + p[1] + 7.2 * (p[6] + p[7]) - 3.6 * (p[5] + p[8]) - 1.8 * (p[3] + p[4]) + 21.6 * p[9] - 1.6 * p[2]) * c1); break; } case 20: // 3D H20P8 { - const double p0 = r_geom[0].FastGetSolutionStepValue(WATER_PRESSURE); - const double p1 = r_geom[1].FastGetSolutionStepValue(WATER_PRESSURE); - const double p2 = r_geom[2].FastGetSolutionStepValue(WATER_PRESSURE); - const double p3 = r_geom[3].FastGetSolutionStepValue(WATER_PRESSURE); - const double p4 = r_geom[4].FastGetSolutionStepValue(WATER_PRESSURE); - const double p5 = r_geom[5].FastGetSolutionStepValue(WATER_PRESSURE); - const double p6 = r_geom[6].FastGetSolutionStepValue(WATER_PRESSURE); - const double p7 = r_geom[7].FastGetSolutionStepValue(WATER_PRESSURE); + const Vector p = GetPressures(8); // edges -- bottom - ThreadSafeNodeWrite(r_geom[8], WATER_PRESSURE, 0.5 * (p0 + p1)); - ThreadSafeNodeWrite(r_geom[9], WATER_PRESSURE, 0.5 * (p1 + p2)); - ThreadSafeNodeWrite(r_geom[10], WATER_PRESSURE, 0.5 * (p2 + p3)); - ThreadSafeNodeWrite(r_geom[11], WATER_PRESSURE, 0.5 * (p3 + p0)); + ThreadSafeNodeWrite(r_geom[8], WATER_PRESSURE, 0.5 * (p[0] + p[1])); + ThreadSafeNodeWrite(r_geom[9], WATER_PRESSURE, 0.5 * (p[1] + p[2])); + ThreadSafeNodeWrite(r_geom[10], WATER_PRESSURE, 0.5 * (p[2] + p[3])); + ThreadSafeNodeWrite(r_geom[11], WATER_PRESSURE, 0.5 * (p[3] + p[0])); // edges -- middle - ThreadSafeNodeWrite(r_geom[12], WATER_PRESSURE, 0.5 * (p4 + p0)); - ThreadSafeNodeWrite(r_geom[13], WATER_PRESSURE, 0.5 * (p5 + p1)); - ThreadSafeNodeWrite(r_geom[14], WATER_PRESSURE, 0.5 * (p6 + p2)); - ThreadSafeNodeWrite(r_geom[15], WATER_PRESSURE, 0.5 * (p7 + p3)); + ThreadSafeNodeWrite(r_geom[12], WATER_PRESSURE, 0.5 * (p[4] + p[0])); + ThreadSafeNodeWrite(r_geom[13], WATER_PRESSURE, 0.5 * (p[5] + p[1])); + ThreadSafeNodeWrite(r_geom[14], WATER_PRESSURE, 0.5 * (p[6] + p[2])); + ThreadSafeNodeWrite(r_geom[15], WATER_PRESSURE, 0.5 * (p[7] + p[3])); // edges -- top - ThreadSafeNodeWrite(r_geom[16], WATER_PRESSURE, 0.5 * (p4 + p5)); - ThreadSafeNodeWrite(r_geom[17], WATER_PRESSURE, 0.5 * (p5 + p6)); - ThreadSafeNodeWrite(r_geom[18], WATER_PRESSURE, 0.5 * (p6 + p7)); - ThreadSafeNodeWrite(r_geom[19], WATER_PRESSURE, 0.5 * (p7 + p4)); + ThreadSafeNodeWrite(r_geom[16], WATER_PRESSURE, 0.5 * (p[4] + p[5])); + ThreadSafeNodeWrite(r_geom[17], WATER_PRESSURE, 0.5 * (p[5] + p[6])); + ThreadSafeNodeWrite(r_geom[18], WATER_PRESSURE, 0.5 * (p[6] + p[7])); + ThreadSafeNodeWrite(r_geom[19], WATER_PRESSURE, 0.5 * (p[7] + p[4])); break; } case 27: // 3D H27P8 { - const double p0 = r_geom[0].FastGetSolutionStepValue(WATER_PRESSURE); - const double p1 = r_geom[1].FastGetSolutionStepValue(WATER_PRESSURE); - const double p2 = r_geom[2].FastGetSolutionStepValue(WATER_PRESSURE); - const double p3 = r_geom[3].FastGetSolutionStepValue(WATER_PRESSURE); - const double p4 = r_geom[4].FastGetSolutionStepValue(WATER_PRESSURE); - const double p5 = r_geom[5].FastGetSolutionStepValue(WATER_PRESSURE); - const double p6 = r_geom[6].FastGetSolutionStepValue(WATER_PRESSURE); - const double p7 = r_geom[7].FastGetSolutionStepValue(WATER_PRESSURE); + const Vector p = GetPressures(8); // edges -- bottom - ThreadSafeNodeWrite(r_geom[8], WATER_PRESSURE, 0.5 * (p0 + p1)); - ThreadSafeNodeWrite(r_geom[9], WATER_PRESSURE, 0.5 * (p1 + p2)); - ThreadSafeNodeWrite(r_geom[10], WATER_PRESSURE, 0.5 * (p2 + p3)); - ThreadSafeNodeWrite(r_geom[11], WATER_PRESSURE, 0.5 * (p3 + p0)); + ThreadSafeNodeWrite(r_geom[8], WATER_PRESSURE, 0.5 * (p[0] + p[1])); + ThreadSafeNodeWrite(r_geom[9], WATER_PRESSURE, 0.5 * (p[1] + p[2])); + ThreadSafeNodeWrite(r_geom[10], WATER_PRESSURE, 0.5 * (p[2] + p[3])); + ThreadSafeNodeWrite(r_geom[11], WATER_PRESSURE, 0.5 * (p[3] + p[0])); // edges -- middle - ThreadSafeNodeWrite(r_geom[12], WATER_PRESSURE, 0.5 * (p4 + p0)); - ThreadSafeNodeWrite(r_geom[13], WATER_PRESSURE, 0.5 * (p5 + p1)); - ThreadSafeNodeWrite(r_geom[14], WATER_PRESSURE, 0.5 * (p6 + p2)); - ThreadSafeNodeWrite(r_geom[15], WATER_PRESSURE, 0.5 * (p7 + p3)); + ThreadSafeNodeWrite(r_geom[12], WATER_PRESSURE, 0.5 * (p[4] + p[0])); + ThreadSafeNodeWrite(r_geom[13], WATER_PRESSURE, 0.5 * (p[5] + p[1])); + ThreadSafeNodeWrite(r_geom[14], WATER_PRESSURE, 0.5 * (p[6] + p[2])); + ThreadSafeNodeWrite(r_geom[15], WATER_PRESSURE, 0.5 * (p[7] + p[3])); // edges -- top - ThreadSafeNodeWrite(r_geom[16], WATER_PRESSURE, 0.5 * (p4 + p5)); - ThreadSafeNodeWrite(r_geom[17], WATER_PRESSURE, 0.5 * (p5 + p6)); - ThreadSafeNodeWrite(r_geom[18], WATER_PRESSURE, 0.5 * (p6 + p7)); - ThreadSafeNodeWrite(r_geom[19], WATER_PRESSURE, 0.5 * (p7 + p0)); + ThreadSafeNodeWrite(r_geom[16], WATER_PRESSURE, 0.5 * (p[4] + p[5])); + ThreadSafeNodeWrite(r_geom[17], WATER_PRESSURE, 0.5 * (p[5] + p[6])); + ThreadSafeNodeWrite(r_geom[18], WATER_PRESSURE, 0.5 * (p[6] + p[7])); + ThreadSafeNodeWrite(r_geom[19], WATER_PRESSURE, 0.5 * (p[7] + p[0])); // face centers - ThreadSafeNodeWrite(r_geom[20], WATER_PRESSURE, 0.25 * (p0 + p1 + p2 + p3)); - ThreadSafeNodeWrite(r_geom[21], WATER_PRESSURE, 0.25 * (p0 + p1 + p4 + p5)); - ThreadSafeNodeWrite(r_geom[22], WATER_PRESSURE, 0.25 * (p1 + p2 + p5 + p6)); - ThreadSafeNodeWrite(r_geom[23], WATER_PRESSURE, 0.25 * (p2 + p3 + p6 + p7)); - ThreadSafeNodeWrite(r_geom[24], WATER_PRESSURE, 0.25 * (p3 + p0 + p7 + p4)); - ThreadSafeNodeWrite(r_geom[25], WATER_PRESSURE, 0.25 * (p4 + p5 + p6 + p7)); + ThreadSafeNodeWrite(r_geom[20], WATER_PRESSURE, 0.25 * (p[0] + p[1] + p[2] + p[3])); + ThreadSafeNodeWrite(r_geom[21], WATER_PRESSURE, 0.25 * (p[0] + p[1] + p[4] + p[5])); + ThreadSafeNodeWrite(r_geom[22], WATER_PRESSURE, 0.25 * (p[1] + p[2] + p[5] + p[6])); + ThreadSafeNodeWrite(r_geom[23], WATER_PRESSURE, 0.25 * (p[2] + p[3] + p[6] + p[7])); + ThreadSafeNodeWrite(r_geom[24], WATER_PRESSURE, 0.25 * (p[3] + p[0] + p[7] + p[4])); + ThreadSafeNodeWrite(r_geom[25], WATER_PRESSURE, 0.25 * (p[4] + p[5] + p[6] + p[7])); // element center - ThreadSafeNodeWrite(r_geom[26], WATER_PRESSURE, 0.125 * (p0 + p1 + p2 + p3 + p4 + p5 + p6 + p7)); + ThreadSafeNodeWrite(r_geom[26], WATER_PRESSURE, 0.125 * (p[0] + p[1] + p[2] + p[3] + p[4] + p[5] + p[6] + p[7])); break; } default: diff --git a/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.hpp b/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.hpp index 0aaf1fc9febf..197a809f9613 100644 --- a/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.hpp +++ b/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.hpp @@ -224,6 +224,7 @@ class KRATOS_API(GEO_MECHANICS_APPLICATION) SmallStrainUPwDiffOrderElement : pub std::vector CalculateBMatrices(const GeometryType::ShapeFunctionsGradientsType& rDN_DXContainer, const Matrix& rNContainer) const; + Vector GetPressures(size_t n_nodes); void AssignPressureToIntermediateNodes(); virtual Vector CalculateGreenLagrangeStrain(const Matrix& rDeformationGradient) const; From 83d65fe80b154284fad4812d971a6b44e0afabff Mon Sep 17 00:00:00 2001 From: Wijtze Pieter Kikstra Date: Mon, 16 Dec 2024 14:30:12 +0100 Subject: [PATCH 32/36] Removed unused K0 things ( review comment Gennady ) --- .../MaterialParameters_stage1.json | 2 -- .../MaterialParameters_stage2.json | 2 -- .../MaterialParameters_stage1.json | 2 -- .../MaterialParameters_stage2.json | 2 -- .../MaterialParameters_stage1.json | 2 -- .../MaterialParameters_stage2.json | 2 -- .../MaterialParameters_stage1.json | 2 -- .../MaterialParameters_stage2.json | 2 -- .../MaterialParameters_stage1.json | 2 -- .../MaterialParameters_stage2.json | 2 -- 10 files changed, 20 deletions(-) diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/MaterialParameters_stage1.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/MaterialParameters_stage1.json index 4e17eff51bb2..fc2e750c8e3b 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/MaterialParameters_stage1.json +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/MaterialParameters_stage1.json @@ -23,8 +23,6 @@ "RESIDUAL_SATURATION": 0.001, "SATURATED_SATURATION": 1.0, "MINIMUM_RELATIVE_PERMEABILITY": 0.001, - "K0_MAIN_DIRECTION": 1, - "K0_NC": 0.6, "YOUNG_MODULUS": 1000000000.0, "POISSON_RATIO": 0.2 } diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/MaterialParameters_stage2.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/MaterialParameters_stage2.json index 0fc3dc1d4f8d..a59003318063 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/MaterialParameters_stage2.json +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/MaterialParameters_stage2.json @@ -23,8 +23,6 @@ "RESIDUAL_SATURATION": 0.001, "SATURATED_SATURATION": 1.0, "MINIMUM_RELATIVE_PERMEABILITY": 0.001, - "K0_MAIN_DIRECTION": 1, - "K0_NC": 0.6, "YOUNG_MODULUS": 1000000000.0, "POISSON_RATIO": 0.2 } diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/MaterialParameters_stage1.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/MaterialParameters_stage1.json index 4e17eff51bb2..fc2e750c8e3b 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/MaterialParameters_stage1.json +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/MaterialParameters_stage1.json @@ -23,8 +23,6 @@ "RESIDUAL_SATURATION": 0.001, "SATURATED_SATURATION": 1.0, "MINIMUM_RELATIVE_PERMEABILITY": 0.001, - "K0_MAIN_DIRECTION": 1, - "K0_NC": 0.6, "YOUNG_MODULUS": 1000000000.0, "POISSON_RATIO": 0.2 } diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/MaterialParameters_stage2.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/MaterialParameters_stage2.json index 0fc3dc1d4f8d..a59003318063 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/MaterialParameters_stage2.json +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/MaterialParameters_stage2.json @@ -23,8 +23,6 @@ "RESIDUAL_SATURATION": 0.001, "SATURATED_SATURATION": 1.0, "MINIMUM_RELATIVE_PERMEABILITY": 0.001, - "K0_MAIN_DIRECTION": 1, - "K0_NC": 0.6, "YOUNG_MODULUS": 1000000000.0, "POISSON_RATIO": 0.2 } diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/MaterialParameters_stage1.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/MaterialParameters_stage1.json index 4e17eff51bb2..fc2e750c8e3b 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/MaterialParameters_stage1.json +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/MaterialParameters_stage1.json @@ -23,8 +23,6 @@ "RESIDUAL_SATURATION": 0.001, "SATURATED_SATURATION": 1.0, "MINIMUM_RELATIVE_PERMEABILITY": 0.001, - "K0_MAIN_DIRECTION": 1, - "K0_NC": 0.6, "YOUNG_MODULUS": 1000000000.0, "POISSON_RATIO": 0.2 } diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/MaterialParameters_stage2.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/MaterialParameters_stage2.json index 0fc3dc1d4f8d..a59003318063 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/MaterialParameters_stage2.json +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/MaterialParameters_stage2.json @@ -23,8 +23,6 @@ "RESIDUAL_SATURATION": 0.001, "SATURATED_SATURATION": 1.0, "MINIMUM_RELATIVE_PERMEABILITY": 0.001, - "K0_MAIN_DIRECTION": 1, - "K0_NC": 0.6, "YOUNG_MODULUS": 1000000000.0, "POISSON_RATIO": 0.2 } diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/MaterialParameters_stage1.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/MaterialParameters_stage1.json index 4e17eff51bb2..fc2e750c8e3b 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/MaterialParameters_stage1.json +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/MaterialParameters_stage1.json @@ -23,8 +23,6 @@ "RESIDUAL_SATURATION": 0.001, "SATURATED_SATURATION": 1.0, "MINIMUM_RELATIVE_PERMEABILITY": 0.001, - "K0_MAIN_DIRECTION": 1, - "K0_NC": 0.6, "YOUNG_MODULUS": 1000000000.0, "POISSON_RATIO": 0.2 } diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/MaterialParameters_stage2.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/MaterialParameters_stage2.json index 0fc3dc1d4f8d..a59003318063 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/MaterialParameters_stage2.json +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/MaterialParameters_stage2.json @@ -23,8 +23,6 @@ "RESIDUAL_SATURATION": 0.001, "SATURATED_SATURATION": 1.0, "MINIMUM_RELATIVE_PERMEABILITY": 0.001, - "K0_MAIN_DIRECTION": 1, - "K0_NC": 0.6, "YOUNG_MODULUS": 1000000000.0, "POISSON_RATIO": 0.2 } diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/MaterialParameters_stage1.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/MaterialParameters_stage1.json index 4e17eff51bb2..fc2e750c8e3b 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/MaterialParameters_stage1.json +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/MaterialParameters_stage1.json @@ -23,8 +23,6 @@ "RESIDUAL_SATURATION": 0.001, "SATURATED_SATURATION": 1.0, "MINIMUM_RELATIVE_PERMEABILITY": 0.001, - "K0_MAIN_DIRECTION": 1, - "K0_NC": 0.6, "YOUNG_MODULUS": 1000000000.0, "POISSON_RATIO": 0.2 } diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/MaterialParameters_stage2.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/MaterialParameters_stage2.json index 0fc3dc1d4f8d..a59003318063 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/MaterialParameters_stage2.json +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/MaterialParameters_stage2.json @@ -23,8 +23,6 @@ "RESIDUAL_SATURATION": 0.001, "SATURATED_SATURATION": 1.0, "MINIMUM_RELATIVE_PERMEABILITY": 0.001, - "K0_MAIN_DIRECTION": 1, - "K0_NC": 0.6, "YOUNG_MODULUS": 1000000000.0, "POISSON_RATIO": 0.2 } From 35b98726ce22e02968b3b072738fe7b4c8233589 Mon Sep 17 00:00:00 2001 From: Wijtze Pieter Kikstra Date: Mon, 16 Dec 2024 14:37:22 +0100 Subject: [PATCH 33/36] Renamed kolom to the english column ( review comment Gennady ) --- .../ProjectParameters_stage1.json | 2 +- .../ProjectParameters_stage2.json | 2 +- .../{kolom.mdpa => column.mdpa} | 0 .../ProjectParameters_stage1.json | 2 +- .../ProjectParameters_stage2.json | 2 +- .../{kolom.mdpa => column.mdpa} | 0 .../ProjectParameters_stage1.json | 2 +- .../ProjectParameters_stage2.json | 2 +- .../{kolom.mdpa => column.mdpa} | 0 .../ProjectParameters_stage1.json | 2 +- .../ProjectParameters_stage2.json | 2 +- .../{kolom.mdpa => column.mdpa} | 0 .../ProjectParameters_stage1.json | 2 +- .../ProjectParameters_stage2.json | 2 +- .../{kolom.mdpa => column.mdpa} | 0 15 files changed, 10 insertions(+), 10 deletions(-) rename applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/{kolom.mdpa => column.mdpa} (100%) rename applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/{kolom.mdpa => column.mdpa} (100%) rename applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/{kolom.mdpa => column.mdpa} (100%) rename applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/{kolom.mdpa => column.mdpa} (100%) rename applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/{kolom.mdpa => column.mdpa} (100%) diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/ProjectParameters_stage1.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/ProjectParameters_stage1.json index 40e73107a11f..c2e14262a8fd 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/ProjectParameters_stage1.json +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/ProjectParameters_stage1.json @@ -13,7 +13,7 @@ "domain_size" : 2, "model_import_settings": { "input_type" : "mdpa", - "input_filename" : "kolom" + "input_filename" : "column" }, "material_import_settings": { "materials_filename" : "MaterialParameters_stage1.json" diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/ProjectParameters_stage2.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/ProjectParameters_stage2.json index f7abd745d771..0546a4ad5dbd 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/ProjectParameters_stage2.json +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/ProjectParameters_stage2.json @@ -13,7 +13,7 @@ "domain_size" : 2, "model_import_settings": { "input_type" : "mdpa", - "input_filename" : "kolom" + "input_filename" : "column" }, "material_import_settings": { "materials_filename" : "MaterialParameters_stage2.json" diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/kolom.mdpa b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/column.mdpa similarity index 100% rename from applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/kolom.mdpa rename to applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/column.mdpa diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/ProjectParameters_stage1.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/ProjectParameters_stage1.json index 40e73107a11f..c2e14262a8fd 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/ProjectParameters_stage1.json +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/ProjectParameters_stage1.json @@ -13,7 +13,7 @@ "domain_size" : 2, "model_import_settings": { "input_type" : "mdpa", - "input_filename" : "kolom" + "input_filename" : "column" }, "material_import_settings": { "materials_filename" : "MaterialParameters_stage1.json" diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/ProjectParameters_stage2.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/ProjectParameters_stage2.json index f7abd745d771..0546a4ad5dbd 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/ProjectParameters_stage2.json +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/ProjectParameters_stage2.json @@ -13,7 +13,7 @@ "domain_size" : 2, "model_import_settings": { "input_type" : "mdpa", - "input_filename" : "kolom" + "input_filename" : "column" }, "material_import_settings": { "materials_filename" : "MaterialParameters_stage2.json" diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/kolom.mdpa b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/column.mdpa similarity index 100% rename from applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/kolom.mdpa rename to applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/column.mdpa diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/ProjectParameters_stage1.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/ProjectParameters_stage1.json index e36bb23f0a2f..caf39a9d2d15 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/ProjectParameters_stage1.json +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/ProjectParameters_stage1.json @@ -13,7 +13,7 @@ "domain_size" : 2, "model_import_settings": { "input_type" : "mdpa", - "input_filename" : "kolom" + "input_filename" : "column" }, "material_import_settings": { "materials_filename" : "MaterialParameters_stage1.json" diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/ProjectParameters_stage2.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/ProjectParameters_stage2.json index 6d28f109786c..165be4e61562 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/ProjectParameters_stage2.json +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/ProjectParameters_stage2.json @@ -13,7 +13,7 @@ "domain_size" : 2, "model_import_settings": { "input_type" : "mdpa", - "input_filename" : "kolom_stage2" + "input_filename" : "column" }, "material_import_settings": { "materials_filename" : "MaterialParameters_stage2.json" diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/kolom.mdpa b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/column.mdpa similarity index 100% rename from applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/kolom.mdpa rename to applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/column.mdpa diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/ProjectParameters_stage1.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/ProjectParameters_stage1.json index d586a269d45d..731234fe8031 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/ProjectParameters_stage1.json +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/ProjectParameters_stage1.json @@ -13,7 +13,7 @@ "domain_size" : 2, "model_import_settings": { "input_type" : "mdpa", - "input_filename" : "kolom" + "input_filename" : "column" }, "material_import_settings": { "materials_filename" : "MaterialParameters_stage1.json" diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/ProjectParameters_stage2.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/ProjectParameters_stage2.json index 7ad300dacb06..e247ccfd3fa3 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/ProjectParameters_stage2.json +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/ProjectParameters_stage2.json @@ -13,7 +13,7 @@ "domain_size" : 2, "model_import_settings": { "input_type" : "mdpa", - "input_filename" : "kolom_stage2" + "input_filename" : "column" }, "material_import_settings": { "materials_filename" : "MaterialParameters_stage2.json" diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/kolom.mdpa b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/column.mdpa similarity index 100% rename from applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/kolom.mdpa rename to applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/column.mdpa diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/ProjectParameters_stage1.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/ProjectParameters_stage1.json index d586a269d45d..731234fe8031 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/ProjectParameters_stage1.json +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/ProjectParameters_stage1.json @@ -13,7 +13,7 @@ "domain_size" : 2, "model_import_settings": { "input_type" : "mdpa", - "input_filename" : "kolom" + "input_filename" : "column" }, "material_import_settings": { "materials_filename" : "MaterialParameters_stage1.json" diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/ProjectParameters_stage2.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/ProjectParameters_stage2.json index 9e3f992eacb8..5e37cffcff18 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/ProjectParameters_stage2.json +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/ProjectParameters_stage2.json @@ -13,7 +13,7 @@ "domain_size" : 2, "model_import_settings": { "input_type" : "mdpa", - "input_filename" : "kolom_stage2" + "input_filename" : "column" }, "material_import_settings": { "materials_filename" : "MaterialParameters_stage2.json" diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/kolom.mdpa b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/column.mdpa similarity index 100% rename from applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/kolom.mdpa rename to applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/column.mdpa From 27b69bcad42ed71e736e4db10bcf73998d49cf3a Mon Sep 17 00:00:00 2001 From: Wijtze Pieter Kikstra Date: Mon, 16 Dec 2024 14:59:17 +0100 Subject: [PATCH 34/36] avoid code repetition --- .../U_Pw_small_strain_element.cpp | 16 +--------------- .../small_strain_U_Pw_diff_order_element.cpp | 13 +------------ 2 files changed, 2 insertions(+), 27 deletions(-) diff --git a/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp b/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp index 711690395c86..cbd212e481f3 100644 --- a/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp +++ b/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp @@ -397,8 +397,6 @@ void UPwSmallStrainElement::FinalizeSolutionStep(const ProcessI ElementVariables Variables; this->InitializeElementVariables(Variables, rCurrentProcessInfo); - RetentionLaw::Parameters RetentionParameters(this->GetProperties()); - const auto b_matrices = CalculateBMatrices(Variables.DN_DXContainer, Variables.NContainer); const auto deformation_gradients = CalculateDeformationGradients(); const auto determinants_of_deformation_gradients = @@ -614,19 +612,7 @@ void UPwSmallStrainElement::CalculateOnIntegrationPoints(const RetentionParameters.SetFluidPressure(GeoTransportEquationUtilities::CalculateFluidPressure( Variables.Np, Variables.PressureVector)); - - if (rVariable == DEGREE_OF_SATURATION) - rOutput[GPoint] = mRetentionLawVector[GPoint]->CalculateSaturation(RetentionParameters); - else if (rVariable == EFFECTIVE_SATURATION) - rOutput[GPoint] = mRetentionLawVector[GPoint]->CalculateEffectiveSaturation(RetentionParameters); - else if (rVariable == BISHOP_COEFFICIENT) - rOutput[GPoint] = mRetentionLawVector[GPoint]->CalculateBishopCoefficient(RetentionParameters); - else if (rVariable == DERIVATIVE_OF_SATURATION) - rOutput[GPoint] = - mRetentionLawVector[GPoint]->CalculateDerivativeOfSaturation(RetentionParameters); - else if (rVariable == RELATIVE_PERMEABILITY) - rOutput[GPoint] = - mRetentionLawVector[GPoint]->CalculateRelativePermeability(RetentionParameters); + rOutput[GPoint] = mRetentionLawVector[GPoint]->CalculateValue(RetentionParameters, rVariable, rOutput[GPoint]); } } else if (rVariable == HYDRAULIC_HEAD) { const PropertiesType& rProp = this->GetProperties(); diff --git a/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp b/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp index 4605084cf953..2e8621d8882f 100644 --- a/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp +++ b/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp @@ -542,18 +542,7 @@ void SmallStrainUPwDiffOrderElement::CalculateOnIntegrationPoints(const Variable RetentionParameters.SetFluidPressure(GeoTransportEquationUtilities::CalculateFluidPressure( Variables.Np, Variables.PressureVector)); - if (rVariable == DEGREE_OF_SATURATION) - rOutput[GPoint] = mRetentionLawVector[GPoint]->CalculateSaturation(RetentionParameters); - else if (rVariable == EFFECTIVE_SATURATION) - rOutput[GPoint] = mRetentionLawVector[GPoint]->CalculateEffectiveSaturation(RetentionParameters); - else if (rVariable == BISHOP_COEFFICIENT) - rOutput[GPoint] = mRetentionLawVector[GPoint]->CalculateBishopCoefficient(RetentionParameters); - else if (rVariable == DERIVATIVE_OF_SATURATION) - rOutput[GPoint] = - mRetentionLawVector[GPoint]->CalculateDerivativeOfSaturation(RetentionParameters); - else if (rVariable == RELATIVE_PERMEABILITY) - rOutput[GPoint] = - mRetentionLawVector[GPoint]->CalculateRelativePermeability(RetentionParameters); + rOutput[GPoint] = mRetentionLawVector[GPoint]->CalculateValue(RetentionParameters, rVariable, rOutput[GPoint]); } } else if (rVariable == HYDRAULIC_HEAD) { constexpr double NumericalLimit = std::numeric_limits::epsilon(); From 856256eb4fbcd4cb941dbaa4725ba8bf3e5d8d59 Mon Sep 17 00:00:00 2001 From: Wijtze Pieter Kikstra Date: Mon, 16 Dec 2024 17:03:46 +0100 Subject: [PATCH 35/36] kp format on request of Anne --- .../U_Pw_small_strain_element.cpp | 8 ++-- .../small_strain_U_Pw_diff_order_element.cpp | 43 +++++++++++-------- .../small_strain_U_Pw_diff_order_element.hpp | 2 +- 3 files changed, 30 insertions(+), 23 deletions(-) diff --git a/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp b/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp index cbd212e481f3..95279b35bc45 100644 --- a/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp +++ b/applications/GeoMechanicsApplication/custom_elements/U_Pw_small_strain_element.cpp @@ -352,7 +352,8 @@ void UPwSmallStrainElement::InitializeNonLinearIteration(const { KRATOS_TRY - ConstitutiveLaw::Parameters ConstitutiveParameters(this->GetGeometry(), this->GetProperties(), rCurrentProcessInfo); + ConstitutiveLaw::Parameters ConstitutiveParameters(this->GetGeometry(), this->GetProperties(), + rCurrentProcessInfo); ConstitutiveParameters.Set(ConstitutiveLaw::COMPUTE_STRESS); ConstitutiveParameters.Set(ConstitutiveLaw::USE_ELEMENT_PROVIDED_STRAIN); ConstitutiveParameters.Set(ConstitutiveLaw::INITIALIZE_MATERIAL_RESPONSE); // Note: this is for nonlocal damage @@ -612,7 +613,8 @@ void UPwSmallStrainElement::CalculateOnIntegrationPoints(const RetentionParameters.SetFluidPressure(GeoTransportEquationUtilities::CalculateFluidPressure( Variables.Np, Variables.PressureVector)); - rOutput[GPoint] = mRetentionLawVector[GPoint]->CalculateValue(RetentionParameters, rVariable, rOutput[GPoint]); + rOutput[GPoint] = mRetentionLawVector[GPoint]->CalculateValue( + RetentionParameters, rVariable, rOutput[GPoint]); } } else if (rVariable == HYDRAULIC_HEAD) { const PropertiesType& rProp = this->GetProperties(); @@ -1235,7 +1237,7 @@ void UPwSmallStrainElement::CalculateAndAddLHS(MatrixType& rLef GeoElementUtilities::AssemblePPBlockMatrix(rLeftHandSideMatrix, permeability_matrix); this->CalculateAndAddCompressibilityMatrix(rLeftHandSideMatrix, rVariables); -} + } KRATOS_CATCH("") } diff --git a/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp b/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp index 2e8621d8882f..bead003a7dfd 100644 --- a/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp +++ b/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.cpp @@ -281,11 +281,10 @@ void SmallStrainUPwDiffOrderElement::FinalizeSolutionStep(const ProcessInfo& rCu Vector SmallStrainUPwDiffOrderElement::GetPressures(const size_t n_nodes) { - GeometryType& r_geom = GetGeometry(); - Vector pressure(n_nodes); - std::transform(r_geom.begin(), r_geom.begin()+n_nodes, pressure.begin(), [](const auto& node) { - return node.FastGetSolutionStepValue(WATER_PRESSURE); - }); + GeometryType& r_geom = GetGeometry(); + Vector pressure(n_nodes); + std::transform(r_geom.begin(), r_geom.begin() + n_nodes, pressure.begin(), + [](const auto& node) { return node.FastGetSolutionStepValue(WATER_PRESSURE); }); return pressure; } @@ -338,21 +337,22 @@ void SmallStrainUPwDiffOrderElement::AssignPressureToIntermediateNodes() ThreadSafeNodeWrite(r_geom[9], WATER_PRESSURE, 0.5 * (p[2] + p[3])); } else if (n_dim == 2) { constexpr double c1 = 1.0 / 9.0; - const Vector p = GetPressures(6); + const Vector p = GetPressures(6); ThreadSafeNodeWrite(r_geom[3], WATER_PRESSURE, (2.0 * p[0] - p[1] + 8.0 * p[3]) * c1); ThreadSafeNodeWrite(r_geom[4], WATER_PRESSURE, (2.0 * p[1] - p[0] + 8.0 * p[3]) * c1); ThreadSafeNodeWrite(r_geom[5], WATER_PRESSURE, (2.0 * p[1] - p[2] + 8.0 * p[4]) * c1); ThreadSafeNodeWrite(r_geom[6], WATER_PRESSURE, (2.0 * p[2] - p[1] + 8.0 * p[4]) * c1); ThreadSafeNodeWrite(r_geom[7], WATER_PRESSURE, (2.0 * p[2] - p[0] + 8.0 * p[5]) * c1); ThreadSafeNodeWrite(r_geom[8], WATER_PRESSURE, (2.0 * p[0] - p[2] + 8.0 * p[5]) * c1); - ThreadSafeNodeWrite(r_geom[9], WATER_PRESSURE, (4.0 * (p[3] + p[4] + p[5]) - (p[0] + p[1] + p[2])) * c1); + ThreadSafeNodeWrite(r_geom[9], WATER_PRESSURE, + (4.0 * (p[3] + p[4] + p[5]) - (p[0] + p[1] + p[2])) * c1); } break; } case 15: // 2D T15P10 { constexpr double c1 = 0.0390625; - const Vector p = GetPressures(10); + const Vector p = GetPressures(10); ThreadSafeNodeWrite(r_geom[3], WATER_PRESSURE, (3.0 * p[0] + p[1] + 27.0 * p[3] - 5.4 * p[4]) * c1); ThreadSafeNodeWrite(r_geom[4], WATER_PRESSURE, (14.4 * (p[3] + p[4]) - 1.6 * (p[0] + p[1])) * c1); ThreadSafeNodeWrite(r_geom[5], WATER_PRESSURE, (3.0 * p[1] + p[0] + 27.0 * p[4] - 5.4 * p[3]) * c1); @@ -362,15 +362,18 @@ void SmallStrainUPwDiffOrderElement::AssignPressureToIntermediateNodes() ThreadSafeNodeWrite(r_geom[9], WATER_PRESSURE, (3.0 * p[2] + p[0] + 27.0 * p[7] - 5.4 * p[8]) * c1); ThreadSafeNodeWrite(r_geom[10], WATER_PRESSURE, (14.4 * (p[7] + p[8]) - 1.6 * (p[0] + p[2])) * c1); ThreadSafeNodeWrite(r_geom[11], WATER_PRESSURE, (3.0 * p[0] + p[2] + 27.0 * p[8] - 5.4 * p[7]) * c1); - ThreadSafeNodeWrite( - r_geom[12], WATER_PRESSURE, - (p[1] + p[2] + 7.2 * (p[3] + p[8]) - 3.6 * (p[4] + p[7]) - 1.8 * (p[5] + p[6]) + 21.6 * p[9] - 1.6 * p[0]) * c1); - ThreadSafeNodeWrite( - r_geom[13], WATER_PRESSURE, - (p[0] + p[2] + 7.2 * (p[4] + p[5]) - 3.6 * (p[3] + p[6]) - 1.8 * (p[7] + p[8]) + 21.6 * p[9] - 1.6 * p[1]) * c1); - ThreadSafeNodeWrite( - r_geom[14], WATER_PRESSURE, - (p[0] + p[1] + 7.2 * (p[6] + p[7]) - 3.6 * (p[5] + p[8]) - 1.8 * (p[3] + p[4]) + 21.6 * p[9] - 1.6 * p[2]) * c1); + ThreadSafeNodeWrite(r_geom[12], WATER_PRESSURE, + (p[1] + p[2] + 7.2 * (p[3] + p[8]) - 3.6 * (p[4] + p[7]) - + 1.8 * (p[5] + p[6]) + 21.6 * p[9] - 1.6 * p[0]) * + c1); + ThreadSafeNodeWrite(r_geom[13], WATER_PRESSURE, + (p[0] + p[2] + 7.2 * (p[4] + p[5]) - 3.6 * (p[3] + p[6]) - + 1.8 * (p[7] + p[8]) + 21.6 * p[9] - 1.6 * p[1]) * + c1); + ThreadSafeNodeWrite(r_geom[14], WATER_PRESSURE, + (p[0] + p[1] + 7.2 * (p[6] + p[7]) - 3.6 * (p[5] + p[8]) - + 1.8 * (p[3] + p[4]) + 21.6 * p[9] - 1.6 * p[2]) * + c1); break; } case 20: // 3D H20P8 @@ -419,7 +422,8 @@ void SmallStrainUPwDiffOrderElement::AssignPressureToIntermediateNodes() ThreadSafeNodeWrite(r_geom[24], WATER_PRESSURE, 0.25 * (p[3] + p[0] + p[7] + p[4])); ThreadSafeNodeWrite(r_geom[25], WATER_PRESSURE, 0.25 * (p[4] + p[5] + p[6] + p[7])); // element center - ThreadSafeNodeWrite(r_geom[26], WATER_PRESSURE, 0.125 * (p[0] + p[1] + p[2] + p[3] + p[4] + p[5] + p[6] + p[7])); + ThreadSafeNodeWrite(r_geom[26], WATER_PRESSURE, + 0.125 * (p[0] + p[1] + p[2] + p[3] + p[4] + p[5] + p[6] + p[7])); break; } default: @@ -542,7 +546,8 @@ void SmallStrainUPwDiffOrderElement::CalculateOnIntegrationPoints(const Variable RetentionParameters.SetFluidPressure(GeoTransportEquationUtilities::CalculateFluidPressure( Variables.Np, Variables.PressureVector)); - rOutput[GPoint] = mRetentionLawVector[GPoint]->CalculateValue(RetentionParameters, rVariable, rOutput[GPoint]); + rOutput[GPoint] = mRetentionLawVector[GPoint]->CalculateValue( + RetentionParameters, rVariable, rOutput[GPoint]); } } else if (rVariable == HYDRAULIC_HEAD) { constexpr double NumericalLimit = std::numeric_limits::epsilon(); diff --git a/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.hpp b/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.hpp index 197a809f9613..fe55156728b3 100644 --- a/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.hpp +++ b/applications/GeoMechanicsApplication/custom_elements/small_strain_U_Pw_diff_order_element.hpp @@ -225,7 +225,7 @@ class KRATOS_API(GEO_MECHANICS_APPLICATION) SmallStrainUPwDiffOrderElement : pub const Matrix& rNContainer) const; Vector GetPressures(size_t n_nodes); - void AssignPressureToIntermediateNodes(); + void AssignPressureToIntermediateNodes(); virtual Vector CalculateGreenLagrangeStrain(const Matrix& rDeformationGradient) const; From 5e78ddde85405ea9c04f1bbb25949094aec14b88 Mon Sep 17 00:00:00 2001 From: mnabideltares Date: Mon, 16 Dec 2024 17:08:14 +0100 Subject: [PATCH 36/36] Set material parameters in a common directory, to avoid file duplications --- .../MaterialParameters_stage1.json | 0 .../MaterialParameters_stage2.json | 0 .../ProjectParameters_stage1.json | 2 +- .../ProjectParameters_stage2.json | 2 +- .../MaterialParameters_stage1.json | 32 ------------------- .../MaterialParameters_stage2.json | 32 ------------------- .../ProjectParameters_stage1.json | 2 +- .../ProjectParameters_stage2.json | 2 +- .../MaterialParameters_stage1.json | 32 ------------------- .../MaterialParameters_stage2.json | 32 ------------------- .../ProjectParameters_stage1.json | 2 +- .../ProjectParameters_stage2.json | 2 +- .../MaterialParameters_stage1.json | 32 ------------------- .../MaterialParameters_stage2.json | 32 ------------------- .../ProjectParameters_stage1.json | 2 +- .../ProjectParameters_stage2.json | 2 +- .../MaterialParameters_stage1.json | 32 ------------------- .../MaterialParameters_stage2.json | 32 ------------------- .../ProjectParameters_stage1.json | 2 +- .../ProjectParameters_stage2.json | 2 +- 20 files changed, 10 insertions(+), 266 deletions(-) rename applications/GeoMechanicsApplication/tests/test_partially_saturated/{test_saturated_below_phreatic_level_pw_triangle3N => Common}/MaterialParameters_stage1.json (100%) rename applications/GeoMechanicsApplication/tests/test_partially_saturated/{test_saturated_below_phreatic_level_pw_triangle3N => Common}/MaterialParameters_stage2.json (100%) delete mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/MaterialParameters_stage1.json delete mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/MaterialParameters_stage2.json delete mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/MaterialParameters_stage1.json delete mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/MaterialParameters_stage2.json delete mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/MaterialParameters_stage1.json delete mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/MaterialParameters_stage2.json delete mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/MaterialParameters_stage1.json delete mode 100644 applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/MaterialParameters_stage2.json diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/MaterialParameters_stage1.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/Common/MaterialParameters_stage1.json similarity index 100% rename from applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/MaterialParameters_stage1.json rename to applications/GeoMechanicsApplication/tests/test_partially_saturated/Common/MaterialParameters_stage1.json diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/MaterialParameters_stage2.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/Common/MaterialParameters_stage2.json similarity index 100% rename from applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/MaterialParameters_stage2.json rename to applications/GeoMechanicsApplication/tests/test_partially_saturated/Common/MaterialParameters_stage2.json diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/ProjectParameters_stage1.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/ProjectParameters_stage1.json index c2e14262a8fd..a2a0c726da96 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/ProjectParameters_stage1.json +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/ProjectParameters_stage1.json @@ -16,7 +16,7 @@ "input_filename" : "column" }, "material_import_settings": { - "materials_filename" : "MaterialParameters_stage1.json" + "materials_filename" : "../Common/MaterialParameters_stage1.json" }, "time_stepping": { "time_step" : 0.1, diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/ProjectParameters_stage2.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/ProjectParameters_stage2.json index 0546a4ad5dbd..3b5ba12534fa 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/ProjectParameters_stage2.json +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle3N/ProjectParameters_stage2.json @@ -16,7 +16,7 @@ "input_filename" : "column" }, "material_import_settings": { - "materials_filename" : "MaterialParameters_stage2.json" + "materials_filename" : "../Common/MaterialParameters_stage2.json" }, "time_stepping": { "time_step" : 0.1, diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/MaterialParameters_stage1.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/MaterialParameters_stage1.json deleted file mode 100644 index fc2e750c8e3b..000000000000 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/MaterialParameters_stage1.json +++ /dev/null @@ -1,32 +0,0 @@ -{ - "properties": [ - { - "properties_id": 0, - "model_part_name": "PorousDomain.Parts_Solid_Grond", - "Material": { - "constitutive_law": { - "name": "GeoLinearElasticPlaneStrain2DLaw" - }, - "Variables": { - "IGNORE_UNDRAINED": true, - "BIOT_COEFFICIENT": 1.0, - "DENSITY_SOLID": 2038.735983690112, - "DENSITY_WATER": 1019.367991845056, - "POROSITY": 0.3, - "BULK_MODULUS_SOLID": 20000000000.0, - "BULK_MODULUS_FLUID": 2200000000.0, - "PERMEABILITY_XX": 1.157E-05, - "PERMEABILITY_YY": 1.157E-05, - "PERMEABILITY_XY": 0.0, - "DYNAMIC_VISCOSITY": 0.001, - "RETENTION_LAW": "SaturatedBelowPhreaticLevelLaw", - "RESIDUAL_SATURATION": 0.001, - "SATURATED_SATURATION": 1.0, - "MINIMUM_RELATIVE_PERMEABILITY": 0.001, - "YOUNG_MODULUS": 1000000000.0, - "POISSON_RATIO": 0.2 - } - } - } - ] -} diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/MaterialParameters_stage2.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/MaterialParameters_stage2.json deleted file mode 100644 index a59003318063..000000000000 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/MaterialParameters_stage2.json +++ /dev/null @@ -1,32 +0,0 @@ -{ - "properties": [ - { - "properties_id": 0, - "model_part_name": "PorousDomain.Parts_Solid_Grond", - "Material": { - "constitutive_law": { - "name": "GeoLinearElasticPlaneStrain2DLaw" - }, - "Variables": { - "IGNORE_UNDRAINED": false, - "BIOT_COEFFICIENT": 1.0, - "DENSITY_SOLID": 2038.735983690112, - "DENSITY_WATER": 1019.367991845056, - "POROSITY": 0.3, - "BULK_MODULUS_SOLID": 20000000000.0, - "BULK_MODULUS_FLUID": 2200000000.0, - "PERMEABILITY_XX": 1.157E-05, - "PERMEABILITY_YY": 1.157E-05, - "PERMEABILITY_XY": 0.0, - "DYNAMIC_VISCOSITY": 0.001, - "RETENTION_LAW": "SaturatedBelowPhreaticLevelLaw", - "RESIDUAL_SATURATION": 0.001, - "SATURATED_SATURATION": 1.0, - "MINIMUM_RELATIVE_PERMEABILITY": 0.001, - "YOUNG_MODULUS": 1000000000.0, - "POISSON_RATIO": 0.2 - } - } - } - ] -} diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/ProjectParameters_stage1.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/ProjectParameters_stage1.json index c2e14262a8fd..a2a0c726da96 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/ProjectParameters_stage1.json +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/ProjectParameters_stage1.json @@ -16,7 +16,7 @@ "input_filename" : "column" }, "material_import_settings": { - "materials_filename" : "MaterialParameters_stage1.json" + "materials_filename" : "../Common/MaterialParameters_stage1.json" }, "time_stepping": { "time_step" : 0.1, diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/ProjectParameters_stage2.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/ProjectParameters_stage2.json index 0546a4ad5dbd..3b5ba12534fa 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/ProjectParameters_stage2.json +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_pw_triangle6N/ProjectParameters_stage2.json @@ -16,7 +16,7 @@ "input_filename" : "column" }, "material_import_settings": { - "materials_filename" : "MaterialParameters_stage2.json" + "materials_filename" : "../Common/MaterialParameters_stage2.json" }, "time_stepping": { "time_step" : 0.1, diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/MaterialParameters_stage1.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/MaterialParameters_stage1.json deleted file mode 100644 index fc2e750c8e3b..000000000000 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/MaterialParameters_stage1.json +++ /dev/null @@ -1,32 +0,0 @@ -{ - "properties": [ - { - "properties_id": 0, - "model_part_name": "PorousDomain.Parts_Solid_Grond", - "Material": { - "constitutive_law": { - "name": "GeoLinearElasticPlaneStrain2DLaw" - }, - "Variables": { - "IGNORE_UNDRAINED": true, - "BIOT_COEFFICIENT": 1.0, - "DENSITY_SOLID": 2038.735983690112, - "DENSITY_WATER": 1019.367991845056, - "POROSITY": 0.3, - "BULK_MODULUS_SOLID": 20000000000.0, - "BULK_MODULUS_FLUID": 2200000000.0, - "PERMEABILITY_XX": 1.157E-05, - "PERMEABILITY_YY": 1.157E-05, - "PERMEABILITY_XY": 0.0, - "DYNAMIC_VISCOSITY": 0.001, - "RETENTION_LAW": "SaturatedBelowPhreaticLevelLaw", - "RESIDUAL_SATURATION": 0.001, - "SATURATED_SATURATION": 1.0, - "MINIMUM_RELATIVE_PERMEABILITY": 0.001, - "YOUNG_MODULUS": 1000000000.0, - "POISSON_RATIO": 0.2 - } - } - } - ] -} diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/MaterialParameters_stage2.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/MaterialParameters_stage2.json deleted file mode 100644 index a59003318063..000000000000 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/MaterialParameters_stage2.json +++ /dev/null @@ -1,32 +0,0 @@ -{ - "properties": [ - { - "properties_id": 0, - "model_part_name": "PorousDomain.Parts_Solid_Grond", - "Material": { - "constitutive_law": { - "name": "GeoLinearElasticPlaneStrain2DLaw" - }, - "Variables": { - "IGNORE_UNDRAINED": false, - "BIOT_COEFFICIENT": 1.0, - "DENSITY_SOLID": 2038.735983690112, - "DENSITY_WATER": 1019.367991845056, - "POROSITY": 0.3, - "BULK_MODULUS_SOLID": 20000000000.0, - "BULK_MODULUS_FLUID": 2200000000.0, - "PERMEABILITY_XX": 1.157E-05, - "PERMEABILITY_YY": 1.157E-05, - "PERMEABILITY_XY": 0.0, - "DYNAMIC_VISCOSITY": 0.001, - "RETENTION_LAW": "SaturatedBelowPhreaticLevelLaw", - "RESIDUAL_SATURATION": 0.001, - "SATURATED_SATURATION": 1.0, - "MINIMUM_RELATIVE_PERMEABILITY": 0.001, - "YOUNG_MODULUS": 1000000000.0, - "POISSON_RATIO": 0.2 - } - } - } - ] -} diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/ProjectParameters_stage1.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/ProjectParameters_stage1.json index caf39a9d2d15..0d730ce3696d 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/ProjectParameters_stage1.json +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/ProjectParameters_stage1.json @@ -16,7 +16,7 @@ "input_filename" : "column" }, "material_import_settings": { - "materials_filename" : "MaterialParameters_stage1.json" + "materials_filename" : "../Common/MaterialParameters_stage1.json" }, "time_stepping": { "time_step" : 0.1, diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/ProjectParameters_stage2.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/ProjectParameters_stage2.json index 165be4e61562..1079fd8ccbfd 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/ProjectParameters_stage2.json +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_difforder_triangle6n/ProjectParameters_stage2.json @@ -16,7 +16,7 @@ "input_filename" : "column" }, "material_import_settings": { - "materials_filename" : "MaterialParameters_stage2.json" + "materials_filename" : "../Common/MaterialParameters_stage2.json" }, "time_stepping": { "time_step" : 0.1, diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/MaterialParameters_stage1.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/MaterialParameters_stage1.json deleted file mode 100644 index fc2e750c8e3b..000000000000 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/MaterialParameters_stage1.json +++ /dev/null @@ -1,32 +0,0 @@ -{ - "properties": [ - { - "properties_id": 0, - "model_part_name": "PorousDomain.Parts_Solid_Grond", - "Material": { - "constitutive_law": { - "name": "GeoLinearElasticPlaneStrain2DLaw" - }, - "Variables": { - "IGNORE_UNDRAINED": true, - "BIOT_COEFFICIENT": 1.0, - "DENSITY_SOLID": 2038.735983690112, - "DENSITY_WATER": 1019.367991845056, - "POROSITY": 0.3, - "BULK_MODULUS_SOLID": 20000000000.0, - "BULK_MODULUS_FLUID": 2200000000.0, - "PERMEABILITY_XX": 1.157E-05, - "PERMEABILITY_YY": 1.157E-05, - "PERMEABILITY_XY": 0.0, - "DYNAMIC_VISCOSITY": 0.001, - "RETENTION_LAW": "SaturatedBelowPhreaticLevelLaw", - "RESIDUAL_SATURATION": 0.001, - "SATURATED_SATURATION": 1.0, - "MINIMUM_RELATIVE_PERMEABILITY": 0.001, - "YOUNG_MODULUS": 1000000000.0, - "POISSON_RATIO": 0.2 - } - } - } - ] -} diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/MaterialParameters_stage2.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/MaterialParameters_stage2.json deleted file mode 100644 index a59003318063..000000000000 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/MaterialParameters_stage2.json +++ /dev/null @@ -1,32 +0,0 @@ -{ - "properties": [ - { - "properties_id": 0, - "model_part_name": "PorousDomain.Parts_Solid_Grond", - "Material": { - "constitutive_law": { - "name": "GeoLinearElasticPlaneStrain2DLaw" - }, - "Variables": { - "IGNORE_UNDRAINED": false, - "BIOT_COEFFICIENT": 1.0, - "DENSITY_SOLID": 2038.735983690112, - "DENSITY_WATER": 1019.367991845056, - "POROSITY": 0.3, - "BULK_MODULUS_SOLID": 20000000000.0, - "BULK_MODULUS_FLUID": 2200000000.0, - "PERMEABILITY_XX": 1.157E-05, - "PERMEABILITY_YY": 1.157E-05, - "PERMEABILITY_XY": 0.0, - "DYNAMIC_VISCOSITY": 0.001, - "RETENTION_LAW": "SaturatedBelowPhreaticLevelLaw", - "RESIDUAL_SATURATION": 0.001, - "SATURATED_SATURATION": 1.0, - "MINIMUM_RELATIVE_PERMEABILITY": 0.001, - "YOUNG_MODULUS": 1000000000.0, - "POISSON_RATIO": 0.2 - } - } - } - ] -} diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/ProjectParameters_stage1.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/ProjectParameters_stage1.json index 731234fe8031..9b6698c89340 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/ProjectParameters_stage1.json +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/ProjectParameters_stage1.json @@ -16,7 +16,7 @@ "input_filename" : "column" }, "material_import_settings": { - "materials_filename" : "MaterialParameters_stage1.json" + "materials_filename" : "../Common/MaterialParameters_stage1.json" }, "time_stepping": { "time_step" : 0.1, diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/ProjectParameters_stage2.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/ProjectParameters_stage2.json index e247ccfd3fa3..19952e0c3d26 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/ProjectParameters_stage2.json +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle3n/ProjectParameters_stage2.json @@ -16,7 +16,7 @@ "input_filename" : "column" }, "material_import_settings": { - "materials_filename" : "MaterialParameters_stage2.json" + "materials_filename" : "../Common/MaterialParameters_stage2.json" }, "time_stepping": { "time_step" : 0.1, diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/MaterialParameters_stage1.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/MaterialParameters_stage1.json deleted file mode 100644 index fc2e750c8e3b..000000000000 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/MaterialParameters_stage1.json +++ /dev/null @@ -1,32 +0,0 @@ -{ - "properties": [ - { - "properties_id": 0, - "model_part_name": "PorousDomain.Parts_Solid_Grond", - "Material": { - "constitutive_law": { - "name": "GeoLinearElasticPlaneStrain2DLaw" - }, - "Variables": { - "IGNORE_UNDRAINED": true, - "BIOT_COEFFICIENT": 1.0, - "DENSITY_SOLID": 2038.735983690112, - "DENSITY_WATER": 1019.367991845056, - "POROSITY": 0.3, - "BULK_MODULUS_SOLID": 20000000000.0, - "BULK_MODULUS_FLUID": 2200000000.0, - "PERMEABILITY_XX": 1.157E-05, - "PERMEABILITY_YY": 1.157E-05, - "PERMEABILITY_XY": 0.0, - "DYNAMIC_VISCOSITY": 0.001, - "RETENTION_LAW": "SaturatedBelowPhreaticLevelLaw", - "RESIDUAL_SATURATION": 0.001, - "SATURATED_SATURATION": 1.0, - "MINIMUM_RELATIVE_PERMEABILITY": 0.001, - "YOUNG_MODULUS": 1000000000.0, - "POISSON_RATIO": 0.2 - } - } - } - ] -} diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/MaterialParameters_stage2.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/MaterialParameters_stage2.json deleted file mode 100644 index a59003318063..000000000000 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/MaterialParameters_stage2.json +++ /dev/null @@ -1,32 +0,0 @@ -{ - "properties": [ - { - "properties_id": 0, - "model_part_name": "PorousDomain.Parts_Solid_Grond", - "Material": { - "constitutive_law": { - "name": "GeoLinearElasticPlaneStrain2DLaw" - }, - "Variables": { - "IGNORE_UNDRAINED": false, - "BIOT_COEFFICIENT": 1.0, - "DENSITY_SOLID": 2038.735983690112, - "DENSITY_WATER": 1019.367991845056, - "POROSITY": 0.3, - "BULK_MODULUS_SOLID": 20000000000.0, - "BULK_MODULUS_FLUID": 2200000000.0, - "PERMEABILITY_XX": 1.157E-05, - "PERMEABILITY_YY": 1.157E-05, - "PERMEABILITY_XY": 0.0, - "DYNAMIC_VISCOSITY": 0.001, - "RETENTION_LAW": "SaturatedBelowPhreaticLevelLaw", - "RESIDUAL_SATURATION": 0.001, - "SATURATED_SATURATION": 1.0, - "MINIMUM_RELATIVE_PERMEABILITY": 0.001, - "YOUNG_MODULUS": 1000000000.0, - "POISSON_RATIO": 0.2 - } - } - } - ] -} diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/ProjectParameters_stage1.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/ProjectParameters_stage1.json index 731234fe8031..9b6698c89340 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/ProjectParameters_stage1.json +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/ProjectParameters_stage1.json @@ -16,7 +16,7 @@ "input_filename" : "column" }, "material_import_settings": { - "materials_filename" : "MaterialParameters_stage1.json" + "materials_filename" : "../Common/MaterialParameters_stage1.json" }, "time_stepping": { "time_step" : 0.1, diff --git a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/ProjectParameters_stage2.json b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/ProjectParameters_stage2.json index 5e37cffcff18..f3be1c44d9b6 100644 --- a/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/ProjectParameters_stage2.json +++ b/applications/GeoMechanicsApplication/tests/test_partially_saturated/test_saturated_below_phreatic_level_upw_smallstrain_triangle6n/ProjectParameters_stage2.json @@ -16,7 +16,7 @@ "input_filename" : "column" }, "material_import_settings": { - "materials_filename" : "MaterialParameters_stage2.json" + "materials_filename" : "../Common/MaterialParameters_stage2.json" }, "time_stepping": { "time_step" : 0.1,