How to use these solutions#
These are detailed worked solutions to the Mixed practice questions of the lesson Homogeneous and Linear Equations, with Mixed Practice. Try each question yourself first, then follow the solution step by step. The most important skill here is the first one — identifying the type of the equation (separable, homogeneous or linear) — so every solution begins by showing how to recognise it.
Question 1: A homogeneous equation with y/x and x/y#
The problem#
Solve dxdy=xy+yx.
Understanding the problem#
We want the general solution: a relation between x and y with one arbitrary constant. The right side contains only the ratios xy and yx=y/x1.
The idea#
Since the right side depends only on xy, the equation is homogeneous. Substitute y=vx, so dxdy=v+xdxdv; the variables v and x will then separate.
Step-by-step solution#
Step 1. Put y=vx. Then xy=v and yx=v1.
v+xdxdv=v+v1.
Step 2. Cancel v from both sides.
xdxdv=v1.
Step 3. Separate the variables: all v on one side, all x on the other.
vdv=xdx.
Step 4. Integrate both sides.
2v2=log∣x∣+C.
Step 5. Put back v=xy and clear fractions (multiply by 2x2; write the new constant 2C again as C).
2x2y2=log∣x∣+C⟹y2=2x2log∣x∣+Cx2.
Checking the answer#
Differentiate y2=2x2log∣x∣+Cx2: 2yy′=4xlog∣x∣+2x+2Cx. So y′=yx(2log∣x∣+C)+x. From the solution, 2log∣x∣+C=x2y2, so y′=yy2/x+x=xy+yx ✓.
Answer#
y2=2x2log∣x∣+Cx2.
The problem#
Solve (x−y)dy−(x+y)dx=0.
Understanding the problem#
The equation is written with differentials. First rewrite it as dxdy=… to see its type.
The idea#
Rearranging gives dxdy=x−yx+y: numerator and denominator are both of degree 1, so the equation is homogeneous. Use y=vx.
Step-by-step solution#
Step 1. Rearrange.
(x−y)dy=(x+y)dx⟹dxdy=x−yx+y.
Step 2. Put y=vx and divide the top and bottom of the right side by x.
v+xdxdv=1−v1+v.
Step 3. Isolate xdxdv.
xdxdv=1−v1+v−v=1−v1+v−v+v2=1−v1+v2.
Step 4. Separate the variables.
1+v21−vdv=xdx.
Step 5. Split the left side into two standard integrals.
∫1+v2dv−∫1+v2vdv=∫xdx.
The first is tan−1v. For the second, the numerator v is half the derivative of 1+v2, so it equals 21log(1+v2).
tan−1v−21log(1+v2)=log∣x∣+C.
Step 6. Put v=xy and combine the logarithms: 21log(1+x2y2)+log∣x∣=21logx2x2+y2+21logx2=21log(x2+y2).
tan−1xy=21log(x2+y2)+C.
Checking the answer#
Differentiate implicitly: x2+y2xy′−y=x2+y2x+yy′, so xy′−y=x+yy′, y′(x−y)=x+y ✓.
Answer#
tan−1xy=21log(x2+y2)+C.
Question 3: A linear equation with an exponential#
The problem#
Solve dxdy−y=e2x.
Understanding the problem#
The equation has the form dxdy+P(x)y=Q(x) with P(x)=−1 and Q(x)=e2x. So it is linear in y.
The idea#
Multiply by the integrating factor IF=e∫Pdx; then y⋅IF=∫Q⋅IFdx+C.
Step-by-step solution#
Step 1. Integrating factor.
IF=e∫(−1)dx=e−x.
Step 2. Apply the formula.
ye−x=∫e2x⋅e−xdx+C=∫exdx+C=ex+C.
Step 3. Multiply by ex.
y=e2x+Cex.
Checking the answer#
y′=2e2x+Cex, so y′−y=2e2x+Cex−e2x−Cex=e2x ✓.
Answer#
y=e2x+Cex.
Question 4: A linear equation with an initial condition#
The problem#
Solve dxdy+x2y=x, given y(1)=1.
Understanding the problem#
Linear form with P(x)=x2, Q(x)=x. The condition y(1)=1 fixes the constant, so we want a particular solution.
The idea#
Integrating factor e∫Pdx, general solution, then substitute x=1, y=1 to find C.
Step-by-step solution#
Step 1. Integrating factor (take x>0, since the condition is at x=1).
IF=e∫x2dx=e2logx=elogx2=x2.
Step 2. Apply the formula.
x2y=∫x⋅x2dx+C=4x4+C.
Step 3. Use y(1)=1.
1⋅1=41+C⟹C=43.
Step 4. Divide by x2.
y=4x2+4x23.
Checking the answer#
At x=1: 41+43=1 ✓. y′=2x−2x33 and x2y=2x+2x33; their sum is x ✓.
Answer#
y=4x2+4x23.
Question 5: A linear equation with cot x#
The problem#
Solve dxdy+ycotx=2cosx.
Understanding the problem#
Linear with P(x)=cotx and Q(x)=2cosx.
The idea#
Integrating factor e∫cotxdx, then integrate Q⋅IF; the double-angle identity 2sinxcosx=sin2x makes the integral easy.
Step-by-step solution#
Step 1. ∫cotxdx=log∣sinx∣, so
IF=elogsinx=sinx.
Step 2. Apply the formula.
ysinx=∫2cosxsinxdx+C=∫sin2xdx+C.
Step 3. Integrate: ∫sin2xdx=−2cos2x.
ysinx=−2cos2x+C.
Checking the answer#
Differentiate both sides: y′sinx+ycosx=sin2x. Divide by sinx: y′+ycotx=2cosx ✓.
Answer#
ysinx=−2cos2x+C. (Equivalently ysinx=sin2x+C′, since −2cos2x=sin2x−21.)
Question 6: A linear equation after dividing through#
The problem#
Solve (1+x2)dxdy+2xy=1+x21.
Understanding the problem#
The coefficient of dxdy is not 1, so we must divide by 1+x2 to reach the standard linear form.
The idea#
Divide, identify P and Q, find the IF.
Step-by-step solution#
Step 1. Divide by 1+x2.
dxdy+1+x22xy=(1+x2)21.
So P=1+x22x, Q=(1+x2)21.
Step 2. Integrating factor. The numerator 2x is the derivative of 1+x2:
∫1+x22xdx=log(1+x2)⟹IF=1+x2.
Step 3. Apply the formula.
y(1+x2)=∫(1+x2)21(1+x2)dx+C=∫1+x2dx+C=tan−1x+C.
Checking the answer#
Notice the original left side is exactly dxd[(1+x2)y]. Differentiating y(1+x2)=tan−1x+C gives (1+x2)y′+2xy=1+x21 ✓.
Answer#
y(1+x2)=tan−1x+C.
Question 7: A homogeneous equation with tan(y/x)#
The problem#
Solve dxdy=xy+tanxy.
Understanding the problem#
The right side depends only on xy, so this is homogeneous.
The idea#
Substitute y=vx, separate, integrate cotv.
Step-by-step solution#
Step 1. With y=vx:
v+xdxdv=v+tanv⟹xdxdv=tanv.
Step 2. Separate: tanvdv=cotvdv.
cotvdv=xdx.
Step 3. Integrate.
log∣sinv∣=log∣x∣+log∣C∣.
(Writing the constant as log∣C∣ lets us combine the logs.)
Step 4. Combine and remove the logarithms.
log∣sinv∣=log∣Cx∣⟹sinv=Cx.
Step 5. Put back v=xy.
sinxy=Cx.
Checking the answer#
Differentiate sinxy=Cx: cosxy⋅x2xy′−y=C=xsin(y/x). So xy′−y=xtanxy, i.e. y′=xy+tanxy ✓.
Answer#
sinxy=Cx.
Question 8: A curve from its slope#
The problem#
Find the equation of the curve passing through (0,1) whose slope at any point (x,y) is x+y.
Understanding the problem#
"Slope at any point is x+y" means dxdy=x+y. The curve must also pass through (0,1), which fixes the constant.
The idea#
Rewrite as dxdy−y=x: linear with P=−1, Q=x. The integral ∫xe−xdx needs integration by parts.
Step-by-step solution#
Step 1. Standard linear form and IF.
dxdy−y=x,IF=e−x.
Step 2. Apply the formula.
ye−x=∫xe−xdx+C.
Step 3. By parts (u=x, dv=e−xdx, so du=dx, v=−e−x):
∫xe−xdx=−xe−x+∫e−xdx=−xe−x−e−x.
Step 4. So ye−x=−xe−x−e−x+C; multiply by ex.
y=−x−1+Cex.
Step 5. Use the point (0,1): 1=0−1+C, so C=2.
y=2ex−x−1.
Checking the answer#
y(0)=2−0−1=1 ✓. y′=2ex−1, and x+y=2ex−1 ✓.
Answer#
y=2ex−x−1.
Question 9: Newton's law of cooling#
The problem#
Newton's law of cooling says dtdT=−k(T−25), where T is the temperature in ∘C and t the time in minutes. A cup of tea at 85∘C cools to 55∘C in 10 minutes. When will it be at 40∘C?
Understanding the problem#
The room is at 25∘C. The rate of cooling is proportional to how much hotter the tea is than the room. We know T(0)=85 and T(10)=55; we must find t with T(t)=40. The constant k is unknown and must be found from the data.
The idea#
The equation is separable in T−25. Solve it to get an exponential, use the two data points, then solve for the required time.
Step-by-step solution#
Step 1. Separate and integrate.
T−25dT=−kdt⟹log∣T−25∣=−kt+c⟹T−25=Ae−kt.
Step 2. Use T(0)=85: 85−25=A, so A=60.
T−25=60e−kt.
Step 3. Use T(10)=55.
30=60e−10k⟹e−10k=21.
Step 4. Set T=40.
15=60e−kt⟹e−kt=41=(21)2=(e−10k)2=e−20k.
Step 5. Compare exponents: kt=20k, so t=20.
Checking the answer#
The temperature excess halves every 10 minutes: 60→30 (at 10 min) →15 (at 20 min). 25+15=40 ✓.
Answer#
The tea reaches 40∘C after 20 minutes.
Question 10: Identify the type and solve#
The problem#
Identify the type of the equation dxdy=ex−y and solve it.
Understanding the problem#
Before solving, decide which method applies. Use the law of indices ex−y=ex⋅e−y.
The idea#
The right side is a product of a function of x and a function of y, so the equation is variables separable (not homogeneous, not linear in y).
Step-by-step solution#
Step 1. Rewrite: dxdy=exe−y.
Step 2. Separate: multiply both sides by eydx.
eydy=exdx.
Step 3. Integrate.
ey=ex+C.
Checking the answer#
Differentiate: eyy′=ex, so y′=ex−y ✓.
Answer#
Variables separable; the solution is ey=ex+C.