# An application of integrating factors (basic ODE)

I'm trying to use integrating factors to solve the ODE ($$g_1, g_0$$ are both functions of $$\xi$$): $$$$\frac{d g_{1}}{d \xi}-\left(\frac{g_{0}^{\prime \prime}}{g_{0}^{\prime}}\right) g_{1}=-g_{0}^{\prime \prime}.$$$$ I multiply both sides by the integrating factor $$e^{-\int g_{0}^{\prime \prime} / g_{0}^{\prime} d \xi}$$: $$$$\frac{d e^{-\int g_{0}^{\prime \prime} / g_{0}^{\prime} d \xi}g_{1}}{d \xi}=-g_{0}^{\prime \prime}e^{-\int g_{0}^{\prime \prime} / g_{0}^{\prime} d \xi} \implies e^{-\int g_{0}^{\prime \prime} / g_{0}^{\prime} d \xi}g_{1} = \int -g_{0}^{\prime \prime}e^{-\int g_{0}^{\prime \prime} / g_{0}^{\prime} d \xi} d \xi.$$$$ We use integration by parts: $$\int -g_{0}^{\prime \prime}e^{-\int g_{0}^{\prime \prime} / g_{0}^{\prime} d \xi} d \xi = -g_{0}^{\prime }e^{-\int g_{0}^{\prime \prime} / g_{0}^{\prime} d \xi} d \xi - \int g_{0}^{\prime \prime}e^{-\int g_{0}^{\prime \prime} / g_{0}^{\prime} d \xi} d \xi.$$ This is clearly an incorrect result. Where have I gone wrong? The solution to this problem states that I should obtain: $$$$g_{1}(\xi) =C g_{0}^{\prime}-g_{0}^{\prime} \int \frac{g_{0}^{\prime \prime}}{g_{0}^{\prime}} d \xi =C g_{0}^{\prime}-g_{0}^{\prime} \ln \left|g_{0}^{\prime}\right|$$$$

$$v(\xi) = -\int\frac{g_0''(\xi)}{g'_0(\xi)} {\rm d}\xi = -\ln g_0'(\xi)$$
$$\begin{eqnarray} g_1(\xi) &=& -e^{-v(\xi)} \int e^{v(\xi)}g_0''(\xi){\rm d}\xi \\ &=& -e^{\ln g_0'(\xi)} \int e^{-\ln g_0'(\xi)} g_0''(\xi){\rm d}\xi \\ &=& -g_0'(\xi) \int \frac{g_0''(\xi)}{g_0'(\xi)}{\rm d}\xi \\ &=& -g_0'(\xi)\left[ \ln g_0'(\xi) + C \right] \end{eqnarray}$$
notice that: $$\int\frac{g''_0}{g'_0}d\xi\stackrel{\color{red}{u=g_0'}}{=}\int\frac1udu=\ln|u|=\ln|g_0'|+C$$ so subbing that in what is your result?