SourceXtractorPlusPlus 1.0.3
SourceXtractor++, the next generation SExtractor
Loading...
Searching...
No Matches
IsClose.h
Go to the documentation of this file.
1
22
23#ifndef SEUTILS_ISCLOSE_H
24#define SEUTILS_ISCLOSE_H
25
26namespace SourceXtractor {
27
28bool isClose(double a, double b, double atol = 1e-8, double rtol = 1e-5) {
29 return std::abs(a - b) <= (atol + rtol * std::abs(b));
30}
31
32} // end SourceXtractor
33
34#endif // SEUTILS_ISCLOSE_H
T atol(T... args)
bool isClose(double a, double b, double atol=1e-8, double rtol=1e-5)
Definition IsClose.h:28