AP® CALCULUS AB & BC · UNIT 7

Finding General Solutions Using Separation of Variables

Separate the variables, integrate both sides and describe a family of solutions. Keep constant solutions, signs and valid intervals in every answer.

Topic 7.6 study notes8 worked examples · 8 practice questionsUpdated 12 November 2026
Calculus notebook with limit and integral symbols, a compass and pencil on an olive and cream study desk

1. The separation method and AP scope

Separation of variables finds exact solutions of certain first-order differential equations by rearranging the equation into a function of the dependent variable on one side and a function of the independent variable on the other, then integrating.

AP Calculus AB and BC · Topic 7.6. Learning objective FUN-7.D, essential knowledge FUN-7.D.1–2 and suggested skill 1.E focus on finding general solutions by separation and antidifferentiation. Initial conditions appear here as preserved review examples and a bridge to Topic 7.7. The original partial-fractions example is clearly identified as a BC integration extension.
dydx=f(x)g(y)

On an interval where g(y)≠0, separate and integrate:

1g(y)dy=f(x)dx
∫1g(y)dy=∫f(x)dx

Before dividing, test any constants y=c for which g(c)=0. A constant is a solution only where it is allowed by the original equation and makes the original right side zero throughout the interval.

A general solution usually describes a family with an arbitrary constant. State the valid intervals and include any extra constant solutions lost during division. An implicit relation may need a branch choice before it describes a single solution function.

2. Recognize a separable equation

Check the algebra before classifying the equation
EquationFactorization or reasonDecision
dydx=xyx·ySeparable
dydx=kyk·y, with constant kSeparable
dydx=xyx·1y; require y≠0Separable
dydx=y2−11·(y2−1)Separable
dydx=xy+xx(y+1)Separable after factoring
dydx=ex−yexe−ySeparable after rewriting
dydx=x+yThe two-variable sum does not factor into one-variable factors on an open rectangle.Not separable in the given variables

A sum is not automatically nonseparable: factoring may reveal a product. In particular, xy+x=x(y+1) is separable. The equation y′=x+y requires another method in these variables.

3. Separate, integrate and preserve the solutions

A complete separation workflow
StageCheck
FactorWrite the right side as f(x)g(y), simplifying only while preserving the original restrictions.
Check constantsTest the zeros of g in the original equation before dividing by it.
SeparateUse 1g(y)dy=f(x)dx on branches where the divisor is nonzero.
IntegrateAntidifferentiate each side with respect to its own variable. Retain absolute values in logarithms.
Combine constantsTwo antiderivative constants reduce to one arbitrary difference C. One written constant is sufficient.
Describe the familySolve for y when practical; choose a valid branch, state its interval and restore excluded constant solutions.
VerifyDifferentiate and substitute into the original differential equation. If an initial condition is supplied, check it too.

Why one integration constant is enough

G(y)+C1=F(x)+C2
G(y)=F(x)+C
C=C2−C1

Writing constants on both sides is valid. Combining them gives a cleaner equivalent relation. Do not treat their initial appearance on both sides as a mathematical error.

Differentiate to justify the rearrangement

If G′(y)=1g(y), differentiating G(y(x))=F(x)+C uses the chain rule and recovers y′g(y)=f(x). This explains the separated integral notation on a nonzero branch; differentials are not independent ordinary fractions that can be rearranged without checking the equation.

4. Eight colorful worked examples

Example 1 · Exponential growth and decay families

Solve dydx=ky, where k is a real constant.

1 · Check the constant solution first

The function y=0 satisfies the original equation. For a nonzero branch, divide by the dependent variable.

1ydy=kdx

2 · Integrate and keep the absolute value

∫1ydy=∫kdx
ln|y|=kx+C

3 · Rename the constant with the right range

|y|=eCekx
y=Aekx

For the nonzero branches, A=±eC, so A≠0. Adding the previously checked zero solution allows any real A. The family is defined on all real inputs.

When k=0, this becomes the family of all constant functions, as required.

Example 2 · Preserved initial-condition example

Solve dydx=2xy, with y(0)=3. This illustrates how the general family leads into Topic 7.7.

1 · Separate on a nonzero branch

The supplied nonzero initial value selects a nonzero member of the family.

1ydy=2xdx

2 · Integrate and express the general family

ln|y|=x2+C
y=Aex2

The family also includes A=0, after checking the zero solution separately.

3 · Use and verify the initial condition

3=Ae0=A
y=3ex2

Differentiation gives y′=6xex2=2xy. The initial value is 3, and the solution is defined for every real input.

Example 3 · An implicit relation with two branch choices

