Question: Find all the separated solutions of the given partial differential equation for the initial conditions given in (a) and (b), respectively: $$u_{tt}-u_{xx}-u=0$$ Conditions: $$0<x<\frac{\pi}{2}, \space \space\space u(0,t)=u\left(\frac{\pi}{2},t\right)=0, \space\space\space u(x,0) = f(x), \space\space\space u_t(x,0) = g(x) $$
I managed to find the general solution as follows:
Let $$ u(x,t) = F(x)G(t)$$ Then, $$\frac{G''(t)}{G(t)}-1=\frac{F''(x)}{F(x)}=k$$ Where $k$ is a constant. Now, I tested the cases $k>0$ and $k=0$, and they do not satisfy the boundary conditions, so $k$ must be negative. Then, suppose $k=-\alpha^2$ where $\alpha >0$
Implying $$F(x)=C_2\sin(2nx) \space\space\space \alpha=2n$$ where $n$ is an integer. And $C_2$ is an arbitrary constant. Similarly, $$G(t)=C_3{\cos\left(\left(\sqrt{4n^2-1}\right)t\right)}+C_4{\sin\left(\left(\sqrt{4n^2-1}\right)t\right)}$$
So: $$u(x,t) = \sum_{n=1}^{\infty}\left[{\sin(2nx)} \left({A_n\cos\left(t\sqrt{4n^2-1}\right)} +{B_n\sin\left(t\sqrt{4n^2-1}\right)}\right)\right]$$ Where \begin{align} A_n &= \frac{4}{\pi}\int_{0}^{\frac{\pi}{2}}f(x)\sin(2nx)\,\Bbb dx \\ B_n &= \frac{4}{\pi\sqrt{4n^2-1}}\int_{0}^{\frac{\pi}{2}}g(x)\sin(2nx)\,\Bbb dx \end{align} Now comes the weird part: For part (a), it says suppose $u(x,0) = x$. So I calculated $A_n$ correctly, as here $f(x)=x$. But, how to calculate $B_n$? I need to know $g(x)$, which was not stated in part (a) [nor part (b), which is similar but $f(x)$ is different].
Somebody solved the question, and in part (a), stated that $u_t(x,0) = 0 \implies B_n=0$ But what I do not understand is, in the header of the question it stated that $u_t(x,0) = g(x)$ and not $0$, so why in part (a), when it only specified $u(x,0) = x$, we assumed $g(x)=0$?
Sorry for the long post. Anyone has an idea? Thanks in advance.
