How to integral legendre polynomial

In summary, the conversation was about the integral \int_{-1}^{1} cos(x) P_{n}(x)\,dx and how to solve it using the Rodrigues formula and integration by parts. The expert summarizer provided a summary of the steps involved in solving the integral and also shared two solutions for different cases (n= even and n= odd). The conversation also mentioned using Wolfram Alpha as an online integrator, but the expert summarizer did not provide a solution from there. Instead, they shared their solution using beta function and Bessel polynomial. The final result shows the relationship between cos(x) and the Legendre polynomial P_{n}(x).
  • #1
Another1
40
0
Question

\(\displaystyle \int_{-1}^{1} cos(x) P_{n}(x)\,dx\)

____________________________________________________________________________________________
my think (maybe incorrect)
\(\displaystyle \int_{-1}^{1} cos(x) P_{n}(x)\,dx\)
\(\displaystyle \frac{1}{2^nn!}\int_{-1}^{1} cos(x) \frac{d^n}{dx^n}(x^2-1)^n\,dx\) This is rodrigues formula
by part n times
\(\displaystyle \frac{1}{2^nn!}(-1)^n\int_{-1}^{1} \frac{d^n}{dx^n}cos(x) \frac{d^{n-n}}{dx^{n-n}}(x^2-1)^n\,dx\)
\(\displaystyle \frac{1}{2^nn!}(-1)^n\int_{-1}^{1} \frac{d^n}{dx^n}cos(x) (x^2-1)^n\,dx\)
in case n = odd number
\(\displaystyle \frac{1}{2^nn!}(-1)^n\int_{-1}^{1} (-1)^{\frac{n+1}{2}}sin(x) (x^2-1)^n\,dx\)
in case n = even number
\(\displaystyle \frac{1}{2^nn!}(-1)^n\int_{-1}^{1} (-1)^{\frac{n}{2}}cos(x) (x^2-1)^n\,dx\)
_________________________________________________________________________________________________

how to integral

\(\displaystyle \int_{-1}^{1}sin(x) (x^2-1)^n\,dx\) and \(\displaystyle \int_{-1}^{1}cos(x) (x^2-1)^n\,dx\)
 
Physics news on Phys.org
  • #3
greg1313 said:

Thank you. But i don't have pro Wolframalpha.
please. you can show that solution?
 
  • #4
Another said:
Thank you. But i don't have pro Wolframalpha.
please. you can show that solution?

I do. But there's no worked solution for this one anyway.
 
Last edited:
  • #5
Joppy said:
I do. But there's no worked solution for this one anyway.

thank you vary much. now i can solve it
 
  • #6
Another said:
thank you vary much. now i can solve it

Would you mind sharing your solution? I remember there being a trick with these things but I cannot remember!
 
  • #7
Joppy said:
Would you mind sharing your solution? I remember there being a trick with these things but I cannot remember!

Ok

let
\(\displaystyle cos(x) = \sum_{n=0}^{\infty}C_{n}P_{n}(x)\)

orthogonal
\(\displaystyle \int_{-1}^{1} cos(x)P_{n}(x)\,dx = \int_{-1}^{1} C_{n}P_{n}(x)P_{n}(x)\,dx\)
\(\displaystyle \int_{-1}^{1} cos(x)P_{n}(x)\,dx = C_{n}\int_{-1}^{1} P_{n}(x)P_{n}(x)\,dx\)
see that
\(\displaystyle \int_{-1}^{1} P_{n}(x)P_{n}(x)\,dx= \frac{1}{2^{2n}(n!)^2}\int_{-1}^{1} \frac{d^n}{dx^n}(x^2-1)^n\frac{d^n}{dx^n}(x^2-1)^n\,dx\)
you can integral by part n time
So..
\(\displaystyle u= \frac{d^n}{dx^n}(x^2-1)^n\) and \(\displaystyle du=\frac{d^{n+1}}{dx^{n+1}}(x^2-1)^n\,dx\)
\(\displaystyle dv= \frac{d^n}{dx^n}(x^2-1)^ndx\) and \(\displaystyle v=\frac{d^{n-1}}{dx^{n-1}}(x^2-1)^n\)

\(\displaystyle udv=uv-vdu\)

