Differential Equations

NCERT Class 12 Mathematics — Differential Equations, Exercise 9.4. All 17 questions solved.

A first-order equation is homogeneous when it can be written as

$$\frac{dy}{dx} = F\!\left(\frac{y}{x}\right)$$

that is, when the right-hand side depends on $x$ and $y$ only through their ratio. Equivalently, writing it as $\tfrac{dy}{dx} = \tfrac{P(x,y)}{Q(x,y)}$, both $P$ and $Q$ are homogeneous of the same degree: $P(\lambda x, \lambda y) = \lambda^n P(x,y)$.

The substitution that solves every one of them is

$$y = vx, \qquad \frac{dy}{dx} = v + x\frac{dv}{dx}$$

After substituting, the $v$’s and the $x$’s separate, and the exercise reduces to Exercise 9.3.

Key insight. The substitution works because the whole right-hand side becomes a function of $v$ alone. What you get is always

$$v + x\frac{dv}{dx} = F(v) \quad\Longrightarrow\quad \frac{dv}{F(v) – v} = \frac{dx}{x}$$

and the $v$ on the left cancelling against part of $F(v)$ is the moment the question becomes tractable. If it does not cancel, check whether the equation was homogeneous in the first place.

When $x$ appears inside a function of $\tfrac{x}{y}$ rather than $\tfrac{y}{x}$ — question 10, and question 16’s multiple choice — substitute $x = vy$ instead. The book’s own answer to question 16 says so explicitly.

In each of the Exercises 1 to 10, show that the given differential equation is homogeneous and solve each of them.

Question 1

$\left(x^2 + xy\right)dy = \left(x^2 + y^2\right)dx$

Solution. Writing $\dfrac{dy}{dx} = \dfrac{x^2+y^2}{x^2+xy}$, both numerator and denominator are homogeneous of degree $2$, so the equation is homogeneous.

Put $y = vx$:

$$v + x\frac{dv}{dx} = \frac{x^2 + v^2x^2}{x^2 + vx^2} = \frac{1 + v^2}{1 + v}$$

$$x\frac{dv}{dx} = \frac{1+v^2}{1+v} – v = \frac{1 + v^2 – v – v^2}{1+v} = \frac{1 – v}{1 + v}$$

Separating:

$$\frac{(1+v)\,dv}{1-v} = \frac{dx}{x}$$

Writing $\tfrac{1+v}{1-v} = -1 + \tfrac{2}{1-v}$ and integrating:

$$-v – 2\log|1-v| = \log|x| + \log \mathrm{C}$$

Substituting $v = \tfrac{y}{x}$ and rearranging gives the printed form.

$$(x – y)^2 = \mathrm{C}x\,e^{-y/x}$$

Question 2

$y’ = \dfrac{x+y}{x}$

Solution. The right side is $1 + \tfrac{y}{x}$, a function of $\tfrac{y}{x}$ alone — homogeneous of degree $0$.

With $y = vx$:

$$v + x\frac{dv}{dx} = 1 + v \quad\Longrightarrow\quad x\frac{dv}{dx} = 1$$

The $v$ cancels completely, leaving $dv = \tfrac{dx}{x}$ and so $v = \log|x| + \mathrm{C}$.

$$y = x\log|x| + \mathrm{C}x$$

Question 3

$(x – y)\,dy – (x + y)\,dx = 0$

Solution. $\dfrac{dy}{dx} = \dfrac{x+y}{x-y}$; both parts are homogeneous of degree $1$.

With $y = vx$:

$$v + x\frac{dv}{dx} = \frac{1+v}{1-v} \quad\Longrightarrow\quad x\frac{dv}{dx} = \frac{1+v – v + v^2}{1-v} = \frac{1 + v^2}{1 – v}$$

$$\frac{(1-v)\,dv}{1+v^2} = \frac{dx}{x}$$

The left side splits into an arctangent and a logarithm:

$$\tan^{-1}v – \frac12\log\left(1+v^2\right) = \log|x| + \mathrm{C}$$

Since $\tfrac12\log\left(1+v^2\right) + \log|x| = \tfrac12\log\left(x^2 + y^2\right)$, this tidies to:

$$\tan^{-1}\left(\frac{y}{x}\right) = \frac12\log\left(x^2 + y^2\right) + \mathrm{C}$$

Question 4

$\left(x^2 – y^2\right)dx + 2xy\,dy = 0$

Solution. $\dfrac{dy}{dx} = \dfrac{y^2 – x^2}{2xy}$, homogeneous of degree $2$ over degree $2$.

With $y = vx$:

$$v + x\frac{dv}{dx} = \frac{v^2 – 1}{2v} \quad\Longrightarrow\quad x\frac{dv}{dx} = \frac{v^2 – 1 – 2v^2}{2v} = -\frac{1 + v^2}{2v}$$

