From 4a8ba59bb14ac0ffe996f6c0dffd4f9f86d1a492 Mon Sep 17 00:00:00 2001 From: wolf Date: Fri, 8 Apr 2005 21:49:05 +0000 Subject: [PATCH] Explain. git-svn-id: https://svn.dealii.org/trunk@10454 0785d39b-7218-0410-832d-ea1e28bc413d --- deal.II/base/include/base/logstream.h | 33 +++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) diff --git a/deal.II/base/include/base/logstream.h b/deal.II/base/include/base/logstream.h index f765e022ce..bc34b2d05a 100644 --- a/deal.II/base/include/base/logstream.h +++ b/deal.II/base/include/base/logstream.h @@ -190,6 +190,39 @@ class LogStream * double values. All numbers * with a smaller absolute value * will be printed as zero. + * + * The default value for this + * threshold is zero, + * i.e. numbers are printed + * according to their real value. + * + * This feature is mostly useful + * for automated tests: there, + * one would like to reproduce + * the exact same solution in + * each run of a + * testsuite. However, subtle + * difference in processor, + * operating system, or compiler + * version can lead to + * differences in the last few + * digits of numbers, due to + * different rounding. While one + * can avoid trouble for most + * numbers when comparing with + * stored results by simply + * limiting the accuracy of + * output, this does not hold for + * numbers very close to zero, + * i.e. zero plus accumulated + * round-off. For these numbers, + * already the first digit is + * tainted by round-off. Using + * the present function, it is + * possible to eliminate this + * source of problems, by simply + * writing zero to the output in + * this case. */ void threshold_double(const double t); -- 2.39.5