\(\displaystyle uv= \frac{d^n}{dx^n}(x^2-1)^n \frac{d^{n-1}}{dx^{n-1}}(x^2-1)^n =0 \) When limit of the integrate from -1 to 1

So when integrate by part n times
\(\displaystyle \int_{-1}^{1} P_{n}(x)P_{n}(x)\,dx= \frac{1}{2^{2n}(n!)^2}\left[0+0+...+(-1)^n\int_{-1}^{1}\frac{d^{n-n}}{dx^{n-n}}(x^2-1)^n \frac{d^{n+n}}{dx^{n+n}}(x^2-1)^n \,dx\right]\)
\(\displaystyle \int_{-1}^{1} P_{n}(x)P_{n}(x)\,dx= \frac{1}{2^{2n}(n!)^2}\left[\int_{-1}^{1}(x^2-1)^n \frac{d^{2n}}{dx^{2n}}(1-x^2)^n \,dx\right]\) ; times (-1)^n in (x^n-1)^n

You know \(\displaystyle (1-x^2)^n=\sum_{k=0}^{n}{n \choose k} 1^{n-k}(-1)^n(x^2)^n \)
\(\displaystyle \int_{-1}^{1} P_{n}(x)P_{n}(x)\,dx= \frac{1}{2^{2n}(n!)^2}\left[\int_{-1}^{1}(x^2-1)^n \frac{d^{2n}}{dx^{2n}}\sum_{k=0}^{n}{n \choose k} 1^{n-k}(-1)^n(x^2)^n \,dx\right]\)

The final term of \(\displaystyle (1-x^2)^n=\sum_{k=0}^{n}{n \choose k} 1^{n-k}(-1)^n(x^2)^n = ...+ {n \choose n }(-1)^n x^{2n}\)

because \(\displaystyle \frac{d^m}{dx^m}x^n = 0\) when n < m

So that
\(\displaystyle \int_{-1}^{1} P_{n}(x)P_{n}(x)\,dx= \frac{1}{2^{2n}(n!)^2}\left[\int_{-1}^{1}(x^2-1)^n \frac{d^{2n}}{dx^{2n}}(-1)^nx^{2n} \,dx\right]\)
\(\displaystyle \int_{-1}^{1} P_{n}(x)P_{n}(x)\,dx= \frac{1}{2^{2n}(n!)^2}\left[\int_{-1}^{1}(x^2-1)^n (-1)^n (2n)! \,dx\right]\)
\(\displaystyle \int_{-1}^{1} P_{n}(x)P_{n}(x)\,dx= \frac{(2n)!}{2^{2n}(n!)^2}\left[\int_{-1}^{1}(1-x^2)^n \,dx\right]\)

set \(\displaystyle s =\frac{x+1}{2}\)

\(\displaystyle \int_{-1}^{1} P_{n}(x)P_{n}(x)\,dx= \frac{(2n)!}{2^{2n}(n!)^2}\left[\int_{0}^{1} 2\cdot 2^{2n}s^n(1-s)^n\,ds\right]\) beta function
\(\displaystyle \int_{-1}^{1} P_{n}(x)P_{n}(x)\,dx= \frac{(2n)!}{2^{2n}(n!)^2} 2\cdot 2^{2n}\frac{(n!)^2}{(2n+1)!}\)
\(\displaystyle \int_{-1}^{1} P_{n}(x)P_{n}(x)\,dx= \frac{2}{2n+1}\)

see that
\(\displaystyle \int_{-1}^{1} cos(x)P_{n}(x)\,dx= \frac{1}{2^{n}n!}\int_{-1}^{1}cos(x)\frac{d^n}{dx^n}(x^2-1)^n\,dx\)

You can integral by part n times.
\(\displaystyle u = con(x)\) and \(\displaystyle dv = \frac{d^n}{dx^n}(x^2-1)^n dx \)
So . . .
\(\displaystyle \int_{-1}^{1} cos(x)P_{n}(x)\,dx= \frac{(-1)^n}{2^{n}n!}\int_{-1}^{1}(x^2-1)^n \frac{d^n}{dx^n}cos(x),dx\)

give two solution

