### First Order DE

• Use analytical methods to solve first order differential equation by direct integration and separation of variables.

### Solved Example:

#### 3-2-01

9 grams of bacteria grows at the rate of $\dfrac{1}{5}$ gram per day per gram. At this rate how long will it take to reach 17 gram?

Solution:
$\dfrac{dm}{dt}=\dfrac{m}{5}$ $5\dfrac{dm}{m}=dt$ $5\int \dfrac{dm}{m}=\int dt+C$ $5\ln m=t+C$ $\ln m=\dfrac{t}{5}+c$ $m=e^{\frac{t}{5}}.e^{c}$ At t=0, m=9 grams $m=9e^{\frac{t}{5}}$ $17=9e^{\frac{t}{5}}$ t=3.18 days

### Solved Example:

#### 3-2-02

The population of a country doubles in 50 years. How many years will it be five times as much? Assume that the rate of increase is proportional to the number of inhabitants.

Solution:
\begin{align*} \dfrac{dN}{dt} &\propto N\\ \dfrac{dN}{dt} &= k.N\\ \dfrac{dN}{N} &= k.dt\\ \int \dfrac{dN}{N} &= \int k.dt + c\\ \ln\ N &= kt + c\\ N &= e^{(kt+c)}\\ &= e^{kt}.e^c\\ N &= C e^{kt} \end{align*} where C = $e^c$ $\dfrac{N_2}{N_1} = e^{k.(50)} = 2$ $\ln\ 2 = 50k$ $k = \dfrac{\ln\ 2}{50} = 0.01386$ Now, time to become five times $\dfrac{N_3}{N_1} = 5 = e^{0.01386(t)}$ $\ln\ 5 = 0.01386 t$ $t = \dfrac{\ln\ 5}{0.01386} = 116.09\ \mathrm{years}$

### Solved Example:

#### 3-2-03

What is the solution of the first order differential equation y(k+1) = y(k) + 5.

Solution:
\begin{align*} y\left( k+1\right) &=y\left( k\right) +5\\ y\left( k+1\right) -y\left( k\right) &=5\\ y'&=\dfrac {y\left( k+1\right) -y\left( k\right) }{\left( k+1\right) -k}\\ y'&=5\\ \dfrac {dy}{dx}&=5\\ dy &=5\ dx\\ y &=5x+c \end{align*} Where C is a constant.

### Solved Example:

#### 3-2-04

Solve xy' (2y - 1) = y (1 - x)

Solution:
\begin{align*} xy' (2y - 1) &= y (1 - x)\\ \dfrac{\dfrac{dy}{dx}(2y-1)}{y} &= \dfrac{(1-x)}{x}\\ \dfrac{dy (2y-1)}{y} &= \dfrac{(1-x)}{x} dx\\ \left(2 - \dfrac{1}{y}\right)dy &= \left( \dfrac{1}{x} - 1\right) dx \end{align*} Integrating, \begin{align*} \int \left(2 - \dfrac{1}{y}\right)dy &= \int \left( \dfrac{1}{x} - 1\right) dx + c\\ 2y - \ln\ y &= \ln\ x -x + c\\ x + 2y &= \ln\ x + \ln\ y + c\\ (x + 2y ) &= \ln (xy) + c \end{align*} Constant of integration can be shifted to the left side , let C = -c. $\ln (xy) = (x + 2y) + C$

### Solved Example:

#### 3-2-05

Find the general solution of y' = y $\sec x$.

Solution:
\begin{align*} y' &= y \sec x\\ \dfrac{dy}{dx} &= y \sec x\\ \dfrac{dy}{y} &= \sec x dx \end{align*} Integrating both sides, \begin{align*} \int \dfrac{dy}{y} &= \int \sec x dx + c\\ \ln\ y &= \ln(\sec x+ \tan x) + c \end{align*} rewriting c = $\ln$ C, \begin{align*} \ln\ y &= \ln(\sec x+ \tan x) + \ln\ C\\ y &= C (\sec x+ \tan x) \end{align*}