Solve dydx=xy.

1 · Keep the original denominator restriction

The equation requires y≠0. Multiplying by the dependent variable gives

ydy=xdx

2 · Integrate and rename the additive constant

y22=x22+C
y2=x2+K

Here K=2C is an arbitrary real constant.

3 · Select a nonzero branch on an interval

y=x2+K
y=−x2+K

Require x2+K>0, and choose one sign on a connected interval. The strict inequality excludes zero heights, even if the implicit relation contains such points.

Implicit differentiation gives 2yy′=2x, hence the original equation where y≠0. The constant zero function is not a solution.

Example 4 · Preserved partial-fractions example · BC extension

Solve dydx=y2−1x2. The partial-fractions integration technique is a BC extension; it is not a prerequisite for the AB core examples.

1 · Preserve the domain and equilibrium members

The input must satisfy x≠0. The constant functions y=1 and y=−1 are both solutions on either side of zero. For nonconstant branches, separate with y≠±1.

dyy2−1=dxx2

2 · Decompose the dependent-variable factor

1y2−1=12(y−1)−12(y+1)

The logarithmic terms combine to an implicit relation after integrating the other side as a negative reciprocal.

3 · State the nonconstant relation and the missing constants

12ln|y−1y+1|=−1x+C

This relation applies where x≠0 and y≠±1, on a chosen solution interval. Include y=1 and y=−1 separately. These equilibria were lost when dividing by the quadratic factor.

Example 5 · Factor a sum before deciding

Solve dydx=xy+x.

1 · Find the hidden product and constant solution

xy+x=x(y+1)

This equation is separable. The constant y=−1 makes the original rate zero.

2 · Separate and integrate nonconstant branches

dyy+1=xdx
ln|y+1|=x22+C

3 · Give the complete family

y=Aex22−1

Allow any real A, including A=0 for the checked equilibrium. Every member is defined on all real inputs.

Example 6 · A rate depending only on the input

Solve dydx=3x2−2.

1 · Treat the missing dependent-variable factor as one

dy=(3x2−2)dx

2 · Antidifferentiate

y=x3−2x+C

Every real value of C gives a solution on all real inputs. Differentiation recovers the given rate.

Example 7 · An inverse-trigonometric antiderivative

Solve dydx=1+y2. Use radians.

1 · Separate without losing a real constant solution

The factor 1+y2 is positive for every real height, so there are no real equilibrium solutions to restore.

dy1+y2=dx

2 · Integrate, then choose a branch interval

arctany=x+C
y=tan(x+C)

For a fixed real C, a representative maximal interval is

−π2−C<x<π2−C

Translated tangent intervals give the other branches. Do not include a tangent pole or join across one. Differentiation gives y′=sec2(x+C)=1+y2 on each branch.

Example 8 · Restore a solution lost by division

Solve dydx=y2.

1 · Record the zero solution before dividing

The constant y=0 solves the equation. For a nonzero branch,

y−2dy=dx

2 · Integrate and solve

−1y=x+C
y=−1x+C

3 · State the interval and complete the answer

Choose an interval contained in x<−C or x>−C. The denominator cannot vanish. Together with y=0, these give all solution branches of this equation.

The zero function cannot be obtained by any finite value of C in the reciprocal family.

5. Six verified views of solution families

These exact solution curves are generated from verified formulas. Colors are supplemented by solid, dashed and dash-dot styles. Ordinary function plots use independent axis scales, so their visual angles are not measurements of slope. Abstract coordinates have no specified physical units.

A family includes its zero member

image/svg+xml Matplotlib v3.11.2, https://matplotlib.org/ −2 −1 0 1 2 x −4 −2 0 2 4 y
For y′=y, the blue solid curve is y=ex, the orange dashed curve is y=−ex, and the green dash-dot line is y=0. All three solve the same equation on the real line.

Factoring reveals a shifted family

image/svg+xml Matplotlib v3.11.2, https://matplotlib.org/ −2 −1 0 1 2 x −5 −3 −1 1 3 y
For y′=x(y+1), the plotted members are y=ex22−1, y=−ex22−1, and the equilibrium y=−1. The constant member must be retained.

An implicit relation needs a branch

image/svg+xml Matplotlib v3.11.2, https://matplotlib.org/ −3 −1 0 1 3 x −3 −1 0 1 3 y
Blue solid curves use y2=x2+1. Orange dashed curves use y2=x2−1; their open markers at (−1,0) and (1,0) exclude points where the original equation y′=xy is undefined. Each upper or lower branch is a separate solution function on its stated interval.

