Expanding an f(x) in terms of Legendre Polynomials

Join the discussion
Registration is free. Start your own thread to ask a follow-up.
3 replies · 11K views
mliuzzolino
Messages
58
Reaction score
0

Homework Statement



Expand f(x) = 1 - x2 on -1 < x < +1 in terms of Legendre polynomials.

Homework Equations


The Attempt at a Solution



Unfortunately, I missed the class where this was explained and I have other classes during my professor's office hours. I have no idea how to begin this...
 
Last edited:
Physics news on Phys.org
As 1 - x² is only a quadratic function you could first try doing it by trial-and-error, knowing that
[tex]P_0(x) = 1, P_1(x) = x, P_2(x) = \tfrac12(3x^2 - 1)[/tex]
which should give you the right answer after you give it some thought.

More formally, there is an expansion along the lines of
[tex]f(x) = \sum_{n = 0}^\infty a_n P_n(x)[/tex]
where
[tex]a_n = \langle P_n(x), f(x) \rangle \operatorname{:=} \int_{-1}^1 P_n(x) f(x) \, dx[/tex]
If you have any text or lecture notes, you should be able to find a similar looking expression in there.
 
CompuChip said:
As 1 - x² is only a quadratic function you could first try doing it by trial-and-error, knowing that
[tex]P_0(x) = 1, P_1(x) = x, P_2(x) = \tfrac12(3x^2 - 1)[/tex]
which should give you the right answer after you give it some thought.

More formally, there is an expansion along the lines of
[tex]f(x) = \sum_{n = 0}^\infty a_n P_n(x)[/tex]
where
[tex]a_n = \langle P_n(x), f(x) \rangle \operatorname{:=} \int_{-1}^1 P_n(x) f(x) \, dx[/tex]
If you have any text or lecture notes, you should be able to find a similar looking expression in there.

I have seen these in my textbook (Advanced Engineering Mathematics by O'Neil), but the section only has 3 problems where it wants you to expand some simple polynomial into Legendre polynomials, only one answer to the 1 of problems but no idea how it is reached, and no examples in the chapter.

So I have f(x) = [itex]\sum_{n = 0}^{\infty}[/itex]anPn(x), and I have a formula for the coefficients: an = [itex]\int_{-1}^{-1}[/itex] Pn(x)f(x)dx.

How do I find the coefficients, an, if the integral is dependent on Pn(x)? Do I do it as follows:

n = 0 --> P0(x) = 1.
a0 = [itex]\int_{-1}^{-1}[/itex] 1 - x2 dx = x - x3/3 evaluated from -1 to 1 = 4/3.

So a0 = 4/3.

The same for n = 1, n = 2. Then a1 = 0, a2 = 14/15.

But then P(x) = 4/3 P0(x) + 0 + 14/15 P2(x) + ...

?

Using this method to check the one problem in the book doesn't yield the correct answer. Am I missing a recursion relation or something?

Between 2nd semester o-chem, neurogenetics, nonlinear dynamics and stability theory, mathematical reasoning and writing, and this advanced applied analysis course, my brain is starting to go crazy and it's becoming incredibly difficult to retain everything nearing the end of the semester. I apologize if I'm failing to understand or I'm missing some simple concept...I'm just feeling very lost in applied analysis at this point...

So any help is greatly, greatly appreciated.
 
Yes, that is the idea, and up to a minus sign in a3 it looks like you are on the right track. Try to find the exact expression for an in your notes, there is an additional factor dependent on n which will lead to the right answer (the reason it is there is that [itex]\int P_m(x) P_n(x) \, dx[/itex] is not equal to 1 for m = n which it should be for the expression I gave you to be correct; this is the difference between an orthogonal and an orthonormal basis).

If you continue working out the ... at the end you will find that all of them are zero. I guess you can use the recursion relation to prove this fact. In fact any polynomial will only have finitely many terms in the expansion.

As for your confusion, I can only hope that going through the calculation will help. This whole theory of expanding in orthogonal/orthonormal bases and how you get the coefficients is pretty interesting, but it's a bit too complicated for this little white box. If you are interested, you should find a book (a good one, maybe readers can recommend one); otherwise, you'll just have to take the whole sum / integral thing for granted :)