stuck on this integration problem

57 Views Asked by At

Solve the following IVP

$$ \dot y = y - t $$

where $t_0 = 1$ and $y(t_0) = y(1) = 1$.


What I did is this:

Let $u = y-t$

Therefore $ \frac{du}{dt} = \frac{dy}{dt} -1$

Hence, differential equation becomes

$\frac{du}{dt} +1 = u$

To integrate this by separation of variables,

$\frac{du}{u-1} = dt$

Hence,

$$ \int_{0}^{u} \frac{du}{u-1} = \int_{1}^{t} d t $$

where lower limit of $u = y(t=1) - t(0) = 1-1 = 0$ and lower limit of $t$ is $t_0 = 1.$

After integration,

$\log_e(u-1) \rvert_0^u = t-1$

$\log_e(u-1) - log_e(0-1) = t-1$

But $\log_e(-1)$ is not defined.

So how do I proceed further?

1

There are 1 best solutions below

2
On

For this type of ODE (by "this type" I mean that the ODE is equivalent to getting a difference of $y$ and $y'$ on one side of the ODE) you can also use the technique one uses to derive the formula for the variation of constants formula. It is \begin{align} y'=y-t\Leftrightarrow y'-y=-t. \end{align} Multiply the ODE by $e^{-t}$ which gives \begin{align} y'(t)e^{-t}-y(t)e^{-t}=-te^{-t}. \end{align} Why did we multiply the ODE by $e^{-t}$? Because now the term on the left hand side can be written as a derivative of a product. Indeed it is \begin{align} y'(t)e^{-t}-y(t)e^{-t}= \frac{d}{dt}(y(t)e^{-t}). \end{align} So you have \begin{align} \frac{d}{dt}(y(t)e^{-t})=-te^{-t}. \end{align} Now you can integrate the equation and use your initial condition. I leave the computation as an exercise.