$$\frac{2v\,dv}{1+v^2} = -\frac{dx}{x} \quad\Longrightarrow\quad \log\left(1+v^2\right) = -\log|x| + \log \mathrm{C}$$

So $\left(1 + \tfrac{y^2}{x^2}\right)x = \mathrm{C}$.

$$x^2 + y^2 = \mathrm{C}x$$

Question 5

$x^2\dfrac{dy}{dx} = x^2 – 2y^2 + xy$

Solution. Dividing by $x^2$ shows the right side is $1 – 2v^2 + v$ with $v = \tfrac{y}{x}$.

$$v + x\frac{dv}{dx} = 1 – 2v^2 + v \quad\Longrightarrow\quad x\frac{dv}{dx} = 1 – 2v^2$$

$$\frac{dv}{1 – 2v^2} = \frac{dx}{x}$$

The left side is the standard form $\tfrac{1}{2a}\log\left|\tfrac{a+t}{a-t}\right|$ after writing $1 – 2v^2 = 2\left(\tfrac12 – v^2\right)$, with $a = \tfrac{1}{\sqrt2}$:

$$\frac{1}{2\sqrt2}\log\left|\frac{x + \sqrt2\,y}{x – \sqrt2\,y}\right| = \log|x| + \mathrm{C}$$

Question 6

$x\,dy – y\,dx = \sqrt{x^2 + y^2}\,dx$

Solution. Rearranged, $\dfrac{dy}{dx} = \dfrac{y + \sqrt{x^2+y^2}}{x}$, which is $v + \sqrt{1+v^2}$ for $x > 0$.

$$v + x\frac{dv}{dx} = v + \sqrt{1+v^2} \quad\Longrightarrow\quad \frac{dv}{\sqrt{1+v^2}} = \frac{dx}{x}$$

Again the $v$ cancels outright:

$$\log\left|v + \sqrt{1+v^2}\right| = \log|x| + \log \mathrm{C}$$

$$\frac{y}{x} + \frac{\sqrt{x^2+y^2}}{x} = \mathrm{C}x$$

$$y + \sqrt{x^2 + y^2} = \mathrm{C}x^2$$

Question 7

$\left\{x\cos\left(\dfrac{y}{x}\right) + y\sin\left(\dfrac{y}{x}\right)\right\}y\,dx = \left\{y\sin\left(\dfrac{y}{x}\right) – x\cos\left(\dfrac{y}{x}\right)\right\}x\,dy$

Solution. Dividing top and bottom by $x^2$ turns everything into functions of $v = \tfrac{y}{x}$:

$$\frac{dy}{dx} = \frac{v(\cos v + v\sin v)}{v\sin v – \cos v}$$

Substituting $y = vx$ and subtracting $v$:

$$x\frac{dv}{dx} = \frac{v\cos v + v^2\sin v – v^2\sin v + v\cos v}{v\sin v – \cos v} = \frac{2v\cos v}{v\sin v – \cos v}$$

$$\frac{(v\sin v – \cos v)\,dv}{v\cos v} = \frac{2\,dx}{x}$$

The left side splits as $\tan v\,dv – \tfrac{dv}{v}$, integrating to $-\log|\cos v| – \log|v|$:

$$-\log|v\cos v| = 2\log|x| + \log c$$

$$xy\cos\left|\frac{y}{x}\right| = \mathrm{C}$$

Question 8

$x\dfrac{dy}{dx} – y + x\sin\left(\dfrac{y}{x}\right) = 0$

Solution. $\dfrac{dy}{dx} = \dfrac{y}{x} – \sin\dfrac{y}{x} = v – \sin v$.

$$v + x\frac{dv}{dx} = v – \sin v \quad\Longrightarrow\quad \frac{dv}{\sin v} = -\frac{dx}{x}$$

$$\log\left|\tan\frac{v}{2}\right| = -\log|x| + \log \mathrm{C}$$

Writing $\tan\tfrac{v}{2} = \tfrac{1 – \cos v}{\sin v}$ and clearing:

$$x\left[1 – \cos\left(\frac{y}{x}\right)\right] = \mathrm{C}\sin\left(\frac{y}{x}\right)$$

Question 9

$y\,dx + x\log\left(\dfrac{y}{x}\right)dy – 2x\,dy = 0$

Solution. Rearranged, $\dfrac{dy}{dx} = \dfrac{-y}{x\log\frac{y}{x} – 2x} = \dfrac{-v}{\log v – 2}$.

$$v + x\frac{dv}{dx} = \frac{-v}{\log v – 2} \quad\Longrightarrow\quad x\frac{dv}{dx} = \frac{-v – v\log v + 2v}{\log v – 2} = \frac{v(1 – \log v)}{\log v – 2}$$

