Skip to main content
Logo image

Coordinated Calculus

Section 2.7 Derivatives of Functions Given Implicitly

In all of our studies with derivatives so far, we have worked with functions whose formula is given explicitly in terms of x. But there are many interesting curves whose equations involving x and y are impossible to solve for y in terms of x.
Figure 2.82. At left, the circle given by x2+y2=16. In the middle, the portion of the circle x2+y2=16 that has been highlighted in the box at left. And at right, the lemniscate given by x3y3=6xy.
Perhaps the simplest and most natural of all such curves are circles. Because of the circle’s symmetry, for each x-value that is strictly between the endpoints of the horizontal diameter, there are two corresponding y-values. For instance, on the left side of Figure 2.82 above, we have labeled A=(3,7) and B=(3,7). These points demonstrate that the circle fails the vertical line test and indicate that it is impossible to represent the circle through a single function of the form y=f(x). However, portions of the circle, such as the highlighted arc that is magnified in the center of Figure 2.82, can be represented explicitly as a function of x. Moreover, it is evident that the circle is locally linear, so we ought to be able to find a tangent line to the curve at every point. Thus, it makes sense to wonder if we can compute dydx at any point on the circle, even though we cannot write y explicitly as a function of x.
We say that the equation x2+y2=16 defines y implicitly as a function of x. The graph of the equation can be broken into pieces where each piece can be defined by an explicit function of x. For the circle, we could choose to take the top half as one function of x, namely y=16x2, and the bottom half as y=16x2. The equation for the circle defines two implicit functions of x.
The righthand curve in Figure 2.82 above is called a lemniscate and is just one of many fascinating possibilities for implicitly given curves.
The question we want to address in this section is “how can we find an equation for dydx without an explicit formula for y in terms of x?” The following example reminds us of some ways we can compute derivatives of functions in settings where the function’s formula is not known.

Example 2.83.

Let f be a differentiable function of x whose formula is not known, and recall that ddx[f(x)] and f(x) are interchangeable notations. Compute the following derivatives; note that each function you must differentiate is a combination of: explicit functions of x, the unknown function f, and an arbitrary constant c.
  1. ddx[x2+f(x)]
  2. ddx[x2f(x)]
  3. ddx[c+x+f(x)2]
  4. ddx[f(x2)]
  5. ddx[xf(x)+f(cx)+cf(x)]
Hint.
  1. Use the sum rule.
  2. Use the product rule.
  3. Remember that c is a constant. You have a choice of which rule to use to differentiate f(x)2.
  4. f(x2) is a composite function.
  5. Use the structure of each term in the sum to determine which rules are appropriate.
Answer.
  1. 2x+f(x).
  2. 2xf(x)+x2f(x).
  3. 1+2f(x)f(x).
  4. 2xf(x2).
  5. f(x)+xf(x)+cf(cx)+cf(x).
