How do you solve first order differential equations?
Answer in short
For dy/dx = F(x, y): if F = g(x) h(y), separate the variables. If F(λx, λy) = F(x, y), put y = vx. If dy/dx + Py = Q with P, Q in x only, use I.F. = e^(∫P dx) and y × I.F. = ∫Q × I.F. dx + C.
Stuck on a question? Take a photo and Lagnever AI explains it step by step. Try it for 7 days for ₹2. Get it on Google Play
Which method? Ask three questions
Every first order, first degree equation can be written dy/dx = F(x, y). Try the methods in this order:
- Can F be split into a function of x times a function of y? Variables separable.
- Is F unchanged when x and y are replaced by λx and λy? Homogeneous.
- Is it dy/dx + Py = Q, with P and Q functions of x alone (or the same with x and y swapped)? Linear.
Method 1: variables separable
If dy/dx = g(x) h(y) and h(y) ≠ 0, divide by h(y) and multiply by dx:
dy/h(y) = g(x) dx ⇒ ∫dy/h(y) = ∫g(x) dx + C
so H(y) = G(x) + C, where H and G are anti derivatives.
Example. Solve dy/dx = (1 + y²)/(1 + x²). Separate: dy/(1 + y²) = dx/(1 + x²). Integrate: tan⁻¹ y = tan⁻¹ x + C.
Example with a condition. Find the curve through (0, 2) with dy/dx = 2xy. For y > 0, dy/y = 2x dx, so log y = x² + C₁ and y = C e^(x²). At x = 0, y = 2, so C = 2: y = 2e^(x²).
Growth. When an amount P grows at a rate proportional to itself, dP/dt = kP. Separating, dP/P = k dt, log P = kt + C₁, so P = P₀ e^(kt), where P₀ is the amount at t = 0. The doubling time is (log 2)/k. At 5% a year, k = 1/20 and the doubling time is 20 log 2 ≈ 13.86 years.
Method 2: homogeneous equations
A function F(x, y) is homogeneous of degree n if F(λx, λy) = λⁿ F(x, y) for every nonzero λ. For example x² + 3xy has degree 2, 2x − y has degree 1, and (x + y)/(x − y) has degree 0. sin x + y is not homogeneous at all.
The equation dy/dx = F(x, y) is homogeneous when F has degree zero. Then F can be written as a function of y/x alone, and the substitution y = vx does the work:
- y = vx, so dy/dx = v + x dv/dx.
- Substitute: v + x dv/dx = g(v), so x dv/dx = g(v) − v.
- Separate: dv/(g(v) − v) = dx/x, and integrate.
- Replace v by y/x.
Example. Solve (x² − y²) dx + 2xy dy = 0. Rearranged, dy/dx = (y² − x²)/(2xy); replacing x, y by λx, λy leaves it unchanged, so it is homogeneous. With y = vx: v + x dv/dx = (v² − 1)/(2v), so x dv/dx = −(1 + v²)/(2v). Separate: 2v dv/(1 + v²) = −dx/x. Integrate: log(1 + v²) = −log|x| + C₁, so x(1 + v²) = C. With v = y/x, x² + y² = Cx.
If the equation is given as dx/dy = F(x, y) with F of degree zero, put x = vy instead, with dx/dy = v + y dv/dy.
Method 3: linear equations and the integrating factor
A first order linear equation has the form
dy/dx + Py = Q, where P and Q depend on x alone (or are constants).
Multiply by g(x) = e^(∫P dx). Because g′ = Pg, the left side g y′ + Pg y is exactly d/dx (y g). So
d/dx (y × I.F.) = Q × I.F. ⇒ y × I.F. = ∫(Q × I.F.) dx + C
Steps: (i) bring the equation to the form dy/dx + Py = Q; (ii) I.F. = e^(∫P dx); (iii) write y × I.F. = ∫Q × I.F. dx + C and integrate.
Example. Solve x dy/dx + 2y = x² (x ≠ 0). Divide by x: dy/dx + (2/x)y = x, so P = 2/x and Q = x. I.F. = e^(2 log x) = x². Then y x² = ∫x³ dx = x⁴/4 + C, so y = x²/4 + Cx⁻².
Linear in x. If the equation is linear in x instead, dx/dy + P₁x = Q₁ with P₁ and Q₁ functions of y, then I.F. = e^(∫P₁ dy) and x × I.F. = ∫(Q₁ × I.F.) dy + C.
Example. Solve y dx + (x − y²) dy = 0. As dx/dy = (y² − x)/y, this is dx/dy + (1/y)x = y, so P₁ = 1/y, I.F. = y and xy = ∫y² dy = y³/3 + C. x = y²/3 + C/y.
A curve from its tangent slope
Example. A curve through (0, 0) has slope at each point equal to the sum of the coordinates. Then dy/dx = x + y, or dy/dx − y = x: linear with P = −1, I.F. = e⁻ˣ. y e⁻ˣ = ∫x e⁻ˣ dx = −(x + 1)e⁻ˣ + C, so y = Ceˣ − x − 1. At the origin C = 1: y = eˣ − x − 1.
Read next: order and degree, the Chapter 9 notes and the NCERT solutions for Exercises 9.3, 9.4 and 9.5.
Practice
-
The general solution of dy/dx = x/y is:
Show answer
Answer: (a) y² − x² = C
-
For dy/dx − 3y = e²ˣ, the integrating factor is:
Show answer
Answer: (b) e⁻³ˣ
-
Solve dy/dx = (x + y)/x.
Show answer
Answer: It is homogeneous. Put y = vx: v + x dv/dx = 1 + v, so dv = dx/x and v = log|x| + C. Hence y = x log|x| + Cx.
-
Solve dy/dx + y = 1, given y = 3 when x = 0.
Show answer
Answer: Linear with P = 1, Q = 1, I.F. = eˣ. Then y eˣ = ∫eˣ dx = eˣ + C, so y = 1 + Ce⁻ˣ. At x = 0, 3 = 1 + C, so C = 2 and y = 1 + 2e⁻ˣ.
Questions students ask
What is a first order, first degree differential equation?
One in which only the first derivative appears, and only to the power 1, so it can be written dy/dx = F(x, y). All three methods of this chapter are for equations of this kind.
Why does the integrating factor work?
With g(x) = e^(∫P dx), g′(x) = P g(x). So g dy/dx + P g y = g dy/dx + g′ y = d/dx (y g). Multiplying dy/dx + Py = Q by g turns the left side into an exact derivative, and one integration finishes the job.
How do I check if an equation is homogeneous?
Write it as dy/dx = F(x, y) and replace x by λx and y by λy. If λ cancels completely, F is homogeneous of degree zero and the equation is homogeneous. (x + y)/(x − y) passes; (x + y + 1)/(x − y) does not.
Can one equation be solved by more than one method?
Yes. dy/dx + y = 1 is linear, and it is also separable: dy/(1 − y) = dx. Both routes give y = 1 + Ce⁻ˣ. Use whichever is quicker.
Stuck on a question?
Take a photo and Lagnever AI explains it step by step. Try it for 7 days for ₹2.
Get it on Google Play Open in browser
For parents: after the trial, the plan renews monthly by UPI or card autopay. You can cancel anytime in the app.