Some functions did clobber the registers, thus nesting functions calls like fp64_mul(fp64_div(a,b),c) did not working correctly, when b or c where constants or variables.
Based on a proposal by @gjlayde on https://www.mikrocontroller.net/topic/85256#6137882, speed of fp64_sin could be improved by another 45%, using an optimized polynomial approximation for x in range [0,PI/2[.
Based on a proposal by @gjlayde on https://www.mikrocontroller.net/topic/85256#6133370, speed of fp64_log could be improved by another 40%. Instead of approximating log(x) in the range [1;2[, it is faster to approximate it in [1/sqrt(2); sqrt(2)] with same accuracy.
V1.1.3 is available for download, fixing a linker relocation error.
Fixed incorrect library.properties file.
V1.1.0 contained an linker symbol that was no longer available, V1.1.1 corrects that bug.
All basic functions were restructured to allow access to full internal 56-bit precision. This was necessary to completely rewrite all trigonometric functions and to update logarithm and exponential functions. As a result, most higher math functions (like sin, cos, tan, asin, acos, atan, log and exp) have now increased precision and reduced execution time, still with small code size. As an example, execution time for fp64_sin is now between 600 and 650 micro seconds on a standard, 16 MHz Arduino MEGA 2560 – or 9500 to 10500 ticks (instructions).
V1.1.0 also includes some minor bugfixes and code improvements.
fp64lib is tested and released now also for the Arduino Mega 2560. Furthermore, a rounding bug in fp64_to_string was fixed.
Just a minor update to fix segment name and an obsolete function.
I fixed a bug that caused incorrect rounding when there was a carry over across all digits, including the one before the decimal point. Check out the latest version via the Arduino library manager.