Make tolerances in checkGeometry depending on ctype
Summary
Replaces fixed tolerances 1.e-8
with ctype dependent tolerance
Details
Tests with geometries using float
as ctype
may fail to reach the desired fixed tolerance 1.e-8
. This is corrected by using the tolerance=sqrt(numeric_limits<ctype>::epsilon())
value. This value gives approximately
-
tolerance<double> = 1.5e-8
and tolerance<float> = 3.5e-4
and thus previous test runs with ctype=double
should also pass the test with this change.
Edited by Simon Praetorius