Unit 7 · Topic 7.6 Beta

General Solutions by Separation of Variables

For a separable equation, put y with dy and x with dx , integrate both sides, and add one constant immediately.

Practice 1: Implementing Mathematical Processes

Question set for this topic

Part 1 · Hook

Why this matters

Checking that y=Cex2/2y = Ce^{x^2/2} solves dydx=xy\frac{dy}{dx} = xy takes one line. Finding it in the first place takes a trick: put all the yy's on one side with dydy, all the xx's on the other with dxdx, and integrate. When an equation lets you do that, it is separable, and you can solve it with the antiderivatives you already know.

Part 2 · Before you start

What this builds on

Part 3 · Prerequisite check

Quick check before you start

1. ∫1xdx=\int \frac{1}{x}\,dx =

  1. ln⁡|x|+C\ln|x| + C
  2. −1x2+C-\frac{1}{x^2} + C
  3. ln⁡x\ln x
  4. x00+C\frac{x^0}{0} + C
Show the answer

The derivative of ln⁡|x|\ln|x| is 1x\frac{1}{x} for x≠0x \ne 0; the absolute value keeps negative xx allowed.

  • Correct: ln⁡|x|+C\ln|x| + C:
  • −1x2+C-\frac{1}{x^2} + C:
  • ln⁡x\ln x:
  • x00+C\frac{x^0}{0} + C:

2. ∫2xex2dx=\int 2xe^{x^2}\,dx =

  1. ex2+Ce^{x^2} + C
  2. x2ex2+Cx^2e^{x^2} + C
  3. 2ex2+C2e^{x^2} + C
  4. ex33+C\frac{e^{x^3}}{3} + C
Show the answer

With u=x2u = x^2, du=2xdxdu = 2x\,dx: ∫eudu=eu+C\int e^u\,du = e^u + C.

  • Correct: ex2+Ce^{x^2} + C:
  • x2ex2+Cx^2e^{x^2} + C:
  • 2ex2+C2e^{x^2} + C:
  • ex33+C\frac{e^{x^3}}{3} + C:

Part 4 · See it

See it first

The slope field of dy/dx = xy on −2.5 ≤ x ≤ 2.5 and −4 ≤ y ≤ 4, with the curves y = Ce^(x²/2) for C = 0.25, 0.5, 1, 2 in crimson above the x-axis, for C = −0.25, −0.5, −1, −2 in blue below it, and C = 0, the x-axis itself, in green. Each curve is flattest at x = 0 and follows the segments.
Separating dydx=xy\frac{dy}{dx} = xy gives y=Cex2/2y = Ce^{x^2/2}. Each curve is one value of CC; C=0C = 0 is the xx-axis. LevlPrep original diagram.

Part 5 · Step by step

How it works, step by step

  1. The right side factors as g(x)h(y)g(x)h(y)the equation is separable: 1h(y)dy=g(x)dx\frac{1}{h(y)}\,dy = g(x)\,dx
  2. Integrate both sideseach side becomes an antiderivative; the two constants combine into one C
  3. An antiderivative of 1y\frac{1}{y} is ln⁡|y|\ln|y|keep the absolute value; exponentiating gives |y|=eCeG(x)|y| = e^{C}e^{G(x)}, so y=AeG(x)y = Ae^{G(x)} with AA any constant
  4. Solve for yy when you canthe general solution: a family of curves, one for each constant

Part 6 · Key ideas

Key ideas

  • Separable means the right side is a product (or quotient) of a function of xx and a function of yy. dydx=x+y\frac{dy}{dx} = x + y is not separable.
  • Separate completely: only yy and dydy on one side, only xx and dxdx on the other. dydy and dxdx stay in the numerators.
  • Integrate both sides and write +C+ C once, right away. Adding it after solving for yy gives a different, wrong family.
  • ∫dyy=ln⁡|y|\int \frac{dy}{y} = \ln|y|. Then |y|=eCe…|y| = e^{C}e^{\dots}, and ±eC\pm e^{C} becomes a constant AA that may be any sign.

