3 The Graphical Behavior of Functions

3.5 Curve Sketching

We have been learning how we can understand the behavior of a function based on its first and second derivatives. While we have been treating the properties of a function separately (increasing and decreasing, concave up and concave down, etc.), we combine them here to produce an accurate graph of the function without plotting lots of extraneous points.

Why bother? Graphing utilities are very accessible, whether on a computer, a hand-held calculator, or a smartphone. These resources are usually very fast and accurate. We will see that our method is not particularly fast — it will require time (but it is not hard). So again: why bother?

margin: f>0, increasing f′′<0, c. down f<0, decreasing f′′<0, c. down f<0,decreasing f′′>0, c. up f>0, increasing f′′>0, c. up Figure 3.5.1: Demonstrating the 4 ways that concavity interacts with increasing / decreasing, along with the relationships with the first and second derivatives. Λ

We are attempting to understand the behavior of a function f based on the information given by its derivatives. While all of a function’s derivatives relay information about it, it turns out that “most” of the behavior we care about is explained by f and f′′. Understanding the interactions between the graph of f and f and f′′ is important and is illustrated in Figure 3.5.1. To gain this understanding, one might argue that all that is needed is to look at lots of graphs. This is true to a point, but is somewhat similar to stating that one understands how an engine works after looking only at pictures. It is true that the basic ideas will be conveyed, but “hands-on” access increases understanding.

The following Key Idea summarizes what we have learned so far that is applicable to sketching graphs of functions and gives a framework for putting that information together. It is followed by several examples.

Key Idea 3.5.1 Curve Sketching

To produce an accurate sketch a given function f, consider the following steps.

  1. (a)

    Find the domain of f. Generally, we assume that the domain is the entire real line then find restrictions, such as where a denominator is 0 or where negatives appear under the radical.

  2. (b)

    Find the location of any vertical asymptotes of f (usually done in conjunction with the previous step).

  3. (c)

    Find the x and y-intercepts of f, and any symmetry.

  4. (d)

    Consider the limits limx-f(x) and limxf(x) to determine the end behavior of the function.

  5. (e)

    Find the critical points of f.

  6. (f)

    Find the possible points of inflection of f.

  7. (g)

    Create a number line that includes all critical points, possible points of inflection, and locations of vertical asymptotes. For each interval created, determine whether f is increasing or decreasing, concave up or down.

  8. (h)

    Evaluate f at each critical point and possible point of inflection. Plot these points on a set of axes. Connect these points with curves exhibiting the proper concavity. Sketch asymptotes and x and y-intercepts where applicable.

Example 3.5.1 Curve sketching

Use Key Idea 3.5.1 to sketch f(x)=3x3-10x2+4x+10.

SolutionWe follow the steps outlined in the Key Idea.

  1. (a)

    The domain of f is the entire real line; there are no values x for which f(x) is not defined.

  2. (b)

    There are no vertical asymptotes.

  3. (c)

    We see that f(0)=10, and f does not appear to factor easily (so we skip finding the roots). It has no symmetry.

  4. (d)

    We determine the end behavior using limits as x approaches ±infinity.

    limx-f(x)=-  limxf(x)=.

    We do not have any horizontal asymptotes.

  5. (e)

    Find the critical points of f. We compute f(x)=9x2-20x+4=(9x-2)(x-2), so that x=29,2.

  6. (f)

    Find the possible points of inflection of f. We see f′′(x)=18x-20, so that

    f′′(x)=0x=10/91.111.
  7. (g)

    We place the values x=29,109,2 on a number line. We mark each subinterval as increasing or decreasing, concave up or down, using the techniques used in Sections 3.3 and 3.4.

    margin: -1123510xy (a)-1123510xy (b) Figure 3.5.2: Sketching f in Example 3.5.1. Λ
  8. (h)

    We plot the appropriate points on axes as shown in Figure 3.5.2(a) and connect the points with the proper concavity. Our curve crosses the y axis at y=10 and crosses the x axis near x=-0.75. In Figure 3.5.2(b) we show a graph of f drawn with a computer program, verifying the accuracy of our sketch.

Example 3.5.2 Curve sketching

Sketch f(x)=x2-x-2x2-x-6.