in case n = odd number
\(\displaystyle \int_{-1}^{1} cos(x)P_{n}(x)\,dx=\frac{1}{2^nn!}(-1)^n\int_{-1}^{1} (-1)^{\frac{n+1}{2}}sin(x) (x^2-1)^n\,dx\)
in case n = even number
\(\displaystyle \int_{-1}^{1} cos(x)P_{n}(x)\,dx=\frac{1}{2^nn!}(-1)^n\int_{-1}^{1} (-1)^{\frac{n}{2}}cos(x) (x^2-1)^n\,dx\)

But \(\displaystyle sin(x) (x^2-1)^n \) are Odd function So \(\displaystyle \frac{1}{2^nn!}(-1)^n\int_{-1}^{1} (-1)^{\frac{n+1}{2}}sin(x) (x^2-1)^n\,dx = 0\)

left only one solution

\(\displaystyle \int_{-1}^{1} cos(x)P_{n}(x)\,dx=\frac{1}{2^nn!}(-1)^n\int_{-1}^{1} (-1)^{\frac{n}{2}}cos(x) (x^2-1)^n\,dx\) n = 0,2,4,...
\(\displaystyle \int_{-1}^{1} cos(x)P_{n}(x)\,dx=\frac{1}{2^nn!}(-1)^{\frac{n}{2}} 2 \int_{0}^{1} cos(x) (1-x^2)^n\,dx\) ; even function

Wolfram|Alpha: Computational Intelligence

You know \(\displaystyle cos(x) = \sum_{i=0}^{\infty}\frac{(-1)^i}{(2i)!}x^{2i} \)
\(\displaystyle \int_{-1}^{1} cos(x)P_{n}(x)\,dx=\frac{2}{2^nn!}(-1)^{\frac{n}{2}} \int_{0}^{1} \sum_{i=0}^{\infty}\frac{(-1)^i}{(2i)!}x^{2i} (1-x^2)^n\,dx\)
\(\displaystyle \int_{-1}^{1} cos(x)P_{n}(x)\,dx=\frac{1}{2^nn!}(-1)^{\frac{n}{2}} \sum_{i=0}^{\infty}\frac{(-1)^i}{(2i)!} (2)\int_{0}^{1} x^{2i} (1-x^2)^n\,dx\); Beta function form
\(\displaystyle \int_{-1}^{1} cos(x)P_{n}(x)\,dx=\frac{1}{2^nn!}(-1)^{\frac{n}{2}} \sum_{i=0}^{\infty}\frac{(-1)^i}{(2i)!} \frac{(i-\frac{1}{2})!n!}{(i-\frac{1}{2}+n+1)!}\)
\(\displaystyle \int_{-1}^{1} cos(x)P_{n}(x)\,dx=\frac{1}{2^nn!}(-1)^{\frac{n}{2}} \sum_{i=0}^{\infty}\frac{(-1)^i}{(2i)!} \frac{(i-\frac{1}{2})! \Gamma(n+1)}{(i+n+\frac{1}{2})!}\)

from \(\displaystyle (i-\frac{1}{2})! = \frac{1}{i!}(\frac{1}{2})^{2i}\sqrt{\pi}(2i)!\)