Restore zero and split at both poles

image/svg+xml Matplotlib v3.11.2, https://matplotlib.org/ −3 −1 0 1 3 x −4 −2 0 2 4 y
For y′=xy2, the blue curve is y=−2x2−1, with a filled point at (0,2). The dashed vertical guides at x=−1 and x=1 are asymptotes, not solution curves. The green dash-dot line is the extra solution y=0.

A simplified formula retains its domain

image/svg+xml Matplotlib v3.11.2, https://matplotlib.org/ 0.0 0.5 1.0 1.5 2.0 x 0 2 4 6 8 y
The original equation y′=yx excludes x=0. The solution selected by y(1)=4 is y=4x on (0,∞). The open origin is excluded; the filled point (1,4) is the initial condition.

The logarithm argument must stay positive

image/svg+xml Matplotlib v3.11.2, https://matplotlib.org/ −3 −2 −1 0 1 2 x −4 −2 0 2 y
For y′=ex−y, the blue solid, orange dashed and green dash-dot curves use y=ln(ex+C) with C=1, C=0 and C=−1, respectively. The last member exists only for x>0, has a vertical asymptote at zero, and passes through the filled point (ln2,0).

Open markers represent excluded finite boundary points. Filled dots identify stated points on selected members. Curves continuing to the edges of the plotted window have been clipped for display; those edges are not additional domain boundaries. No path is drawn across an excluded input or pole.

6. Common forms, constants and domains

Frequently encountered separated families
TypeEquationFamily or relationRestriction
Exponentialy′=kyy=AekxAny real A; all real inputs.
Producty′=xyy=Aex22Any real A, including zero.
Quotienty′=xyy2=x2+CChoose a fixed sign with x2+C>0; no zero solution.
Input onlyy′=f(x)y=F(x)+CUse an antiderivative with F′=f on the interval.
Height onlyy′=g(y)∫1g(y)dy=x+CNonzero-factor branches; also check zeros of g.

General versus particular solutions

A general family contains an arbitrary constant, such as y=Ae2x. The initial condition y(0)=5 selects the particular member y=5e2x. A single formula may omit exceptional equilibrium solutions, so always check what was divided out.

Logarithms, signs and renamed constants

∫1ydy=ln|y|+C

The absolute value permits both positive and negative nonzero branches. From ln|y|=F(x)+C, exponentiation gives |y|=eCeF(x). The new coefficient A=±eC can be any nonzero real number; zero must be justified separately.

Other antiderivatives and course boundaries

A positive constant a gives the familiar inverse-trigonometric form

∫dyy2+a2=1aarctan(ya)+C

For y2−a2, factoring leads to partial fractions, as in the preserved BC extension. A substitution may also be needed on either side. Keep the core AB method separate from integration techniques that are BC extensions.

Domain and branch checks

Keep original denominator exclusions before canceling factors. Logarithms require positive arguments; square-root solution branches may require a strict positive radicand when zero would make the original equation undefined. A solution function is defined on a connected interval where it is differentiable and satisfies the equation at every point.

7. Eight practice questions with complete solutions

1. Select an exponential member

Solve dydx=3y, y(0)=2.

Show complete solution

1 · Separate and integrate

ln|y|=3x+C
y=Ae3x

2 · Apply the initial value and verify

A=2
y=2e3x

The derivative is 6e3x=3y, and the initial value is 2. The solution is defined for all real inputs.

2. Do not lose the zero solution

Solve dydx=xy2.

Show complete solution

1 · Separate a nonzero branch

Record y=0 first. On a nonzero branch,

y−2dy=xdx
−1y=x22+C

2 · Write equivalent families with renamed constants

y=−1x22+C
y=−2x2+K

Here K=2C. Choose a connected interval where the denominator is nonzero, and include the separate constant solution y=0.

3. Keep an excluded input after simplifying

Solve dydx=yx, y(1)=4.

Show complete solution

1 · Preserve the input restriction and integrate

The original equation requires x≠0. For nonzero branches,

dyy=dxx
ln|y|=ln|x|+C

On a connected interval with a fixed sign of the input, the family can be written y=Ax. It also includes the checked zero solution when A=0.

2 · Select the member and its interval

y=4x
0<x<∞

The initial point (1,4) selects the positive-input interval. The simplified line does not allow the original equation to be evaluated at zero.

4. Separate an exponential difference

Solve dydx=ex−y.

Show complete solution

1 · Rewrite, separate and integrate

ex−y=exe−y
eydy=exdx
ey=ex+C

2 · Enforce the logarithm domain

y=ln(ex+C)

