Algorithms_in_C++ 1.0.0
Set of algorithms implemented in C++.
|
for vector
More...
Functions | |
bool | are_almost_equal (double a, double b, double absolute_tolerance=0.0001) |
Compare two floating point numbers with a certain tolerance. This is needed as with some values, the result (e.g.: -196.15) might be a bit lower (in this case, -196.499999...). | |
double | kelvin_to_celsius (double temperature_in_k) |
Conversion from Kelvin to Celsius algorithm. | |
for vector
for vector
Other algorithms.
for IO operations
for reverse
for assert
for I/O operations for stack
Other algorithms
for assert for std::abs
Other algorithms
for assert for IO Operations for std::list
Other algorithms
for assert for std::uint64_t for I/O operations
Other algorithms
bool others::are_almost_equal | ( | double | a, |
double | b, | ||
double | absolute_tolerance = 0.0001 ) |
Compare two floating point numbers with a certain tolerance. This is needed as with some values, the result (e.g.: -196.15) might be a bit lower (in this case, -196.499999...).
a | the first number to compare |
b | the second number to compare |
tolerance | the tolerance to use when comparing the numbers |
double others::kelvin_to_celsius | ( | double | temperature_in_k | ) |
Conversion from Kelvin to Celsius algorithm.
number | the Celsius number that will be used to convert |