Skip to content
Snippets Groups Projects
Commit ca83341c authored by Klaus Böhnlein's avatar Klaus Böhnlein
Browse files

Add more Timers

parent e0f7b025
No related branches found
No related tags found
No related merge requests found
...@@ -941,7 +941,6 @@ public: ...@@ -941,7 +941,6 @@ public:
// --- Solving the Corrector-problem: // --- Solving the Corrector-problem:
auto solve() auto solve()
{ {
std::cout << "start corrector solver..." << std::endl;
bool set_oneBasisFunction_Zero = parameterSet_.get<bool>("set_oneBasisFunction_Zero", false); bool set_oneBasisFunction_Zero = parameterSet_.get<bool>("set_oneBasisFunction_Zero", false);
bool substract_integralMean = false; bool substract_integralMean = false;
if(parameterSet_.get<bool>("set_IntegralZero", false)) if(parameterSet_.get<bool>("set_IntegralZero", false))
...@@ -977,6 +976,7 @@ public: ...@@ -977,6 +976,7 @@ public:
x_2_ = load_alpha2_; x_2_ = load_alpha2_;
x_3_ = load_alpha3_; x_3_ = load_alpha3_;
std::cout << "start corrector solver..." << std::endl;
Dune::Timer SolverTimer; Dune::Timer SolverTimer;
if (Solvertype==1) // CG - SOLVER if (Solvertype==1) // CG - SOLVER
{ {
...@@ -1334,6 +1334,7 @@ public: ...@@ -1334,6 +1334,7 @@ public:
// --- Check Orthogonality relation Paper (75) // --- Check Orthogonality relation Paper (75)
auto check_Orthogonality() auto check_Orthogonality()
{ {
Dune::Timer orthogonalityTimer;
std::cout << "Check Orthogonality..." << std::endl; std::cout << "Check Orthogonality..." << std::endl;
auto localView = basis_.localView(); auto localView = basis_.localView();
...@@ -1436,11 +1437,11 @@ public: ...@@ -1436,11 +1437,11 @@ public:
std::cout << "WARNING: check_Orthogonality failed! apparently orthogonality (75) not satisfied on discrete level" << std::endl; std::cout << "WARNING: check_Orthogonality failed! apparently orthogonality (75) not satisfied on discrete level" << std::endl;
} }
std::cout << "Time required for orthogonality check: " << orthogonalityTimer.elapsed() << std::endl;
return 0; return 0;
} }
// --- Check whether stiffness matrix is symmetric // --- Check whether stiffness matrix is symmetric
void checkSymmetry() void checkSymmetry()
{ {
......
...@@ -58,8 +58,6 @@ public: ...@@ -58,8 +58,6 @@ public:
{ {
// prestrain_ = material_.getPrestrainFunction(); // prestrain_ = material_.getPrestrainFunction();
} }
...@@ -76,8 +74,8 @@ public: ...@@ -76,8 +74,8 @@ public:
// --- Compute Effective Quantities // --- Compute Effective Quantities
void computeEffectiveQuantities() void computeEffectiveQuantities()
{ {
std::cout << "starting effective quantities computation..." << std::endl; std::cout << "starting effective quantities computation..." << std::endl;
Dune::Timer effectiveQuantitiesTimer;
// Get everything.. better TODO: with Inheritance? // Get everything.. better TODO: with Inheritance?
// auto test = correctorComputer_.getLoad_alpha1(); // auto test = correctorComputer_.getLoad_alpha1();
...@@ -232,6 +230,7 @@ public: ...@@ -232,6 +230,7 @@ public:
// TEST // TEST
// std::cout << std::setprecision(std::numeric_limits<float_50>::digits10) << higherPrecEnergy << std::endl; // std::cout << std::setprecision(std::numeric_limits<float_50>::digits10) << higherPrecEnergy << std::endl;
std::cout << "Time required to solve for effective quantities: " << effectiveQuantitiesTimer.elapsed() << std::endl;
return ; return ;
} }
......
...@@ -280,9 +280,7 @@ int main(int argc, char *argv[]) ...@@ -280,9 +280,7 @@ int main(int argc, char *argv[])
//--- write material indicator function to VTK //--- write material indicator function to VTK
if (parameterSet.get<bool>("write_materialFunctions", false)) if (parameterSet.get<bool>("write_materialFunctions", false))
{
material.writeVTKMaterialFunctions(level); material.writeVTKMaterialFunctions(level);
}
//--- TEST:: Compute Qeff without using the orthogonality (75)... //--- TEST:: Compute Qeff without using the orthogonality (75)...
// only really makes a difference whenever the orthogonality is not satisfied! // only really makes a difference whenever the orthogonality is not satisfied!
...@@ -295,6 +293,9 @@ int main(int argc, char *argv[]) ...@@ -295,6 +293,9 @@ int main(int argc, char *argv[])
printmatrix(std::cout, Qeff, "Matrix Qeff", "--"); printmatrix(std::cout, Qeff, "Matrix Qeff", "--");
printvector(std::cout, Beff, "Beff", "--"); printvector(std::cout, Beff, "Beff", "--");
//--- write effective quantities to matlab folder (for symbolic minimization) //--- write effective quantities to matlab folder (for symbolic minimization)
if(parameterSet.get<bool>("write_toMATLAB", false)) if(parameterSet.get<bool>("write_toMATLAB", false))
effectiveQuantitiesComputer.writeToMatlab(outputPath); effectiveQuantitiesComputer.writeToMatlab(outputPath);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment