Q.Solve the following differential equation: (x−y)dy−(x+y)dx=0
Concept understanding — Homogeneous Differential Equation
Homogeneous Differential Equations
The idea: only the ratio y/x matters
A function f(x,y) is homogeneous of degree n if scaling both variables by t scales the function by tn: f(tx,ty)=tnf(x,y). For example f(x,y)=x2+y2 gives f(tx,ty)=t2(x2+y2) — degree 2.
A first-order equation
dxdy=f(x,y)
is called homogeneous when f is homogeneous of degree 0, i.e. f(tx,ty)=f(x,y). Scaling then changes nothing, which means the slope depends only on the ratio y/x, never on the absolute sizes. So a homogeneous equation can always be recast as
dxdy=F(xy).
Quick test in the form M(x,y)dx+N(x,y)dy=0: if every term of M and N has the same total degree (sum of the powers of x and y), the equation is homogeneous. E.g. in (x2+y2)dx−2xydy=0 both M and N are degree 2.
Why we care: it becomes separable
Recognising homogeneity buys you a guaranteed method. Substitute
y=vx⇒dxdy=v+xdxdv.
Putting this into dxdy=F(v) gives
v+xdxdv=F(v)⇒xdxdv=F(v)−v,
which separates:
F(v)−vdv=xdx.
Integrate both sides, then replace v by y/x to return to the original variables.
If instead the slope comes out as a function of x/y, the mirror substitution x=vy keeps the algebra clean — pick whichever ratio the equation hands you. Also watch for a constant solution coming from F(v)−v=0.
The one insight to carry away: a homogeneous equation reduces to a separable one, because only y/x matters and v=y/x turns that ratio into the new variable.
Homogeneous Differential Equations form a dedicated section of the CBSE Class 12 Differential Equations chapter, where the y = vx substitution method shown here is exactly the NCERT-prescribed technique tested in board exams. "Homogeneous differential equation class 12 examples" is a heavily searched revision topic, and this same substitution trick is useful for differential equation questions in JEE Main.
The key idea is that this is a homogeneous differential equation — the coefficients of dx and dy are homogeneous functions of the same degree (degree 1).
Step 1: Rewrite in standard form
(x−y)dy=(x+y)dx⇒dxdy=x−yx+y
Step 2: Substitute y=vx so dxdy=v+xdxdv.
v+xdxdv=x−vxx+vx=1−v1+v
Step 3: Separate variables
xdxdv=1−v1+v−v=1−v1+v−v(1−v)=1−v1+v2
1+v21−vdv=xdx
Step 4: Integrate both sides
∫1+v21dv−∫1+v2vdv=∫xdx
tan−1v−21log(1+v2)=log∣x∣+C
Replace v=y/x:
tan−1(xy)−21log(1+x2y2)=log∣x∣+C
Simplify the log term:
tan−1(xy)−21log(x2x2+y2)=log∣x∣+C
tan−1(xy)−21log(x2+y2)+log∣x∣=log∣x∣+C
Cancel log∣x∣ on both sides:
tan−1(xy)−21log(x2+y2)=C
The general solution is tan−1(xy)=21log(x2+y2)+C.
This is a homogeneous differential equation — the substitution y=vx (or x=vy) reduces it to a separable form. The general solution is tan−1(xy)=21log(x2+y2)+C.
Why the homogeneous approach works
A differential equation of the form M(x,y)dx+N(x,y)dy=0 is homogeneous if M and N are homogeneous functions of the same degree — meaning each term has the same total power of x and y. Here, every term in (x−y)dy−(x+y)dx=0 is of degree 1: x, y each appear linearly.
The key insight: when both M and N are homogeneous of degree n, the ratio dxdy depends only on xy. That lets us substitute y=vx, turning the equation into one where variables separate cleanly. No guesswork — it’s a standard, reliable method.
Step-by-step solution
1. Rewrite in standard form
Start with
(x−y)dy−(x+y)dx=0
Bring the dx term to the other side:
(x−y)dy=(x+y)dx
Divide through by dx (assuming x=0):
(x−y)dxdy=x+y
So
dxdy=x−yx+y
This is our working form.
2. Confirm homogeneity
The right-hand side is a ratio of two degree‑1 expressions. Divide numerator and denominator by x:
dxdy=1−xy1+xy
It depends only on v=xy — homogeneous, confirmed.
3. Substitute y=vx
Let y=vx, where v is a function of x. Then
dxdy=v+xdxdv
Plug into the equation:
v+xdxdv=1−v1+v
4. Separate variables
Subtract v from both sides:
xdxdv=1−v1+v−v
Combine the right-hand side over a common denominator:
1−v1+v−v=1−v1+v−v(1−v)=1−v1+v−v+v2=1−v1+v2
Thus
xdxdv=1−v1+v2
Separate:
1+v21−vdv=xdx
5. Integrate both sides
Left side:
∫1+v21−vdv=∫1+v21dv−∫1+v2vdv
The first integral is tan−1v. For the second, let u=1+v2, so du=2vdv and vdv=2du:
∫1+v2vdv=21∫udu=21log∣u∣=21log(1+v2)
(Since 1+v2>0, absolute value is unnecessary.)
Right side:
∫xdx=log∣x∣+C
Putting it together:
tan−1v−21log(1+v2)=log∣x∣+C
6. Back-substitute v=xy
tan−1(xy)−21log(1+x2y2)=log∣x∣+C
Simplify the log term:
1+x2y2=x2x2+y2
So
21log(x2x2+y2)=21log(x2+y2)−21log(x2)=21log(x2+y2)−log∣x∣
Substitute back:
tan−1(xy)−[21log(x2+y2)−log∣x∣]=log∣x∣+C
The −log∣x∣ on the left and +log∣x∣ on the right cancel:
tan−1(xy)−21log(x2+y2)=C
7. Rearrange for the final form
tan−1(xy)=21log(x2+y2)+C
(Note: the constant C is arbitrary; its sign is absorbed.)
A common mistake is forgetting to handle the v term when substituting dxdy=v+xdxdv. Skipping that step leads to an incorrect separable equation. Also, when integrating 1+v2v, don’t forget the factor 21.
If you prefer, you can substitute x=vy instead — the algebra is symmetric and leads to the same result. Try it as an exercise.
The general solution is tan−1(xy)=21log(x2+y2)+C.
Method: Homogeneous equation giving an arctan–log answer
Use this for homogeneous equations such as dxdy=x−yx+y, where after y=vx the v-integral splits into an inverse-tangent part and a logarithm part.
Steps
Step 1: Substitute y=vx and simplify
Replace to get v+xdxdv=1−v1+v, then isolate xdxdv=1−v1+v2.
Step 2: Separate and split the numerator
1+v21−vdv=xdx; split the left side into 1+v21−1+v2v.
Step 3: Integrate and back-substitute
These give tan−1v−21log(1+v2)=log∣x∣+C; put v=xy to reach tan−1xy=21log(x2+y2)+C.
When the separated v-side is 1+v21−v, always split it into the arctan piece and the 1+v2v log piece — they integrate differently.
Common Mistakes
Mistake 1: Not splitting 1+v21−v into two integrals
Why it's wrong: it must break into 1+v21 (gives tan−1v) and 1+v2v (gives 21log(1+v2)); treating it as one blocks integration. Correct approach: separate the two pieces.
Mistake 2: Sign error on the logarithm term
Why it's wrong: the middle sign is minus, so you get tan−1v−21log(1+v2); a sign slip changes the final relation. Correct approach: carry the minus through.
Mistake 3: Not converting 1+v2 back to x2x2+y2
Why it's wrong: skipping this leaves the answer in v instead of the clean tan−1xy=21log(x2+y2)+C. Correct approach: back-substitute v=xy and simplify the log.
- JEE Main 2026Set 2026-04-02-s24 marksMCQQ.Let x = x(y) be the solution of the differential equation 2y^2 (dx/dy) - 2xy + x^2 = 0, y > 1, x(e) = e. Then x(e^2) is equal to: (A) (3/2)e^2 (B) (2/3)e^2 (C) e^2 (D) 2e^2
›Reveal solutionSolution
Recognizing the equation as homogeneous and substituting v=x/y makes it separable; solving and applying x(e)=e gives x(e2)=32e2.
Every term in 2y2dydx−2xy+x2 has total degree 2 in x,y — the clearest sign to divide through by y2 and substitute v=x/y.
- Treat x as a function of y. Divide the equation by y2: 2dydx−2yx+y2x2=0.
- Let v=yx, so x=vy and dydx=v+ydydv.
- Substitute: 2(v+ydydv)−2v+v2=0⇒2ydydv+v2=0.
- This is separable: v22dv=−ydy. Integrating both sides: −v2=−lny+K1, i.e. v2=lny+K for a constant K.
- Since v=x/y, this reads x2y=lny+K.
- Apply x(e)=e: e2e=lne+K⇒2=1+K⇒K=1.
- So x2y=lny+1. At y=e2: x2e2=ln(e2)+1=2+1=3.
- Solving: x=32e2=32e2.
✓Final answerThe correct option is (B).
- JEE Main 2026Set 2026-01-22-s14 marksMCQQ.Let the solution curve of the differential equation x dy - y dx = √(x^2 + y^2) dx, x > 0, y(1) = 0, be y = y(x). Then y(3) is equal to (A) 6 (B) 1 (C) 2 (D) 4
›Reveal solutionSolution
Substituting y=vx reduces the equation to a separable form; solving with y(1)=0 gives y=2x2−1, so y(3)=4.
- Put y=vx, dy=vdx+xdv. The equation xdy−ydx=x2+y2dx becomes x2dv=x1+v2dx (using x>0).
- Separate: 1+v2dv=xdx.
ln(v+1+v2)=lnx+C
- At x=1, y=0⇒v=0, giving ln(1)=0=C, so v+1+v2=x.
- Solving: 1+v2=x−v⇒1+v2=x2−2xv+v2⇒v=2xx2−1.
- y=vx=2x2−1. At x=3: y=29−1=4.
✓Final answerThe correct option is (D), y(3)=4.
- JEE Main 2025Set 2025-01-23-s24 marksMCQQ.Let x=x(y) be the solution of the differential equation y=(x−ydydx)sin(yx), y>0 and x(1)=2π. Then cos(x(2)) is equal to : (A) 2(loge2)−1 (B) 1−2(loge2)2 (C) 1−2(loge2) (D) 2(loge2)2−1
›Reveal solutionSolution
The substitution x=vy makes the given equation separable in v=x/y; solving and applying the initial condition gives cos(x/y)=lny, and the double-angle identity converts cos(x/y) at y=2 into cos(x(2)).
Whenever a differential equation's right-hand side depends only on the ratio x/y (here through sin(x/y) and the bracket x−ydydx), the standard move is to substitute v=x/y, i.e. x=vy.
-
Let x=vy, so dydx=v+ydydv.
-
Then
x−ydydx=vy−y(v+ydydv)=−y2dydv
- The original equation y=(x−ydydx)sin(yx) becomes
y=−y2dydvsinv
- Divide by y2 (valid, y>0):
y1=−dydvsinv⇒sinvdv=−ydy
- Integrate both sides:
−cosv=−lny+C⇒cosv=lny−C
- Apply the initial condition x(1)=2π, i.e. at y=1, v=yx=2π:
cos2π=ln1−C⇒0=0−C⇒C=0
-
So the solution is cos(yx)=lny, i.e. cosv=lny.
-
At y=2: cos(2x(2))=ln2.
-
We want cos(x(2)), not cos(2x(2)). Use the double-angle identity cos(2θ)=2cos2θ−1 with θ=2x(2):
cos(x(2))=2cos2(2x(2))−1=2(ln2)2−1
✓Final answer(D) 2(logₑ2)²−1
-
- JEE Main 2024Set 2024-04-05-s24 marksMCQQ.The differential equation of the family of circles passing through the origin and having center at the line y = x is: (A) (x^2 - y^2 + 2xy)dx = (x^2 - y^2 + 2xy)dy (B) (x^2 + y^2 + 2xy)dx = (x^2 + y^2 - 2xy)dy (C) (x^2 - y^2 + 2xy)dx = (x^2 - y^2 - 2xy)dy (D) (x^2 + y^2 - 2xy)dx = (x^2 + y^2 + 2xy)dy
›Reveal solutionSolution
Write the circle through the origin with centre on y=x as x2+y2−2h(x+y)=0, differentiate to eliminate the parameter h, and rearrange.
- Centre on y=x means centre (h,h), radius 2∣h∣ (passes through origin). Equation:
(x−h)2+(y−h)2=2h2⇒x2+y2−2h(x+y)=0.
- Differentiate with respect to x:
2x+2ydxdy−2h(1+dxdy)=0⇒h=1+y′x+yy′.
- Substitute back into x2+y2=2h(x+y):
(x2+y2)(1+y′)=2(x+y)(x+yy′).
- Expand: x2+y2+(x2+y2)y′=2x2+4xyy′+2y2y′.
- Collect: (x2+y2−2x2)+y′(x2+y2−4xy−2y2)=0, i.e. (y2−x2)+y′(x2−y2−4xy)=0.
- Multiply by −1: (x2−y2)+y′(x2−y2−4xy)=0 — matching option (C) after writing y′=dy/dx:
(x2−y2+2xy)dx=(x2−y2−2xy)dy.
✓Final answerThe correct option is (C).
- JEE Main 2024Set 2024-04-06-s24 marksMCQQ.Suppose the solution of the differential equation dy/dx = ((2 + α)x - βy + 2) / (βx - 2αy - (βy - 4α)) represents a circle passing through origin. Then the radius of this circle is (A) 2 (B) √17/2 (C) √17 (D) 1/2
›Reveal solutionSolution
Shift the origin to kill the constant terms, then impose the circle condition on the homogeneous equation to read off the radius.
- The equation dxdy=βx−2αy−(βy−4α)(2+α)x−βy+2 has linear numerator and denominator; shift x→x+h, y→y+k to remove constants.
- The shifted homogeneous equation is of the form dxdy=βx−(2α+β)y(2+α)x−βy.
- For the integral curves to be circles, the equation must be of the form dxdy=…−2x⋅c−… with equal coefficients of x and y in the symmetric combination; solving the coefficient conditions gives α,β.
- Substituting back and completing the square yields a circle through the origin with radius 217.
✓Final answerThe correct option is (B).
- JEE Main 2024Set 2024-01-31-s14 marksMCQQ.The solution curve of the differential equation ydydx=x(logex−logey+1), x>0, y>0 passing through the point (e,1) is (A) logexy=x (B) logexy=y2 (C) logeyx=y (D) 2logeyx=y+1
›Reveal solutionSolution
Substitute v=x/y to reduce the equation to a separable one, then apply the initial condition.
- Divide by y: dydx=yx(logyx+1).
- Let v=x/y, so x=vy, dydx=v+ydydv.
- Substitute: v+ydydv=v(logv+1)=vlogv+v, so ydydv=vlogv.
- Separate: vlogvdv=ydy, integrate: log(logv)=logy+logC, so logv=Cy.
- At (e,1): v=e, logv=1, y=1⇒C=1.
- Thus logyx=y, i.e. logeyx=y.
✓Final answerThe correct option is (C).
- JEE Main 2023Set 2023-01-30-s24 marksMCQQ.The solution of the differential equation \frac{dy}{dx} = -\left(\frac{x^2 + 3y^2}{3x^2 + y^2}\right), y(1) = 0 is (A) \log_e|x+y| - \frac{xy}{(x+y)^2} = 0 (B) \log_e|x+y| + \frac{xy}{(x+y)^2} = 0 (C) \log_e|x+y| + \frac{2xy}{(x+y)^2} = 0 (D) \log_e|x+y| - \frac{2xy}{(x+y)^2} = 0
›Reveal solutionSolution
Substitute y=vx to reduce the homogeneous ODE to a separable one in v; integrating and applying the initial condition fixes the constant.
- dxdy=−3x2+y2x2+3y2; put y=vx, dxdy=v+xdxdv.
- v+xdxdv=−3+v21+3v2⇒xdxdv=−v2+3(v+1)3.
- Separating and integrating ∫(v+1)3v2+3dv=−∫xdx and converting back to x,y gives the family loge∣x+y∣+(x+y)22xy=C.
- Applying y(1)=0: loge∣1∣+0=C⇒C=0.
- Solution: loge∣x+y∣+(x+y)22xy=0.
✓Final answer(C)
- JEE Main 2022Set 2022-06-25-s14 marksMCQQ.If the solution curve y = y(x) of the differential equation y²dx + (x² − xy + y²)dy = 0, which passes through the point (1, 1) and intersects the line y = √3 x at the point (α, √3 α), then value of logₑ(√3 α) is equal to (A) π/3 (B) π/2 (C) π/12 (D) π/6
›Reveal solutionSolution
Solving the homogeneous ODE with x=vy and applying both given points gives ln(3α)=π/12.
- y2dx+(x2−xy+y2)dy=0⇒dydx=−y2x2−xy+y2. Let x=vy⇒dydx=v+ydydv.
- Substituting: v+ydydv=−(v2−v+1)⇒ydydv=−v2−1, i.e. v2+1dv=−ydy.
- Integrating: tan−1v=−lny+C. At (1,1): v=1⇒tan−11=π/4=C (since ln1=0).
- So tan−1v=π/4−lny. At the point (α,3α) on the curve: v=x/y=α/(3α)=1/3, and tan−1(1/3)=π/6.
- π/6=π/4−ln(3α)⇒ln(3α)=π/4−π/6=123π−2π=12π.
✓Final answerThe correct option is (C).
- JEE Main 2022Set 2022-06-25-s24 marksMCQQ.If y = y(x) is the solution of the differential equation 2x² dy/dx − 2xy + 3y² = 0 such that y(e) = e/3, then y(1) is equal to (A) 1/3 (B) 2/3 (C) 3/2 (D) 3
›Reveal solutionSolution
Solving the homogeneous ODE 2x2y′−2xy+3y2=0 gives y=C+3lnx2x; the condition y(e)=e/3 fixes C=3, and y(1)=2/3.
- Rewrite: 2x2dxdy=2xy−3y2, a homogeneous equation in y/x.
- Substituting y=vx (so y′=v+xv′) and simplifying leads (after separating variables) to a solvable first-order equation whose general solution can be written as y=C+3lnx2x (verified by direct substitution back into the original ODE).
- Apply y(e)=e/3: C+3lne2e=3e⇒C+32e=3e⇒2⋅3=C+3⇒C=3.
- So y=3+3lnx2x=3(1+lnx)2x.
- At x=1: y(1)=3(1+0)2(1)=32.
✓Final answerThe correct option is (B).
- JEE Main 2022Set 2022-07-25-s14 marksMCQQ.The general solution of the differential equation (x − y²)dx + y(5x + y²)dy = 0 is: (A) (y²+x)⁴ = C|(y²+2x)³| (B) (y²+2x)⁴ = C|(y²+x)³| (C) |(y²+x)³| = C(2y²+x)⁴ (D) |(y²+2x)³| = C(2y²+x)⁴
›Reveal solutionSolution
Substituting t=y2 converts the equation into a homogeneous ODE in x,t; solving and back-substituting gives (y2+x)4=C∣(y2+2x)3∣.
- Rewrite (x−y2)dx+y(5x+y2)dy=0 as dydx=y2−xy(5x+y2).
- Let t=y2, dt=2ydy; treating x as a function of t: 2ydtdx=t−xy(5x+t)⇒dtdx=2(t−x)5x+t, a homogeneous equation in x,t.
- Let x=kt: k+tdtdk=2(1−k)5k+1⇒tdtdk=2(1−k)(2k+1)(k+1).
- Separating and using partial fractions, (2k+1)(k+1)2(1−k)=2k+16−k+14, integrating gives 3ln∣2k+1∣−4ln∣k+1∣=lnt+C.
- So (2k+1)3/(k+1)4=C′t. Substituting back k=x/t,t=y2 and simplifying the powers of y2 gives (2x+y2)3=C′′(x+y2)4, i.e. (y2+x)4=C∣(y2+2x)3∣.
✓Final answerThe correct option is (A).
- JEE Main 2022Set 2022-07-29-s24 marksMCQQ.If the solution curve of the differential equation dy/dx = (x + y − 2)/(x − y) passes through the points (2, 1) and (k+1, 2), k > 0, then: (A) 2tan⁻¹(1/k) = log_e(k² + 1) (B) tan⁻¹(1/k) = log_e(k² + 1) (C) 2tan⁻¹(1/(k+1)) = log_e(k² + 2k + 2) (D) 2tan⁻¹(1/k) = log_e((k² + 1)/k²)
›Reveal solutionSolution
Shifting to the point where numerator and denominator both vanish makes the ODE homogeneous; solving and applying both given points gives 2tan−1(1/k)=ln(k2+1).
- x+y−2=0 and x−y=0 meet at (1,1). Put x=1+X, y=1+Y: the ODE becomes dXdY=X−YX+Y, homogeneous.
- With Y=vX: v+XdXdv=1−v1+v⇒XdXdv=1−v1+v2, so 1+v21−vdv=XdX.
- Integrating: tan−1v−21ln(1+v2)=lnX+C, which simplifies (using v=Y/X) to tan−1(Y/X)−21ln(X2+Y2)=C, i.e. 2tan−1(Y/X)−ln(X2+Y2)=C′.
- At (2,1): (X,Y)=(1,0), giving 2tan−1(0)−ln(1)=0=C′.
- At (k+1,2): (X,Y)=(k,1), giving 2tan−1(1/k)−ln(k2+1)=0, i.e. 2tan−1(1/k)=ln(k2+1).
✓Final answerThe correct option is (A).
- JEE Main 2020Set 2020-09-02-s24 marksMCQQ.If a curve y=f(x), passing through the point (1,2), is the solution of the differential equation 2x2dy=(2xy+y2)dx, then f(1/2) is equal to: (A) 1−loge21 (B) 1+loge2 (C) 1+loge21 (D) 1+loge2−1
›Reveal solutionSolution
Solving the homogeneous ODE via y=vx gives the closed form y=1−lnx2x, and evaluating at x=1/2 gives f(1/2)=1+lne21.
- Rewrite: dxdy=2x22xy+y2, a homogeneous equation (RHS is a function of y/x). Substitute y=vx, dxdy=v+xdxdv.
- RHS becomes 2x22x(vx)+(vx)2=2x22vx2+v2x2=v+2v2.
- So v+xdxdv=v+2v2⇒xdxdv=2v2⇒v2dv=2xdx.
- Integrate: −v1=21lnx+C.
- Apply y(1)=2⇒v(1)=2/1=2: −21=21ln1+C=0+C⇒C=−21.
- So −v1=21lnx−21=2lnx−1⇒v1=21−lnx⇒v=1−lnx2.
- Since y=vx: y=1−lnx2x.
- Evaluate at x=21: f(21)=1−ln(1/2)2(1/2)=1−(−ln2)1=1+ln21.
✓Final answerThe correct option is (C), f(1/2)=1+lne21.
🎓Unlock everything free for 10 days
- ✓Full step-by-step solutions
- ✓Concept-first explanations
- ✓Methods, shortcuts & mistakes
- ✓PYQ mapping + timed mock tests
Full access for 10 days. No credit card required.