Tutorials › AP Calculus › Solving Equations with One-Sided Dependence

Separable Equations and Growth · Tutorial 564 of 999

Solving Equations with One-Sided Dependence

Use antiderivatives to solve one-sided differential equations, apply initial conditions, and identify constant solutions.

Intermediate 9 min read

What You'll Learn

  • Solve equations of the form dy/dx = f(x) by finding an antiderivative and applying an initial condition.
  • Recognize when a solution is naturally given implicitly.
  • Separate and integrate equations of the form dy/dx = g(y) on intervals where g(y) is nonzero.
  • Identify constant solutions by checking the zeros of g.
  • Check proposed solutions by differentiating and substituting into the equation.

Two Simple Kinds of Differential Equations

A differential equation may depend on both \(x\) and \(y\), but some equations depend on just one of them. If the derivative depends only on \(x\), finding a solution amounts to finding an antiderivative. If the derivative depends only on \(y\), the equation can be separated and integrated, provided we take care at values where the right-hand side is zero.

These cases are useful for practicing how a general solution is built and how an initial condition selects one member of a family. They also highlight an important issue: dividing by a function of \(y\) can discard constant solutions, so those must be checked separately.

Definition: An equation of the form \(\frac{dy}{dx}=f(x)\) has one-sided dependence on \(x\): its right-hand side depends only on the independent variable. An equation of the form \(\frac{dy}{dx}=g(y)\) has one-sided dependence on \(y\): its right-hand side depends only on the dependent variable.

When the Derivative Depends Only on \(x\)

