Hi Nikolai. ;) > Dmitry, could you please explain how to apply CORDIC to exponential > function? I'm not promising alot but as only will have 20 free minutes to go other office location I will search for those docs in backed up database of file server. I remember that there were many articles in the past how to apply CORDIC for non standart math functions and hopefully for exponential too. (There was a discussion somewhere that CORDIC can be applied for that but doubled iterations are required for some cases) > I just recently started to learn about that algorithm and how to use > it for magnitude, phase, sine and cosine calculations. But I would > like to learn how to use CORDIC for other elementary math. Not much > pointers on the net :( Try altavista with: +CORDIC +"math*" +"exponent*" I guess it should works. I played with CORDIC together with vertical math to significantly reduce code size and execution time for some correlation based signal detection. Because it is very easy to do number shifting in vertical math. Special thanks to Scott Dattalo and John Payson. You guys opened a door for me into such a upside down beautiful world ;) > BTW, it doesn't look so good for magnitude calculation. It takes > around 1500 cycles for PIC to find sqrt(x^2+y^2), where x, y are 16 > bit signed numbers. Probably, using good square and square root > routines would be faster in that case. 1500 is sounding too long.. Probably you are doing correction on every iteration not finally ? I'll be curious to look your code if that is possible. Looks like a good candidate for optimization ;) WBR Dmitry. -- http://www.piclist.com hint: To leave the PICList mailto:piclist-unsubscribe-request@mitvma.mit.edu