Loading [MathJax]/jax/output/HTML-CSS/fonts/TeX/fontdata.js
Skip to main content
Library homepage
 

Text Color

Text Size

 

Margin Size

 

Font Type

Enable Dyslexic Font
Mathematics LibreTexts

2.2: Separable Equations

( \newcommand{\kernel}{\mathrm{null}\,}\)

A first order differential equation is separable if it can be written as

h(y)y=g(x),

where the left side is a product of y and a function of y and the right side is a function of x. Rewriting a separable differential equation in this form is called separation of variables. In Section 2.1, we used separation of variables to solve homogeneous linear equations. In this section we’ll apply this method to nonlinear equations.

To see how to solve Equation ???, let’s first assume that y is a solution. Let G(x) and H(y) be antiderivatives of g(x) and h(y); that is,

H(y)=h(y)andG(x)=g(x).

Then, from the chain rule,

ddxH(y(x))=H(y(x))y(x)=h(y)y(x).

Therefore Equation ??? is equivalent to

ddxH(y(x))=ddxG(x).

Integrating both sides of this equation and combining the constants of integration yields

H(y(x))=G(x)+c.

Although we derived this equation on the assumption that y is a solution of Equation ???, we can now view it differently: Any differentiable function y that satisfies Equation ??? for some constant c is a solution of Equation ???. To see this, we differentiate both sides of Equation ???, using the chain rule on the left, to obtain

H(y(x))y(x)=G(x),

which is equivalent to

h(y(x))y(x)=g(x)

because of Equation ???.

In conclusion, to solve Equation ??? it suffices to find functions G=G(x) and H=H(y) that satisfy Equation ???. Then any differentiable function y=y(x) that satisfies Equation ??? is a solution of Equation ???.

Example 2.2.1

Solve the equation

y=x(1+y2).

Solution

Separating variables yields

y1+y2=x.

Integrating yields

tan1y=x22+c

Therefore

y=tan(x22+c).

Example 2.2.2
  1. Solve the equation y=xy.
  2. Solve the initial value problem y=xy,y(1)=1.
  3. Solve the initial value problem y=xy,y(1)=2.
Solution a

Separating variables in Equation ??? yields

yy=x.

Integrating yields

y22=x22+c,or equivalentlyx2+y2=2c.

The last equation shows that c must be positive if y is to be a solution of Equation ??? on an open interval. Therefore we let 2c=a2 (with a>0) and rewrite the last equation as

x2+y2=a2.

This equation has two differentiable solutions for y in terms of x:

y=a2x2,a<x<a,

and

y=a2x2,a<x<a.

The solution curves defined by Equation ??? are semicircles above the x-axis and those defined by Equation ??? are semicircles below the x-axis (Figure 2.2.1 ).

Solution b

The solution of Equation ??? is positive when x=1; hence, it is of the form Equation ???. Substituting x=1 and y=1 into Equation ??? to satisfy the initial condition yields a2=2; hence, the solution of Equation ??? is

y=2x2,2<x<2.

Solution c

The solution of Equation ??? is negative when x=1 and is therefore of the form Equation ???. Substituting x=1 and y=2 into Equation ??? to satisfy the initial condition yields a2=5. Hence, the solution of Equation ??? is

y=5x2,5<x<5.

fig020201.svg
Figure 2.2.1 : (a) y=2x2,  2<x<2;  (b) y=5x2,  5<x<5

Implicit Solutions of Separable Equations

In Examples 2.2.1 and 2.2.2 we were able to solve the equation H(y)=G(x)+c to obtain explicit formulas for solutions of the given separable differential equations. As we’ll see in the next example, this isn’t always possible. In this situation we must broaden our definition of a solution of a separable equation. The next theorem provides the basis for this modification. We omit the proof, which requires a result from advanced calculus called as the implicit function theorem.

Theorem 2.2.1 : Implicit Function Theorem

Suppose g=g(x) is continuous on (a,b) and h=h(y) are continuous on (c,d). Let G be an antiderivative of g on (a,b) and let H be an antiderivative of h on (c,d). Let x0 be an arbitrary point in (a,b), let y0 be a point in (c,d) such that h(y0)0, and define

c=H(y0)G(x0).

Then there’s a function y=y(x) defined on some open interval (a1,b1), where aa1<x0<b1b, such that y(x0)=y0 and

H(y)=G(x)+c

for a1<x<b1. Therefore y is a solution of the initial value problem

h(y)y=g(x),y(x0)=y0.

It’s convenient to say that Equation ??? with c arbitrary is an implicit solution of h(y)y=g(x). Curves defined by Equation ??? are integral curves of h(y)y=g(x). If c satisfies Equation ???, we’ll say that Equation ??? is an implicit solution of the initial value problem Equation ???. However, keep these points in mind:

  • For some choices of c there may not be any differentiable functions y that satisfy Equation ???.
  • The function y in Equation ??? (not Equation ??? itself) is a solution of h(y)y=g(x).
Example 2.2.3
  1. Find implicit solutions of y=2x+15y4+1.
  2. Find an implicit solution of y=2x+15y4+1,y(2)=1.
Solution a

Separating variables yields

(5y4+1)y=2x+1.

Integrating yields the implicit solution

y5+y=x2+x+c.

