I'm looking for an efficient implementation of the function
pow(a, b), where
a is limited to the interval
>= 1 (both are real numbers—i.e., not necessarily integers).
If it helps,
b is not a high number—let's say it is less than 10-20. That would open up the possibility of solving this problem iteratively, with a small number of iterations ~=
The code should work on a 32-bit microcontroller, possibly without a floating-point unit (i.e., using a fixed-point implementation).
How can I implement such a function, optimized for the following constraints? I'm looking for the algorithm itself, so pseudocode is acceptable.