SolutionWe again follow the steps outlined in Key Idea 3.5.1.

  1. (a)

    In determining the domain, we assume it is all real numbers and look for restrictions. We find that at x=-2 and x=3, f(x) is not defined. So the domain of f is D={real numbers x|x-2,3}.

  2. (b)

    The vertical asymptotes of f are at x=-2 and x=3, the places where f is undefined. We see that limx-2-f(x)=, limx-2+f(x)=-, limx3-f(x)=-, and limx3+f(x)=.

  3. (c)

    We see that f(0)=13 and that f(x)=0 when 0=x2-x-2=(x-2)(x+1) so that x=-1,2. There is no symmetry.

  4. (d)

    There is a horizontal asymptote of y=1, as both limx-f(x)=1 and limxf(x)=1. (Either one would be sufficient to give the horizontal asymptote.)

  5. (e)

    To find the critical points of f, we first find f(x). Using the Quotient Rule, we find

    f(x)=-8x+4(x2-x-6)2=-8x+4(x-3)2(x+2)2.

    f(x)=0 when x=1/2, and f is undefined when x=-2,3. Since f is undefined only when f is, these are not critical points. The only critical point is x=1/2.

  6. (f)

    To find the possible points of inflection, we find f′′(x), again employing the Quotient Rule:

    f′′(x)=24x2-24x+56(x-3)3(x+2)3.

    We find that f′′(x) is never 0 (setting the numerator equal to 0 and solving for x, we find the only roots to this quadratic are imaginary) and f′′ is undefined when x=-2,3. Thus concavity will possibly only change at x=-2 and x=3 (although these are not inflection points, since f is not defined there). margin: -4-224-55xy (a)-4-224-55xy (b) Figure 3.5.3: Sketching f in Example 3.5.2. Λ

  7. (g)

    We place the values x=1/2, x=-2 and x=3 on a number line. We mark in each interval whether f is increasing or decreasing, concave up or down. We see that f has a relative maximum at x=1/2; concavity changes only at the vertical asymptotes.

  8. (h)

    In Figure 3.5.3(a), we plot the points from the number line on a set of axes and connect the points with the appropriate concavity. We also show f crossing the x axis at x=-1 and x=2. Figure 3.5.3(b) shows a computer generated graph of f, which verifies the accuracy of our sketch.

Example 3.5.3 Curve sketching

Sketch f(x)=5(x-2)(x+1)x2+2x+4.

SolutionWe again follow Key Idea 3.5.1.

  1. (a)

    We assume that the domain of f is all real numbers and consider restrictions. The only restrictions come when the denominator is 0, but this never occurs. Therefore the domain of f is all real numbers, .

  2. (b)

    There are no vertical asymptotes.

  3. (c)

    We see that f(0)=-52 and that f(x)=0 when x=-1,2.

  4. (d)

    We have a horizontal asymptote of y=5, as

    limx±f(x)=limx±5(1-2x)(1+1x)1+2x+4x2=5.
  5. (e)

    We find the critical points of f by setting f(x)=0 and solving for x. We find

    f(x)=15x(x+4)(x2+2x+4)2f(x)=0 when x=-4,0.
  6. (f)

    We find the possible points of inflection by solving f′′(x)=0 for x. We find

    f′′(x)=-30x3+180x2-240(x2+2x+4)3.

    The cubic in the numerator does not factor very “nicely.” We instead approximate the roots at x=-5.759, x=-1.305 and x=1.064.

  7. (g)

    We place the critical points and possible inflection points on a number line and mark each interval as increasing/decreasing, concave up/down appropriately.

  8. (h)

    In Figure 3.5.4(a) we plot the significant points from the number line as well as the two roots of f, x=-1 and x=2, and connect the points with the appropriate concavity. Figure 3.5.4(b) shows a computer generated graph of f, affirming our results (but the top left was slightly off). margin: -555xy (a)-555xy (b) Figure 3.5.4: Sketching f in Example 3.5.3. Λ

In each of our examples, we found a few, significant points on the graph of f that corresponded to changes in increasing/decreasing or concavity. We connected these points with curves, and finished by showing a very accurate, computer generated graph.

Why are computer graphics so good? It is not because computers are “smarter” than we are. Rather, it is largely because computers are much faster at computing than we are. In general, computers graph functions much like most students do when first learning to draw graphs: they plot equally spaced points, then connect the dots using lines. By using lots of points, the connecting lines are short and the graph looks smooth.

This does a fine job of graphing in most cases (in fact, this is the method used for many graphs in this text). However, in regions where the graph is very “curvy,” this can generate noticeable sharp edges on the graph unless a large number of points are used. High quality computer algebra systems, such as Mathematica, use special algorithms to plot lots of points only where the graph is “curvy.”

In Figure 3.5.5, a graph of y=sinx is given, generated by Mathematica. The small points represent each of the places Mathematica sampled the function. Notice how at the “bends” of sinx, lots of points are used; where sinx is relatively straight, fewer points are used. (Many points are also used at the endpoints to ensure the “end behavior” is accurate.)

Figure 3.5.5: A graph of y=sinx generated by Mathematica.

How does Mathematica know where the graph is “curvy”? Calculus. When we study curvature in a later chapter, we will see how the first and second derivatives of a function work together to provide a measurement of “curviness.” Mathematica employs algorithms to determine regions of “high curvature” and plots extra points there.

Again, the goal of this section is not “How to graph a function when there is no computer to help.” Rather, the goal is “Understand that the shape of the graph of a function is largely determined by understanding the behavior of the function at a few key places.” In Example 3.5.3, we were able to accurately sketch a complicated graph using only 5 points and knowledge of asymptotes!

There are many applications of our understanding of derivatives beyond curve sketching. The next chapter explores some of these applications, demonstrating just a few kinds of problems that can be solved with a basic knowledge of differentiation.

Exercises 3.5

 

Terms and Concepts

  1. 1.

    Why is sketching curves by hand beneficial even though technology is readily available?

  2. 2.

    T/F: When sketching graphs of functions, it is useful to find the critical points.

  3. 3.

    T/F: When sketching graphs of functions, it is useful to find the possible points of inflection.

  4. 4.

    T/F: When sketching graphs of functions, it is useful to find the horizontal and vertical asymptotes.

