TN 12th MathsLearn · Visualize · Practice
𝑑𝑦

Chapter 10

Ordinary Differential Equations

Order, degree, formation and solving first-order differential equations.

1. What is a differential equation?

Many laws of nature do not tell you a quantity directly — they tell you its rate of change. Newton's cooling law, radioactive decay, population growth, and the motion of a spring are all stated as relationships between a function and its derivatives. Any equation that connects an unknown function with one or more of its derivatives is a differential equation.

DefinitionDifferential equation

A differential equation is an equation involving an unknown function and its derivatives. For example dydx=2x\dfrac{dy}{dx} = 2x,  d2ydx2+y=0\ \dfrac{d^2y}{dx^2} + y = 0, and dydx+y=ex\dfrac{dy}{dx} + y = e^x are all differential equations.

Solving a differential equation means finding the function y=f(x)y = f(x) that satisfies it. Unlike an algebraic equation whose answer is a number, the answer here is a whole function (or a family of functions).

Key idea: A differential equation describes how a quantity changes; its solution reconstructs the quantity itself. Integration is the simplest example: solving $\dfrac{dy}{dx} = 2x$ gives $y = x^2 + C$.

2. Order and degree

Two numbers classify a differential equation at a glance. The order measures how many times we have differentiated; the degree measures the power of the top derivative once the equation is cleaned of radicals and fractions.

DefinitionOrder

The order of a differential equation is the order of the highest derivative that appears in it.

DefinitionDegree

The degree is the power (exponent) of the highest-order derivative, after the equation has been made a polynomial in all the derivatives — that is, after clearing any radical signs or fractional powers of the derivatives. If it cannot be written as such a polynomial, the degree is not defined.

