Find the general solution of the inhomogeneous wave equation $$u_{tt} − c^2u_{xx} = \sin t$$ What is the solution to the initial-value problem for this equation with $u(x, 0) = 0$ and $u_t(x, 0) = 1$?
I know that the general solution to the homogenous equation is $u(x,t) = f(x+ct) + g(x-ct)$ and I know how to solve the initial value problem from there. It's the inhomogenous part of this equation that is confusing me.
Thanks in advance!
First, observe that a particular solution is $u_p(t) = -\sin t$.
Then, find the remaining homogeneous solution $v(x,t)$ such that $u = u_p + v$. This gives the BVP
\begin{cases} v_{tt} - c^2 v_{xx} = 0 \\ v(x,0) = u(x,0) - u_p(0) = 0 \\ v_t(x,0) = u_t(x,0) - u_p'(0) = 2 \end{cases}
d'Alembert's formula gives
$$v(x,t) = \frac{1}{2c}\int_{x-ct}^{x+ct} 2 ds = \frac{1}{c}\big[(x+ct) - (x-ct) \big] = \frac{2ct}{c} = 2t$$