If \(F'(x)=f(x)\) on an interval, then every function of the form \(y=F(x)+C\), where \(C\) is a constant, satisfies \(\frac{dy}{dx}=f(x)\). Conversely, if \(y\) satisfies this equation, then \(y-F\) has derivative zero, so it is constant on the interval. Thus the full family of solutions is an antiderivative plus a constant.

An initial condition \(y(x_0)=y_0\) determines that constant. In terms of any antiderivative \(F\), the solution is \(y=F(x)-F(x_0)+y_0\). This formula works on any interval where \(f\) is defined and the antiderivative exists.

Worked Example: An Initial-Value Problem with \(x\)-Dependence

Solve \(\frac{dy}{dx}=3x^2-4x+1\) with \(y(0)=2\).

First find an antiderivative of the right-hand side:

$$ y=x^3-2x^2+x+C. $$

Use the initial condition. Substituting \(x=0\) and \(y=2\) gives \(2=0-0+0+C\), so \(C=2\). The particular solution is therefore:

$$ y=x^3-2x^2+x+2. $$

Check it by differentiating: \(\frac{dy}{dx}=3x^2-4x+1\), as required. At \(x=0\), the formula gives \(y=2\), so it also satisfies the initial condition.

When the Derivative Depends Only on \(y\)

For \(\frac{dy}{dx}=g(y)\), the dependent variable appears on the right-hand side. On an interval where \(g(y)\ne 0\), separation gives \(\frac{1}{g(y)}\,dy=dx\). Integrating both sides produces a relation between \(y\) and \(x\). That relation may be implicit; it is a solution description when it determines a differentiable function \(y(x)\) on the interval in question.

Important condition: The step of dividing by \(g(y)\) is valid only where \(g(y)\ne 0\). Any value \(c\) for which \(g(c)=0\) gives a constant solution \(y=c\), which must be checked separately.

Here is why the integration works. Suppose \(g(y)\ne 0\) along a solution and define \(G\) by \(G'(y)=1/g(y)\) on the relevant range of \(y\). The chain rule gives:

$$ \frac{d}{dx}G(y(x)) = G'(y(x))\frac{dy}{dx} = \frac{1}{g(y(x))}g(y(x)) = 1. $$

A function with derivative \(1\) differs from \(x\) by a constant. Therefore \(G(y(x))=x+C\). This establishes the implicit solution relation and explains why the method works. It does not include points where \(g(y)=0\), because \(G'\) as defined here is not available there.

Worked Example: An Autonomous Equation with an Initial Condition

Solve \(\frac{dy}{dx}=y^2-1\) with \(y(0)=0\), and also identify its constant solutions.

First find the constant solutions directly. A constant \(y=c\) has derivative zero, so it solves the equation when \(c^2-1=0\). Factoring gives \((c-1)(c+1)=0\), so \(y=1\) and \(y=-1\) are constant solutions.

For nonconstant solutions with \(y\ne 1\) and \(y\ne -1\), separate variables and use partial fractions:

$$ \frac{dy}{y^2-1}=dx, \qquad \frac{1}{y^2-1} = \frac{1}{2}\left(\frac{1}{y-1}-\frac{1}{y+1}\right). $$

Integrating gives:

$$ \frac{1}{2}\ln\left|\frac{y-1}{y+1}\right|=x+C. $$

Use \(y(0)=0\). Substitution gives \(\frac{1}{2}\ln|{-1}/{1}|=C\), so \(C=0\). The initial value lies between \(-1\) and \(1\); on that range, \(\left|\frac{y-1}{y+1}\right|=\frac{1-y}{1+y}\). Thus:

$$ \frac{1}{2}\ln\left(\frac{1-y}{1+y}\right)=x, \qquad \frac{1-y}{1+y}=e^{2x}. $$

Writing \(q=e^{2x}\), multiply by \(1+y\) and rearrange: \(1-y=q+qy\), so \(1-q=y(1+q)\). Hence:

$$ y=\frac{1-e^{2x}}{1+e^{2x}}. $$

Check the initial condition: at \(x=0\), the numerator is \(1-1=0\) and the denominator is \(1+1=2\), giving \(y(0)=0\). To check the equation, let \(q=e^{2x}\), so \(dq/dx=2q\). Differentiating yields \(\frac{dy}{dx}=-4q/(1+q)^2\). Meanwhile, \(y^2-1=((1-q)^2-(1+q)^2)/(1+q)^2=-4q/(1+q)^2\). The derivative and the right-hand side agree.

Constant Solutions and Division

For \(\frac{dy}{dx}=g(y)\), the constant function \(y=c\) is a solution exactly when \(g(c)=0\). This follows by substituting \(y=c\): its derivative is zero, so the equation requires \(0=g(c)\). There may be no such values, one such value, or several.

For \(\frac{dy}{dx}=f(x)\), a constant function \(y=c\) is a solution on an interval exactly when \(f(x)=0\) throughout that interval. A zero of \(f\) at just one point is not enough; the differential equation must hold at every point of the interval.

Worked Example: A Constant Solution from an Initial Condition

Solve \(\frac{dy}{dx}=0\) with \(y(2)=-3\).

Every antiderivative of zero is a constant, so the general solution is \(y=C\). Applying the initial condition gives \(C=-3\), and the particular solution is \(y=-3\).

Check: differentiating \(y=-3\) gives \(\frac{dy}{dx}=0\), and substituting \(x=2\) gives \(y(2)=-3\). Both the equation and the initial condition hold.

A Common Mistake: Dividing Away a Solution

Consider again \(\frac{dy}{dx}=y^2-1\). A tempting first step is to divide by \(y^2-1\). This produces an equation that is valid only when \(y^2-1\ne0\). If we then claim that the separated equation describes every solution, we have made an error: the constant functions \(y=1\) and \(y=-1\) were excluded by the division.

The correction is to check the zeros of the right-hand side before dividing. Solve \(g(c)=0\) to find the possible constant solutions, then separate and integrate only on intervals where \(g(y)\ne0\). Finally, check any proposed solution in the original differential equation. This procedure respects the condition required for division and prevents constant solutions from being lost.

A Reliable Procedure

1
Identify which variable appears.
If the right-hand side is \(f(x)\), find an antiderivative. If it is \(g(y)\), prepare to separate where \(g(y)\ne0\).
2
Check for constant solutions.
For \(g(y)\), solve \(g(c)=0\). For \(f(x)\), a constant solution requires \(f\) to be zero throughout the interval.
3
Integrate and apply the initial condition.
Include a constant of integration, then substitute the given point to determine it. For \(g(y)\), keep track of the interval where division is valid.
4
Verify the result.
Differentiate the proposed solution and substitute it into the original equation. Also check the initial condition when one is given.

Why These Cases Matter

These equations make the distinction between a general solution and a particular solution concrete. Integration produces a family of curves; an initial condition selects a curve from that family. In the autonomous case, examining zeros of \(g\) also reveals constant solutions before separation is attempted.

The essential checks are brief but important: identify where division is legal, include the integration constant, apply the initial condition, and verify by substitution. An implicit relation is acceptable when it describes a differentiable solution on the stated interval; an explicit formula is not always necessary.

Check Your Understanding

For each question, consider both the equation and any conditions needed for the method.

  1. What is the general solution of \(\frac{dy}{dx}=4x\), and what particular solution satisfies \(y(1)=3\)?
  2. For \(\frac{dy}{dx}=g(y)\), what equation must a constant solution \(y=c\) satisfy?
  3. Why must values with \(g(y)=0\) be checked before dividing by \(g(y)\)?
  4. Is a constant function a solution of \(\frac{dy}{dx}=x-2\) on an interval containing more than one \(x\)-value? Explain.
  5. What calculation verifies that a proposed function satisfies a differential equation and an initial condition?

Test yourself: AP Calculus practice exams

Ready to check what you know? Work an AP-style practice exam, then open the full solutions.

Want all 1,114 practice problems?

This tutorial covers one topic. Calc Pass covers all of AP Calculus AB & BC: full review, every practice question, and step-by-step solutions to each one.

QR code to download the Calc Pass app

Get the Calc Pass App

Scan to download and practice on the go, with instant scoring.

Calc Pass Volume 1: 1,114 Practice Questions book cover

Vol. 1: 1,114 Questions

The complete practice question bank, organized by AB & BC topic.

View on Amazon
Calc Pass Volume 2: Solutions Manual book cover

Vol. 2: Solutions Manual

Fully worked solutions to every question in Volume 1.

View on Amazon