Note: Always remove radicals and fractional powers of derivatives before reading off the degree. The power on $y$ itself does not matter for order or degree — only the powers on the derivatives do. The degree, when it exists, is always a positive integer.
Quick readings
  • dydx+y=x\dfrac{dy}{dx} + y = x — order 11, degree 11.
  • (d2ydx2)3+dydx=0\left(\dfrac{d^2y}{dx^2}\right)^3 + \dfrac{dy}{dx} = 0 — order 22, degree 33.
  • d2ydx2=1+(dydx)2\dfrac{d^2y}{dx^2} = \sqrt{1 + \left(\dfrac{dy}{dx}\right)^2} — square first, then order 22, degree 22.
  • sin ⁣(dydx)+d2ydx2+3x=0\sin\!\left(\dfrac{dy}{dx}\right) + \dfrac{d^2y}{dx^2} + 3x = 0 — order 22, degree not defined (a sin\sin of a derivative can't be made polynomial).
ExampleOrder and degree
Find the order and degree of (d2ydx2)2+(dydx)3+y=0\left(\dfrac{d^2y}{dx^2}\right)^2 + \left(\dfrac{dy}{dx}\right)^3 + y = 0.
ExampleDegree after clearing a radical
Find the order and degree of [1+(dydx)2]=yd3ydx3\left[1 + \left(\dfrac{dy}{dx}\right)^2\right] = y\,\dfrac{d^3y}{dx^3} once it involves fractional powers — more precisely, of 1+(dydx)2=d2ydx2\sqrt{1 + \left(\dfrac{dy}{dx}\right)^2} = \dfrac{d^2y}{dx^2}.
ExampleA fractional-power equation
Find the order and degree of d2ydx2+(dydx)1/3+x1/4=0\dfrac{d^2y}{dx^2} + \left(\dfrac{dy}{dx}\right)^{1/3} + x^{1/4} = 0.

3. Classification of differential equations

Differential equations are sorted along two main axes: how many independent variables are involved, and whether the unknown function enters linearly.

Ordinary vs. partial
  • Ordinary (ODE): the unknown function depends on a single independent variable, so only ordinary derivatives dydx\dfrac{dy}{dx} appear. This chapter is about ODEs.
  • Partial (PDE): the unknown depends on several variables and partial derivatives ux\dfrac{\partial u}{\partial x} appear.
DefinitionLinear differential equation

A differential equation is linear if the unknown function yy and all its derivatives appear only to the first power and are never multiplied together (and there are no functions like siny\sin y or eye^y of them). The coefficients may be any functions of xx. Otherwise it is nonlinear.

Linear or nonlinear?
  • dydx+x2y=sinx\dfrac{dy}{dx} + x^2 y = \sin x — linear (coefficients may depend on xx).
  • dydx+y2=x\dfrac{dy}{dx} + y^2 = x — nonlinear, because of y2y^2.
  • ydydx=1y\,\dfrac{dy}{dx} = 1 — nonlinear, because yy multiplies its derivative.
  • dydx+siny=0\dfrac{dy}{dx} + \sin y = 0 — nonlinear, because siny\sin y is a transcendental function of yy.
Note: Only the dependent variable $y$ and its derivatives decide linearity. Coefficients such as $x^2$, $\sin x$ or $e^x$ multiplying $y$ are completely fine in a linear equation.

4. Forming a differential equation by eliminating constants

A family of curves carrying arbitrary constants can be turned into a differential equation that every member of the family obeys. The recipe: differentiate as many times as there are arbitrary constants, then eliminate the constants using the equations you have generated.

Key idea: The order of the resulting differential equation equals the number of independent arbitrary constants you eliminate.
ExampleEliminate one constant
Find the differential equation of the family of all straight lines through the origin, y=mxy = mx.
ExampleEliminate two constants (exponentials)
Form the differential equation whose general solution is y=Aex+Bexy = A e^{x} + B e^{-x}.
ExampleEliminate two constants (trigonometric)
Form the differential equation by eliminating AA and BB from y=Acosx+Bsinxy = A\cos x + B\sin x.
ExampleA parabola family
Find the differential equation of the family of parabolas y2=4axy^2 = 4ax, where aa is arbitrary.

5. General and particular solutions

Because integration always introduces constants, a differential equation of order nn has a solution containing nn arbitrary constants.

DefinitionGeneral solution

The general solution of an nn-th order differential equation is a solution containing nn independent arbitrary constants — it represents the entire family of solution curves.

DefinitionParticular solution

A particular solution is obtained by giving the arbitrary constants specific values, usually to satisfy given initial or boundary conditions. It singles out one curve from the family.

ExampleFrom general to particular
The general solution of dydx=2x\dfrac{dy}{dx} = 2x is y=x2+Cy = x^2 + C. Find the particular solution with y=3y = 3 when x=1x = 1.
Note: To verify a proposed solution, substitute it (and its derivatives) into the equation and check both sides agree — a quick, exam-safe way to confirm your answer.

6. Variables separable method

The friendliest first-order equations are those that can be rearranged so that everything involving yy sits with dydy and everything involving xx sits with dxdx. Then we simply integrate each side.

DefinitionSeparable equation

A first-order equation is separable if it can be written as g(y)dy=f(x)dxg(y)\,dy = f(x)\,dx. Its solution is obtained by integrating both sides: g(y)dy=f(x)dx+C\int g(y)\,dy = \int f(x)\,dx + C.

Method
dydx=f(x)g(y)    g(y)dy=f(x)dx+C\frac{dy}{dx} = \frac{f(x)}{g(y)} \;\Longrightarrow\; \int g(y)\,dy = \int f(x)\,dx + C
Note: Add just one arbitrary constant, on either side. There is no need to write a constant on both sides — the two would merge into one.
ExampleA separable equation
Solve dydx=1+y21+x2\dfrac{dy}{dx} = \dfrac{1 + y^2}{1 + x^2}.
ExampleSeparable with an initial condition
Find the particular solution of (1+x3)dyx2ydx=0(1 + x^3)\,dy - x^2 y\,dx = 0 satisfying y(1)=2y(1) = 2.
ExampleReducible to separable by substitution
Solve dydx=(x+y+1)2\dfrac{dy}{dx} = (x + y + 1)^2 (a dydx=f(ax+by+c)\dfrac{dy}{dx} = f(ax+by+c) type).

7. Homogeneous differential equations

Some first-order equations are not directly separable but can be written purely in terms of the ratio yx\dfrac{y}{x}. A clever substitution converts them into separable ones.

DefinitionHomogeneous equation

A first-order equation dydx=F(x,y)\dfrac{dy}{dx} = F(x, y) is homogeneous if it can be written as dydx=g ⁣(yx)\dfrac{dy}{dx} = g\!\left(\dfrac{y}{x}\right) — the right side depends only on the ratio yx\dfrac{y}{x}. Equivalently, Mdx+Ndy=0M\,dx + N\,dy = 0 is homogeneous when MM and NN are homogeneous functions of the same degree.

Solving method (substitution $y = vx$)
  • Put y=vxy = vx, so that dydx=v+xdvdx\dfrac{dy}{dx} = v + x\dfrac{dv}{dx}.
  • Substitute to get v+xdvdx=g(v)v + x\dfrac{dv}{dx} = g(v).
  • This is separable: dvg(v)v=dxx\dfrac{dv}{g(v) - v} = \dfrac{dx}{x}. Integrate, then replace v=yxv = \dfrac{y}{x}.
Note: After integrating, always substitute $v = \dfrac{y}{x}$ back so the answer is expressed in the original variables $x$ and $y$.
ExampleHomogeneous equation
Solve (x2y2)dx+2xydy=0(x^2 - y^2)\,dx + 2xy\,dy = 0.
ExampleHomogeneous with a root
Solve xdydx=y+x2+y2x\,\dfrac{dy}{dx} = y + \sqrt{x^2 + y^2} (take x>0x > 0).

8. First-order linear equations and the integrating factor

The most important solvable type is the first-order linear equation. It cannot usually be separated, but multiplying through by a cleverly chosen factor turns the left side into the derivative of a product, after which one integration finishes the job.

DefinitionLinear form

A first-order linear differential equation has the standard form dydx+Py=Q\dfrac{dy}{dx} + P y = Q, where PP and QQ are functions of xx alone.

Integrating factor
IF=ePdx\text{IF} = e^{\int P\,dx}

Multiplying dydx+Py=Q\dfrac{dy}{dx} + P y = Q by the integrating factor makes the left side an exact derivative ddx ⁣(yIF)\dfrac{d}{dx}\!\big(y \cdot \text{IF}\big). Integrating gives the solution.

Solution
yIF=QIFdx+Cy \cdot \text{IF} = \int Q \cdot \text{IF}\,dx + C
Note: Before reading off $P$, make the coefficient of $\dfrac{dy}{dx}$ equal to $1$ by dividing through. $P$ is then whatever multiplies $y$.
ExampleConstant coefficient linear ODE
Solve dydx+2y=ex\dfrac{dy}{dx} + 2y = e^{-x}.
ExampleVariable coefficient linear ODE
Solve dydx+1xy=x\dfrac{dy}{dx} + \dfrac{1}{x}\,y = x, for x>0x > 0.
ExampleLinear in $x$ instead of $y$
Solve dydx=12xy2\dfrac{dy}{dx} = \dfrac{1}{2x - y^2}, which is not linear in yy.

9. Application: growth, decay and Newton's cooling

A quantity whose rate of change is proportional to its current amount obeys dydt=ky\dfrac{dy}{dt} = ky. This single equation models population growth (Malthusian law), radioactive decay, and — with a shift — Newton's law of cooling.

Growth / decay law
dydt=ky    y=Cekt\frac{dy}{dt} = ky \;\Longrightarrow\; y = C e^{kt}

If k>0k > 0 the quantity grows exponentially; if k<0k < 0 it decays. The constant CC is the initial amount y(0)y(0).

ExamplePopulation doubling
A colony's growth is proportional to its size and it doubles in 5050 years. In how many years does it triple?
ExampleRadioactive decay and half-life
An isotope has initial mass 200200 mg and 5050 mg two years later. Find the mass at time tt.
ExampleNewton's law of cooling
Water at 100100^\circC cools to 8080^\circC in 1010 min in a room at 2525^\circC. Find its temperature after 2020 minutes.
Key idea: Open the Visualize tab: the slope field of $\dfrac{dy}{dx} = y$ (take $k = 1$) shows solution curves that steepen as $y$ grows — the visual signature of exponential growth.

10. Application: mixing problems

In a stirred tank, the amount x(t)x(t) of dissolved substance changes at the net rate dxdt=(rate in)(rate out)\dfrac{dx}{dt} = (\text{rate in}) - (\text{rate out}). This standard set-up produces a first-order linear equation.

Balance law
dxdt=INOUT\frac{dx}{dt} = \text{IN} - \text{OUT}
ExampleSalt in a tank
A tank holds 10001000 L of water with 100100 g of salt. Brine with 55 g/L flows in at 1010 L/min; the well-stirred mixture flows out at 1010 L/min. Find the salt x(t)x(t).
Note: Sanity-check the long-run behaviour: as $t \to \infty$, $x \to 5000$ g, the salt content of $1000$ L at the incoming concentration $5$ g/L. If your steady state disagrees with the inflow concentration, recheck the setup.