$$\frac{(\log v – 2)\,dv}{v(1 – \log v)} = \frac{dx}{x}$$

Put $t = \log v$, so $\tfrac{dv}{v} = dt$, and the left side becomes $\int\tfrac{t-2}{1-t}dt = \int\left(-1 – \tfrac{1}{1-t}\right)dt = -t + \log|1-t|$. Resubstituting and simplifying gives:

$$cy = \log\left|\frac{y}{x}\right| – 1$$

Question 10

$\left(1 + e^{x/y}\right)dx + e^{x/y}\left(1 – \dfrac{x}{y}\right)dy = 0$

Solution. Here the ratio that appears is $\tfrac{x}{y}$, so substitute $x = vy$, with $\dfrac{dx}{dy} = v + y\dfrac{dv}{dy}$.

$$\frac{dx}{dy} = \frac{-e^{v}(1 – v)}{1 + e^{v}}$$

$$v + y\frac{dv}{dy} = \frac{-e^v + ve^v}{1 + e^v} \quad\Longrightarrow\quad y\frac{dv}{dy} = \frac{-e^v + ve^v – v – ve^v}{1+e^v} = -\frac{v + e^v}{1 + e^v}$$

$$\frac{\left(1 + e^v\right)dv}{v + e^v} = -\frac{dy}{y}$$

The numerator on the left is exactly the derivative of the denominator, so both sides are logarithms:

$$\log\left|v + e^v\right| = -\log|y| + \log \mathrm{C}$$

$$y\left(\frac{x}{y} + e^{x/y}\right) = \mathrm{C}$$

$$y\,e^{x/y} + x = \mathrm{C}$$

For each of the differential equations in Exercises from 11 to 15, find the particular solution satisfying the given condition.

Question 11

$(x+y)\,dy + (x-y)\,dx = 0$; $y = 1$ when $x = 1$

Solution. $\dfrac{dy}{dx} = \dfrac{y-x}{x+y} = \dfrac{v-1}{1+v}$.

$$x\frac{dv}{dx} = \frac{v – 1 – v – v^2}{1+v} = -\frac{1 + v^2}{1 + v}$$

$$\frac{(1+v)\,dv}{1+v^2} = -\frac{dx}{x} \quad\Longrightarrow\quad \tan^{-1}v + \frac12\log\left(1+v^2\right) = -\log|x| + c$$

Combining the logarithms as in question 3:

$$\tan^{-1}\frac{y}{x} + \frac12\log\left(x^2+y^2\right) = c$$

At $(1, 1)$: $\tfrac{\pi}{4} + \tfrac12\log 2 = c$. Doubling:

$$\log\left(x^2 + y^2\right) + 2\tan^{-1}\frac{y}{x} = \frac{\pi}{2} + \log 2$$

Question 12

$x^2\,dy + \left(xy + y^2\right)dx = 0$; $y = 1$ when $x = 1$

Solution. $\dfrac{dy}{dx} = -\dfrac{xy+y^2}{x^2} = -(v + v^2)$.

$$x\frac{dv}{dx} = -v – v^2 – v = -\left(2v + v^2\right) = -v(2+v)$$

$$\frac{dv}{v(2+v)} = -\frac{dx}{x}$$

Partial fractions give $\tfrac{1}{v(2+v)} = \tfrac12\left(\tfrac1v – \tfrac{1}{2+v}\right)$:

$$\frac12\log\left|\frac{v}{2+v}\right| = -\log|x| + c$$

Substituting $v = \tfrac{y}{x}$ and applying $(1, 1)$ gives, after clearing:

$$y + 2x = 3x^2y$$

Question 13

$\left[x\sin^2\left(\dfrac{y}{x}\right) – y\right]dx + x\,dy = 0$; $y = \dfrac{\pi}{4}$ when $x = 1$

Solution. $\dfrac{dy}{dx} = \dfrac{y – x\sin^2\frac{y}{x}}{x} = v – \sin^2 v$.

$$x\frac{dv}{dx} = -\sin^2 v \quad\Longrightarrow\quad \operatorname{cosec}^2v\,dv = -\frac{dx}{x}$$

$$-\cot v = -\log|x| + c \quad\Longrightarrow\quad \cot\frac{y}{x} = \log|x| + c$$

At $x = 1$, $y = \tfrac{\pi}{4}$: $\cot\tfrac{\pi}{4} = 1 = 0 + c$, so $c = 1$. Since $\log|x| + 1 = \log|ex|$:

$$\cot\left(\frac{y}{x}\right) = \log|ex|$$

Question 14

