Problem 83
Medium Reduction of Order

Find the general solution of x y'' - (x+2) y' + y = 0 . A…

Find the general solution of $x\,y'' - (x+2)\,y' + y = 0$. A polynomial particular solution exists.

Explanation of Method

Find a polynomial $y_1$ by matching degrees, then reduce the order via $y=y_1v$ to reach the general solution.

Step 1: Find the degree of the polynomial solution

For $y_1=x^n$, the degree-$n$ terms come from $-x\,y_1'$ and $y_1$ (everything else is lower degree): $-x\cdot nx^{n-1} + x^n = (1-n)x^n.$

This vanishes when $n=1$.

Step 2: Solve for the coefficients and verify

Try $y_1=ax+b$: $y_1'=a$, $y_1''=0$.

\[ x(0) - (x+2)a + (ax+b) = b-2a = 0 \implies b=2a. \]

Taking $a=1$ gives $y_1=x+2$. Check: $0-(x+2)(1)+(x+2)=0. $\checkmark$$

Step 3: Substitute $y=y_1v$ and reduce the order

Set $y=(x+2)v(x)$: $y'=v+(x+2)v'$, $y''=2v'+(x+2)v''$. Substituting into $xy''-(x+2)y'+y=0$, the $v$ terms cancel and

\[ x(x+2)v'' + \bigl[2x-(x+2)^2\bigr]v' = 0 \implies x(x+2)v'' - (x^2+2x+4)v' = 0. \]

Step 4: Solve the first-order equation for $w=v'$

\[ \frac{dw}{w} = \frac{x^2+2x+4}{x(x+2)}\,dx. \]

Dividing $x^2+2x+4$ by $x(x+2)=x^2+2x$ leaves remainder $4$, so

\[ \frac{x^2+2x+4}{x(x+2)} = 1+\frac4{x(x+2)} = 1+\frac2x-\frac2{x+2}, \] where $\dfrac4{x(x+2)}=\dfrac{A}{x}+\dfrac{B}{x+2}$ gives $A=2$ (at $x=0$) and $B=-2$ (at $x=-2$). Integrating, \[\ln|w| = x+2\ln|x|-2\ln|x+2|+\mathrm{const} \implies w = \frac{A\,x^2e^x}{(x+2)^2}.\]

Step 5: Integrate for $v$

Write $\dfrac{x^2}{(x+2)^2}=\dfrac{(x+2)^2-4(x+2)+4}{(x+2)^2}=1-\dfrac4{x+2}+\dfrac4{(x+2)^2}$ (direct expansion of $(x+2-2)^2=x^2$), so

\[ v' = Ae^x\!\left(1-\frac4{x+2}+\frac4{(x+2)^2}\right). \]

Since, by the quotient rule, \[\frac{d}{dx}\!\left(-\frac{4e^x}{x+2}\right) = -\frac{4e^x}{x+2}+\frac{4e^x}{(x+2)^2},\]

integration gives

\[ v = Ae^x - \frac{4Ae^x}{x+2}+B = Ae^x\cdot\frac{x-2}{x+2}+B. \]

Step 6: General solution

Then $y=(x+2)v = A(x-2)e^x+B(x+2)$. Renaming $C_1=B$, $C_2=A$:

Step 7: Verify $y_2=(x-2)e^x$

\[ y_2'=(x-1)e^x,\qquad y_2''=xe^x. \]

\[ x\cdot xe^x - (x+2)(x-1)e^x + (x-2)e^x = e^x\bigl[x^2-(x^2+x-2)+(x-2)\bigr]=0.\ \checkmark \]

Step 8: Linear independence

\[ W(y_1,y_2) = \begin{vmatrix} x+2 & (x-2)e^x \\ 1 & (x-1)e^x\end{vmatrix} = e^x\bigl[(x+2)(x-1)-(x-2)\bigr] = x^2e^x \neq 0 \quad (x\neq0), \] so $y_1=x+2$ and $y_2=(x-2)e^x$ form a fundamental system.


Result

Final answer:

\[\boxed{\,y = C_1(x+2) + C_2(x-2)e^x\,}\]