Skip to content
Exercise 9.3 · Q14

Q.Solve the following differential equation: dydx=ytan⁡x;y=1\frac{dy}{dx} = y \tan x; y = 1 when x=0x = 0

CBSENCERTSubjective· 3mImportance★★★★★
18% · 41/222 Questions
🔒 Locked · start free trial →

You're viewing a preview — the full solution, concept, methods & PYQ mapping are locked.

Start your 14-day free trial to unlock the full solution →

This is a first-order separable ODE. By separating variables and integrating, we get log⁡∣y∣=−log⁡∣cos⁡x∣+C\log|y| = -\log|\cos x| + C. Using the initial condition y(0)=1y(0)=1 gives C=0C=0, so the solution is y=sec⁡xy = \sec x.

The key idea here is separation of variables. When a differential equation can be written in the form dydx=f(x) g(y)\frac{dy}{dx} = f(x) \, g(y), we can rearrange it so that all yy terms are on one side and all xx terms on the other — then integrate both sides. That’s exactly what we have here: dydx=ytan⁡x\frac{dy}{dx} = y \tan x is of that form, with g(y)=yg(y) = y and f(x)=tan⁡xf(x) = \tan x.

Why does this work? Because we’re treating dydy and dxdx as differentials that can be moved algebraically (a standard technique in ODEs). Once separated, we integrate each side with respect to its own variable, and the constant of integration is determined by the initial condition.

Let’s go through it step by step.

  1. Separate the variables. Write the equation as

dyy=tan⁡x dx\frac{dy}{y} = \tan x \, dx

This is valid as long as y≠0y \neq 0 (and we’ll check later that the solution doesn’t cross zero for the given initial condition).

  1. Integrate both sides.

∫dyy=∫tan⁡x dx\int \frac{dy}{y} = \int \tan x \, dx

The left side is straightforward: ∫dyy=log⁡∣y∣+C1\int \frac{dy}{y} = \log|y| + C_1.

For the right side, recall that tan⁡x=sin⁡xcos⁡x\tan x = \frac{\sin x}{\cos x}. Let u=cos⁡xu = \cos x, then du=−sin⁡x dxdu = -\sin x \, dx, so

∫tan⁡x dx=∫sin⁡xcos⁡xdx=−∫duu=−log⁡∣u∣+C2=−log⁡∣cos⁡x∣+C2\int \tan x \, dx = \int \frac{\sin x}{\cos x} dx = -\int \frac{du}{u} = -\log|u| + C_2 = -\log|\cos x| + C_2

Combining constants, we get

log⁡∣y∣=−log⁡∣cos⁡x∣+C\log|y| = -\log|\cos x| + C

where C=C2−C1C = C_2 - C_1 is an arbitrary constant.

  1. Simplify using logarithm properties.

log⁡∣y∣+log⁡∣cos⁡x∣=C⇒log⁡∣ycos⁡x∣=C\log|y| + \log|\cos x| = C \quad \Rightarrow \quad \log|y \cos x| = C

Exponentiate both sides:

∣ycos⁡x∣=eC|y \cos x| = e^C

Let A=eC>0A = e^C > 0, so ∣ycos⁡x∣=A|y \cos x| = A. Removing the absolute value, we write

ycos⁡x=±A=ky \cos x = \pm A = k

where kk is any non-zero constant (the sign is absorbed). So the general solution is

y=kcos⁡x=ksec⁡xy = \frac{k}{\cos x} = k \sec x …

Unlock everything free for 14 days

  • Full step-by-step solutions
  • Concept-first explanations
  • Methods, shortcuts & mistakes
  • PYQ mapping + timed mock tests

Full access for 14 days. No credit card required.