On my exam I had to solve the following differential equation.
\begin{equation} (\ln(x)-1)y'' - \frac{1}{x}y' + \frac{1}{x^2}y = \frac{(\ln(x) - 1)^2}{x^2} \end{equation}
Which is a differential equation of the form: \begin{equation} y'' + a(x)y' + b(x)y = R(x) \end{equation}
The only method we've seen to solve this kind of differential equations is:
If the differential equation is of the form:
\begin{equation} y'' + a(x)y' + b(x)y = 0 \end{equation}
First find a solution of the characteristic equation, being $\varphi_1$. Then:
\begin{equation} \varphi_2(x) = \varphi_1(x)\int\frac{dx}{A(x)(\varphi_1(x))^2} \end{equation}
With $A(x) = e^{\int a(x) dx}$
Then the homogenous solution is given by:
\begin{equation} y(x) = c_1\varphi_1(x) + c_2\varphi_2(x) \end{equation}
The first problem is that this doesn't satisfy the requirements for this method since the differential equation is not homogenous, but since this is the only fitting method, I'd still try to use it. My guess would be to start with the characteristic equation which gives:
\begin{equation} (\ln(x)-1)x^2 - 1 + \frac{1}{x^2}y = 0 \end{equation}
or
\begin{equation} x^2 - \frac{1}{(\ln(x)-1)} + \frac{1}{x^2(\ln(x)-1)} = 0 \end{equation}
but i wouldn't even know how to start solving this equation to find the roots of the equation. Does anyone have an idea as to how to tackle this problem.
Note the only other ways of solving linear differential equations that we have seen are ways to solve first order differential equation or ways to solve second order differential equations in the form:
\begin{equation} y'' + py' + qy = R(x)\;\;\;\text{with}\;\; p,q\in\mathbb{R} \end{equation}
Replace $$\begin{align}z&=\ln x -1\\ w(z)&=y(x)\text{.}\end{align}$$ Then the differential equation is $$z w'' -(z+1)w'+w=z^2\mathrm{e}^{z+1}\text{.}$$ The linear differential operator on the left side factors, so the solution to this equation can be found by solving in turn the first-order equations $$\begin{align} zv'-v&=z^2\mathrm{e}^{z+1} \\ w'-w&=v\text{.} \end{align}$$ Another form for these equations is $$\begin{align} \left(\tfrac{v}{z}\right)'&=\mathrm{e}^{z+1} \\ (\mathrm{e}^{-z}w)'&=\mathrm{e}^{-z}v\text{.} \end{align}$$