From 97728cae911b4e5fa323cc3898ba2509108d2d3f Mon Sep 17 00:00:00 2001 From: Dmitri Naumov Date: Mon, 16 Oct 2023 16:05:14 +0200 Subject: [PATCH 1/3] [PL/SD] east-const --- ProcessLib/SmallDeformation/SmallDeformationProcess.cpp | 8 ++++---- ProcessLib/SmallDeformation/SmallDeformationProcess.h | 6 +++--- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/ProcessLib/SmallDeformation/SmallDeformationProcess.cpp b/ProcessLib/SmallDeformation/SmallDeformationProcess.cpp index bed27c80494..0bd5602d085 100644 --- a/ProcessLib/SmallDeformation/SmallDeformationProcess.cpp +++ b/ProcessLib/SmallDeformation/SmallDeformationProcess.cpp @@ -133,7 +133,7 @@ void SmallDeformationProcess::initializeConcreteProcess( template void SmallDeformationProcess::assembleConcreteProcess( - const double t, double const dt, std::vector const& x, + double const t, double const dt, std::vector const& x, std::vector const& x_prev, int const process_id, GlobalMatrix& M, GlobalMatrix& K, GlobalVector& b) { @@ -155,7 +155,7 @@ void SmallDeformationProcess::assembleConcreteProcess( template void SmallDeformationProcess:: assembleWithJacobianConcreteProcess( - const double t, double const dt, std::vector const& x, + double const t, double const dt, std::vector const& x, std::vector const& x_prev, int const process_id, GlobalMatrix& M, GlobalMatrix& K, GlobalVector& b, GlobalMatrix& Jac) { @@ -180,7 +180,7 @@ void SmallDeformationProcess:: template void SmallDeformationProcess::postTimestepConcreteProcess( std::vector const& x, - std::vector const& x_prev, const double t, const double dt, + std::vector const& x_prev, double const t, double const dt, int const process_id) { DBUG("PostTimestep SmallDeformationProcess."); @@ -206,7 +206,7 @@ void SmallDeformationProcess::postTimestepConcreteProcess( template void SmallDeformationProcess::computeSecondaryVariableConcrete( double const t, double const dt, std::vector const& x, - GlobalVector const& x_prev, const int process_id) + GlobalVector const& x_prev, int const process_id) { DBUG("Compute the secondary variables for SmallDeformationProcess."); std::vector dof_tables; diff --git a/ProcessLib/SmallDeformation/SmallDeformationProcess.h b/ProcessLib/SmallDeformation/SmallDeformationProcess.h index 4618f7baeaa..fa31d7ad7d8 100644 --- a/ProcessLib/SmallDeformation/SmallDeformationProcess.h +++ b/ProcessLib/SmallDeformation/SmallDeformationProcess.h @@ -49,7 +49,7 @@ class SmallDeformationProcess final : public Process MeshLib::Mesh const& mesh, unsigned const integration_order) override; - void assembleConcreteProcess(const double t, double const dt, + void assembleConcreteProcess(double const t, double const dt, std::vector const& x, std::vector const& x_prev, int const process_id, GlobalMatrix& M, @@ -63,13 +63,13 @@ class SmallDeformationProcess final : public Process void postTimestepConcreteProcess(std::vector const& x, std::vector const& x_prev, - const double t, const double dt, + double const t, double const dt, int const process_id) override; void computeSecondaryVariableConcrete(double const t, double const dt, std::vector const& x, GlobalVector const& x_prev, - const int process_id) override; + int const process_id) override; private: SmallDeformationProcessData _process_data; From df7d9b19bad9ffb67f3fb9e5fc9603b42101701b Mon Sep 17 00:00:00 2001 From: Dmitri Naumov Date: Fri, 20 Oct 2023 17:44:08 +0200 Subject: [PATCH 2/3] [PL] Set high precision for matrix debug output --- ProcessLib/Assembly/MatrixOutput.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ProcessLib/Assembly/MatrixOutput.cpp b/ProcessLib/Assembly/MatrixOutput.cpp index 5eaa76d2a2c..1459d052855 100644 --- a/ProcessLib/Assembly/MatrixOutput.cpp +++ b/ProcessLib/Assembly/MatrixOutput.cpp @@ -33,14 +33,14 @@ std::string getSeparatorAfterFilenamePrefix(std::string const& filenamePrefix) #ifndef USE_PETSC static void outputGlobalMatrix(GlobalMatrix const& mat, std::ostream& os) { - os << "(" << mat.getNumberOfRows() << " x " << mat.getNumberOfColumns() - << ")\n"; + os << std::setprecision(16) << "(" << mat.getNumberOfRows() << " x " + << mat.getNumberOfColumns() << ")\n"; mat.write(os); } static void outputGlobalVector(GlobalVector const& vec, std::ostream& os) { - os << "(" << vec.size() << ")\n"; + os << std::setprecision(16) << "(" << vec.size() << ")\n"; os << vec.getRawVector() << '\n'; } From ec732c434291dab3cabb6b4aa9edc132167540d2 Mon Sep 17 00:00:00 2001 From: Dmitri Naumov Date: Tue, 24 Oct 2023 15:37:07 +0200 Subject: [PATCH 3/3] [T/TRM] Slightly relax tolerance --- Tests/Data/ThermoRichardsMechanics/MFront/A2/A2.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Tests/Data/ThermoRichardsMechanics/MFront/A2/A2.xml b/Tests/Data/ThermoRichardsMechanics/MFront/A2/A2.xml index 9d05717fdb6..1f6b762ff77 100644 --- a/Tests/Data/ThermoRichardsMechanics/MFront/A2/A2.xml +++ b/Tests/Data/ThermoRichardsMechanics/MFront/A2/A2.xml @@ -109,6 +109,6 @@ - 7e-10 + 1e-9