# PDE - wave equation

#### Hurry

##### New member
Hi, I have a test tomorrow and I'd like you to guys help me please.

Solve the following:

\begin{align*} & {{u}_{tt}}={{u}_{xx}}+1+x,\text{ }0<x<1,\text{ }t>0. \\ & u(x,0)=\frac{1}{6}{{x}^{3}}-\frac{1}{2}{{x}^{2}}+\frac{1}{3},\text{ }{{u}_{t}}(x,0)=0,\text{ }0<x<1. \\ & {{u}_{x}}(0,t)=u(1,t)=0,\text{ }t>0. \end{align*}

I think it can be solved by using $u(x,t)=v(x,t)+a(x)$ and then applying D'Alembert later, does this work?

#### Jester

##### Well-known member
MHB Math Helper
Since you have boundary condition you'll want to use separation of variables. It you let

$u = v + ax^3 + bx^2 + cx + d$

you can pick $a,b,c$ and $d$ such that the BC's are the same and the term $1+x$ in the PDE can be eliminated