Calculus3Differential Equations1 of 7
Differential Equations · 1

Introduction to Differential Equations

1

What a differential equation is

When we're given dydx=2x\der{\frac{dy}{dx}} = \oth{2x}, finding y\yfn{y} is just finding an antiderivative, y=x2+C\yfn{y = x^2} + \cst{C}. But if we change one letter, to dydx=2y\der{\frac{dy}{dx}} = \oth{2y}, integrating stops working. Let's see why, and find a function that works anyway.

Find a function with dydx=2y\der{\frac{dy}{dx}} = \oth{2y}
dydx=2x→y=x2+Cdydx=2y→y=  ?\displaystyle \begin{aligned}\der{\frac{dy}{dx}} &= \oth{2x} \quad\to\quad \yfn{y = x^2} + \cst{C}\\[6pt] \der{\frac{dy}{dx}} &= \oth{2y} \quad\to\quad \yfn{y} = \;?\end{aligned}
Text solution
Why we can't integratey\yfn{y} is an unknown function of xx, the very function we're trying to find, so we can't integrate 2y\oth{2y} with respect to xx.
∫2y dx\displaystyle \int \oth{2y}\,dx =  ?\displaystyle = \;?
Read it as slope and heightThe equation says that at every point on the curve, the slope is twice the height. At height 3\yfn{3} the slope must be 6\oth{6}. So we need a function whose derivative is twice itself.
Try y=e2x\yfn{y = e^{2x}}exe^x is its own derivative, so we put a 22 in the exponent, and the chain rule brings that 22 out.
dydx\displaystyle \der{\frac{dy}{dx}} =e2x⋅2\displaystyle = \der{e^{2x}\cdot 2} =2⋅e2x\displaystyle = 2\cdot \yfn{e^{2x}} =2y\displaystyle = 2\yfn{y}

An equation like dydx=2y\der{\frac{dy}{dx}} = \oth{2y}, with an unknown function and its derivatives, is called a differential equation. You'll often see it written y′=2y\der{y'} = \oth{2y}, which means the exact same thing. A function that makes the equation true for every xx is called a solution.

So a solution isn't a number, the way x=0x = 0 and x=3x = 3 solve x2=3xx^2 = 3x. It's a whole function, like y=e2x\yfn{y = e^{2x}}, and we check it by substituting the function for y\yfn{y} and its derivative for dydx\der{\frac{dy}{dx}}.

2

Checking whether a function is a solution

We know y=e2x\yfn{y = e^{2x}} solves dydx=2y\der{\frac{dy}{dx}} = \oth{2y}. Let's test two more functions the same way, and then find the constant functions that solve a new equation.

Test whether y=3e2x\yfn{y = 3e^{2x}} and y=x2\yfn{y = x^2} solve dydx=2y\der{\frac{dy}{dx}} = \oth{2y}, and find the constant solutions of dydt=y(4−y)\der{\frac{dy}{dt}} = \oth{y(4 - y)}
dydx=2yy=3e2x  ?y=x2  ?\displaystyle \begin{gathered}\der{\frac{dy}{dx}} = \oth{2y}\\ \yfn{y = 3e^{2x}}\;? \qquad \yfn{y = x^2}\;?\end{gathered}
dydt=y(4−y)y=c,c=  ?\displaystyle \begin{gathered}\der{\frac{dy}{dt}} = \oth{y(4 - y)}\\ \yfn{y = c}, \qquad \yfn{c} = \;?\end{gathered}
Text solution
Test y=3e2x\yfn{y = 3e^{2x}}Both sides come out as the same expression, so they're equal for every xx, and y=3e2x\yfn{y = 3e^{2x}} is a solution.
dydx=6e2x2y=2⋅3e2x=6e2x\displaystyle \begin{aligned}\der{\frac{dy}{dx}} &= \der{6e^{2x}}\\ \oth{2y} &= \oth{2\cdot 3e^{2x}} = \oth{6e^{2x}}\end{aligned}
Test y=x2\yfn{y = x^2}The two sides are equal at x=0x = 0 and x=1x = 1, but not at x=2x = 2. They aren't equal for every xx, so y=x2\yfn{y = x^2} is not a solution.
dydx=2x2y=2x2\displaystyle \begin{aligned}\der{\frac{dy}{dx}} &= \der{2x}\\ \oth{2y} &= \oth{2x^2}\end{aligned}
x=2: 4≠8\displaystyle {x = 2}{:}\ \der{4} \ne \oth{8}
Constant solutionsAny constant has derivative 0\der{0}, so it solves dydt=y(4−y)\der{\frac{dy}{dt}} = \oth{y(4 - y)} exactly when the right side is 00. y=2\yfn{y = 2} isn't a solution, because there the right side is 4\oth{4}.
y(4−y)=0  →  y=0, y=4\displaystyle {\oth{y(4 - y)} = 0 \;\to\; \yfn{y = 0},\ \yfn{y = 4}}

