Message Boards Message Boards

0
|
2596 Views
|
5 Replies
|
1 Total Likes
View groups...
Share
Share this post:

Ploting LegendreP gets abruptly noisy for larger numbers?

Posted 3 years ago

Hi there,

I'm trying to plot the graph for LegendreP[70+3/2,3/2,x] for x between -1 to 1.

But it looks very bad. if ones try it for 60+3/2 it looks good. Why does it happen, and is there something to do about it?

Thanks!

POSTED BY: major son
5 Replies
Posted 3 years ago

Yes! it definitely gets the job done. Thank you!

POSTED BY: major son

Machine-precision might not be enough. But can easily be solved by using more precision, e.g.:

Plot[LegendreP[70 + 3/2, 3/2, x], {x, -1, -0.9}, WorkingPrecision -> 30, PlotPoints -> 100]
POSTED BY: Sander Huisman
Posted 3 years ago

it is Mathematica 12.0.

The code I use to plot is: Plot[LegendreP[70 + 3/2, -3/2, x], {x, -1, 1}, ]

Look at my attachment. for n=65+3/2 it already show some noise. But for n=70+3/2 it is complete garbage. I tried using PlotPoints with a big number (4000) but it will not help.

Note: I had a typo in the legendre order: it is minus 3/2.

What do you think? Is there a way to plot larger and larger degrees of the LegendreP?

Thanks!

Attachment

Attachment

Attachments:
POSTED BY: major son

Version? Mathematica or WolframAlpha? Code to plot?

POSTED BY: Sander Huisman
Plot[LegendreP[70 + 3/2, 3/2, x], {x, -1, 1}, PlotPoints -> 100]

enter image description here

seems fine for Mathematica V12.2 MacOS.

POSTED BY: Sander Huisman
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract