# General solution for a differential equation

I have the following differential equation from a Bellman equation ;

$\displaystyle V\left(s\right)=e^{-rt_{0}\left(s\right)}V\left(S_{2}\right)$ for $s<s_{2}$

In calculations, authors (of the paper that I read) found the general solution in a following way ;

$\displaystyle V\left(s\right)=e^{-rt_{0}\left(s\right)V\left(S_{2}\right)}$

Where they have defined $t_{0}^{'}(s) = -\frac{1}{G(s)}$

Some hints ? or how can I find this general form ?

Just put the $V$'s on one side $$\frac{V'(s)}{V(s)} = \frac{r}{G(s)}$$ and integrate from $s$ to $s_2$ $$\int_s^{s_2} \frac{V'}{V} = \int_s^{s_2} \frac{r}{G}$$ which comes out to $$\ln V(s_2) - \ln V(s) = r t_0(s)$$ where $t_0(s)$ is defined as $$t_0(s) = \int_s^{s_2} \frac{1}{G}.$$ It follows that $$\ln V(s) = -rt_0(s) + \ln V(s_2)$$ which upon exponentiation gives you $$V(s) = e^{-r t_0(s)} V(s_2).$$