Solution.
  1. Applying the sum rule, we see that
    ddx[x2+f(x)]=ddx[x2]+ddx[f(x)]=2x+f(x).
  2. Applying the product rule, we find
    ddx[x2f(x)]=ddx[x2]f(x)+x2ddx[f(x)]=2xf(x)+x2f(x).
  3. Applying the sum rule yields
    ddx[c+x+f(x)2]=ddx[c]+ddx[x]+ddx[f(x)2]=1+ddx[f(x)2].
    Using the chain rule
     31 
    Note that we could instead use the product rule.
    to differentiate the final term, we end up with
    ddx[c+x+f(x)2]=1+2f(x)ddx[f(x)]=1+2f(x)f(x).
  4. We use the chain rule and calculate
    ddx[f(x2)]=f(x2)ddx[x2]=2xf(x2).
  5. We start with the sum rule:
    ddx[xf(x)+f(cx)+cf(x)]=ddx[xf(x)]+ddx[f(cx)]+ddx[cf(x)].
    We now apply the product rule to the first term, the chain rule to the middle term, and the constant multiple rule to the final term. This gives us
    ddx[xf(x)+f(cx)+cf(x)]=([f(x)+xf(x)]+[cf(cx)]+c[f(x)]=(f(x)+xf(x)+cf(cx)+cf(x).

Subsection 2.7.1 Implicit Differentiation

Example 2.84.

We begin our exploration of implicit differentiation with the example of the circle described by x2+y2=16. How can we find a formula for dydx?
By viewing y as an implicit function of x, we think of y as some function whose formula f(x) is unknown, but which we can differentiate. Just as y represents an unknown formula, so too its derivative with respect to x, dydx, will be (at least temporarily) unknown.
So we view y as an unknown differentiable function of x and differentiate both sides of the equation with respect to x.
ddx[x2+y2]=ddx[16].
On the right, the derivative of the constant 16 is 0, and on the left we can apply the sum rule, so it follows that
ddx[x2]+ddx[y2]=0.
Note carefully the different roles being played by x and y. Because x is the independent variable, ddx[x2]=2x. But y is the dependent variable and y is an implicit function of x. Recall Example 2.83, where we computed ddx[f(x)2]. Computing ddx[y2] is the same and requires the chain rule, by which we find that ddx[y2]=2y1dydx. We now have that
2x+2ydydx=0.
We solve this equation for dydx by subtracting 2x from both sides and dividing by 2y.
dydx=2x2y=xy.
There are several important things to observe about the result that dydx=xy. First, this expression for the derivative involves both x and y. This makes sense because there are two corresponding points on the circle for each value of x between 4 and 4, and the slope of the tangent line is different at each of these points.
Second, this formula is entirely consistent with our understanding of circles. The slope of the radius from the origin to the point (a,b) is mr=ba. The tangent line to the circle at (a,b) is perpendicular to the radius, and thus has slope mt=ab, as shown on the right in Figure 2.85. In particular, the slope of the tangent line is zero at (0,4) and (0,4), and is undefined at (4,0) and (4,0). All of these values are consistent with the formula dydx=xy.
Figure 2.85. The circle given by x2+y2=16 with point (a,b) on the circle and the tangent line at that point, with labeled slopes mr and mt of the radial line and tangent line, respectively.

Example 2.86.

For the curve given implicitly by x3+y22xy=2, shown below in Figure 2.87, find the slope of the tangent line at (1,1).
Figure 2.87. The curve x3+y22xy=2.
We begin by differentiating the curve’s equation implicitly. Taking the derivative of each side with respect to x yields
ddx[x3+y22xy]=ddx[2].
By the sum rule and the fact that the derivative of a constant is zero, we have
ddx[x3]+ddx[y2]2ddx[xy]=0.
For the three derivatives we now must execute, the first uses the simple power rule, the second requires the chain rule (since y is an implicit function of x), and the third necessitates the product rule (again, since y is a function of x). Applying these rules, we now find that
3x2+2ydydx2[y+xdydx]=0.
We want to solve this equation for dydx. To do so, we first collect all of the terms involving dydx on one side of the equation.
2ydydx2xdydx=2y3x2.
Then we factor the left side to isolate dydx.
dydx(2y2x)=2y3x2.
Finally, we divide both sides by (2y2x) and conclude that
dydx=2y3x22y2x.
Note that the expression for dydx depends on both x and y. To find the slope of the tangent line at (1,1), we substitute the coordinates into the formula for dydx, using the notation
dydx|(1,1)=2(1)3(1)22(1)2(1)=14.
This value matches our visual estimate of the slope of the tangent line shown in Figure 2.87.
Example 2.86 shows that it is possible when differentiating implicitly to have multiple terms involving dydx. We use addition and subtraction to collect all terms involving dydx on one side of the equation, then factor to get a single term of dydx. Finally, we divide to solve for dydx.
We use the notation
dydx|(a,b)
to denote the evaluation of dydx at the point (a,b). This is analogous to writing f(a) when f depends on a single variable.

Warning 2.88.

There is a big difference between writing ddx and dydx. For example,
ddx[x2+y2]
gives an instruction to take the derivative with respect to x of the quantity x2+y2, presumably where y is a function of x. On the other hand,
dydx(x2+y2)
means the product of the derivative of y with respect to x with the quantity x2+y2. Understanding this notational subtlety is absolutely necessary.

Example 2.89.

Consider the curve defined by the equation x=y55y3+4y, whose graph is pictured below in Figure 2.90.
  1. Explain why it is not possible to express y as an explicit function of x.
  2. Use implicit differentiation to find a formula for dydx.
  3. Use your result from part (b) to find an equation of the line tangent to the graph of x=y55y3+4y at the point (0,1).
  4. Use a graphing utility and your result from part (b) to estimate all of the points at which the graph of x=y55y3+4y has a vertical tangent line.
Figure 2.90. The curve x=y55y3+4y.
Hint.
  1. Does the graph pass the vertical line test?
  2. Note, for instance, that ddx[y5]=5y4dydx.
  3. Remember the meaning of dydx|(0,1).
  4. What is the slope of a vertical line?
Answer.
  1. The graph of the curve fails the vertical line test.
  2. dydx=15y415y2+4.
  3. y=16x+1.
  4. (1.418697,0.543912), (1.418697,0.543912), (3.63143,1.64443), and (3.63143,1.64443).
Solution.
  1. Because the graph of the curve fails the vertical line test, y cannot be a function of x. This also confirms our intuition that there is not an algebraic means by which we can rearrange the equation x=y55y3+4y to write y in terms of x.
  2. We differentiate implicitly, taking the derivative of each side with respect to x:
    ddx[x]=ddx[y55y3+4y].
    We then evaluate the elementary derivative on the left and use the sum rule on the right to find that
    1=ddx[y5]ddx[5y3]+ddx[4y].
    Viewing y as a function of x and using the chain and constant multiple rules, we now have
    1=5y4dydx15y2dydx+4dydx.
    Factoring yields
    1=dydx(5y415y2+4),
    and therefore
    dydx=15y415y2+4.
  3. To find an equation of the line tangent to the graph of x=y55y3+4y at the point (0,1), we only need the slope of the tangent line. Hence we compute
    dydx|(0,1)=15(1)415(1)2+4=16.
    Therefore, the equation of the tangent line is
    y1=16(x0),
    or y=16x+1.
  4. Since a line is vertical whenever its slope is undefined, we seek all points (x,y) that make dydx undefined. This will occur precisely when the denominator, 5y415y2+4, is zero. Using a graphing utility or computer algebra system to solve the equation 5y415y2+4=0, we find that this happens at the four approximate y-values y±0.543912,±1.64443. For each such value, we use the original equation x=y55y3+4y to find the x-value of the point. Doing so, we have established that there are four points at which the tangent line is vertical, and they are approximately (1.418697,0.543912), (1.418697,0.543912), (3.63143,1.64443), and (3.63143,1.64443).
It is natural to ask where the tangent line to a curve is vertical or horizontal. The slope of a horizontal tangent line must be zero, while the slope of a vertical tangent line is undefined. Often the formula for dydx is expressed as a quotient of functions of x and y, say
dydx=p(x,y)q(x,y).
The tangent line is horizontal precisely when the numerator is zero and the denominator is nonzero, making the slope of the tangent line zero. If we can solve the equation p(x,y)=0 for either x and y in terms of the other, we can substitute that expression into the original equation for the curve. This gives an equation in a single variable, and if we can solve that equation we can find the point(s) on the curve where p(x,y)=0. At those points, the tangent line is horizontal.
Similarly, the tangent line is vertical whenever q(x,y)=0 and p(x,y)0, making the slope undefined.

Example 2.91.

Consider the curve defined by the equation y(y21)(y2)=x(x1)(x2), whose graph is pictured below in Figure 2.92. Through implicit differentiation, it can be shown that
dydx=(x1)(x2)+x(x2)+x(x1)(y21)(y2)+2y2(y2)+y(y21).
Use this fact to answer each of the following questions.
  1. Determine the exact x-coordinates of all points (x,y) at which the tangent line to the curve is horizontal. Then use the graph to determine how many points of horizontal tangency correspond to each x-coordinate you find.
  2. Determine the exact y-coordinates of all points (x,y) at which the tangent line to the curve is vertical. Then use the graph to determine how many points of horizontal tangency correspond to each y-coordinate you find.
  3. Find the equation of the tangent line to the curve at one of the points where x=1.
Figure 2.92. y(y21)(y2)=x(x1)(x2).
Hint.
  1. Note that the numerator of dydx is a quadratic function of x, so you can use the quadratic formula to find its roots.
  2. The denominator of dydx can also be written as 2(2y1)(y2y1).
  3. When x=1, then y must satisfy the equation y(y21)(y2)=0.
Answer.
  1. The tangent line is horizontal when x=3±33; each of these two x-values corresponds to four points of horizontal tangency on the curve.
  2. The tangent line is vertical when y=12,1±52. Each of these y-values corresponds to a single point of vertical tangency on the curve.
  3. The four possibilities are y1=12(x1), y=12(x1), y+1=16(x1), or y2=16(x1).
Solution.
  1. To find where the tangent line to the curve is horizontal, we set dydx=0, which requires that the numerator be zero. In other words, we need to solve
    (x1)(x2)+x(x2)+x(x1)=0.
    Expanding and combining like terms, we find that 3x26x+2=0, which occurs where
    x=6±(6)24(3)(2)2(3)=3±33.
    Since 3+331.57735 and 3330.42265, we see from the graph in Figure 2.92 that at each such x-value, there are four corresponding y-values
     32 
    For instance, when x=333, then y must satisfy the equation y(y21)(y2)=x(x1)(x2)|x=333=239. Because this is a quartic (degree 4) equation in y, we can use computational technology to help us find the solutions. Doing so, we find four approximate values for y: y1.058,0.229,0.771,2.058. Thus our estimates for four points at which the tangent line is horizontal are: (333,1.058), (333,0.229), (333,0.771), and (333,2.058). Similar work can be done to find the four points at which the tangent line is horizontal when x=3+33.
    for which the tangent line will be horizontal.
  2. The tangent line to the curve is vertical wherever dydx is undefined, which occurs precisely where
    (y21)(y2)+2y2(y2)+y(y21)=0.
    Expanding and combining like terms, we see that we need to solve the cubic equation 4y36y22y+2=0. From the graph, it appears that y=12 is a point at which the tangent line is vertical, and we verify this by plugging it into our cubic equation. The equation then factors as 2(2y1)(y2y1)=0, with the quadratic term having roots y=1±52. Visual inspection of the curve at y=12, y1.236, and y0.618 reveals that each of these y-values occurs at exactly one point of vertical tangency.
     33 
    We may wish to find the x-coordinate that corresponds to each such y-value. For instance, when y=12, x must satisfy 12(141)(122)=x(x1)(x2), or in other words, x33x2+2x=916. We can use technology to verify that there is only one such x, and x2.210. Similar work can be done to find the x-values that correspond to y=1±52.
  3. There are four points on the curve where x=1, which correspond to the y-values that satisfy y(y21)(y2)=0: (1,0), (1,1), (1,1), (1,2). We choose the point (1,1) and evaluate dydx at this point. Doing so,
    dydx|(1,1)=(11)(12)+1(12)+1(11)(121)(12)+212(12)+1(121)=12=12.
    Thus, the equation of the tangent line to the curve at (1,1) is
    y1=12(x1).
    Similarly,
    • the equation of the tangent line to the curve at (1,0) is
      y=12(x1);
    • the equation of the tangent line to the curve at (1,0) is
      y+1=16(x1);
    • the equation of the tangent line to the curve at (1,0) is
      y2=16(x1).

Example 2.93.

For each of the following curves, use implicit differentiation to find dydx and determine the equation of the tangent line at the given point.
  1. x3y3=6xy,  (3,3)
  2. sin(y)+y=x3+x,  (0,0)
  3. 3xexy=y2,  (0.619,1)
Hint.
  1. Note that ddx[6xy] requires the product rule.
  2. With y being a function of x, ddx[sin(y)] requires the chain rule.
  3. To calculate ddx[xexy], first use the product rule and temporarily defer computing ddx[exy].
Answer.
  1. dydx=3x26y3y2+6x, and the tangent line has equation y3=1(x+3).
  2. dydx=3x2+1cos(y)+1, and the tangent line has equation y=12x.
  3. dydx=3exy3xyexy2y+3x2exy, and the tangent line is y1=0.235(x0.619).
Solution.
  1. Differentiating with respect to x,
    ddx[x3y3]=ddx[6xy],
    so that by the chain and product rules we have
    3x23y2dydx=6y+6xdydx.
    Rearranging to get all terms with dydx on the same side, it follows that
    3x26y=(3y2dydx+6xdydx=((3y2+6x)dydx.
    Thus we have established that
    dydx=3x26y3y2+6x.
    Evaluating at the point (3,3), we have dydx|(3,3)=3(3)26(3)3(3)2+6(3)=1. Thus the tangent line has equation y3=1(x+3), or y=x+6.
  2. After differentiating with respect to x, we have
    cos(y)dydx+dydx=3x2+1.
    Taking the usual steps to solve for dydx, we find that
    dydx=3x2+1cos(y)+1.
    Evaluating the slope of the tangent line at (0,0), we have dydx|(0,0)=12, and thus the tangent line at (0,0) has equation y=12x.
  3. Differentiating both sides with respect to x yields
    ddx[3xexy]=ddx[y2].
    On the left side, we need to start with the product rule; the right side requires the chain rule because y is a function of x. Applying these rules gives us
    3exy+3xddx[exy]=2ydydx.
    To continue differentiating the left side, we need the chain rule followed by the product rule:
    3exy+3xddx[exy]=(3exy+3x(exyddx[xy])=(3exy+3xexy(yxdydx)=(3exy3xyexy3x2exydydx.
    We now have the equation
    3exy3xyexy3x2exydydx=2ydydx.
    Since we need to solve for dydx, we combine like terms before factoring and dividing to end up with
    3exy3xyexy=(2ydydx+3x2exydydx=((2y+3x2exy)dydx(3exy3xyexy2y+3x2exy=(dydx.
    Evaluating at the point (0.619,1), we find the slope of the tangent line to be
    dydx|(0.619,1)=3e0.6193(0.619)e0.6192+3(0.619)2e0.6190.235.
    Hence the tangent line equation is y1=0.235(x0.619).
Implicit differentiation also gives us tools that we can use to find the derivative of functions that are given explicitly. The following example demonstrates the technique for one such function.

Example 2.94.

Find dydx when y=xx.
We first notice that our previous rules of differentiation do not apply in this case because we have a variable in both the base and the exponent of this expression. In order to solve this problem, we will need to turn it into an equivalent implicit function. We begin by taking the natural logarithm of both sides to get
ln(y)=ln(xx).
Through the properties of logarithms, this simplifies to
ln(y)=xln(x).
Now we can implicitly differentiate both sides, yielding
1ydydx=(ln(x)+x1x=(ln(x)+1.
Simplification by collecting and isolating dydx gives us
dydx=(y(ln(x)+1)=(xx(ln(x)+1).
Therefore,
ddx[xx]=xx(ln(x)+1).

Subsection 2.7.2 Summary

  • In an equation involving x and y where portions of the graph can be defined by explicit functions of x, we say that y is an implicit function of x. A good example of such a curve is the unit circle.
  • We use implicit differentiation to differentiate an implicitly defined function. We differentiate both sides of the equation with respect to x, treating y as a function of x by applying the chain rule. If possible, we subsequently solve for dydx using algebra.
  • While dydx may now involve both the variables x and y, dydx still gives the slope of the tangent line to the curve. It may be used to decide where the tangent line is horizontal (dydx=0) or vertical (dydx is undefined), or to find the equation of the tangent line at a particular point on the curve.

Exercises 2.7.3 Exercises

1. Implicit differentiation in a polynomial equation.

Find dy/dx in terms of x and y if x2yx3y4=0.
dydx=

2. Implicit differentiation in an equation with logarithms.

Find dydx in terms of x and y if xlny+y3=8lnx.
dydx=

3. Implicit differentiation in an equation with inverse trigonometric functions.

Find dy/dx in terms of x and y if arctan(x3y)=xy3.
dydx=

4. Slope of the tangent line to an implicit curve.

Find the slope of the tangent to the curve x3+2xy+y2=9 at (1,2).
The slope is .
(Enter undef if the slope is not defined at this point.)

5. Equation of the tangent line to an implicit curve.

Use implicit differentiation to find an equation of the tangent line to the curve 3xy3+5xy=72 at the point (9,1).
The equation
 34 
/webwork2_files/helpFiles/Entering-Equations.html
defines the tangent line to the curve at the point (9,1).

6. Finding horizontal and vertical tangency with implicit differentiation.

Consider the curve given by the equation 2y3+y2y5=x42x3+x2. Find all points at which the tangent line to the curve is horizontal or vertical. Be sure to use a graphing utility to plot this implicit curve and to visually check the results of algebraic reasoning that you use to determine where the tangent lines are horizontal and vertical.

7. Equation of the tangent line to an implicit trigonometric curve.

For the curve given by the equation sin(x+y)+cos(xy)=1, find the equation of the tangent line to the curve at the point (π2,π2).

8. Revisiting exponential derivatives using implicit differentiation.

Implicit differentiation enables us a different perspective from which to see why the rule ddx[ax]=axln(a) holds, if we assume that ddx[ln(x)]=1x. This exercise leads you through the key steps to do so.
  1. Let y=ax. Rewrite this equation using the natural logarithm function to write x in terms of y (and the constant a).
  2. Differentiate both sides of the equation you found in (a) with respect to x, keeping in mind that y is implicitly a function of x.
  3. Solve the equation you found in (b) for dydx, and then use the definition of y to write dydx solely in terms of x. What have you found?