When a constant function solves a differential equation, we call it a constant solution. For dydt=y(4−y)\der{\frac{dy}{dt}} = \oth{y(4 - y)}, those are y=0\yfn{y = 0} and y=4\yfn{y = 4}.

The test of y=x2\yfn{y = x^2} is the one to remember. Checking a couple of points made it look like a solution, but the two sides have to be the same expression, so that their graphs are the same curve.

11
22
22
44
66
88
xx
yy
y=x2\htmlClass{lc-green}{y = x^2}
(1,2)(1, 2)
(2,4)\htmlClass{lc-pink}{(2, 4)}
(2,8)\htmlClass{lc-blue}{(2, 8)}
y=2x\htmlClass{lc-pink}{y = 2x}
y=2x2\htmlClass{lc-blue}{y = 2x^2}
11
22
xx
yy
y=3e2x\htmlClass{lc-green}{y = 3e^{2x}}
y=6e2x\htmlClass{lc-pink}{y = 6e^{2x}}
y=6e2x\htmlClass{lc-blue}{y = 6e^{2x}}
The line y=2x\der{y = 2x} and the parabola y=2x2\oth{y = 2x^2} intersect at x=0x = 0 and x=1x = 1, but nowhere else. For y=3e2x\yfn{y = 3e^{2x}}, both sides give the same curve.
3

Families of solutions and initial conditions

Both e2x\yfn{e^{2x}} and 3e2x\yfn{3e^{2x}} solve dydx=2y\der{\frac{dy}{dx}} = \oth{2y}, so what do all the solutions look like? For dydx=2x\der{\frac{dy}{dx}} = \oth{2x}, adding C\cst{C} gave us every solution, so it's natural to try e2x+C\yfn{e^{2x}} + \cst{C} here too.

Why the solutions of dydx=2y\der{\frac{dy}{dx}} = \oth{2y} are Ce2x\cst{C}\yfn{e^{2x}} and not e2x+C\yfn{e^{2x}} + \cst{C}
dydx=2yy=e2x+C  ?y=Ce2x  ?\displaystyle \begin{gathered}\der{\frac{dy}{dx}} = \oth{2y}\\ \yfn{y = e^{2x}} + \cst{C}\;? \qquad \yfn{y = }\cst{C}\yfn{e^{2x}}\;?\end{gathered}
Text solution
Why adding C\cst{C} worked for 2x\oth{2x}The derivative of a constant is 00, so shifting the parabola up or down keeps every slope. And the slope dydx=2x\der{\frac{dy}{dx}} = \oth{2x} asks for depends only on xx.
ddx(x2+C)\displaystyle \der{\frac{d}{dx}\left(x^2 + \cst{C}\right)} =2x\displaystyle = \oth{2x}
Shifting e2x\yfn{e^{2x}} doesn't workHere the slope must be twice the height. Adding C\cst{C} changes the height but not the slope, so the two sides match only when C=0\cst{C} = 0.
dydx=2e2x2y=2e2x+2C\displaystyle \begin{aligned}\der{\frac{dy}{dx}} &= \der{2e^{2x}}\\ \oth{2y} &= \oth{2e^{2x} + 2\cst{C}}\end{aligned}
Multiplying doesBy the constant multiple rule, multiplying by C\cst{C} multiplies both the height and the slope by C\cst{C}, so the slope stays twice the height for every C\cst{C}. C=0\cst{C} = 0 gives the constant solution y=0\yfn{y = 0}.
y\displaystyle \yfn{y} =Ce2x:dydx\displaystyle = \cst{C}\yfn{e^{2x}}{:} \quad \der{\frac{dy}{dx}} =2Ce2x\displaystyle = \der{2\cst{C}e^{2x}} =2y\displaystyle = \oth{2y}

Here are the three curves at x=0x = 0. Shifting by 22 raised the height to 3\yfn{3} and left the slope at 2\der{2}, while multiplying by 33 tripled both.

