Section 12.2 Extreme Values and Optimization
¶We have already learned that derivatives can help us identify the location of local extreme values, points that are the highest or lowest values in a neighborhood of that point. It is often the case that we need to find the highest or lowest value that a function ever achieves, not just in its own neighborhood. We call these global extremes.
Applications involving the identification of extreme values are often called optimization problems. The task in optimization is to identify the value of an independent variable in the system that will maximize or minimize some objective. Aside from the calculus in finding the extreme values, creating an appropriate function that will serve as the objective is often the greatest challenge.
Subsection 12.2.1 Global Extreme Values
The Extreme Value Theorem guarantees that a continuous function restricted to a closed interval will always have global maximum minimum values. Those extremes can only occur at either the end points of the interval or at critical points (points with horizontal or undefined tangents). This guides our strategy.
Compute \(f'(x)\text{.}\)
Identify critical points: solve \(f'(x)=0\) and identify all points where \(f'(x)\) is not defined.
Classify the points, including the end points for comparison.
Example 12.2.1.
Find the maximum and minimum values of \(\displaystyle f(x)=\frac{x-1}{x^2+1}\) on the interval \([-2,2]\text{.}\)
Because the denominator of \(f(x)\) is never zero, \(x^2+1 \ne 0\text{,}\) \(f(x)\) is continuous everywhere. Consequently, the Extreme Value Theorem guarantees that \(f\) will have a maximum and minimum value on the closed interval \([-2,2]\text{.}\)
First, we compute \(f'(x)\text{,}\) which involves the quotient rule.
Next, we find critical points. Again, the denominator is nonzero, so \(f'(x)\) will be defined and continuous for every value \(x\text{.}\) We only need to find solutions to \(f'(x)=0\text{,}\) which are solutions to \(-x^2+2x+1=0\text{.}\) The quadratic formula gives
The critical values are \(x=1-\sqrt{2}\approx 0.414\) and \(1+\sqrt{2} \approx 2.414\text{.}\)
If we were to test these critical values as turning points, we would look at the signs of \(f'(x)\) on the intervals formed by the critical points. The sign analysis is summarized with the number line below, showing that \(x=1-\sqrt{2}\) is a local minimum and \(x=1+\sqrt{2}\) is a local maximum.
To find the extreme values on the interval, we really just need to compare the values of \(f(x)\) at the end points of the interval with the critical points that are inside the interval. Because \(x=1+\sqrt{2}\) is outside \([-2,2]\text{,}\) we do not include that point.
We finish by interpreting our results. The maximum value of \(f\) on the interval \([-2,2]\) is \(\frac{1}{5}\text{,}\) occurring at \(x=2\text{.}\) The minimum value of \(f\) on the interval is \(\frac{\sqrt{2}}{4-2\sqrt{2}} \approx -1.207\text{,}\) occurring at \(x=1-\sqrt{2} \approx 0.414\text{.}\) A graph of the function showing these extremes is given below.
When the function is not continuous or the interval is not a closed interval, the function is not guaranteed to have global extreme values. When an end point for a continuous function is not included, the function achieves every value up to the limit at that end point. This means that it is possible that the function does not actually have an extreme value. For every value the function does achieve, there may be another value that is more extreme.
Example 12.2.2.
The function \(f(x)=x\) restricted to \((0,1)\) is continuous. The values (range) is obviously \((0,1)\text{.}\) But \(f\) does not have a maximum or minimum value. The upper limit \(y=1\) is never achieved because \(x=1\) is not in the restricted domain. But for any value \(y \lt 1\text{,}\) there will always be another value that is larger. Similarly, \(y=0\) is an unacheived lower limit and \(f\) does not have a minimum value.
When looking for extreme values for functions that have discontinuities or where the domain is restricted to an open interval, we do the same things as for continuous functions: find critical points and compare values of the function. However, we need to include any relevant limits in the comparison. If a limiting value is more extreme than any of the achieved extreme values, then the function does not achieve that extreme value.
Example 12.2.3.
Find the extreme values of the function \(f(x) = x^3+x^2-2x+2\) on the interval \((-2,2)\text{.}\)
The function is continuous. If the interval was closed, \([-2,2]\text{,}\) the Extreme Value Theorem would guarantee that it had a maximum and minimum value. By excluding the end points, we might no longer achieve one or both of those values.
First, find \(f'(x)=3x^2+2x-2\text{.}\) Use this to find critical points, where \(f'(x)=0\text{.}\) The quadratic formula is needed:
The critical values are \(x=\frac{-1-\sqrt{7}}{3} \approx -1.215\) and \(x=\frac{-1+\sqrt{7}}{3} \approx 0.5486\text{.}\) Both critical values are in the interval.
We now compare the values of the function at the critical values and at the end points.
The minimum value for \(f\) on the interval \([-2,2]\) is approximately 1.369 at \(x=\frac{-1+\sqrt{7}}{3}\text{;}\) the maximum value is 10 at \(x=2\text{.}\) However, when working with the open interval \((-2,2)\text{,}\) the maximum value is a limit value that is not achieved. So \(f\) does not have a maximum value on \((-2,2)\text{,}\) though it does have the same minimum value.
Example 12.2.4.
Find the extreme values of the function \(f(x)=\frac{10x-15}{x^2}\text{.}\)
The function \(f(x)=\frac{10x-15}{x^2}\) has a discontinuity at \(x=0\) because division by zero is undefined. This corresponds to a vertical asymptote at \(x=0\text{.}\) Because the question does not give an interval, we must be considering the entire domain, \((-\infty,0) \cup (0,\infty)\text{.}\) Extreme values are not guaranteed.
We begin by finding critical values. The derivative requires the quotient rule.
The critical value is the solution to \(-10x+30=0\text{,}\) or \(x=3\text{.}\) When doing sign analysis, we also need to use the discontinuity \(x=0\) to create the intervals that are tested.
The sign analysis on \(f'(x)\) informs us about the vertical asymptote. The function decreases immediately to the left of \(x=0\text{,}\) letting us know
Similarly, the function is increasing immediately to the right of \(x=0\text{,}\) showing that
This is enough to guarantee that \(f(x)\) does not have a minimum value because it is unbounded in the negative direction.
The critical point \(x=3\) is a turning point corresponding to a local maximum. The value of the function is \(f(3)=\frac{15}{9}=\frac{5}{3}\text{.}\) To see if this is a global maximum, we need to compare it with the ends of the intervals, as \(x \to \pm \infty\text{.}\) These limits are both zero.
These limits show that \(y=0\) is a horizontal asymptote for \(f(x)\) as \(x \to \pm \infty\text{.}\)
Interpreting our results, we see that \(f(x)\) has a maximum value of \(\frac{5}{3}\) at \(x=3\) and no minimum value due to the infinite limit at \(x=0\text{.}\)
Subsection 12.2.2 Optimization
Optimization is the application of finding extreme values to either maximize or minimize some quantity of interest. In general, we will have a system where there is some variable that we have freedom to vary and some quantity that is a function of that variable that we want to be at a maximum or minimum value. The variable that we vary is the independent variable. The quantity that we optimize is called the objective function.
For example, consider a crystal goblet. When a pure note is sounded, the goblet will resonate with a strength that depends on the frequency of the note. If we wanted to shatter the goblet, we would want to find the frequency with which the goblet resonated the most. In this example, the frequency of the note being played is the independent variable and the strength of resonance would be the objective function.
Example 12.2.5.
The most elementary example of resonance is for a forced simple harmonic oscillator. The independent variable is the forcing frequency \(\omega\text{.}\) The objective function is the amplification factor of the resonant response \(A\text{.}\) The system also has parameters related to the oscillator itself: \(\omega_0\text{,}\) which represents natural frequency of the oscillator in the absence of friction, and \(\alpha\text{,}\) which represents a rate at which the oscillator's motion would decay in the absence of a stimulus. The amplification factor is defined by the equation
Find the frequency that is amplified the most.
Physically, the driving frequency must be a non-negative value, so \(\omega \ge 0\text{.}\) So we will look for extreme values on the domain \([0,\infty)\text{.}\) The denominator involves the sum of two squares which can not be simultaneously equal to zero. Consequently, \(A(\omega)\) is a continuous function defined for all values of \(\omega\text{.}\) We need to find the critical values by solving \(A'(\omega)=0\text{.}\) Computing \(A'\) involves repeated use of the chain rule.
Critical values are solutions to the equation \(2 \omega (\omega^2-\omega_0^2+2\alpha^2) = 0\text{.}\) Solutions occur when \(\omega=0\) and \(\omega^2 = \omega_0^2-2\alpha^2\text{,}\) which only occurs when \(\omega_0^2 \gt 2 \alpha^2\text{.}\)
When \(\omega_0^2 \gt 2 \alpha^2\text{,}\) the sign of \(A'(\omega)\) changes sign at the critical value at
since the factor \(\omega^2 - (\omega_0^2-2\alpha^2)\) changes sign. The denominator will always be positive. This allows us to determine the sign analysis of \(A'(\omega)\text{.}\)
The sign analysis of \(A'(\omega)\) shows that \(A(\omega)\) is increasing for \(\omega\) in the interval \([0,\omega^*]\) and decreasing for \(\omega\) in the interval \([\omega^*,\infty)\text{.}\) Consequently, \(A\) achieves a maximum value when \(\omega = \omega^*\text{.}\) That maximum value is
A typical resonance response curve is shown below for this case (\(\omega_0=1\) and \(\alpha=0.25\)).
In the case that \(\omega_0^2 \lt 2 \alpha^2\) and the only critical value is \(\omega=0\text{,}\) the factor in the numerator of \(A'(\omega)\) given by \(\omega^2 - \omega_0^2 + 2\alpha^2\) will always be positive. This implies that \(A'(\omega) \lt 0\) for all \(\omega \gt 0\text{,}\) meaning that \(A(\omega)\) is a decreasing function whose maximum must be at the end-point \(\omega=0\text{.}\)
Not every application involves unspecified parameters.
Example 12.2.6.
The number of births in a population during a given time period is equal to the per capita birth rate times the population size. Suppose that the per capita birth rate was found to also depend on the population size. Average per capita birth rates for certain controlled population sizes were experimentally obtained and shown in the table below. Find a model for the per capita birth rate as a function of population size and use that model to predict the maximum population birth rate.
Population | Per Capita Birth Rate |
100 | 0.0190 |
200 | 0.0158 |
300 | 0.0146 |
400 | 0.0134 |
500 | 0.0120 |
We start by looking at the graph of the data. Let \(P\) be the population size and let \(b\) be the per capita birth rate. We are interested in the function \(P \mapsto b\text{,}\) so the graph plots points \((P, b)\text{.}\)
The relationship between these points is decreasing. A linear model looks like it could be appropriate. Using linear regression on our data, we find a model
The total birth rate is defined as \(B(P) = b(P) \cdot P\text{,}\) which according to our model is given by
This is our objective function, the quantity we want as large as possible.
To find the maximum value of \(B\text{,}\) we compute \(B' = 0.019878 - 3.2846 \times 10^{-5} P\) and solve \(B'=0\) to find the critical point.
Because \(B'' = -3.2846 \times 10^{-5}\) is negative, we know that \(B\) is a concave down function and the critical value corresponds to a maximum value. The maximum total birth rate is
occurring for \(P=605.2\text{.}\) A population should be an integer value, so we would expect the maximum birth rate to occur when \(P=605\text{.}\)
However, our prediction is dependent on the model that we chose. What if we used a different equation for our original per capita birth rate? The original data points have the appearance of being concave up. So maybe we should use an exponential regression curve. This gives
The graph below shows the two models for per capita birth rate with the data.
Using the exponential model for the per capita birth rate, we obtain a modified objective function
The derivative is
The critical value must solve \(1-0.001125P\) since the exponential factor is always positive. This gives \(P = \frac{1}{0.001125} \approx 888.9\text{.}\) Sign analysis of \(B'(P)\) shows that this critical value corresponds to a maximum value, \(B(888.9)=6.763\text{.}\)
Notice how two different models can yield significantly different predictions. The two models are illustrated together in the figure below. Notice that the original, quadratic model has the non-physical predication of a negative number of births for sufficiently large population sizes.