normalized ALF (Assotiated Legendre Function)

Ben Abbott bpabbott at mac.com
Wed Feb 13 09:40:58 CST 2008


On Wednesday, February 13, 2008, at 09:58AM, "Marco Caliari" <marco.caliari at univr.it> wrote:
>I discovered that the warning is misleading. Consider
>
>legendre(151,0)
>
>The last entry is -Inf and the script "should" returns a warning (you 
>should replace scale == inf with abs(scale) == inf). But, there is no 
>instability: the value -Inf is "right", in the sense that it is too large 
>in magnitude to be represented. Now consider
>
>legendre(151,eps)
>
>Again a warning (due to the check on a and b), but, again, no instability.
>
>Moreover, Matlab has no warnings and it is less robust. Consider
>
>legendre(151,-0.9)
>
>in Matlab and with the script now enclosed. To conclude, I would suggest 
>to leave the warnings out.
>
>Marco
>

ok.

I'll begin adding some tests and include on for "legendre(151,0) == Inf".

If you have any other good examples, feel free to post them!

Ben


More information about the Help-octave mailing list