Part 7 · Misconception

A common mistake

The wrong idea: Solve dydx=2xy2\frac{dy}{dx} = 2xy^2: −1y=x2-\frac{1}{y} = x^2, so y=−1x2+Cy = -\frac{1}{x^2} + C.

What actually happens: The constant belongs in the integration step: −1y=x2+C-\frac{1}{y} = x^2 + C, so y=−1x2+Cy = -\frac{1}{x^2 + C}. Adding CC at the end gives functions that do not satisfy the equation.

Part 8 · Check yourself

Check yourself

Exam-style questions. Anything you miss goes into your review queue.

Table

Four differential equations

Four differential equations, labeled I to IV
LabelIIIIIIIV
Equationdydx=2xy2\frac{dy}{dx} = 2xy^2dydx=x+y\frac{dy}{dx} = x + ydydx=ex−y\frac{dy}{dx} = e^{x - y}dydx=x2−y2\frac{dy}{dx} = x^2 - y^2

1. Which equations in the table are separable? Select all that apply.

  1. I
  2. II
  3. III
  4. IV
Show the answer

Separable means the right side is g(x)h(y)g(x)h(y). I and III factor that way; II and IV do not.

  • Correct: I: 2xy2=(2x)(y2)2xy^2 = (2x)(y^2), a product of a function of xx and a function of yy.
  • II: x+yx + y is a sum; it cannot be written as g(x)h(y)g(x)h(y).
  • Correct: III: ex−y=ex⋅e−ye^{x - y} = e^{x} \cdot e^{-y}, a product.
  • IV: x2−y2x^2 - y^2 is a difference of a function of xx and a function of yy, not a product of one with the other.

2. Which is a correct separation of equation III?

  1. e−ydy=exdxe^{-y}\,dy = e^{x}\,dx
  2. dy=ex−ydxdy = e^{x - y}\,dx
  3. eydy=e−xdxe^{y}\,dy = e^{-x}\,dx
  4. eydy=exdxe^{y}\,dy = e^{x}\,dx
Show the answer

ex−y=exeye^{x - y} = \frac{e^{x}}{e^{y}}, so eydy=exdxe^{y}\,dy = e^{x}\,dx.

  • e−ydy=exdxe^{-y}\,dy = e^{x}\,dx: e−ye^{-y} is on the right side of the equation; moving it to the left divides by it, giving eye^{y}.
  • dy=ex−ydxdy = e^{x - y}\,dx: yy is still on the dxdx side: not separated.
  • eydy=e−xdxe^{y}\,dy = e^{-x}\,dx: The xx factor exe^{x} stays as it is; only the yy factor moves.
  • Correct: eydy=exdxe^{y}\,dy = e^{x}\,dx: dydx=exey\frac{dy}{dx} = \frac{e^{x}}{e^{y}}; multiply both sides by eydxe^{y}\,dx.

3. What is the general solution of equation I?

  1. y=−1x2+Cy = -\frac{1}{x^2} + C
  2. y=−1x2+Cy = -\frac{1}{x^2 + C}
  3. y=1x2+Cy = \frac{1}{x^2 + C}
  4. y=−(x2+C)y = -(x^2 + C)
Show the answer

∫y−2dy=∫2xdx\int y^{-2}\,dy = \int 2x\,dx gives −1y=x2+C-\frac{1}{y} = x^2 + C, so y=−1x2+Cy = -\frac{1}{x^2 + C}.

  • y=−1x2+Cy = -\frac{1}{x^2} + C: The constant was added after solving for yy; it belongs right after integrating.
  • Correct: y=−1x2+Cy = -\frac{1}{x^2 + C}: −1y=x2+C-\frac{1}{y} = x^2 + C, then take reciprocals and change the sign.
  • y=1x2+Cy = \frac{1}{x^2 + C}: ∫y−2dy=−1y\int y^{-2}\,dy = -\frac{1}{y}; the minus sign was lost.
  • y=−(x2+C)y = -(x^2 + C): From −1y=x2+C-\frac{1}{y} = x^2 + C, yy is the reciprocal, not the negative.

