# multivariable calculus

I am working with the chain rule in multivariable calculus and I am having some difficulty with the question:

Let $f,g : \Bbb R \longrightarrow \Bbb R$ where $f$ and $g$ are twice differentiable. Show that $u(x,t)=f(x-at)+g(x+at)$ is a solution to the wave equation $u_{tt} = a^2 u_{xx}$.

Any help would be greatly appreciated! Thanks!

-

Let $\phi(x,t) = f(x-at)$. Then $\phi_{tt}(x,t) = a^2 f_{xx}(x-at)$ and $\phi_{xx}(x,t) = f_{xx}(x,t)$. Hence $\phi_{tt} = a^2 \phi_{xx}$, so $\phi$ satisfies the wave equation.
Now let $\eta(x,t) = g(x+at)$, this gives $\eta_{tt}(x,t) = a^2 g_{xx}(x,t)$ and $\eta_{xx}(x,t) = g_{xx}(x,t)$. Hence $\eta_{tt} = a^2 \eta_{xx}$, so $\eta$ satisfies the wave equation.
Since the wave equation is linear, it follows that $u =\phi+\eta$ also satisfies the wave equation.