$\dfrac{dy}{dx} – \dfrac{y}{x} + \operatorname{cosec}\left(\dfrac{y}{x}\right) = 0$; $y = 0$ when $x = 1$

Solution. $\dfrac{dy}{dx} = v – \operatorname{cosec}v$, so

$$x\frac{dv}{dx} = -\operatorname{cosec}v \quad\Longrightarrow\quad \sin v\,dv = -\frac{dx}{x}$$

$$-\cos v = -\log|x| + c \quad\Longrightarrow\quad \cos\frac{y}{x} = \log|x| + c$$

At $(1, 0)$: $\cos 0 = 1 = c$.

$$\cos\left(\frac{y}{x}\right) = \log|ex|$$

Question 15

$2xy + y^2 – 2x^2\dfrac{dy}{dx} = 0$; $y = 2$ when $x = 1$

Solution. $\dfrac{dy}{dx} = \dfrac{2xy + y^2}{2x^2} = v + \dfrac{v^2}{2}$.

$$x\frac{dv}{dx} = \frac{v^2}{2} \quad\Longrightarrow\quad \frac{2\,dv}{v^2} = \frac{dx}{x}$$

$$-\frac2v = \log|x| + c \quad\Longrightarrow\quad -\frac{2x}{y} = \log|x| + c$$

At $(1, 2)$: $-1 = 0 + c$, so $c = -1$. Then $-\tfrac{2x}{y} = \log|x| – 1$, which rearranges to:

$$y = \frac{2x}{1 – \log|x|}, \qquad x \ne 0,\ x \ne e$$

Question 16

A homogeneous differential equation of the form $\dfrac{dx}{dy} = h\left(\dfrac{x}{y}\right)$ can be solved by making the substitution

(A) $y = vx$
(B) $v = yx$
(C) $x = vy$
(D) $x = v$

Solution. The right-hand side is a function of $\tfrac{x}{y}$, so the substitution should make that ratio the new variable: $v = \tfrac{x}{y}$, that is $x = vy$.

Option (A) is the substitution for the other form, $\tfrac{dy}{dx} = F\left(\tfrac{y}{x}\right)$. Using it here would leave the equation just as tangled as before.

$$\text{(C)}\quad x = vy$$

Question 17

Which of the following is a homogeneous differential equation?

(A) $(4x + 6y + 5)\,dy – (3y + 2x + 4)\,dx = 0$
(B) $(xy)\,dx – \left(x^3 + y^3\right)dy = 0$
(C) $\left(x^3 + 2y^2\right)dx + 2xy\,dy = 0$
(D) $y^2\,dx + \left(x^2 – xy – y^2\right)dy = 0$

Solution. Test each pair of coefficients for being homogeneous of the same degree.

  • (A) Constant terms $5$ and $4$ are degree $0$ while the rest are degree $1$; neither coefficient is homogeneous at all.
  • (B) $xy$ has degree $2$, $x^3 + y^3$ has degree $3$. Same-degree fails.
  • (C) $x^3 + 2y^2$ mixes degree $3$ and degree $2$, so it is not homogeneous.
  • (D) $y^2$ has degree $2$, and every term of $x^2 – xy – y^2$ has degree $2$. Both are homogeneous of degree $2$.

$$\text{(D)}\quad y^2\,dx + \left(x^2 – xy – y^2\right)dy = 0$$

Common mistakes

  • Substituting $y = vx$ but forgetting that $\tfrac{dy}{dx} = v + x\tfrac{dv}{dx}$. Writing $\tfrac{dy}{dx} = x\tfrac{dv}{dx}$ loses the term that makes the cancellation work.
  • Using $y = vx$ when the equation is in $\tfrac{x}{y}$. Question 10 and the answer to question 16 both call for $x = vy$.
  • Checking homogeneity of only one coefficient. Both must be homogeneous, and of the same degree. Option (B) in question 17 fails only on the second condition.
  • Resubstituting too early. Do all the integration in $v$, then replace $v$ by $\tfrac{y}{x}$ once at the end.
  • Not writing the constant as $\log \mathrm{C}$. Nearly every answer in this exercise is a product or a quotient, which only appears if the constant enters as a logarithm.
  • Losing the modulus. $\log|x|$, not $\log x$: several of these solutions are valid for negative $x$ too.

Practise next

  • Exercise 9.5 — linear equations, the third and last solution method in the chapter.
  • Exercise 9.3 — the separation of variables that every question here reduces to after the substitution.
Keep track of what you have finished — create a free account.

Doubts are answered by Shiwam, usually within a day. Ask about this question specifically — a general question about the chapter is better asked in class.

Ask your doubt

Stuck on this question? Ask Shiwam directly.

A free account lets you post a doubt on any question, keep track of the exercises you have finished, and come back to the answer later.

Create a free accountI already have one