# 17.1: First Order Differential Equations

- Page ID
- 4841

\( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

\( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)

\( \newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\)

( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\)

\( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\)

\( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\)

\( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\)

\( \newcommand{\Span}{\mathrm{span}}\)

\( \newcommand{\id}{\mathrm{id}}\)

\( \newcommand{\Span}{\mathrm{span}}\)

\( \newcommand{\kernel}{\mathrm{null}\,}\)

\( \newcommand{\range}{\mathrm{range}\,}\)

\( \newcommand{\RealPart}{\mathrm{Re}}\)

\( \newcommand{\ImaginaryPart}{\mathrm{Im}}\)

\( \newcommand{\Argument}{\mathrm{Arg}}\)

\( \newcommand{\norm}[1]{\| #1 \|}\)

\( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\)

\( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\AA}{\unicode[.8,0]{x212B}}\)

\( \newcommand{\vectorA}[1]{\vec{#1}} % arrow\)

\( \newcommand{\vectorAt}[1]{\vec{\text{#1}}} % arrow\)

\( \newcommand{\vectorB}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

\( \newcommand{\vectorC}[1]{\textbf{#1}} \)

\( \newcommand{\vectorD}[1]{\overrightarrow{#1}} \)

\( \newcommand{\vectorDt}[1]{\overrightarrow{\text{#1}}} \)

\( \newcommand{\vectE}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash{\mathbf {#1}}}} \)

\( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

\( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)

\(\newcommand{\avec}{\mathbf a}\) \(\newcommand{\bvec}{\mathbf b}\) \(\newcommand{\cvec}{\mathbf c}\) \(\newcommand{\dvec}{\mathbf d}\) \(\newcommand{\dtil}{\widetilde{\mathbf d}}\) \(\newcommand{\evec}{\mathbf e}\) \(\newcommand{\fvec}{\mathbf f}\) \(\newcommand{\nvec}{\mathbf n}\) \(\newcommand{\pvec}{\mathbf p}\) \(\newcommand{\qvec}{\mathbf q}\) \(\newcommand{\svec}{\mathbf s}\) \(\newcommand{\tvec}{\mathbf t}\) \(\newcommand{\uvec}{\mathbf u}\) \(\newcommand{\vvec}{\mathbf v}\) \(\newcommand{\wvec}{\mathbf w}\) \(\newcommand{\xvec}{\mathbf x}\) \(\newcommand{\yvec}{\mathbf y}\) \(\newcommand{\zvec}{\mathbf z}\) \(\newcommand{\rvec}{\mathbf r}\) \(\newcommand{\mvec}{\mathbf m}\) \(\newcommand{\zerovec}{\mathbf 0}\) \(\newcommand{\onevec}{\mathbf 1}\) \(\newcommand{\real}{\mathbb R}\) \(\newcommand{\twovec}[2]{\left[\begin{array}{r}#1 \\ #2 \end{array}\right]}\) \(\newcommand{\ctwovec}[2]{\left[\begin{array}{c}#1 \\ #2 \end{array}\right]}\) \(\newcommand{\threevec}[3]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \end{array}\right]}\) \(\newcommand{\cthreevec}[3]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \end{array}\right]}\) \(\newcommand{\fourvec}[4]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \\ #4 \end{array}\right]}\) \(\newcommand{\cfourvec}[4]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \\ #4 \end{array}\right]}\) \(\newcommand{\fivevec}[5]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \\ #4 \\ #5 \\ \end{array}\right]}\) \(\newcommand{\cfivevec}[5]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \\ #4 \\ #5 \\ \end{array}\right]}\) \(\newcommand{\mattwo}[4]{\left[\begin{array}{rr}#1 \amp #2 \\ #3 \amp #4 \\ \end{array}\right]}\) \(\newcommand{\laspan}[1]{\text{Span}\{#1\}}\) \(\newcommand{\bcal}{\cal B}\) \(\newcommand{\ccal}{\cal C}\) \(\newcommand{\scal}{\cal S}\) \(\newcommand{\wcal}{\cal W}\) \(\newcommand{\ecal}{\cal E}\) \(\newcommand{\coords}[2]{\left\{#1\right\}_{#2}}\) \(\newcommand{\gray}[1]{\color{gray}{#1}}\) \(\newcommand{\lgray}[1]{\color{lightgray}{#1}}\) \(\newcommand{\rank}{\operatorname{rank}}\) \(\newcommand{\row}{\text{Row}}\) \(\newcommand{\col}{\text{Col}}\) \(\renewcommand{\row}{\text{Row}}\) \(\newcommand{\nul}{\text{Nul}}\) \(\newcommand{\var}{\text{Var}}\) \(\newcommand{\corr}{\text{corr}}\) \(\newcommand{\len}[1]{\left|#1\right|}\) \(\newcommand{\bbar}{\overline{\bvec}}\) \(\newcommand{\bhat}{\widehat{\bvec}}\) \(\newcommand{\bperp}{\bvec^\perp}\) \(\newcommand{\xhat}{\widehat{\xvec}}\) \(\newcommand{\vhat}{\widehat{\vvec}}\) \(\newcommand{\uhat}{\widehat{\uvec}}\) \(\newcommand{\what}{\widehat{\wvec}}\) \(\newcommand{\Sighat}{\widehat{\Sigma}}\) \(\newcommand{\lt}{<}\) \(\newcommand{\gt}{>}\) \(\newcommand{\amp}{&}\) \(\definecolor{fillinmathshade}{gray}{0.9}\)We start by considering equations in which only the first derivative of the function appears.

Definition 17.1.1: First Order Differential Equation

A **first order differential equation** is an equation of the form \(F(t, y, \dot{y})=0\).

A solution of a first order differential equation is a function \(f(t)\) that makes \(F(t,f(t),f'(t))=0\) for every value of \(t\).

Here, \(F\) is a function of three variables which we label \(t\), \(y\), and \(\dot{y}\). It is understood that \(\dot{y}\) will explicitly appear in the equation although \(t\) and \(y\) need not. The term "first order'' means that the first derivative of \(y\) appears, but no higher order derivatives do.

Example \(\PageIndex{2}\):

The equation from Newton's law of cooling, \(\dot{y}=k(M-y)\) is a first order differential equation; \(F(t,y,\dot y)=k(M-y)-\dot y\).

Example \(\PageIndex{3}\):

\(\dot{y}=t^2+1\) is a first order differential equation; \(F(t,y,\dot y)= \dot y-t^2-1\). All solutions to this equation are of the form \(t^3/3+t+C\).

Definition 17.1.4: First Order Initial Value Problem

A **first order initial value problem** is a system of equations of the form \(F(t, y, \dot{y})=0\), \(y(t_0)=y_0\). Here \(t_0\) is a fixed time and \(y_0\) is a number.

A solution of an initial value problem is a solution \(f(t)\) of the differential equation that also satisfies the **initial condition **\(f(t_0) = y_0\).

Example \(\PageIndex{5}\):

The initial value problem \(\dot{y}=t^2+1\), \(y(1)=4\) has solution \( f(t)=t^3/3+t+8/3\).

The general first order equation is rather too general, that is, we can't describe methods that will work on them all, or even a large portion of them. We can make progress with specific kinds of first order differential equations. For example, much can be said about equations of the form \(\dot{y} = \phi (t, y)\) where \(\phi \) is a function of the two variables \(t\) and \(y\). Under reasonable conditions on \(\phi\), such an equation has a solution and the corresponding initial value problem has a unique solution. However, in general, these equations can be very difficult or impossible to solve explicitly.

Example \(\PageIndex{6}\):

Consider this specific example of an initial value problem for Newton's law of cooling: \(\dot y = 2(25-y)\), \(y(0)=40\). We first note that if \(y(t_0) = 25\), the right hand side of the differential equation is zero, and so the constant function \(y(t)=25\) is a solution to the differential equation. It is not a solution to the initial value problem, since \(y(0)\not=40\). (The physical interpretation of this constant solution is that if a liquid is at the same temperatureas its surroundings, then the liquid will stay at that temperature.) So long as \(y\) is not 25, we can rewrite the differential equation as

\[\eqalign{{dy\over dt}{1\over 25-y}&=2\cr{1\over 25-y}\,dy&=2\,dt,\cr}\]

so

\[\int {1\over 25-y}\,dy = \int 2\,dt,\]

that is, the two anti-derivatives must be the same except for a constant difference. We can calculate these anti-derivatives and rearrange the results:

\[\eqalign{\int {1\over 25-y}\,dy &= \int 2\,dt\cr (-1)\ln|25-y| &= 2t+C_0\cr \ln|25-y| &= -2t - C_0 = -2t + C\cr |25-y| &= e^{-2t+C}=e^{-2t} e^C\cr y-25 & = \pm\, e^C e^{-2t} \cr y &= 25 \pm e^C e^{-2t} =25+Ae^{-2t}.\cr}\]

Here \( A = \pm\, e^C = \pm\, e^{-C_0}\) is some non-zero constant. Since we want \(y(0)=40\), we substitute and solve for \(A\):

\[\eqalign{40&=25+Ae^0\cr 15&=A,\cr}\]

and so \( y=25+15 e^{-2t}\) is a solution to the initial value problem. Note that \(y\) is never 25, so this makes sense for all values of \(t\). However, if we allow \(A=0\) we get the solution \(y=25\) to the differential equation, which would be the solution to the initial value problem if we were to require \(y(0)=25\). Thus, \( y=25+Ae^{-2t}\) describes all solutions to the differential equation \(\dot y = 2(25-y)\), and all solutions to the associated initial value problems.

Why could we solve this problem? Our solution depended on rewriting the equation so that all instances of \(y\) were on one side of the equation and all instances of \(t\) were on the other; of course, in this case the only \(t\) was originally hidden, since we didn't write \(dy/dt\) in the original equation. This is not required, however.

Example \(\PageIndex{7}\):

Solve the differential equation \(\dot y = 2t(25-y)\). This is almost identical to the previous example. As before, \(y(t)=25\) is a solution. If \(y\not=25\),

\[\eqalign{\int {1\over 25-y}\,dy &= \int 2t\,dt\cr(-1)\ln|25-y| &= t^2+C_0\cr \ln|25-y| &= -t^2 - C_0 = -t^2 + C\cr |25-y| &= e^{-t^2+C}=e^{-t^2} e^C\cr y-25 & = \pm\, e^C e^{-t^2} \cr y &= 25 \pm e^C e^{-t^2} =25+Ae^{-t^2}.\cr}\]

As before, all solutions are represented by \(y=25+Ae^{-t^2}\), allowing \(A\) to be zero.

Definition 17.1.8: Separable Differential Equation

A first order differential equation is **separable** if it can be written in the form \(\dot{y} = f(t) g(y)\).

As in the examples, we can attempt to solve a separable equation by converting to the form

\[\int {1\over g(y)}\,dy=\int f(t)\,dt.\]

This technique is called **separation of variables**. The simplest (in principle) sort of separable equation is one in which \(g(y)=1\), in which case we attempt to solve

\[\int 1\,dy=\int f(t)\,dt.\]

We can do this if we can find an anti-derivative of \(f(t)\).

Also as we have seen so far, a differential equation typically has an infinite number of solutions. Ideally, but certainly not always, a corresponding initial value problem will have just one solution. A solution in which there are no unknown constants remaining is called a **particular solution**.

The general approach to separable equations is this: Suppose we wish to solve \(\dot{y} =f(t) g(y)\) where \(f\) and \(g\) are continuous functions. If \(g(a)=0\) for some \(a\) then \(y(t)=a\) is a constant solution of the equation, since in this case \(\dot y = 0 = f(t)g(a)\). For example, \(\dot{y} =y^2 -1\) has constant solutions \(y(t)=1\) and \(y(t)=-1\).

To find the nonconstant solutions, we note that the function \(1/g(y)\) is continuous where \(g\not=0\), so \(1/g\) has an antiderivative \(G\). Let \(F\) be an antiderivative of \(f\). Now we write

\[G(y) = \int {1\over g(y)}\,dy = \int f(t)\,dt=F(t)+C,\]

so \(G(y)=F(t)+C\). Now we solve this equation for \(y\).

Of course, there are a few places this ideal description could go wrong: we need to be able to find the antiderivatives \(G\) and \(F\), and we need to solve the final equation for \(y\). The upshot is that the solutions to the original differential equation are the constant solutions, if any, and all functions \(y\) that satisfy \(G(y)=F(t)+C\).

Example \(\PageIndex{9}\):

Consider the differential equation \(\dot y=ky\). When \(k>0\), this describes certain simple cases of population growth: it says that the change in the population \(y\) is proportional to the population. The underlying assumption is that each organism in the current population reproduces at a fixed rate, so the larger the population the more new organisms are produced. While this is too simple to model most real populations, it is useful in some cases over a limited time. When \(k<0\), the differential equation describes a quantity that decreases in proportion to the current value; this can be used to model radioactive decay.

The constant solution is \(y(t)=0\); of course this will not be the solution to any interesting initial value problem. For the non-constant solutions, we proceed much as before:

\[\eqalign{\int {1\over y}\,dy&=\int k\,dt\cr \ln|y| &= kt+C\cr |y| &= e^{kt} e^C\cr y &= \pm \,e^C e^{kt} \cr y&= Ae^{kt}.\cr}\]

Again, if we allow \(A=0\) this includes the constant solution, and we can simply say that \( y=Ae^{kt}\) is the general solution. With an initial value we can easily solve for \(A\) to get the solution of the initial value problem. In particular, if the initial value is given for time \(t=0\), \(y(0)=y_0\), then \(A=y_0\) and the solution is \( y= y_0 e^{kt}\).