\(\displaystyle \int_{-1}^{1} cos(x)P_{n}(x)\,dx=\frac{1}{2^nn!}(-1)^{\frac{n}{2}}\Gamma(n+1) \sum_{i=0}^{\infty}\frac{(-1)^i}{(2i)!} \frac{1}{(i+n+\frac{1}{2})!}\frac{1}{i!}(\frac{1}{2})^{2i}\sqrt{\pi}(2i)!\)
\(\displaystyle \int_{-1}^{1} cos(x)P_{n}(x)\,dx=\frac{1}{2^nn!}(-1)^{\frac{n}{2}}\Gamma(n+1) \sum_{i=0}^{\infty}\frac{(-1)^i}{(2i)!} \frac{1}{(i+n+\frac{1}{2})!}\frac{1}{i!}(\frac{1}{2})^{2i}\sqrt{\pi}(2i)! \cdot \frac{2^{n+\frac{1}{2}}}{2^{n+\frac{1}{2}}}\)
\(\displaystyle \int_{-1}^{1} cos(x)P_{n}(x)\,dx=\frac{1}{2^nn!}(-1)^{\frac{n}{2}}\Gamma(n+1) 2^{n+\frac{1}{2}}\sqrt{\pi}\sum_{i=0}^{\infty}\frac{(-1)^i}{i!} \frac{1}{(i+n+\frac{1}{2})!}(\frac{1}{2})^{2i} \cdot (\frac{1}{2})^{n+\frac{1}{2}}\)
\(\displaystyle \int_{-1}^{1} cos(x)P_{n}(x)\,dx=\frac{1}{2^nn!}(-1)^{\frac{n}{2}}\Gamma(n+1) 2^{n+\frac{1}{2}}\sqrt{\pi}\sum_{i=0}^{\infty}\frac{(-1)^i}{i!} \frac{1}{(i+n+\frac{1}{2})!}(\frac{1}{2})^{n+\frac{1}{2}+2i}\)
\(\displaystyle \int_{-1}^{1} cos(x)P_{n}(x)\,dx=\frac{1}{2^nn!}(-1)^{\frac{n}{2}}\Gamma(n+1) 2^{n+\frac{1}{2}}\sqrt{\pi}J_{n+\frac{1}{2}}(1)\) ; Bessel polynomialSo
\(\displaystyle C_{n}=\frac{2n+1}{2}\int_{-1}^{1} cos(x)P_{n}(x)\,dx= \frac{2n+1}{2} \frac{1}{2^nn!}(-1)^{\frac{n}{2}}\Gamma(n+1) 2^{n+\frac{1}{2}}\sqrt{\pi}J_{n+\frac{1}{2}}(1)\)
\(\displaystyle C_{n}=\frac{2n+1}{2}\int_{-1}^{1} cos(x)P_{n}(x)\,dx= \frac{2n+1}{n!}(-1)^{\frac{n}{2}}\Gamma(n+1) 2^{-\frac{1}{2}}\sqrt{\pi}J_{n+\frac{1}{2}}(1)\) n = 0,2,4,...

and finaly

\(\displaystyle cos(x) = \sum_{n=0}^{\infty}C_{n}P_{n}(x)\)
\(\displaystyle cos(x) = \sum_{n=0}^{\infty} \frac{2n+1}{n!}(-1)^{\frac{n}{2}}\Gamma(n+1) 2^{-\frac{1}{2}}\sqrt{\pi}J_{n+\frac{1}{2}}(1) P_{n}(x)\)

- My solution
 
Last edited:

1. What is an integral Legendre polynomial?

An integral Legendre polynomial is a mathematical function used in calculus and differential equations. It is a type of orthogonal polynomial and is defined as the solution to a specific differential equation called the Legendre equation. These polynomials have many applications in physics, engineering, and other fields.

2. How do you calculate an integral Legendre polynomial?

To calculate an integral Legendre polynomial, you can use the recurrence relation or the Rodrigues' formula. The recurrence relation involves using the coefficients of the previous polynomials to calculate the next one, while the Rodrigues' formula uses derivatives to express the polynomial in terms of its coefficients. Alternatively, you can also use a computer program or a mathematical software to generate the polynomials.

3. What is the purpose of using integral Legendre polynomials?

Integral Legendre polynomials are useful in solving various mathematical problems involving integration over a specific range. They have the special property of being orthogonal, which means they are perpendicular to each other when plotted on a graph. This makes them ideal for approximating functions and solving differential equations.

4. Are there any special properties of integral Legendre polynomials?

Yes, integral Legendre polynomials have several unique properties that make them useful in mathematical applications. Some of these properties include orthogonality, recurrence relation, and the Rodrigues' formula. They also have a finite number of roots, which can be used to determine the weights and nodes for numerical integration methods.

5. Can integral Legendre polynomials be used in multidimensional problems?

Yes, integral Legendre polynomials can be extended to higher dimensions and used in multidimensional problems. This is known as multivariate Legendre polynomials, and they have similar properties as their one-dimensional counterparts. They are commonly used in solving problems involving multiple variables, such as in quantum mechanics and statistical mechanics.

Similar threads

Replies
4
Views
343
Replies
1
Views
931
  • Calculus
Replies
29
Views
711
Replies
1
Views
3K
Replies
12
Views
1K
Replies
2
Views
285
Replies
16
Views
2K
Replies
2
Views
1K
Replies
4
Views
1K
Replies
5
Views
381
Back
Top