Simple ODE $\frac{f''}{f'}=-2\frac{g'}{g}$ I have stuck with ODE problems. 
\begin{align}
\frac{f''}{f'}=-2\frac{g'}{g}
\end{align}
Here i know the solution is $ g^2 f' =const$. but i don't know how to obtain those relation. 
It seems simple. 
Is my approach is correct?
\begin{align}
\int \frac{f''}{f'}dx= -2\int \frac{g'}{g} dx =const
\end{align}
\begin{align}
\ln(f') = -2 \ln(g) = const, \quad \ln(f' g^2) =const \therefore f'g^2 =const
\end{align}
Maybe it is more construct way 
\begin{align}
&\int \frac{f''}{f'}dx= -2\int \frac{g'}{g} dx \\
& \ln(f')+Const = -2 \ln(g) +Const' \\
& \ln(f'g^2) = Const-Const' = Const''
\end{align}
 A: I would rather write it this way : I am under the understanding that f and g are functions of the same variable. By hypothesis, f' and g are supposed to have none zeros (denominator..). So $f'*g^2$ is always $\neq 0$.
$ \frac{f''}{f'} + 2\frac{g'}{g} = 0  => f'*g^2(\frac{f''}{f'} + 2\frac{g'}{g}) = 0 $ => $ \int (f'*g^2*(\frac{f''}{f'} + 2\frac{g'}{g})) = 0 $ Here the $\int$ is an indefinite primitive, a constant will show up.
Hence you get : $ \int (f'*g^2*(\frac{f''}{f'} + 2\frac{g'}{g})) = \int (g^2*f" + 2*g*g'*f')) =  \int (f'*g^2)' = f'*g^2 +cte = 0$ 
Reciprocally, if : $ f'*g^2 = cte $ => $ f"*g^2 + 2*f'*g'*g = 0 $ Dividing by $f'*g^2 \neq 0$ , you get :
$ \frac{f''}{f'} + 2\frac{g'}{g} = 0 $ Hence this is all your solutions.
I think it's clearer than saying : $ \int \frac{f''}{f'}dx= -2\int \frac{g'}{g} dx =const $ because it's not exactly true. What you say is that :$ ln(f') = -2*ln(g) = cte$ which might be true, but it's not always the case. This is only one possibility out of all possible solutions of the ODE.
A: Multiply everything by $f'\cdot g^2$ to rewrite the differential equation as $$f''\cdot g^2+2g'\cdot g\cdot f'=0,$$ and note that the LHS is $$(f')'\cdot g^2+f'\cdot (g^2)'=(f'\cdot g^2)',$$ to deduce that the solutions are $$f'\cdot g^2=C.$$
