Help with computing/understanding Fourier Sine Expansion.

LoganS
Messages
5
Reaction score
0
1. Find the Fourier sine expansion of \phi(x)=1. This was posted in Calculus and Beyond thread, but I realized that this thread may be more appropriate.

2. The attempt at a solution.
I start with \phi(x)=A_1sin(\pi x)+A_2sin(2\pi x)+\cdots+A_nsin(n\pi x), and then add multiply by A_msin(m\pi x) term on each side and integrate from 0 to 1.
So I have \int\phi(x)A_msin(m\pi x)=\int\left(A_1sin(\pi x)A_msin(m\pi x)+A_2sin(2\pi x)A_msin(m\pi x)+\cdots+A_nsin(n\pi x)A_msin(m\pi x)\right).
I know that due to orthogonality you can discard the terms where m is not equal to n (but I don't really understand why so if you can explain this I would appreciate it).
Discarding those terms and using a trig relation I get, \int\phi(x)A_msin(m\pi x)=1/2\int\left(cos((m-n)\pi x)-cos((m+n)\pi x)\right).
I then solve the integral and try to get ##A_m=\frac{4}{\pi}\left(\frac{1}{m}\right),## but I don't know why the answer has only the odd terms.
The book answer is 1=\frac{4}{\pi}\left(sin(\pi x)+\frac{1}{3}sin(3\pi x)+\frac{1}{5}sin(5\pi x) +\cdots\right).

Any and all help is greatly appreciated.
 
Last edited:
Physics news on Phys.org
LoganS said:
1. Find the Fourier sine expansion of \phi(x)=1. This was posted in Calculus and Beyond thread, but I realized that this thread may be more appropriate.

2. The attempt at a solution.
I start with \phi(x)=A_1sin(\pi x)+A_2sin(2\pi x)+\cdots+A_nsin(n\pi x), and then add multiply by A_msin(m\pi x) term on each side and integrate from 0 to 1.

So I have \int\phi(x)A_msin(m\pi x)=\int\left(A_1sin(\pi x)A_msin(m\pi x)+A_2sin(2\pi x)A_msin(m\pi x)+\cdots+A_nsin(n\pi x)A_msin(m\pi x)\right).

The starting point is
\phi(x) = \displaystyle \sum_{n=1}^{\infty} a_n \sin(n\pi x)

To work out a_n, multiply by \sin (m\pi x) and integrate between 0 and 1:
<br /> \int_0^1 \phi(x) \sin(m\pi x)\,\mathrm{d}x <br /> = \sum_{n=1}^\infty a_n \int_0^1 \sin(n \pi x) \sin(m\pi x)\,\mathrm{d}x<br />

I know that due to orthogonality you can discard the terms where m is not equal to n (but I don't really understand why so if you can explain this I would appreciate it).

We need to calculate I = \int_0^1 \sin(n\pi x)\sin(m \pi x)\,\mathrm{d}x. This we do by parts:
<br /> I = \int_0^1 \sin(n\pi x)\sin(m \pi x)\,\mathrm{d}x \\<br /> = \left[ -\frac{1}{m\pi} \sin(n\pi x)\cos(m\pi x)\right]_0^1<br /> + \frac{n}{m}\int_0^1 \cos(n\pi x)\cos(m\pi x)\,\mathrm{d}x \\<br /> = \frac{n}{m}\int_0^1 \cos(n\pi x)\cos(m\pi x)\,\mathrm{d}x<br />
where the last follows because \sin(0) = \sin(m\pi) = 0. Now we can integrate by parts again:
<br /> I = \frac{n}{m}\int_0^1 \cos(n\pi x)\cos(m\pi x)\,\mathrm{d}x \\<br /> = \frac{n}{m}\left[ \frac{1}{m\pi} \cos(n\pi x)\sin(m \pi x)\right]_0^1<br /> + \frac{n^2}{m^2} \int_0^1 \sin(n\pi x)\sin(m\pi x)\,\mathrm{d}x \\<br /> = \frac{n^2}{m^2} I

So (1 - n^2/m^2)I = 0. It follows then that if n \neq m then I = 0. If n = m then the integrand is \sin^2(m\pi x) which is non-negative and not identically zero, so its integral must be strictly positive. So we have, using the identity \sin^2 \theta = \frac12 (1 - \cos 2\theta):
<br /> \int_0^1 \phi(x) \sin(m\pi x)\,\mathrm{d}x <br /> = a_m \int_0^1 \sin(m \pi x) \sin(m\pi x)\,\mathrm{d}x \\<br /> = a_m \int_0^1 \sin^2(m \pi x)\,\mathrm{d}x \\<br /> = \frac12 a_m \int_0^1 1 - \cos(2m \pi x)\,\mathrm{d}x\\<br /> = \frac12 a_m<br />
so that
<br /> a_m = 2 \int_0^1 \phi(x) \sin(m\pi x)\,\mathrm{d}x.<br />

Discarding those terms and using a trig relation I get, \int\phi(x)A_msin(m\pi x)=1/2\int\left(cos((m-n)\pi x)-cos((m+n)\pi x)\right).
I then solve the integral and try to get ##A_m=\frac{4}{\pi}\left(\frac{1}{m}\right),## but I don't know why the answer has only the odd terms.

a_m = 2\int_0^1 \sin(m\pi x)\,\mathrm{d}x = -\frac{2}{m\pi} \left[\cos(m\pi x)\right]_0^1 \\<br /> = - \frac{2}{m\pi}( \cos(m\pi) - 1) \\<br /> = - \frac{2}{m\pi}( (-1)^m - 1) \\<br /> = \frac{2}{m\pi}(1 - (-1)^m)
If m is even, (-1)^m = 1 so a_m = 0. If m is odd, (-1)^m = -1 and a_m = 4/(m\pi), which is the given answer.

The book answer is 1=\frac{4}{\pi}\left(sin(\pi x)+\frac{1}{3}sin(3\pi x)+\frac{1}{5}sin(5\pi x) +\cdots\right).

Any and all help is greatly appreciated.
 
Thread 'Direction Fields and Isoclines'
I sketched the isoclines for $$ m=-1,0,1,2 $$. Since both $$ \frac{dy}{dx} $$ and $$ D_{y} \frac{dy}{dx} $$ are continuous on the square region R defined by $$ -4\leq x \leq 4, -4 \leq y \leq 4 $$ the existence and uniqueness theorem guarantees that if we pick a point in the interior that lies on an isocline there will be a unique differentiable function (solution) passing through that point. I understand that a solution exists but I unsure how to actually sketch it. For example, consider a...
Back
Top