6.7 First-Order Differential Equations: Linear & Non-Linear

Key Takeaways

  • A first-order equation is separable when it can be written as f(y) dy = g(x) dx, which is always the first form to test for because it needs no integrating factor.

  • The linear form dy/dx + Py = Q is solved with the integrating factor e raised to the integral of P dx, after which the solution is y times IF equals the integral of Q times IF.

  • An exact equation M dx + N dy = 0 satisfies the condition that the partial of M with respect to y equals the partial of N with respect to x.

  • Bernoulli's equation dy/dx + Py = Q y^n is reduced to linear form by the substitution v = y raised to the power (1 - n).

Last updated: August 2026

Why Differential Equations Matter in Paper-II

A differential equation is a relation containing derivatives. Its order is the order of the highest derivative, and its degree is the power of that highest derivative once the equation is cleared of radicals and fractions. Almost every dynamic process examined later in Paper-II is described by one: the cooling of a forged component obeys a first-order equation, damped vibration of a shaft obeys a second-order one, and the transient temperature of a lumped body in heat transfer is a first-order decay.

Because CIL awards one mark per item with no negative marking, the productive skill here is recognising which of four standard types you are looking at, since each has a fixed recipe.

Type 1: Variable Separable

If the equation can be rearranged so that all yy terms sit with dydy and all xx terms with dxdx:

f(y) dy=g(x) dx⟹∫f(y) dy=∫g(x) dx+Cf(y)\,dy = g(x)\,dx \quad \Longrightarrow \quad \int f(y)\,dy = \int g(x)\,dx + C

Always test this first — it requires no machinery.

Worked example — Newton's law of cooling. A casting at T0T_0 cools in surroundings at TsT_s according to

dTdt=−k(T−Ts)\frac{dT}{dt} = -k(T - T_s)

Separating gives dTT−Ts=−k dt\dfrac{dT}{T - T_s} = -k\,dt, so ln⁡(T−Ts)=−kt+C\ln(T - T_s) = -kt + C, and applying the initial condition T=T0T = T_0 at t=0t = 0 yields

T=Ts+(T0−Ts)e−ktT = T_s + (T_0 - T_s)e^{-kt}

This exponential-decay form reappears verbatim as the lumped-capacitance solution in the Heat Transfer chapter.

Type 2: Homogeneous Equations

If dydx=F ⁣(yx)\dfrac{dy}{dx} = F\!\left(\dfrac{y}{x}\right), that is, every term has the same total degree in xx and yy, substitute

y=vx⟹dydx=v+xdvdxy = vx \quad \Longrightarrow \quad \frac{dy}{dx} = v + x\frac{dv}{dx}

The substitution always converts a homogeneous equation into a variable-separable one in vv and xx.

Type 3: Linear First-Order Equations

The standard form is

dydx+P(x) y=Q(x)\frac{dy}{dx} + P(x)\,y = Q(x)

where PP and QQ are functions of xx alone. Multiply through by the integrating factor

IF=e∫P dx\text{IF} = e^{\int P\,dx}

which makes the left side an exact derivative, giving the solution

y⋅IF=∫Q⋅IF dx+Cy \cdot \text{IF} = \int Q \cdot \text{IF}\,dx + C

Worked example. Solve dydx+yx=x2\dfrac{dy}{dx} + \dfrac{y}{x} = x^2.

Here P=1/xP = 1/x, so IF=e∫dx/x=eln⁡x=x\text{IF} = e^{\int dx/x} = e^{\ln x} = x. Then yx=∫x3 dx=x44+Cyx = \int x^3\,dx = \dfrac{x^4}{4} + C, giving y=x34+Cxy = \dfrac{x^3}{4} + \dfrac{C}{x}.

If instead the roles of xx and yy are reversed — the equation is linear in xx with yy as the independent variable — write it as dxdy+P(y)x=Q(y)\dfrac{dx}{dy} + P(y)x = Q(y) and use the same recipe.

Type 4: Exact Differential Equations

An equation written as

M(x,y) dx+N(x,y) dy=0M(x,y)\,dx + N(x,y)\,dy = 0

is exact when