4. Which is a correct first step in separating dydx=x2y\frac{dy}{dx} = \frac{x^2}{y}?

  1. dyy=x2dx\frac{dy}{y} = x^2\,dx
  2. ydy=dxx2y\,dy = \frac{dx}{x^2}
  3. dy=x2ydxdy = \frac{x^2}{y}\,dx
  4. ydy=x2dxy\,dy = x^2\,dx
Show the answer

ydy=x2dxy\,dy = x^2\,dx has only yy with dydy and only xx with dxdx.

  • dyy=x2dx\frac{dy}{y} = x^2\,dx: yy is in the denominator on the right; moving it multiplies, giving ydyy\,dy.
  • ydy=dxx2y\,dy = \frac{dx}{x^2}: x2x^2 is in the numerator; it stays there.
  • dy=x2ydxdy = \frac{x^2}{y}\,dx: yy is still on the dxdx side: not separated.
  • Correct: ydy=x2dxy\,dy = x^2\,dx: Multiply both sides by ydxy\,dx.

5. Separate and integrate dydx=ycos⁡x\frac{dy}{dx} = y\cos x.

  1. y=sin⁡x+Cy = \sin x + C
  2. ln⁡|y|=sin⁡x+C\ln|y| = \sin x + C
  3. ln⁡|y|=−sin⁡x+C\ln|y| = -\sin x + C
  4. ln⁡|y|=sin⁡x\ln|y| = \sin x
Show the answer

dyy=cos⁡xdx\frac{dy}{y} = \cos x\,dx, so ln⁡|y|=sin⁡x+C\ln|y| = \sin x + C, and y=Aesin⁡xy = Ae^{\sin x}.

  • y=sin⁡x+Cy = \sin x + C: yy multiplies cos⁡x\cos x; it must be divided across before integrating.
  • Correct: ln⁡|y|=sin⁡x+C\ln|y| = \sin x + C: ∫dyy=∫cos⁡xdx\int \frac{dy}{y} = \int \cos x\,dx.
  • ln⁡|y|=−sin⁡x+C\ln|y| = -\sin x + C: An antiderivative of cos⁡x\cos x is +sin⁡x+\sin x.
  • ln⁡|y|=sin⁡x\ln|y| = \sin x: The constant of integration is missing.

6. A student writes: "dydx=x+y\frac{dy}{dx} = x + y, so dyy=xdx\frac{dy}{y} = x\,dx." What is wrong?

  1. x+yx + y is a sum, so dividing by yy leaves xy+1\frac{x}{y} + 1: the equation is not separable.
  2. Nothing: dividing by yy is allowed when y≠0y \ne 0.
  3. The student should have written ydy=xdxy\,dy = x\,dx.
  4. The student forgot +C+ C.
Show the answer

Separation needs g(x)h(y)g(x)h(y). A sum such as x+yx + y cannot be split that way.

  • Correct: x+yx + y is a sum, so dividing by yy leaves xy+1\frac{x}{y} + 1: the equation is not separable.: Dividing x+yx + y by yy does not leave xx.
  • Nothing: dividing by yy is allowed when y≠0y \ne 0.: x+yy=xy+1\frac{x + y}{y} = \frac{x}{y} + 1, not xx.
  • The student should have written ydy=xdxy\,dy = x\,dx.: That would also be wrong: the right side is not a product.
  • The student forgot +C+ C.: No integration has happened yet; the separation itself is wrong.

Part 9 · Summary

Summary

For a separable equation, put yy with dydy and xx with dxdx, integrate both sides, and add one constant immediately. Keep ln⁡|y|\ln|y|; when you exponentiate, the constant absorbs the sign. The general solution is a family of curves, one for each constant.

Part 10 · Up next

What comes next

Part 11 · Connections

Connections