First-Order Linear Differential Equations

I have the following exepression in my book:

$$\frac{dx}{dt}+a_1(t)x=g(t), \ \ \ \ x(t_0)=x_0$$

Then it says, multiply both sides of the differential equation by the integrating factor $I(t)$.

$$I(t) \frac{dx(t)}{dt}+a_1(t)I(t)x(t)=I(t)g(t)$$

So far so good. Hereafter it says, the left-hand side is an exact derivative.

$$\frac{d[x(t)I(t)]}{dt}=I(t)g(t)$$

And my question is, how does the book come to the last? Can anyone give a HINT.

• Do they tell you what the integrating factor is? Because if they do, you really just need to differentiate the LHS of the last equality. Edit: This should make it clear. Beware that the link isn't a hint at all, but I don't see what good a hint would be here, nor if a good hint exists in this case. – Git Gud Oct 15 '15 at 13:12

I suppose that the integrating factor $I$ is defined by $$I(t) = \exp\left(\int_{t_0}^t a_1(s)\, ds\right)$$ and hence has the property $$I'(t) = \exp\left(\int_{t_0}^t a_1(s)\,ds\right)a_1(t) = I(t)a_1(t)$$ so $$\frac{d}{dt}\bigl(x(t)I(t)\bigr) = \frac{d}{dt}x(t)\cdot I(t) + x(t) \cdot \frac{d}{dt} I(t) = \frac{d}{dt}x(t)\cdot I(t) + x(t)a_1(t)I(t)$$ which is the left hand side.
• I am asuming you use the chain rule ($f'(g(x)) \cdot g'(x)$) but how do you take the derivative of the inner part? – Alim Teacher Oct 15 '15 at 13:33
• By the fundamental theorem of calculus, we have $\frac{d}{dt}\int_{t_0}^t a(s)\,ds = a(t)$. – martini Oct 15 '15 at 13:34