[Speex-dev] math_approx.c
Oleg Homenko
beeb at palmosters.com
Wed Aug 1 05:33:29 PDT 2007
Jean-Marc Valin wrote on 8/1/2007 2:26 PM:
>> Hi,
>> I started to optimize math_approx fixed point functions to ARM CPU. And
>> found out that approximations are not Taylor series,
>>
>
> That's right.
>
> for example:
>
>> spx_exp2(x) = D0 + D1*x + D2*x^2 +D3*x^3,
>> where D0 = 1, D1 = log(2), D2 = (log(2))^2 / 2, D3 = (log(2))^3 / 6 for
>> Taylor serie,
>> but Speex source code uses different coefficients:
>> D0 = 1, D1 = log(2), D2 = 3 - 4*log(2), D3 = 3*log(2) - 2
>>
>> Can anyone explain the difference? Was it done to equalize error along
>> range? How were obtained D2 and D3?
>>
>
> It's actually a polynomial fit. That's better than Taylor series
> because, as you say, the error is better distributed.
>
> Jean-Marc
Thanks Jean-Marc!
Could you please give me any links to the pages with theory?
Oleg
More information about the Speex-dev
mailing list