To find the solution to a non-homogenous, find the complementary function to the homogenous solution. Then find a particular solution to find a general solution.
The method of variation of parameters can, in principle, always be used to find a particular solution for a non-homogenous equation.
Given the nonhomogeneous equation , that has the complementary solution the particular solution can be constructed by
where is the Wronskian of .