Calculating the coefficients with the Fourier series

Click For Summary

Discussion Overview

The discussion revolves around solving an initial and boundary value problem involving the heat equation using Fourier series and Sturm-Liouville theory. Participants explore methods for calculating coefficients in the Fourier series representation of a function, addressing the implications of boundary conditions on the expansion approach.

Discussion Character

  • Technical explanation
  • Mathematical reasoning
  • Debate/contested

Main Points Raised

  • One participant presents a method using separation of variables to derive the solution for the heat equation, leading to a Fourier series representation of the initial condition.
  • Another participant questions whether the coefficients can be calculated by expanding the function in an odd way, suggesting a potential alternative approach using Sturm-Liouville theory.
  • Several participants provide calculations for the coefficients \(A_n\) using both Fourier series and Sturm-Liouville theory, noting discrepancies in the results obtained from each method.
  • One participant suggests that the inner product formula related to Sturm-Liouville theory is correct, while another expresses confusion about the appropriate Fourier formula to use.
  • Concerns are raised about the applicability of odd or even expansions due to mixed boundary conditions, prompting further inquiry into the correct approach for this specific problem.

Areas of Agreement / Disagreement

Participants express differing views on the correct method for calculating coefficients, with no consensus reached on whether the Fourier series or Sturm-Liouville theory provides the correct results in this context. The discussion remains unresolved regarding the appropriate expansion method due to the mixed boundary conditions.

Contextual Notes

Participants highlight limitations related to the boundary conditions, indicating that the mixed nature of the conditions complicates the choice between odd and even function expansions. The discussion reflects uncertainty about the correct application of Fourier series in this scenario.

mathmari
Gold Member
MHB
Messages
4,984
Reaction score
7
Hey! :o

I have to solve the following initial and boundary value problem:
$$u_t=u_{xx}, 0<x<L, t>0 (1)$$
$$u(0,t)=u_x(L,t)=0, t>0$$
$$u(x,0)=x, 0<x<L$$

I did the following:
Using the method separation of variables, the solution is of the form: $u(x,t)=X(x)T(t)$

Replacing this at $(1)$, we get:

$$\left.\begin{matrix}
X''+\lambda X=0, 0<x<L\\
X(0)=0, X'(L)=0
\end{matrix}\right\} (2)$$

$$\left.\begin{matrix}
T'+\lambda T=0, t>0
\end{matrix}\right\} (3)$$

$$u(x,0)=X(x)T(0)=x$$Solving the problem $(2)$ we get that the eigenfunctions are $$X_n(x)=\sin{(\frac{(2n+1) \pi x}{2L})}$$

Solving the problem $(3)$ we get $$T_n(t)=A_ne^{-(\frac{(2n+1) \pi}{2L})^2t}$$

So the solution of the initial problem is of the form $$u(x,t)=\sum_{n=1}^{\infty}{A_n \sin{(\frac{(2n+1) \pi x}{2L})}e^{-(\frac{(2n+1) \pi}{2L})^2t}}$$

$$u(x,0)=x \Rightarrow x=\sum_{n=1}^{\infty}{A_n \sin{(\frac{(2n+1) \pi x}{2L})}}$$

To calculate the coefficients $A_n$ can I do the following:

We expand the function $f(x)=x$ in an odd way in $[-L,L]$.
So we can write $f$ as a Fourier series:
$$f(x)=\sum_{n=1}^{\infty}{b_n \sin{(\frac{2(2n+1) \pi x}{2 \cdot 2L})}}, \text{ where } b_n=\frac{2}{4L} \int_{-L}^L{f(x) \sin{(\frac{2(2n+1) \pi x}{4L})}}dx$$

Or is it wrong to calculate these coefficients in that way?? (Wondering)
 
Physics news on Phys.org
Or is it better to calculate them with the Sturm-Liouville theory?
 
When I calculate the coefficients using the Fourier series, I get the following:

$$f(x)=\sum_{n=1}^{\infty}{b_n \sin{(\frac{2 (2n+1) \pi x}{2 \cdot 2L})}},$$ $$\text{ where } b_n=\frac{2}{4L} \int_{-L}^L{f(x) \sin{(\frac{2 (2n+1) \pi x}{4L})}}dx=\frac{1}{L} \int_0^L{f(x) \sin{(\frac{ (2n+1) \pi x}{2L})}}dx$$

So $$A_n=\frac{1}{L} \int_0^L{x \sin{(\frac{(2n+1) \pi x}{2})}}dx =\frac{1}{L} \frac{4L^2}{(2n+1)^2 \pi^2}(-1)^n=\frac{4L}{(2n+1)^2 \pi^2}(-1)^n$$When I use the Sturm-Liouville theory, I get the following:

