# General Solution To Linear First Order ODEs

A linear ordinary differential equation (ODE) is any equation of the form:

This differential equation is ordinary because it only contains derivatives of a single dependent variable, y. It is linear because each derivative of $y$ is linear (i.e. there is no $(\frac{dy}{dx})^{2}$ etc.). A first order linear ODE contains only the first derivative.

Linear ODEs of this type have a general solution that can be found through the use of an integrating factor. The goal is to choose an integrating factor, $p(x)$, such that the above form is equivalent to:

Notice that this can be rewritten as:

By comparing (1) and (2), we notice that $p(x)$ is an integrating factor if and only if

By inspection we can see that a solution for $p(x)$ is

Now the solution of (1) can be found by integration.

And we have our solution. Note that there are other ways to solve linear ODEs that may be much faster than this for specific scenarios. However this solution works in all cases.