of Equation ???.

Solution b

Imposing the initial condition y(2)=1 in Equation ??? yields 1+1=4+2+c, so c=4. Therefore

y5+y=x2+x4

is an implicit solution of the initial value problem Equation ???. Although more than one differentiable function y=y(x) satisfies Equation ??? near x=1, it can be shown that there is only one such function that satisfies the initial condition y(1)=2. Figure 2.2.2 shows a direction field and some integral curves for Equation ???.

fig020202.svg
Figure 2.2.2 : A direction field and integral curves for y=2x+15y4+1

Constant Solutions of Separable Equations

An equation of the form

y=g(x)p(y)

is separable, since it can be rewritten as

1p(y)y=g(x).

However, the division by p(y) is not legitimate if p(y)=0 for some values of y. The next two examples show how to deal with this problem.

Example 2.2.4

Find all solutions of

y=2xy2.

Solution

Here we must divide by p(y)=y2 to separate variables. This isn’t legitimate if y is a solution of Equation ??? that equals zero for some value of x. One such solution can be found by inspection: y0. Now suppose y is a solution of Equation ??? that isn’t identically zero. Since y is continuous there must be an interval on which y is never zero. Since division by y2 is legitimate for x in this interval, we can separate variables in Equation ??? to obtain

yy2=2x.

Integrating this yields

1y=x2+c,

which is equivalent to

y=1x2+c.

We’ve now shown that if y is a solution of Equation ??? that is not identically zero, then y must be of the form Equation ???. By substituting Equation ??? into Equation ???, you can verify that Equation ??? is a solution of Equation ???. Thus, solutions of Equation ??? are y0 and the functions of the form Equation ???. Note that the solution y0 isn’t of the form Equation ??? for any value of c.

Figure 2.2.3 shows a direction field and some integral curves for Equation ???

fig020203.svg
Figure 2.2.3 : A direction field and integral curves for y=2xy2
Example 2.2.5

Find all solutions of

y=12x(1y2).

Here we must divide by p(y)=1y2 to separate variables. This isn’t legitimate if y is a solution of Equation ??? that equals ±1 for some value of x. Two such solutions can be found by inspection: y1 and y1. Now suppose y is a solution of Equation ??? such that 1y2 isn’t identically zero. Since 1y2 is continuous there must be an interval on which 1y2 is never zero. Since division by 1y2 is legitimate for x in this interval, we can separate variables in Equation ??? to obtain

2yy21=x.

A partial fraction expansion on the left yields

[1y11y+1]y=x,

and integrating yields

ln|y1y+1|=x22+k;

hence,

|y1y+1|=ekex2/2.

Since y(x)±1 for x on the interval under discussion, the quantity (y1)/(y+1) cannot change sign in this interval. Therefore we can rewrite the last equation as

y1y+1=cex2/2,

where c=±ek, depending upon the sign of (y1)/(y+1) on the interval. Solving for y yields

y=1+cex2/21cex2/2.

We’ve now shown that if y is a solution of Equation ??? that is not identically equal to ±1, then y must be as in Equation ???. By substituting Equation ??? into Equation ??? you can verify that Equation ??? is a solution of Equation ???. Thus, the solutions of Equation ??? are y1, y1 and the functions of the form Equation ???. Note that the constant solution y1 can be obtained from this formula by taking c=0; however, the other constant solution, y1, cannot be obtained in this way.

Figure 2.2.4 shows a direction field and some integrals for Equation ???.

fig020204.svg
Figure 2.2.4 : A direction field and integral curves for y=x(1y2)2

Differences Between Linear and Nonlinear Equations

Theorem 2.1.2 states that if p and f are continuous on (a,b) then every solution of

y+p(x)y=f(x)

on (a,b) can be obtained by choosing a value for the constant c in the general solution, and if x0 is any point in (a,b) and y0 is arbitrary, then the initial value problem

y+p(x)y=f(x),y(x0)=y0

has a solution on (a,b).

The not true for nonlinear equations. First, we saw in Examples 2.2.4 and 2.2.5 that a nonlinear equation may have solutions that cannot be obtained by choosing a specific value of a constant appearing in a one-parameter family of solutions. Second, it is in general impossible to determine the interval of validity of a solution to an initial value problem for a nonlinear equation by simply examining the equation, since the interval of validity may depend on the initial condition. For instance, in Example 2.2.2 we saw that the solution of

dydx=xy,y(x0)=y0

is valid on (a,a), where a=x20+y20.

Example 2.2.6

Solve the initial value problem

y=2xy2,y(0)=y0

and determine the interval of validity of the solution.

Solution

First suppose y00. From Example 2.2.4 , we know that y must be of the form

y=1x2+c.

Imposing the initial condition shows that c=1/y0. Substituting this into Equation ??? and rearranging terms yields the solution

y=y01y0x2.

This is also the solution if y0=0. If y0<0, the denominator isn’t zero for any value of x, so the the solution is valid on (,). If y0>0, the solution is valid only on (1/y0,1/y0).


This page titled 2.2: Separable Equations is shared under a CC BY-NC-SA 3.0 license and was authored, remixed, and/or curated by William F. Trench via source content that was edited to the style and standards of the LibreTexts platform.

Support Center

How can we help?