Problems

  1. 5.
    Given the graph of f, identify the concavity of f, its inflection points, its regions of increasing and decreasing, and its relative extrema.-22-4-224xy
  2. 6.
    Given the graph of f, identify the concavity of f, its inflection points, its regions of increasing and decreasing, and its relative extrema.-22-4-224xy

In Exercises 7–12., practice using Key Idea 3.5.1 by applying the principles to the given functions with familiar graphs.

  1. 7.

    f(x)=2x+4

  2. 8.

    f(x)=-x2+1

  3. 9.

    f(x)=sinx

  4. 10.

    f(x)=ex

  5. 11.

    f(x)=1x

  6. 12.

    f(x)=1x2

In Exercises 13–46., sketch a graph of the given function using Key Idea 3.5.1. Show all work; check your answer with technology.

  1. 13.

    f(x)=x3-2x2+4x+1

  2. 14.

    f(x)=-x3+5x2-3x+2

  3. 15.

    f(x)=x3+3x2+3x+1

  4. 16.

    f(x)=x3-x2-x+1

  5. 17.

    f(x)=(x-2)ln(x-2)

  6. 18.

    f(x)=(x-2)2ln(x-2)

  7. 19.

    f(x)=x2-4x2

  8. 20.

    f(x)=x2-4x+3x2-6x+8

  9. 21.

    f(x)=x+sinx on [0,2π].

  10. 22.

    f(x)=x2-2x+1x2-6x+8

  11. 23.

    f(x)=xx+1

  12. 24.

    f(x)=x2ex

  13. 25.

    f(x)=sinxcosx on [-π,π]

  14. 26.

    f(x)=(x-3)2/3+2

  15. 27.

    f(x)=(x-1)2/3x

  16. 28.

    f(x)=xx-5

  17. 29.

    f(x)=secx-2cosx on [0,2π].

  18. 30.

    f(x)=x2-x2

  19. 31.

    f(x)=xx2-1

  20. 32.

    f(x)=x5/3-5x2/3

  21. 33.

    f(x)=sinx2+cosx on [0,2π].

  22. 34.

    f(x)=xx2+3

  23. 35.
    f(x)=4x2-4x+14x2-12x+9 Hint: f(x) can be simplified in a variety of ways. Use whichever simplification works best for your current task.
  24. 36.

    y=x2+x-x

  25. 37.

    y=x+cosx

  26. 38.

    y=xtanx on (-π2,π2)

  27. 39.

    y=sinx+3cosx on [-2π,2π]

  28. 40.

    y=cscx-2sinx on (0,π)

  29. 41.

    f(x)=3x2+4

  30. 42.

    f(x)=3x2-4

  31. 43.

    f(x)=xx2+4

  32. 44.

    f(x)=xx2-4

  33. 45.

    f(x)=xx-4

  34. 46.

    f(x)=(x-1)2x2+1

In Exercises 47–52., sketch the graph of a function that satisfies all of the given conditions.

  1. 47.
    f(0)=f(2)=f(4)=0, f(x)>0 if x<0 or 2<x<4, f(x)<0 if 0<x<2 or x>4, f′′(x)>0 if 1<x<3, f′′(x)<0 if x<1 or x>4
  2. 48.
    f(5)=0, f(x)<0 when x<5, f(x)>0 if x>5, f′′(2)=0, f′′(8)=0, f′′(x)<0 if x<2 or x>8, f′′(x)>0 if 2<x<8
  3. 49.
    f(0)=0, f(-2)=f(1)=f(9)=0, limxf(x)=0, limx6f(x)=-, f(x)<0 on (-,-2),(1,6),(9,), f(x)>0 on (-2,1),(6,9), f′′(x)>0 on (-,0),(12,), f′′(x)<0 on (0,6),(6,12)
  4. 50.
    f is odd, f(x)<0 on (0,2), f(x)>0 on (2,), f′′(x)>0 on (0,3), f′′(x)<0 on (3,), limxf(x)=-2
  5. 51.
    concave up on (-,-1), (1,); concave down on (-1,1); increasing on (-,0); and decreasing on (0,).
  6. 52.
    limx-f(x)=1, limx3-f(x)=, limxf(x)=-1, limx3+f(x)=-; f(x)>0 on (-,-2), (-1,0), (2,3), (3,); f(x)<0 on (-2,-1), (0,2); f′′(x)>0 on (-,-3), (1,3); and f′′(x)<0 on (-3,-1), (-1,1), (3,).

In Exercises 53–56., a function with the parameters a and b are given. Describe the critical points and possible points of inflection of f in terms of a and b.

  1. 53.

    f(x)=ax2+b2

  2. 54.

    f(x)=ax2+bx+1

  3. 55.

    f(x)=sin(ax+b)

  4. 56.

    f(x)=(x-a)(x-b)

  1. 57.

    Given x2+y2=1, use implicit differentiation to find dydx and d2ydx2. Use this information to justify the sketch of the unit circle.

Omni CMS