Take the 2-minute tour ×
Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

The solution of a PDE can be represented by a Fourier cosine series $$ u(x,t)=\sum_{n=1}^\infty A_n(t)\cos\frac{n\pi x}L. $$

Applying a given initial condition

$$ u(x,0)=100, $$

lets us solve for $A_n(0)$ through the orthogonality of cosines:

$$\begin{align} u(x,0)&=\sum_{n=1}^\infty A_n(0)\cos\frac{n\pi x}L=100\\ &\Rightarrow A_n(0)=\frac{400}L\int_0^L\cos\frac{n\pi x}L\,dx=0. \end{align}$$

This does not seem correct, however. What am I doing wrong?

share|improve this question

1 Answer 1

up vote 2 down vote accepted

You are missing the $n=0$ term in your cosine expansion.

If you choose to expand your $f(x)$ in terms of cosine, then you need to have $$f(x) = \sum_{n=0}^{\infty} f_n \cos(n \pi x/L)$$

share|improve this answer
    
But $n=1,2,\dots$, or am I missing something? –  Josué Molina Oct 26 '12 at 19:25
    
Oh, the problem is given without an $A_0$ term. Could this be a typo? –  Josué Molina Oct 26 '12 at 19:27
    
@JosuéMolina If you choose to expand in cos then you need to have the $n=0$ term. However, if you choose to expand in $\sin$ you will not have the $n=0$ term. –  user17762 Oct 26 '12 at 19:29

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.