Integrating Factor Method. Why Can We Set the Constant of Integration to Zero?

My textbook gives a demonstration of the use of the integrating factor method for solving first order ordinary differential equations:

$\dfrac{dx}{dt} + p(t)x = r(t)$

$\implies g(t)\dfrac{dx}{dt} + g(t)p(t)x = g(t)r(t)$

$\dfrac{d}{dt}[g(t)x]$

We use the product rule and compare the expression to the left-hand side of the above equation:

$g(t)\dfrac{dx}{dt} + \dfrac{dg}{dt}x = g(t)\dfrac{dx}{dt}+g(t)p(t)x$

$\therefore \dfrac{dg}{dt} = g(t)p(t)$

The above equation is separable.

$\therefore \int\dfrac{dg}{g(t)} = \int p(t) dt$

$\implies ln[g(t)] = \int p(t)dt$

My textbook then says that, "We can set the constant of integration to zero -- any function that satisfies $\dfrac{dg}{dt} = g(t)p(t)$ will do for our purposes". However, it gives no explanation as to why this is the case. Why can we set the constant of integration to zero? Why is any function that satisfied $\dfrac{dg}{dt} = g(t)p(t)$ appropriate for our purposes?

I would greatly appreciate it if people could please take the time to elaborate on this.


Solution 1:

Integration Factor = $g(t) = \exp(\int p(t)dt) = \exp(P(t)+c) = \exp(P(t))\cdot\exp(c)$, where $P(t)$ is the antiderivative of $p(t)$.

Solution of LDE is:

$$x\cdot(\exp(P(t)+c)) = \int \exp(P(t)+c)\cdot r(t)dt$$

This factor $\exp(c)$ is cancelled from both sides! Paul has already elaborated thanks!

Solution 2:

It is not necessary to clarify what $g(t)$ actually is in order to solve the DE, all it requires is that $\frac{dg}{dt} = g(t)p(t)$ is satisfied. As such, any $g$ should do, and so why not use the cleanest one?

Let $\int p(t) dt = P(t) + C$. It turns out that: $$g(t) = e^{P(t) + C} = e^Ce^{P(t)}$$ If you plug this into the original differential equation, you can divide out by $e^C$ and the product rule can still be set up. As such, $C = 0$ works, and again, is easiest.