# Particular Solution

Consider the nonhomogeneous differential equation y^((n))+a_(n-1)(x)y^((n-1))+...+a_1(x)y'+a_0(x)y=g(x) .

Recall from section about linear independence that solution of the corresponding homogeneous equation y^((n))+a_(n-1)(x)y^((n-1))+...+a_1(x)y'+a_0(x)y=0 is given as y_h=c_1y_1(x)+c_2y_2(x)+...+c_ny_n(x) .

Then if y_p is solution of nonhomogeneous equation then general solution of nonhomogeneous equation is y=y_h+y_p .

Proof.

Plug in y=y_h+y_p into differential equation:

(y_h+y_p)^((n))+a_(n-1)(x)(y_h+y_p)^((n-1))+...+a_1(x)(y_h+y_p)'+a_0(x)y=

=(y_h^((n))+a_(n-1)(x)y_h^((n-1))+...+a_1(x)y_h'+a_0(x)y_h)+(y_p^((n))+a_(n-1)(x)y_p^((n-1))+...+a_1(x)y_p'+a_0(x)y_p)=

=0+g(x)=g(x)

So, indeed y=y_p+y_h is solution of nonhomogeneous differential equation.

Example. Solution of homogeneous equation y''+y'-2y=0 is y_h=c_1e^(-2x)+c_2e^(x) .

For the nonhomogeneous equation y''+y'-2y=2(1+x-x^2) particular solution is y_p=x^2 .

So, general solution of nonhomogeneous differential equation y''+y'-2y=2(1+x-x^2) is y=y_h+y_p=c_1e^(-2x)+c_2e^x+x^2 .