Section 4.5 The Second Derivative and Concavity
For an intuitive definition of the derivative, we talked about zooming in on the graph until it looks like a straight line and taking the slope. For concavity, we want to zoom out a bit, so the graph curves up or down from a line.
We say that a graph is concave up if the line between two points is above the graph, or alternatively if the first derivative is increasing. (In finance, such a curve is said to be convex.) Similarly, we say that a graph is concave down if the line between two points is below the graph, or alternatively if the first derivative is decreasing. (In finance, such a curve is said to be concave.)
In determining is a curve is concave up or concave down, we want to take the second derivative of a function, or the derivative of the derivative.
Definition 4.5.1.
For a function \(f(x)\text{,}\) the second derivative of \(f(x)\) or the derivative of \(f'(x)\text{,}\) denoted as \(f''(x)\text{,}\) is defined as
We also want to recall some alternate notations we may use.
As we have noted before, when there are several forms, we use the one that makes the most sense in the case on which we are working.
Example 4.5.2. Finding second derivatives.
Find the second derivative for each of the following functions:
\(\displaystyle f(x)=3x^5+4x^2\)
\(\displaystyle g(x)=5 x^6+3x+9\)
\(\displaystyle h(x)=x e^{2x}\)
\(\displaystyle j(x)=6 \sqrt{x}+\frac{3}{x}\)
\(\displaystyle k(x)=\frac{\ln(x)}{x^3} \)
Using our rule:
\(\displaystyle f''(x)=\frac{d}{dx}(\frac{d}{dx}( 3x^5+4x^2 ))\frac{d}{dx} (15x^4+8x)=60x^3+8.\)
\(\displaystyle g''(x)=\frac{d}{dx} (\frac{d}{dx} (5 x^6+3x+9))=\frac{d}{dx} (30x^5+3)=150x^4.\)
\(\displaystyle \begin{aligned} h'' (x)\amp =\frac{d}{dx} (\frac{d}{dx} (x e^{2x} )) =\frac{d}{dx} (e^{2x}+2xe^{2x} )\\ \amp =2e{^2}x+2e^{2x}+4xe^{2x}=4e^{2x}+4xe^2x.\end{aligned}\)
\(\displaystyle \begin{aligned} j'' (x) \amp = \frac{d}{dx} (\frac{d}{dx} (6 \sqrt{x}+3/x))=\frac{d}{dx} (\frac{d}{dx} (6x^{1/2}+3x^{1} ))\\ \amp = \frac{d}{dx} (3x^{1/2}3x^{2} )=3/2 x^{3/2}+6x^{3}.\end{aligned}\)
\(\displaystyle \begin{aligned} k'' (x) \amp = \frac{d}{dx} (\frac{d}{dx} (\frac{\ln(x)}{x^3} ))=\frac{d}{dx} (\frac{(\frac{1}{x} x^33(x^2 ) ln(x))}{x^6 }\\ \amp = \frac{d}{dx} (\frac{(13 \ln(x))}{x^4 } = \frac{(\frac{3}{x} x^4(13 \ln(x) )4x^3)}{x^8} \\ \amp =\frac{3(13 \ln(x) )4}{x^5} = \frac{7+12\ln(x)}{x^5}.\end{aligned} \)
As the last problem shows, it is often useful to simplify between taking the first and second derivatives.
If our function is the position of \(x\text{,}\) then the first derivative is the rate of change or the velocity of \(f(x)\text{.}\) The second derivative is acceleration or how fast velocity changes.
Graphically, the first derivative gives the slope of the graph at a point. The second derivative tells whether the curve is concave up or concave down at that point. If the second derivative is positive at a point, the graph is bending upwards at that point. Similarly if the second derivative is negative, the graph is concave down. This is of particular interest at a critical point where the tangent line is flat and concavity tells us if we have a relative minimum or maximum.
Insight 4.5.3. Second derivative test of extrema.
Let \(f(x)\) be a function with \(f'(x_0)=0\text{.}\) Then if \(f''(x_0) \gt 0\text{,}\) the function has a local minimum at \(x=x_0\text{.}\) If \(f''(x_0) \lt 0\text{,}\) the function has a local maximum at \(x=x_0\text{.}\) If \(f''(x_0)=0\text{,}\) the second derivative test fails.
Example 4.5.4. Second derivative tests.
For the designated function and point, determine if the graph has a local minimum, local maximum, or nonextreme point, or if the second derivative test fails.
\(\displaystyle f(x)=x^312 x,\qquad\qquad x_0=2\)
\(\displaystyle f(x)=x^312 x,\qquad\qquad x_0=2\)
\(\displaystyle f(x)=x^312 x,\qquad\qquad x_0=4\)
\(\displaystyle g(x)=x^4,\qquad\qquad x_0=0\)
\(\displaystyle h(x)=x^5,\qquad\qquad x_0=0\)
Using our rule:

\(f(x)=x^312 x,\qquad\qquad f'(x)=3x^212,\qquad\qquad f''(x)=6\)x.
At \(x_0=2\text{,}\) we have \(f'(x_0)=0\) and \(f''(x_0)=12\text{.}\) We are at a critical point, and the curve is concave up, so we have a local minimum.

\(f(x)=x^312 x,\qquad\qquad f'(x)=3x^212,\qquad\qquad f''(x)=6x\text{.}\)
At \(x_0=2\text{,}\) we have \(f'(x_0)=0\) and \(f'' (x_0 )=12\text{.}\) We are at a critical point and the curve is concave down, so we have a local maximum.

\(f(x)=x^312 x,\qquad\qquad f'(x)=3x^212,\qquad\qquad f''(x)=6x\text{.}\)
At \(x_0=4\text{,}\) we have \(f'(x_0)=36\text{.}\) The second derivative is positive, so the curve is concave up, but since the derivative is not zero, this is not an extreme point.

\(g(x)=x^4,\qquad\qquad g'(x)=4x^3,\qquad\qquad g''(x)=12x^2\text{.}\)
At \(x_0=0\text{,}\) we have \(g'(x_0)=0\) and \(g''(x_0)=0\text{,}\) so the second derivative test fails at this point. (However if we look a the graph, we can see the curve is concave up everywhere, and that this point is a local minimum.)

\(h(x)=x^5,\qquad\qquad h'(x)=5x^4,\qquad\qquad h''(x)=20x^3\text{.}\)
At \(x_0=0\text{,}\) we have \(h'(x_0)=0\) and \(h''(x_0)=0\text{,}\) so the second derivative test fails at this point. (However if we look a the graph, we can see this point is neither a local minimum or a local maximum. It is a place where the graph switches from being concave up to being concave down. This is called an inflection point.)
We will use the second derivative test for finding maximums and minimums in the next chapter.
Second derivative with CAS.
We can find second derivatives with our favorite CAS programs.
With Symbolab
With WolframAlpha
Second derivative in finance.
The mathematical first and second derivatives are used in pricing various financial products and options that are also called derivatives. The first derivative is used to give a value to whether the underlying product has a price that goes up or down. It looks at the slope of the pricing curve. The second derivative is used to give a value to the volatility of the underlying product. It looks at how much the pricing curve bends. We will return to these uses when we look at integrals.
Exercises Exercises: The Second Derivative and Concavity Problems
Exercise Group.
Find the first and second derivatives of the given function.
Determine where the function is concave up and where it is concave down.
Find the critical points of the function. Classify each as a local minimum, a local maximum, neither, or not a local extremum.
1.
\(f(x)=(x3)^24\)

\begin{equation*} f'(x)=2(x3) \end{equation*}\begin{equation*} f''(x)=2 \end{equation*}
The second derivative is always positive, so the function is always concave up
There is one critical point at \(x=3\text{.}\) It is a local minimum.
2.
\(g(t)=(x3)(x1)(x+4)\)
3.
\(h(t)=t^2 e^{t}\)

\begin{equation*} h' (t)=2te^{t}t^2 e^{t}=(2t)te^{t} \end{equation*}\begin{equation*} h'' (t)=(22t)e^{t}(2tt^2)e^{t}=(24t+t^2 ) e^{t} \end{equation*}
The function is concave down, where the second derivative is negative, that is for \(2\sqrt{2} \lt t \lt 2+\sqrt{2}\text{.}\) It is concave up outside this region.
There are critical points when the derivative is undefined or 0. The only critical points are when \(t=0\) and \(t=2\text{.}\) When \(t=0\text{,}\) \(h''(t)\gt 0\text{,}\) so we have a local minimum. When \(t=2\text{,}\) \(h''(t)\lt 0\text{,}\) so we have a local maximum.
4.
\(k(x)=(x^29)^3\)
5.
\(m(x)=\frac{x^24}{x^29}\)

\begin{equation*} m' (x)=\frac{10}{(x^29)^3} \end{equation*}\begin{equation*} m'' (x)=\frac{30x^2+90}{(x^29)^3} \end{equation*}
The function is concave down, where the second derivative is negative, which for our function is when the denominator is negative. The function \(m(x)\) is concave down when \(3 \lt x \lt 3\text{.}\) It is concave up outside this region.
There are critical points when \(t\) is 0 or 2. When \(t=0\text{,}\) \(h''(t)\gt 0\text{,}\) so we have a local minimum. When \(t=2\text{,}\) the second derivative is negative and we have a local maximum.
6.
\(\text{ConsumerSurplus}= 10*(0.95)^{\frac{\quantity}{100}} 2*(1.07)^{\frac{\quantity}{100}}\)
7.
\(\price= 10\frac{\quantity}{100} \frac{\quantity^2}{10000}\)

\begin{equation*} price'=\frac{1}{100}\frac{quantity}{5000} \end{equation*}\begin{equation*} price''=\frac{1}{5000} \end{equation*}
The second derivative is always negative, to the function is always concave down.
There is one critical point at \(quantity=50\text{.}\) It is a local maximum.
8.
\(\revenue=\quantity*\left(20*.9^{\left(\frac{\quantity}{200}\right)}\right)\)
9.
\(\Sprice= 10*1.04^{\left(\frac{\quantity}{100}\right)}\)

\begin{equation*} \Sprice'=\frac{\ln(104)}{10}*1.04^{(\quantity/100)} \end{equation*}\begin{equation*} \Sprice''=\frac{\ln(104)^2}{1000}*1.04^{(quantity/100)} \end{equation*}
The second derivative is always positive, to the function is always concave up.
The first derivative is always positive. There are no critical points.
Exercise Group.
Identify which curve is \(f\text{,}\) \(f'\text{,}\) and \(f''\text{.}\)
10.
11.
Note that local maximums of a function must correspond to zeroes of its derivative. The original function is F (green). Its derivative is D (Purple). The second derivative is E (black).
12.
13.
Looking at the middle segment of the curves, the green curve is a downward facing parabola, whose derivative is a line with a negative slope like the purples curve, whose derivative is a negative constant like the black line.
Exercise Group.
For the next set of problems, you need to know the formula for the price of a zero coupon bond given the face value, the interest rate, and the time to maturity. For such instruments we use the formula
(Be aware that a rate of 4% is a rate of 0.04.)
For each problem give:
The cost of the bond as described.
The first derivative of cost as a function of rate. (This measures risk of interest rate change.)
The second derivative of cost as a function of rate. (This measures the value of an option on the bond.)
14.
The face value of the bond is $1000. The interest rate is currently 4%. The bond matures in 10 years.
15.
The face value of the bond is $1000. The interest rate is currently 4%. The bond matures in 30 years.
 \begin{equation*} \cost=\frac{1000}{(1.04)^{30}} =308.32 \end{equation*}

\begin{equation*} \cost(\rate)=\FaceValue(1+\rate)^{(\years)} \end{equation*}\begin{equation*} \cost(\rate)=\years*\FaceValue(1+\rate)^{(\years1)} \end{equation*}\begin{equation*} \cost'(.04)=30*1000(1.04)^{31}=8993 \end{equation*}

\begin{equation*} \cost''(\rate)=\years(1+\years)*\FaceValue(1+\rate)^{(\years2)} \end{equation*}\begin{equation*} \cost(.04)=30(31)*1000(1.04)^{(32)}=265103 \end{equation*}
16.
The face value of the bond is $1000. The interest rate is currently 6%. The bond matures in 10 years.
17.
The face value of the bond is $1000. The interest rate is currently 3%. The bond matures in 20 years.
 \begin{equation*} \cost=\frac{1000}{(1.03)^{20}} =553.68 \end{equation*}

\begin{equation*} \cost(\rate)=\FaceValue(1+\rate)^{(\years)} \end{equation*}\begin{equation*} \cost(\rate)=\years*\FaceValue(1+\rate)^{(\years1)} \end{equation*}\begin{equation*} \cost'(.03)=20*1000(1.03)^{21}=8000 \end{equation*}

\begin{equation*} \cost''(\rate)=\years(1+\years)*\FaceValue(1+\rate)^{(\years2)} \end{equation*}\begin{equation*} \cost(.03)=20(21)*1000(1.03)^{(22)}=219914 \end{equation*}