Require ex+C>0. If C≥0, the domain is all real inputs. If C<0, the maximal domain is x>ln(−C). The original rate is always positive, so there are no real constant solutions.

5. Factor a sum and retain the equilibrium

Find the general solution of y′=2x(y−2).

Show complete solution

1 · Record the constant and separate

The equilibrium is y=2. For other branches,

dyy−2=2xdx
ln|y−2|=x2+C

2 · Include every coefficient

y=2+Aex2

Every real A is allowed, including zero for the equilibrium. All members are defined on the real line.

6. Recognize a nonseparable equation

Can y′=x+y be separated into one function of the input times one function of the height, on an open rectangle?

Show complete solution

1 · Test the proposed product form

The two-variable sum does not factor into separate one-variable functions. For example, comparing heights 1 and 2 would require the following ratio to be independent of the input wherever its denominator is nonzero.

x+1x+2

2 · Justify the classification

ddx(x+1x+2)=1(x+2)2

This derivative is positive where defined, so that ratio is not constant. The same comparison can be made with two distinct heights in any open rectangle. The equation is not separable in the given variables; another differential-equation method is needed.

7. Choose the right square-root branch

Solve y′=xy with y(0)=−2.

Show complete solution

1 · Use the implicit family and initial value

y2=x2+K
4=K

2 · Choose the negative branch

y=−x2+4

This branch stays negative and is defined for all real inputs, so the original denominator is never zero. Its derivative is −xx2+4, which equals the original right side.

8. Integrate an input-only rate

Find the general solution of y′=2xcos(x2). Use radians.

Show complete solution

1 · Use substitution on the input side

u=x2
du=2xdx
y=∫cosudu

2 · Return to the original variable

y=sin(x2)+C

Differentiating with the chain rule gives y′=2xcos(x2). Every real C gives a solution on all real inputs.

8. Common mistakes and clear written work

  • Classifying a sum too quickly. Factor first: xy+x is separable.
  • Dividing out a valid solution. Check original constant solutions before dividing by a height-dependent factor.
  • Dropping absolute values. The reciprocal antiderivative is ln|y| on nonzero branches.
  • Changing the allowed range of a constant. An exponential coefficient from eC is positive until signs and separately checked zero members are included.
  • Calling two constants invalid. Constants on both sides are legitimate; combine their difference into one arbitrary constant.
  • Forgetting a sign or power during integration. Differentiate antiderivatives such as −1y to check them.
  • Mixing the integration variables. Put each differential beside the expression in its own variable.
  • Treating both square-root signs as one function. Select one branch on a valid interval.
  • Ignoring original exclusions. A simplified formula does not define the original equation at a forbidden input or height.
  • Leaving an initial condition unused when one is supplied. Substitute it after finding the family, then verify the selected member.

Make the written solution checkable

Show separation, antiderivatives, an arbitrary constant, any required algebra and the final family with its restrictions. If a problem asks for an explicit solution, solve for the dependent variable and select the valid branch. If an initial condition is given, find the particular member as requested. Check the original equation by differentiation. Points on a particular AP question depend on its own scoring guidelines.

9. Frequently asked questions

Is this topic shared by AP Calculus AB and BC?

Yes. Topic 7.6 covers general solutions by separation and antidifferentiation in both courses. The preserved example using linear partial fractions is labeled as a BC integration extension.

Can a differential equation containing a sum be separable?

Yes. Factoring may reveal a product: xy+x=x(y+1). A different sum, such as x+y, is not separable in the given variables.

Why must I check constant solutions before dividing?

Dividing by a factor that can be zero excludes those heights during the calculation. Test each candidate in the original equation; a valid equilibrium may need to be restored separately.

Is it wrong to put constants on both sides?

No. The two constants combine into one arbitrary difference. Writing one constant after integration is simply more economical.

Why is there an absolute value in the logarithm?

The derivative of ln|y| is 1y on either nonzero sign interval. Using only lny would discard negative branches unless positivity had already been established.

Can I always leave an implicit answer?

Follow the instruction. An implicit relation can describe a family, but an explicit solution request requires solving for the dependent variable where possible and choosing a valid branch. Always keep the original restrictions.

How do I verify the general solution?

Differentiate, substitute into the original equation, and check the allowed interval and any excluded constants. If an initial condition is supplied, verify that point as well.

10. Continue through Unit 7

General solutions connect antiderivatives with differential equations. Next, use initial conditions to select a particular solution and its valid interval.

AB students can come directly from Topic 7.4: reasoning using slope fields. Euler’s method is a BC-only numerical topic; separation gives exact families for equations that can be separated.