### Solved Example:

#### 3-2-06

Which of the following equations is a variable separable DE?

Solution:
Only equation given in (C) can be rearranged with x terms on one side and y terms on the other as follows. \begin{align*} 2ydx &=\left( x^{2}+1\right) dy\\ 2 \left(\dfrac {dx}{x^{2}+1} \right)&=\dfrac {dy}{y} \end{align*} Such differential equation is called variable separable differential equation.

### Solved Example:

#### 3-2-07

Radium decomposes at a rate proportional to the amount present. If half of the original amount disappears after 1000 years, what is the percentage lost in 100 years?

Solution:
\begin{align*} \dfrac {dN}{dt} &\propto N\\ \dfrac {dN}{dt} &=-kN\\ \dfrac {dN}{N} &=-kdt\\ \ln N &=-kt+c \end{align*} $\mathrm{At}\ t=0,N=N_{0}$ $C=\ln N_{0}$ \begin{align*} \ln \left( \dfrac {N}{N_{0}}\right) &=-kt\\ \ln \left( \dfrac {1}{2}\right) &=-k\left( 1000\right)\\ k &=\dfrac {-1}{1000}\ln \left( \dfrac {1}{2}\right)\\ k &=6.93\times 10^{-4} \end{align*} $\mathrm{At}\ t=100,$ \begin{align*} \dfrac {N}{N_{0}} &=e^{-kt}\\ &=e^{-6.93\times 10^{-4}\times 100}\\ &=0.933 \end{align*} $\mathrm{Lost}=1-0.933=0.067=6.7\%$

### Solved Example:

#### 3-2-08

According to Newton's law of cooling, the rate at which a substance cools in air is directly proportional to the difference between the temperature of the substance and that of air. If the temperature of the air is 30$^\circ$ and the substance cools from 100$^\circ$ to 70$^\circ$ in 15 minutes, how long will it take to cool 100$^\circ$ to 50$^\circ$?

Solution:
\begin{align*} \dfrac {d\theta }{dt} &\propto \left( \theta -\theta _{0}\right)\\ \dfrac {d\theta }{dt} &=-k\left( \theta -\theta _{0}\right)\\ \dfrac {d\theta }{\theta -\theta _{0}} &=-kdt\\ \ln \left( \theta -\theta _{0}\right) &=-kt+c \end{align*} $At\ t=0,\theta =100$ $\ln \left( \dfrac {100-30}{70-30}\right) =kt$ $k =\dfrac {1}{15}\ln\left[ \dfrac {70}{40}\right] =0.037$ $\ln \left[ \dfrac {100-30}{50-30}\right] =0.037t$ $t =\dfrac {1}{0.037}\ln \left[ \dfrac {70}{20}\right] =33.85\min$

### Solved Example:

#### 3-2-09

The solution of the differential equation $\dfrac{dy}{dx} + y^2 = 0$ is:

Solution:
\begin{align*} \dfrac {dy}{dx}+y^{2} &=0\\ \dfrac {dy}{dx} &=-y^{2}\\ -\dfrac {dy}{y^{2}} &=dx \end{align*} Integrating both the sides, we have \begin{align*} -\int \dfrac {dy}{y^{2}} &=\int dx\\ y^{-1} &=x+c\\ y &=\dfrac {1}{x+c} \end{align*}

Consider the differential equation $\dfrac {dy}{dx}=\left( 1+y^{2}\right)x$ The general solution with constant c is:
$\dfrac {dy}{dx}=\left( 1+y^{2}\right) x$ $\left( \dfrac {dy}{1+y^{2}}\right) =xdx$ Integrating both the sides, we get, $\int \dfrac {dy}{1+y^{2}}=\int xdx$ $\tan ^{-1}y=\dfrac {x^{2}}{2}+c$ $y=\tan \left( \dfrac {x^{2}}{2}+c\right)$