Associated legendre polynomials fail after certain degree
古いコメントを表示
Hi,
I am using legendre polynomials for an application on spherical harmonics. However the code
legendre(170,0.5)
where 170 is the degree/order fail, giving me Inf or NaN. Is this considered a bug or is there way to aid the issue using higher precision somehow?
Best
採用された回答
その他の回答 (1 件)
Walter Roberson
2017 年 12 月 16 日
0 投票
If you have the symbolic toolbox you can work with it
2 件のコメント
ailbeildce
2017 年 12 月 17 日
編集済み: ailbeildce
2017 年 12 月 17 日
Walter Roberson
2017 年 12 月 17 日
For integer m you can see https://en.wikipedia.org/wiki/Associated_Legendre_polynomials#Definition_for_non-negative_integer_parameters_%E2%84%93_and_m which the formula given in terms of derivatives. As the different orders correspond to different numbers of derivatives of the Legendre polynomial, you can find the different orders in a loop.
カテゴリ
ヘルプ センター および File Exchange で Polynomials についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!