I have to convert below PDE to a homogeneous PDE and then solve it with separation of variables method. I don't know how to do this conversion. Could someone guide me please?
${\partial^2u\over\partial t^2}={\partial^2u\over\partial x^2}+Ax$
$u(0,t)=u(l,t)=0 , u(x,0)=u_t(x,0)=0$
You are asked to look for a function $\tilde{u}$ such that solving the homogenous equation
$$ L (\tilde{u}) := \partial^2_{t t} \tilde{u} - \partial^2_{x x} \tilde{u} = 0 $$
by separation of variables will yield a solution for the original inhomogeneous equation
$$ L (u) = Ax. $$
So you want your function to fulfil
$$ \partial^2_{x x} \tilde{u} = \partial^2_{x x} u + A x. $$
Integrate this twice wrt. $x$ to obtain $\tilde{u}$, then solve the new equation and plug the result back. But careful with the new boundary conditions ($\tilde{u}$ has new values at the boundary). Good luck!