∂M∂y=∂N∂x\frac{\partial M}{\partial y} = \frac{\partial N}{\partial x}

This is the same equality-of-mixed-partials condition met in the previous section, and it means the left side is the total differential of some function u(x,y)u(x,y). The solution is u=Cu = C, obtained as

∫M dx  (treating y constant)+∫(terms of N free of x)dy=C\int M\,dx \;(\text{treating } y \text{ constant}) + \int \left(\text{terms of } N \text{ free of } x\right) dy = C

When the exactness test fails, an integrating factor can sometimes restore it. Two standard cases:

  • If 1N(∂M∂y−∂N∂x)\dfrac{1}{N}\left(\dfrac{\partial M}{\partial y} - \dfrac{\partial N}{\partial x}\right) is a function of xx alone, call it f(x)f(x); then IF=e∫f dx\text{IF} = e^{\int f\,dx}.
  • If 1M(∂N∂x−∂M∂y)\dfrac{1}{M}\left(\dfrac{\partial N}{\partial x} - \dfrac{\partial M}{\partial y}\right) is a function of yy alone, call it g(y)g(y); then IF=e∫g dy\text{IF} = e^{\int g\,dy}.

Bernoulli's Equation

The non-linear form named in the syllabus is

dydx+P(x)y=Q(x) yn,n≠0,1\frac{dy}{dx} + P(x)y = Q(x)\,y^{n}, \qquad n \neq 0, 1

Divide throughout by yny^n and substitute v=y1−nv = y^{1-n}. Since dvdx=(1−n)y−ndydx\dfrac{dv}{dx} = (1-n)y^{-n}\dfrac{dy}{dx}, the equation becomes

dvdx+(1−n)Pv=(1−n)Q\frac{dv}{dx} + (1-n)Pv = (1-n)Q

which is linear in vv and solved by the integrating factor of Type 3.

Classification Flowchart

Test in this orderIf it passes
Can the variables be separated?Integrate both sides directly
Is dy/dxdy/dx a function of y/xy/x only?Substitute y=vxy = vx
Is it y′+Py=Qyny' + Py = Qy^n?Substitute v=y1−nv = y^{1-n}, then linear
Is it y′+Py=Qy' + Py = Q?Integrating factor e∫Pdxe^{\int P dx}
Is My=NxM_y = N_x?Exact; solve u=Cu = C

Application: Draining a Mine Sump

A sump of uniform cross-section AA drains through an orifice of area aa. Torricelli's law gives the outflow velocity as 2gh\sqrt{2gh}, so

Adhdt=−Cd a2ghA\frac{dh}{dt} = -C_d\,a\sqrt{2gh}

This is variable-separable. Writing h−1/2dh=−Cda2gAdth^{-1/2}dh = -\dfrac{C_d a\sqrt{2g}}{A}dt and integrating from h1h_1 to h2h_2 gives the emptying time

t=2A(h1−h2)Cd a2gt = \frac{2A\left(\sqrt{h_1} - \sqrt{h_2}\right)}{C_d\,a\sqrt{2g}}

The same result is derived again from a control-volume argument in the Fluid Mechanics chapter, which is a useful cross-check that the calculus and the physics agree.

Test Your Knowledge

The integrating factor for the differential equation dy/dx + y/x = x^2 is:

A

x

B

1/x

C

e raised to x

D

x squared

Test Your Knowledge

The substitution that reduces Bernoulli's equation dy/dx + Py = Q y^n to linear form is:

A

v = y/x

B

v = y raised to the power (1 - n)

C

v = ln y

D

v = y raised to the power n

Test Your Knowledge

The equation M dx + N dy = 0 is exact if:

A

The partial derivative of M with respect to x equals the partial derivative of N with respect to y

B

M equals N

C

The partial derivative of M with respect to y equals the partial derivative of N with respect to x

D

M and N are both homogeneous of the same degree

Test Your Knowledge

A casting cooling according to Newton's law of cooling has a temperature-time relationship that is:

A

Parabolic in time

B

Constant until a critical time, then linear

C

Linear in time

D

Exponentially decaying towards the ambient temperature

Sections you finish are checked off in the contents.