# solve ODE solution with intial value

Consider the initial value problem $y' + \frac{2}{3}y = 1-\frac{1}{2}t, y(0) = y_0$ Find the value of $y_0$ for which the solution touches, but does not cross, the $t$-axis. Solving this equation with $\mu(t)=e^{\frac{2}{3}t}$ we get $y=\frac{21}{8}- \frac{3}{4}t + C e^{-\frac{2}{3}t}$, using $y(0)=y_0$ we get, $C=y_0-\frac{21}{8}$, so the solution that passes through $(0, y_0)$ is $y=\frac{21}{8}- \frac{3}{4}t + (y_0-\frac{21}{8}) e^{-\frac{2}{3}t}$, this solution has slope zero when it just touches the $t$-axis, so $y'=-\frac{3}{4}+(y_0-\frac{21}{8})e^{-\frac{2}{3}t}.(-\frac{2}{3})=0$, using $y(t)=0$ we have $(y_0-\frac{21}{8}) e^{-\frac{2}{3}t}=\frac{3}{4}t-\frac{21}{8}$ and using $y'=0$ we have $(y_0-\frac{21}{8})e^{-\frac{2}{3}t}=\frac{9}{8}$ therefore, $\frac{3}{4}t-\frac{21}{8}=\frac{9}{8} \Rightarrow t=5$ using $(y_0-\frac{21}{8})e^{-\frac{2}{3}(5)}=\frac{9}{8}$ we get $y_0=34.18$, but the answer is $y_0=-1.6428$

-

The solution is $$y(t)=\frac{21}{8}-\frac{3}{4}t + \left( y_0 - \frac{21}{8} \right)e^{-\frac{2}{3}t}.$$ The two conditions $y(t)=0$ and $y'(t)=0$ read $$\begin{cases} \frac{21}{8}-\frac{3}{4}t + \left( y_0-\frac{21}{8} \right) ^{-\frac{2}{3}t} =0 \\ -\frac{3}{4}-\frac{2}{3} \left( y_0-\frac{21}{8} \right)e^{-\frac{2}{3}t}=0. \end{cases}$$ By substitution, $$-\frac{3}{4}-\frac{2}{3} \left( \frac{3}{4}t-\frac{21}{8} \right)=0,$$ and $t=2$. Then $$y_0 = \frac{3}{8} \left(7-3 e^{\frac{4}{3}} \right) \approx -1.64288$$