General solution for a standing wave to the wave equation.

1. Apr 26, 2015

pondzo

1. The problem statement, all variables and given/known data

If $u(x,t)\in \mathbb R, x\in[-\pi,\pi]$ represents a standing wave with $u(\pm\pi,t)=0$ Then what is the most general solution u(x,t)?

2. Relevant equations

3. The attempt at a solution

Using the separation of variable technique: u(x,t)=P(x)Q(t)
I get $P(x) =A\sin{(\lambda x)}+B\cos{(\lambda x)}$
$u(\pm\pi,t)=0$ implies either (1) or (2);
(1) A=0 and $\lambda=\frac{2n-1}{2}$ so $P(x)=B\cos{(\frac{2n-1}{2}x)}$
(2) B=0 and $\lambda=n$ so $P(x)=A\sin{(nx)}$
If (1) then $Q(t)=C_n\sin{(\frac{2n-1}{2}ct+\phi)}$ and $u(x,t)=\sum_{n=1}^\infty b_n\sin{(\frac{2n-1}{2}ct+\phi)}\cos{(\frac{2n-1}{2}x)}$
If (2) then $Q(t)=C_n\sin{(nct+\phi)}$ and $u(x,t)=\sum_{n=1}^\infty a_n\sin{(nct+\phi)}\sin{(nx)}$
So i would be inclined to say the most general solution is linear combinations of (1) and (2);
$u(x,t)=\sum_{n=1}^\infty a_n\sin{(nct+\phi)}\sin{(nx)} + \sum_{n=1}^\infty b_n\sin{(\frac{2n-1}{2}ct+\phi)}\cos{(\frac{2n-1}{2}x)}$

However this is what the solution says;
$u(x,t)=\sum_{n=1}^\infty a_n\sin{(nx)}\sin{(nct+\phi)}+\sum_{n=1}^\infty b_n\cos{(\frac{2n-1}{2}x)}\sin{(nct+\phi)}$
I don't quite understand this solution because in one part of u(x,t) it has quantized lamda as integers ($\lambda=n$) and in another part it has quantized lamda as odd multiples divided by two ($\lambda=\frac{2n-1}{2}$). Its as if the solution has taken linear combinations of my (1) and (2) and let lambda equal different values. Are you allowed to do this?

Last edited: Apr 26, 2015
2. Apr 26, 2015

BvU

I see nothing wrong with your reasoning, so I suspect you found an error in the book solutions.