y=e2x\displaystyle \yfn{y = e^{2x}}
y(0)=1\displaystyle {\yfn{y(0)} = \yfn{1}}
y′(0)=2\displaystyle {\der{y'(0)} = \der{2}}
2y(0)=2\displaystyle {\oth{2y(0)} = \oth{2}}
y=e2x+2\displaystyle \yfn{y = e^{2x} + 2}
y(0)=3\displaystyle {\yfn{y(0)} = \yfn{3}}
y′(0)=2\displaystyle {\der{y'(0)} = \der{2}}
2y(0)=6\displaystyle {\oth{2y(0)} = \oth{6}}
y=3e2x\displaystyle \yfn{y = 3e^{2x}}
y(0)=3\displaystyle {\yfn{y(0)} = \yfn{3}}
y′(0)=6\displaystyle {\der{y'(0)} = \der{6}}
2y(0)=6\displaystyle {\oth{2y(0)} = \oth{6}}

Finding the curve through a given point

Every value of C\cst{C} gives a solution, so we call y=Ce2x\yfn{y} = \cst{C}\yfn{e^{2x}} the general solution. A requirement like y(0)=3\cst{y(0) = 3}, which picks the curve through (0,3)\cst{(0, 3)}, is called an initial condition, and the equation together with it is an initial value problem. The one curve it picks is a particular solution.

Find the particular solutions for dydx=2y\der{\frac{dy}{dx}} = \oth{2y} and y′′=6x\der{y''} = \oth{6x}
xx
yy
y=Ce2x\htmlClass{lc-green}{y = }\htmlClass{lc-orange}{C}\htmlClass{lc-green}{e^{2x}}
C=2\htmlClass{lc-orange}{C} = 2
C=1\htmlClass{lc-orange}{C} = 1
C=−1\htmlClass{lc-orange}{C} = -1
(0,3)\htmlClass{lc-orange}{(0, 3)}
Text solution
Plug in the pointSubstitute the point's coordinates into the general solution and solve for C\cst{C}. At x=0x = 0, e0=1e^0 = 1, so C\cst{C} is just the y-value.
y(0)=3:3=Ce0=C→  y=3e2x\displaystyle \begin{aligned}&\cst{y(0) = 3}: \quad \cst{3} = \cst{C}e^{0} = \cst{C}\\ &\qquad \to\; y = 3e^{2x}\end{aligned}
At another xx, C\cst{C} isn't the y-valueThe curve y=3e2xy = 3e^{2x} has height 3e23e^2 at x=1x = 1, so it misses (1,3)\cst{(1, 3)}. We plug in both coordinates instead.
y(1)=3:3=Ce2→  C=3e2→  y=3e2 e2x=3e2x−2\displaystyle \begin{aligned}&\cst{y(1) = 3}: \quad \cst{3} = \cst{C}e^{2}\\ &\qquad \to\; \cst{C} = \frac{3}{e^2}\\ &\qquad \to\; y = \frac{3}{e^2}\,e^{2x} = 3e^{2x-2}\end{aligned}
Integrate y′′=6x\der{y''} = \oth{6x} twiceEach integration brings in its own constant.
y′′=6x→y′=3x2+C1→y=x3+C1x+C2\displaystyle \begin{aligned}\der{y''} &= \oth{6x}\\ \to\quad \der{y'} &= 3x^2 + \cst{C_1}\\ \to\quad \yfn{y} &= x^3 + \cst{C_1}x + \cst{C_2}\end{aligned}
One condition for each constanty′(0)=2\cst{y'(0) = 2} fixes C1\cst{C_1}, and then y(0)=1\cst{y(0) = 1} fixes C2\cst{C_2}.
y′(0)=2  →  C1=2y(0)=1  →  C2=1\displaystyle \begin{aligned}\cst{y'(0) = 2} &\;\to\; \cst{C_1} = 2\\ \cst{y(0) = 1} &\;\to\; \cst{C_2} = 1\end{aligned}
y\displaystyle y =x3+2x+1\displaystyle = x^3 + 2x + 1

The order of a differential equation is the order of its highest derivative, so dydx=2y\der{\frac{dy}{dx}} = \oth{2y} is first order and y′′=6x\der{y''} = \oth{6x} is second order. A second-order equation has two constants, so it needs two conditions to pick out one curve, just as motion problems need v(0)\cst{v(0)} to get velocity from acceleration and s(0)\cst{s(0)} to get position from velocity.

Does adding a constant still give a solution?

4

Solutions of the form erxe^{rx} and cos⁡(kt)\cos(kt)

Sometimes we're told the form of a solution, like erx\yfn{e^{\kfix{r}x}} or cos⁡(kt)\yfn{\cos(\kfix{k}t)}, and we only need the constant that makes it work. We find it the same way we checked solutions, by substituting the function and its derivatives into the equation.

Find the values of r\kfix{r} for which y=erx\yfn{y = e^{\kfix{r}x}} solves y′′−y′−6y=0\der{y''} - \der{y'} - 6\yfn{y} = 0, and the values of k\kfix{k} for which y=cos⁡(kt)\yfn{y = \cos(\kfix{k}t)} solves y′′+9y=0\der{y''} + 9\yfn{y} = 0
y′′−y′−6y=0y=erx,r=  ?\displaystyle \begin{gathered}\der{y''} - \der{y'} - 6\yfn{y} = 0\\ \yfn{y = e^{\kfix{r}x}}, \qquad \kfix{r} = \;?\end{gathered}
y′′+9y=0y=cos⁡(kt),k=  ?\displaystyle \begin{gathered}\der{y''} + 9\yfn{y} = 0\\ \yfn{y = \cos(\kfix{k}t)}, \qquad \kfix{k} = \;?\end{gathered}
Text solution
DifferentiateBy the chain rule, each derivative brings down another r\kfix{r}.
y′\displaystyle \der{y'} =rerx,y′′\displaystyle = \der{\kfix{r}e^{rx}}, \qquad \der{y''} =r2erx\displaystyle = \der{\kfix{r^2}e^{rx}}
Substitute and factor out erx\yfn{e^{rx}}Every term has an erx\yfn{e^{rx}}.
r2erx−rerx−6erx=erx(r2−r−6)=0\displaystyle \begin{aligned}&\kfix{r^2}\yfn{e^{rx}} - \kfix{r}\yfn{e^{rx}} - 6\yfn{e^{rx}}\\ &= \yfn{e^{rx}}\kfix{\left(r^2 - r - 6\right)} = 0\end{aligned}
Set the bracket to 00erx\yfn{e^{rx}} is never 00, so the product is 00 for every xx only when the bracket is 00.
(r−3)(r+2)\displaystyle \kfix{(r - 3)(r + 2)} =0  →  r\displaystyle = 0 \;\to\; r =3, r\displaystyle = 3,\ r =−2\displaystyle = -2
The same steps for cos⁡(kt)\yfn{\cos(\kfix{k}t)}Two derivatives bring out k2\kfix{k^2}, and cos⁡(kt)\yfn{\cos(kt)} factors out. It isn't 00 everywhere, since cos⁡0=1\cos 0 = 1, so the bracket must be 00.
y′′\displaystyle \der{y''} =−k2cos⁡(kt)\displaystyle = \der{-\kfix{k^2}\cos(kt)}
(9−k2)cos⁡(kt)\displaystyle \kfix{\left(9 - k^2\right)}\yfn{\cos(kt)} =0\displaystyle = 0
9−k2=0  →  k=3, k=−3\displaystyle {\kfix{9 - k^2} = 0 \;\to\; k = 3,\ k = -3}
5

Writing a differential equation from a sentence

In word problems, the rate is usually described in a sentence, and we write the differential equation ourselves. We translate the sentence one phrase at a time.

the rate of change of P\displaystyle {\der{\text{the rate of change of } P}}
→  dPdt\displaystyle \to\; \der{\frac{dP}{dt}}
is\displaystyle \text{is}
→  =\displaystyle \to\; {=}
proportional to P\displaystyle {\kfix{\text{proportional to }}\oth{P}}
→  kP\displaystyle \to\; \kfix{k}\oth{P}
inversely proportional to P\displaystyle {\kfix{\text{inversely proportional to }}\oth{P}}
→  kP\displaystyle \to\; \frac{\kfix{k}}{\oth{P}}
Write differential equations for a growing population and a cooling cup of coffee
growing population PdPdt=  ?\displaystyle \begin{gathered}\text{growing population } P\\ \der{\frac{dP}{dt}} = \;?\end{gathered}
coffee in a 70∘F roomdTdt=  ?\displaystyle \begin{gathered}\text{coffee in a } 70^\circ\text{F room}\\ \der{\frac{dT}{dt}} = \;?\end{gathered}
Text solution
A growing populationA rate proportional to its size gives kP\kfix{k}\oth{P}. The population grows, so dPdt\der{\frac{dP}{dt}} is positive, and P\oth{P} is positive too, so k\kfix{k} is positive.
dPdt\displaystyle \der{\frac{dP}{dt}} =kP,k>0\displaystyle = \kfix{k}\oth{P}, \qquad \kfix{k} \gt 0
Coffee in a 70∘F70^\circ\text{F} roomThe temperature TT changes at a rate proportional to the difference between the coffee's temperature and the room's.
dTdt\displaystyle \der{\frac{dT}{dt}} =k(T−70)\displaystyle = \kfix{k}(\oth{T - 70})
Choose the signThe coffee is hotter than the room but cooling, so k\kfix{k} must be negative. Writing the minus sign out front lets k\kfix{k} itself be positive, and it's the same equation.
T−70>0,dTdt<0\displaystyle {\oth{T - 70} \gt 0}, \qquad {\der{\frac{dT}{dt}} \lt 0}
dTdt\displaystyle \der{\frac{dT}{dt}} =−k(T−70),k>0\displaystyle = \kfix{-k}(\oth{T - 70}), \qquad \kfix{k} \gt 0
The rate at one momentWith k=0.1\kfix{k = 0.1} and the coffee at 150∘F150^\circ\text{F}, the equation says it's cooling at 8∘F8^\circ\text{F} per minute, without solving anything. At T=70\yfn{T = 70} the rate is 00, so T=70\yfn{T = 70} is a constant solution.
k=0.1, T=150:dTdt=−0.1(150−70)=−8\displaystyle \begin{aligned}&\kfix{k = 0.1},\ \yfn{T = 150}{:}\\ &\der{\frac{dT}{dt}} = \kfix{-0.1}(\oth{150 - 70}) = -8\end{aligned}

Here's the coffee sentence again, with each phrase carried to its piece of the equation.

Its temperature
T\htmlClass{lc-pink}{T} changes
at a rate
proportional to
the difference
between T\htmlClass{lc-blue}{T} and
the room’s 70°F
dTdt=k (T−70)\htmlClass{lc-pink}{\frac{dT}{dt}} = \htmlClass{lc-violet}{k}\,(\htmlClass{lc-blue}{T - 70})
Its
temperature
T\htmlClass{lc-pink}{T} changes
at a rate
proportional
to
the
difference
between T\htmlClass{lc-blue}{T}
and the
room’s 70°F
dTdt=k (T−70)\htmlClass{lc-pink}{\frac{dT}{dt}} = \htmlClass{lc-violet}{k}\,(\htmlClass{lc-blue}{T - 70})

Summary

What makes a function a solution
y=3e2x:\displaystyle \yfn{y = 3e^{2x}}{:}
dydx=6e2x2y=6e2x\displaystyle \begin{aligned}\der{\frac{dy}{dx}} &= \der{6e^{2x}}\\ \oth{2y} &= \oth{6e^{2x}}\end{aligned}
y=x2:\displaystyle \yfn{y = x^2}{:}
dydx=2x2y=2x2\displaystyle \begin{aligned}\der{\frac{dy}{dx}} &= \der{2x}\\ \oth{2y} &= \oth{2x^2}\end{aligned}

To check whether a function is a solution, substitute y\yfn{y} and its derivatives into both sides of the equation. If both sides simplify to the exact same expression for every xx, the function is a solution. For y=3e2x\yfn{y = 3e^{2x}}, both sides equal 6e2x6e^{2x} everywhere. For y=x2\yfn{y = x^2}, the two sides match only at x=0x = 0 and x=1x = 1, so it's not a solution.

Constant solutions
dydt\displaystyle \der{\frac{dy}{dt}} =y(4−y)\displaystyle = \oth{y(4 - y)}
y(4−y)\displaystyle \oth{y(4 - y)} =0  →  y=0, y=4\displaystyle = 0 \;\to\; \yfn{y = 0},\ \yfn{y = 4}

For a constant solution y=c\yfn{y = c}, the function doesn't change, so its derivative is 00. To find all constant solutions, replace dydt\der{\frac{dy}{dt}} with 00 and solve for y\yfn{y}.

General and particular solutions
dydx\displaystyle \der{\frac{dy}{dx}} =2y:y\displaystyle = \oth{2y}: \quad \yfn{y} =Ce2x\displaystyle = \cst{C}\yfn{e^{2x}}
y(1)=3:3=Ce2→  C=3e2\displaystyle \begin{aligned}\cst{y(1) = 3}: &\quad \cst{3} = \cst{C}e^2\\ &\quad \to\; \cst{C} = \frac{3}{e^2}\end{aligned}

The equation says the slope must be twice the height at every point. Multiplying e2x\yfn{e^{2x}} by a constant C\cst{C} multiplies both the height and the slope by C\cst{C}, keeping the slope equal to 2y\oth{2y}, so the general solution is y=Ce2x\yfn{y} = \cst{C}\yfn{e^{2x}}, not e2x+C\yfn{e^{2x}} + \cst{C}. To find the particular solution through a point, plug the point's coordinates into the general solution and solve for C\cst{C}. At x=0x = 0, e0=1e^0 = 1, so C\cst{C} is just the initial y-value. If xx is not 00, you have to solve for C\cst{C}. For (1,3)\cst{(1, 3)}, we get 3=Ce2\cst{3} = \cst{C}e^2, which means C=3e2\cst{C} = \frac{3}{e^2}, not 33.

Order and initial conditions
y′′=6xy=x3+C1x+C2\displaystyle \begin{aligned}\der{y''} &= \oth{6x}\\ \yfn{y} &= x^3 + \cst{C_1}x + \cst{C_2}\end{aligned}
y′(0)=2,y(0)=1\displaystyle \cst{y'(0) = 2},\quad \cst{y(0) = 1}

The order of a differential equation is the order of the highest derivative in it. In a second-order equation like y′′=6x\der{y''} = \oth{6x}, each integration adds a constant, so integrating twice gives two constants, C1\cst{C_1} and C2\cst{C_2}. Finding a particular solution takes two initial conditions, such as y′(0)\cst{y'(0)} and y(0)\cst{y(0)}.

Finding r\kfix{r} in an exponential solution
y=erx:erx(r2−r−6)=0→  r=3, r=−2\displaystyle \begin{aligned}\yfn{y = e^{\kfix{r}x}}: &\quad \yfn{e^{rx}}\kfix{\left(r^2 - r - 6\right)} = 0\\ &\quad \to\; r = 3,\ r = -2\end{aligned}

To find the values of r\kfix{r} that make y=erx\yfn{y = e^{\kfix{r}x}} a solution, substitute y\yfn{y} and its derivatives into the equation and factor out erx\yfn{e^{rx}}. Because erx\yfn{e^{rx}} is never 00, the equation holds for every xx only when the remaining factor equals 00.

Writing equations from words
dTdt\displaystyle \der{\frac{dT}{dt}} =−k(T−70),k>0\displaystyle = \kfix{-k}(\oth{T - 70}), \qquad \kfix{k} \gt 0

Translate "rate of change of QQ" to dQdt\der{\frac{dQ}{dt}}, "proportional to" to k\kfix{k} times that quantity, and "inversely proportional to" to k\kfix{k} divided by that quantity. Then check whether QQ is increasing or decreasing to fix the sign. For coffee hotter than a 70∘F70^\circ\text{F} room, T−70>0\oth{T - 70} > 0 and the coffee is cooling, so the derivative is negative and we write dTdt=−k(T−70)\der{\frac{dT}{dt}} = \kfix{-k}(\oth{T - 70}) with k>0\kfix{k} > 0.

6

Practice

Enter exact values.

1
Show that y=xln⁡xy = x\ln x is a solution of xdydx−y=xx\dfrac{dy}{dx} - y = x.

Use the product rule to find dydx\frac{dy}{dx} for y=xln⁡xy = x\ln x.

If you got 1−xln⁡x1 - x\ln x Check the derivative of xln⁡xx\ln x. The product rule gives ln⁡x+x⋅1x\ln x + x\cdot\frac1x, not just 1x\frac1x.

Differentiate y=xln⁡x\yfn{y = x\ln x} with the product rule.
dydx\displaystyle \der{\frac{dy}{dx}} =ln⁡x+x⋅1x\displaystyle = \der{\ln x + x\cdot\frac1x} =ln⁡x+1\displaystyle = \der{\ln x + 1}
Plug y\yfn{y} and dydx\der{\frac{dy}{dx}} into the left side.
x(ln⁡x+1)−xln⁡x\displaystyle x(\der{\ln x + 1}) - \yfn{x\ln x} =xln⁡x+x−xln⁡x\displaystyle = x\ln x + x - x\ln x =x\displaystyle = x
That is the right side, x\oth{x}, so y=xln⁡x\yfn{y = x\ln x} is a solution.
2
Which of these functions is a solution of dydx=y−2\dfrac{dy}{dx} = y - 2?

For each candidate, do dydx\frac{dy}{dx} and y−2y - 2 give the same expression?

If you got y=2exy = 2e^x Check both sides. The derivative is 2ex2e^x, but y−2y - 2 is 2ex−22e^x - 2.

Substitute each candidate into both sides of dydx=y−2\der{\frac{dy}{dx}} = \oth{y - 2}.
y=2ex:dydx\displaystyle \yfn{y = 2e^x}: \quad \der{\frac{dy}{dx}} =2ex,y−2\displaystyle = \der{2e^x}, \qquad \oth{y - 2} =2ex−2\displaystyle = \oth{2e^x - 2}
y=ex+2:dydx\displaystyle \yfn{y = e^x + 2}: \quad \der{\frac{dy}{dx}} =ex,y−2\displaystyle = \der{e^x}, \qquad \oth{y - 2} =ex+2−2\displaystyle = \oth{e^x + 2 - 2} =ex\displaystyle = \oth{e^x}
y=ex−2:dydx\displaystyle \yfn{y = e^x - 2}: \quad \der{\frac{dy}{dx}} =ex,y−2\displaystyle = \der{e^x}, \qquad \oth{y - 2} =ex−4\displaystyle = \oth{e^x - 4}
y=e2x:dydx\displaystyle \yfn{y = e^{2x}}: \quad \der{\frac{dy}{dx}} =2e2x,y−2\displaystyle = \der{2e^{2x}}, \qquad \oth{y - 2} =e2x−2\displaystyle = \oth{e^{2x} - 2}
Only y=ex+2\yfn{y = e^x + 2} makes the two sides equal for every xx, so it is the solution.
3
Find all constant solutions of dydt=y2−5y+6\dfrac{dy}{dt} = y^2 - 5y + 6.

If yy is constant, what is dydt\frac{dy}{dt}, and what does that make y2−5y+6y^2 - 5y + 6?

If you got t=2t = 2 and t=3t = 3 A constant solution is a fixed value of yy, not tt.

A constant function has derivative 00, so set the right side equal to 00.
y constant:dydt\displaystyle \yfn{y \text{ constant}}: \quad \der{\frac{dy}{dt}} =0  →  y2−5y+6\displaystyle = \der{0} \;\to\; \oth{y^2 - 5y + 6} =0\displaystyle = 0
Factor the quadratic to find the values of y\yfn{y}.
(y−2)(y−3)\displaystyle (y - 2)(y - 3) =0  →  y=2, y=3\displaystyle = 0 \;\to\; \yfn{y = 2},\ \yfn{y = 3}
4
For what values of rr is y=erxy = e^{rx} a solution of y′′+2y′−8y=0y'' + 2y' - 8y = 0?

Find y′y' and y′′y'' using the chain rule. What factor comes down each time?

Factor out erxe^{rx}. Since erxe^{rx} is never 00, what must equal 00?

Differentiate y=erx\yfn{y = e^{\kfix{r}x}} twice using the chain rule.
y′\displaystyle \der{y'} =rerx,y′′\displaystyle = \der{\kfix{r}e^{rx}}, \qquad \der{y''} =r2erx\displaystyle = \der{\kfix{r^2}e^{rx}}
Substitute y\yfn{y}, y′\der{y'}, and y′′\der{y''} into the equation and factor out erx\yfn{e^{rx}}.
r2erx+2rerx−8erx\displaystyle \kfix{r^2}\yfn{e^{rx}} + 2\kfix{r}\yfn{e^{rx}} - 8\yfn{e^{rx}} =erx(r2+2r−8)\displaystyle = \yfn{e^{rx}}\kfix{\left(r^2 + 2r - 8\right)} =0\displaystyle = 0
erx\yfn{e^{rx}} is never 00, so set the quadratic factor to 00 and solve for r\kfix{r}.
erx≠0  →  r2+2r−8\displaystyle \yfn{e^{rx}} \ne 0 \;\to\; \kfix{r^2 + 2r - 8} =(r+4)(r−2)\displaystyle = \kfix{(r + 4)(r - 2)} =0  →  r\displaystyle = 0 \;\to\; r =2, r\displaystyle = 2,\ r =−4\displaystyle = -4
5
(a) Show that y=Cex2y = Ce^{x^2} is a solution of dydx=2xy\dfrac{dy}{dx} = 2xy for every constant CC. (b) Find the solution with y(1)=3y(1) = 3.

Differentiate ex2e^{x^2} using the chain rule. What is the derivative of the exponent x2x^2?

Plug x=1x = 1 into Cex2Ce^{x^2} and set it equal to 33. What is CC?

If you got y=3ex2y = 3e^{x^2} Check the value of y(1)y(1). When x=1x = 1, 3ex23e^{x^2} gives 3e3e, not 33.

Differentiate y=Cex2\yfn{y} = \cst{C}\yfn{e^{x^2}} using the chain rule.
dydx\displaystyle \der{\frac{dy}{dx}} =Cex2⋅2x\displaystyle = \der{\cst{C}e^{x^2}\cdot 2x} =2x⋅Cex2\displaystyle = 2x\cdot \yfn{\cst{C}e^{x^2}} =2xy\displaystyle = \oth{2xy}
Set x=1x = 1 and y=3y = 3 to find C\cst{C}, then simplify the exponent.
y(1)=3:3\displaystyle \cst{y(1) = 3}: \quad \cst{3} =Ce1  →  C\displaystyle = \cst{C}e^{1} \;\to\; \cst{C} =3e  →  y\displaystyle = \frac3e \;\to\; y =3e ex2\displaystyle = \frac3e\,e^{x^2} =3ex2−1\displaystyle = 3e^{x^2 - 1}
6
Water drains from a tank so that the depth hh of the water, in feet, decreases at a rate proportional to the square root of the depth. Time tt is in minutes. When h=16h = 16, the depth is decreasing at 2 feet per minute. (a) Write a differential equation for hh, with k>0k > 0. (b) Find kk. (c) How fast is the depth decreasing when h=4h = 4?

The rate is proportional to h\sqrt{h}, and hh is decreasing, so what is the sign of dhdt\frac{dh}{dt}?

Plug h=16h = 16 and dhdt=−2\frac{dh}{dt} = -2 into your differential equation to solve for kk.

Because hh is decreasing, dhdt\der{\frac{dh}{dt}} is negative.
dhdt\displaystyle \der{\frac{dh}{dt}} =−kh,k>0\displaystyle = \kfix{-k}\oth{\sqrt{h}}, \qquad \kfix{k} \gt 0
Plug in h=16h = 16 and dhdt=−2\der{\frac{dh}{dt}} = \der{-2} to find k\kfix{k}.
h\displaystyle h =16:−2\displaystyle = 16: \quad \der{-2} =−k16\displaystyle = \kfix{-k}\oth{\sqrt{16}} =−4k  →  k\displaystyle = -4k \;\to\; k =12\displaystyle = \frac12
Plug h=4h = 4 directly into the differential equation.
h\displaystyle h =4:dhdt\displaystyle = 4: \quad \der{\frac{dh}{dt}} =−124\displaystyle = -\frac12\oth{\sqrt4} =−1\displaystyle = -1
So when h=4h = 4, the depth is decreasing at 11 foot per minute.
7
Find the constants aa and bb for which y=ax+by = ax + b is a solution of dydx+2y=4x\dfrac{dy}{dx} + 2y = 4x. (Challenge)

Substitute y=ax+by = ax + b and its derivative into dydx+2y=4x\frac{dy}{dx} + 2y = 4x, then group the xx terms and constant terms.

The equation must hold for every xx, so match the xx coefficients and the constant terms on both sides.

If you got a=2a = 2, b=0b = 0 Check the constant terms. On the right side the constant term is 00, so a+2b=0a + 2b = 0.

Substitute y=ax+b\yfn{y = \kfix{a}x + \kfix{b}} and its derivative dydx=a\der{\frac{dy}{dx}} = \der{\kfix{a}} into the differential equation.
dydx\displaystyle \der{\frac{dy}{dx}} =a:a+2(ax+b)\displaystyle = \der{\kfix{a}}: \quad \der{\kfix{a}} + 2(\yfn{\kfix{a}x + \kfix{b}}) =2ax+(a+2b)\displaystyle = 2\kfix{a}x + (\kfix{a} + 2\kfix{b}) =4x\displaystyle = \oth{4x}
Match the coefficients of xx and the constant terms on both sides.
2a\displaystyle 2\kfix{a} =4,a+2b\displaystyle = 4, \qquad \kfix{a} + 2\kfix{b} =0  →  a\displaystyle = 0 \;\to\; a =2, b\displaystyle = 2,\ b =−1\displaystyle = -1
Check y=2x−1y = 2x - 1 in the differential equation.
y\displaystyle y =2x−1:2+2(2x−1)\displaystyle = 2x - 1: \quad 2 + 2(2x - 1) =4x\displaystyle = \oth{4x}