$$A_n=\frac{(f(x),X_n(x))}{||X_n||^2}$$

$$(f(x),X_n(x))=\int_0^L{f(x) \sin{(\frac{ (2n+1) \pi x}{2L})}}dx=\int_0^L{x \sin{(\frac{ (2n+1) \pi x}{2L})}}dx=\frac{4L^2}{(2n+1)^2 \pi^2}(-1)^n$$

$$||X_n^2||=\int_0^L{\sin^2{(\frac{ (2n+1) \pi x}{2L})}}dx=\frac{L}{2}$$

So $$A_n=\frac{2}{L}\frac{4L^2}{(2n+1)^2 \pi^2}(-1)^n=\frac{8L}{(2n+1)^2 \pi^2}(-1)^n$$The results are not the same...
What have I done wrong? (Wondering)
 
mathmari said:
When I calculate the coefficients using the Fourier series, I get the following:

$$f(x)=\sum_{n=1}^{\infty}{b_n \sin{(\frac{2 (2n+1) \pi x}{2 \cdot 2L})}},$$ $$\text{ where } b_n=\frac{2}{4L} \int_{-L}^L{f(x) \sin{(\frac{2 (2n+1) \pi x}{4L})}}dx=\frac{1}{L} \int_0^L{f(x) \sin{(\frac{ (2n+1) \pi x}{2L})}}dx$$

So $$A_n=\frac{1}{L} \int_0^L{x \sin{(\frac{(2n+1) \pi x}{2})}}dx =\frac{1}{L} \frac{4L^2}{(2n+1)^2 \pi^2}(-1)^n=\frac{4L}{(2n+1)^2 \pi^2}(-1)^n$$When I use the Sturm-Liouville theory, I get the following:

$$A_n=\frac{(f(x),X_n(x))}{||X_n||^2}$$

$$(f(x),X_n(x))=\int_0^L{f(x) \sin{(\frac{ (2n+1) \pi x}{2L})}}dx=\int_0^L{x \sin{(\frac{ (2n+1) \pi x}{2L})}}dx=\frac{4L^2}{(2n+1)^2 \pi^2}(-1)^n$$

$$||X_n^2||=\int_0^L{\sin^2{(\frac{ (2n+1) \pi x}{2L})}}dx=\frac{L}{2}$$

So $$A_n=\frac{2}{L}\frac{4L^2}{(2n+1)^2 \pi^2}(-1)^n=\frac{8L}{(2n+1)^2 \pi^2}(-1)^n$$The results are not the same...
What have I done wrong? (Wondering)

Hey! (Blush)

Hmm, I don't think you have the right Fourier formula...

What you call Sturm-Liouville theory is actually an inner product formula, which does look correct.
 
I like Serena said:
Hey! (Blush)

Hmm, I don't think you have the right Fourier formula...

What you call Sturm-Liouville theory is actually an inner product formula, which does look correct.

Ahaa! Ok! So I have to use the inner product formula in these cases? (Wondering)
 
mathmari said:
Ahaa! Ok! So I have to use the inner product formula in these cases? (Wondering)

It boils down to the same thing.
The great discovery Fourier made was that $\{\cos(n\pi x), \sin(n\pi x) \}$ forms a basis for all square integrable functions. To find the coefficients we simply need to take the inner product.
If you apply the Fourier sine series correctly you should find the same result.
 
I like Serena said:
It boils down to the same thing.
The great discovery Fourier made was that $\{\cos(n\pi x), \sin(n\pi x) \}$ forms a basis for all square integrable functions. To find the coefficients we simply need to take the inner product.
If you apply the Fourier sine series correctly you should find the same result.

Ahaa! Ok!

What have I done wrong at the Fourier series?? (Wondering)

Since the boundary conditions are mixed we cannot expand the function neither in an odd way nor in an even way...

What can I do in this case?? (Wondering)
 

Similar threads

  • · Replies 7 ·
Replies
7
Views
3K
  • · Replies 2 ·
Replies
2
Views
2K
Replies
1
Views
2K
  • · Replies 4 ·
Replies
4
Views
3K
  • · Replies 4 ·
Replies
4
Views
3K
Replies
28
Views
6K
  • · Replies 1 ·
Replies
1
Views
2K
  • · Replies 2 ·
Replies
2
Views
2K
  • · Replies 5 ·
Replies
5
Views
4K
  • · Replies 4 ·
Replies
4
Views
3K