Skip to content
Snippets Groups Projects
Commit 198d48f4 authored by Elias Pipping's avatar Elias Pipping Committed by Elias Pipping
Browse files

Make printing of the difference optional

parent 57cb7f77
No related branches found
No related tags found
No related merge requests found
...@@ -419,20 +419,22 @@ int main(int argc, char *argv[]) { ...@@ -419,20 +419,22 @@ int main(int argc, char *argv[]) {
} }
std::cout << std::endl; std::cout << std::endl;
VectorType diff2 = u2; if (parset.get<bool>("printDifference")) {
diff2 -= u1; VectorType diff2 = u2;
std::cout << "sup |u1 - u2| = " << diff2.infinity_norm() << ", " diff2 -= u1;
<< "|u1 - u2| = " << diff2.two_norm() << std::endl; std::cout << "sup |u1 - u2| = " << diff2.infinity_norm() << ", "
<< "|u1 - u2| = " << diff2.two_norm() << std::endl;
VectorType diff3 = u3;
diff3 -= u1; VectorType diff3 = u3;
std::cout << "sup |u1 - u3| = " << diff3.infinity_norm() << ", " diff3 -= u1;
<< "|u1 - u3| = " << diff3.two_norm() << std::endl; std::cout << "sup |u1 - u3| = " << diff3.infinity_norm() << ", "
<< "|u1 - u3| = " << diff3.two_norm() << std::endl;
VectorType diff4 = u4;
diff4 -= u1; VectorType diff4 = u4;
std::cout << "sup |u1 - u4| = " << diff4.infinity_norm() << ", " diff4 -= u1;
<< "|u1 - u4| = " << diff4.two_norm() << std::endl; std::cout << "sup |u1 - u4| = " << diff4.infinity_norm() << ", "
<< "|u1 - u4| = " << diff4.two_norm() << std::endl;
}
if (parset.get<bool>("printFrictionalBoundary")) { if (parset.get<bool>("printFrictionalBoundary")) {
// Print displacement on frictional boundary // Print displacement on frictional boundary
......
...@@ -4,6 +4,7 @@ timesteps = 100 ...@@ -4,6 +4,7 @@ timesteps = 100
verbose = false verbose = false
printFrictionalBoundary = false printFrictionalBoundary = false
printProgress = true printProgress = true
printDifference = false
useNonlinearGS = false # true useNonlinearGS = false # true
useGS = false useGS = false
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment