# Elements of the Differential and Integral Calculus/Chapter VIII
## CHAPTER VIII

MAXIMA AND MINIMA. POINTS OF INFLECTION. CURVE TRACING
79. Introduction. A great many practical problems occur where we have to deal with functions of such a nature that they have a greatest (maximum) value or a least (minimum) value, and it is very important to know what particular value of the variable gives such a value of the function. For instance, suppose that it is required to find the dimensions of the rectangle of greatest area that can be inscribed in a circle of radius 5 inches. Consider the circle in the following figure:
Inscribe any rectangle, as BD.
Let CD = x; then DE = ${\sqrt {100-x^{2}}}$, and the area of the rectangle is evidently
(1) $A=x{\sqrt {100-x^{2}}}$.
That a rectangle of maximum area must exist may be seen as follows: Let the base CD (= x) increase to 10 inches (the diameter); then the altitude $DE={\sqrt {100-x^{2}}}$ will decrease to zero and the area will become zero. Now let the base decrease to zero; then the altitude will increase to 10 inches and the area will again become zero. It is therefore intuitionally evident that there exists a greatest rectangle. By a careful study of the figure we might suspect that when the rectangle becomes a square its area would be the greatest, but this would at best be mere guesswork. A better way would evidently be to plot the graph of the function (1) and note its behavior. To aid us in drawing the graph of (1), we observe that
(a) from the nature of the problem it is evident that x and A must both be positive; and
(b) the values of x range from zero to 10 inclusive.
Now construct a table of values and draw the graph.
What do we learn from the graph?
| x | A |
| 0 | 0 |
| 1 | 9.9 |
| 2 | 19.6 |
| 3 | 28.6 |
| 4 | 36.6 |
| 5 | 43.0 |
| 6 | 48.0 |
| 7 | 49.7 |
| 8 | 48.0 |
| 9 | 39.6 |
| 10 | 0.0 |
(a) If carefully drawn, we may find qui!e accurately the area of the rectangle corresponding to any value x by measuring the length of the corresponding ordinate. Thus,
| when | $x=OM=3$ inches, |
| then | $A=MP=28.6$ square inches; |
| and when | $x=ON=4{\frac {1}{2}}$ inches, |
| then | $A=NQ=$ about 39.8 sq. in. (found by measurement). |
(b) There is one horizontal tangent (RS). The ordinate TH from its point of contact T is greater than any other ordinate. Hence this discovery: One of the inscribed rectangles has evidently a greater area than any of the others. In other words, we may infer from this that the function defined by (1) has a maximum value. We cannot find this value (= HT) exactly by measurement, but it is very easy to find, using Calculus methods. We observed that at T the tangent was horizontal; hence the slope will be zero at that point (Illustrative Example 1, p. 74 [§64]). To find the abscissa of T we then find the first derivative of (1), place it equal to zero, and solve for x. Thus
| (1) | $\ A$ | $=x{\sqrt {100-x^{2}}}$, |
| | ${\frac {dA}{dx}}$ | $=\ {\frac {100-2x^{2}}{\sqrt {100-x^{2}}}}$ |
| | ${\frac {100-2x^{2}}{\sqrt {100-x^{2}}}}$ | $=\ 0$. |
| Solving, | $\ x$ | $=\ 5{\sqrt {2}}$. |
| Substituting back, we get | $\ DE$ | $=\ {\sqrt {100-x^{2}}}=5{\sqrt {2}}$. |
Hence the rectangle of maximum area inscribed in the circle is a square of area
$A=CD\times DE=5{\sqrt {2}}\times 5{\sqrt {2}}=50$ square inches. The length of HT is therefore 50.
Take another example. A wooden box is to be built to contain 108 cu. ft. It is to have an open top and a square base. What must be its dimensions in order that the amount of material required shall be a minimum; that is, what dimensions will make the cost the least?
Let x = length of side of square base in feet,
and y = height of box.
Since the volume of the box is given, however, y may be found in terms of x. Thus
    volume $=\ x^{2}y\ =\ 108$; ∴ $y\ =\ {\frac {108}{x^{2}}}$.
We may now express the number (= M) of square feet of lumber required as a function of x as follows:
| | area of base = | $x^{2}$ sq. ft., |
| | and area of four sides = | $=\ 4xy\ =\ {\frac {432}{x^{2}}}$ sq. ft. Hence |
| (2) | $\ M$ | $=\ x^{2}+{\frac {432}{x}}$ |
| X | M |
| 1 | 433 |
| 2 | 220 |
| 3 | 153 |
| 4 | 124 |
| 5 | 111 |
| 6 | 108 |
| 7 | 111 |
| 8 | 118 |
| 9 | 129 |
| 10 | 143 |
is a formula giving the number of square feet required in any such box having a capacity of 108 cu. ft. Draw a graph of (2).
What do we learn from the graph?
(a) If carefully drawn, we may measure the ordinate corresponding to any length (= x) of the side of the square base and so determine the number of square feet of lumber required.
(b) There is one horizontal tangent (RS). The ordinate from its point of contact T is less than any other ordinate. Hence this discovery: One of the boxes evidently takes less lumber than any of the others. In other words, we may infer that the function defined by (2) has a minimum value. Let us find this point on the graph exactly, using our Calculus. Differentiating (2) to get the slope at any point, we have
    ${\frac {dM}{dx}}=2x-{\frac {432}{x^{2}}}$.
At the lowest point T the slope will be zero. Hence
    $2x-{\frac {432}{x^{2}}}=0$;
that is, when x = 6 the least amount of lumber will be needed.
Substituting in (2), we see that this is
    M = 108 sq. ft.
The fact that a least value of M exists is also shown by the following reasoning. Let the base increase from a very small square to a very large one. In the former case the height must be very great and therefore the amount of lumber required will be large. In the latter case, while the height is small, the base will take a great deal of lumber. Hence M varies from a large value, grows less, then increases again to another large value. It follows, then, that the graph must have a "lowest" point corresponding to the dimensions which require the least amount of lumber, and therefore would involve the least cost.
We will now proceed to the treatment in detail of the subject of maxima and minima.
80. Increasing and decreasing functions. A function is said to be increasing when it increases as the variable increases and decreases as the variable decreases. A function is said to be decreasing when it decreases as the variable increases and increases as the variable decreases.
The graph of a function indicates plainly whether it is increasing or decreasing. For instance, consider the function $a^{x}$ whose graph (Fig. a) is the locus of the equation
| $y=a^{x}$ | a > 1 |
As we move along the curve from left to right the curve is rising; that is, as x increases the function (= y) always increases. Therefore $a^{x}$ is an increasing function for all values of x.
| Fig. a Fig. a. | Fig. b |
On the other hand, consider the function $(a-x)^{3}$ whose graph (Fig. b) is the locus of the equation
    $y=(a-x)^{3}$.
Now as we move along the curve from left to right the curve is falling; that is, as x increases, the function (= y) always decreases. Hence $(a-x)^{3}$ is a decreasing function for all values of x.
That a function may be sometimes increasing and sometimes decreasing is shown by the graph (Fig. c) of
    $y=2x^{3}-9x^{2}+12x-3$.
As we move along the curve from left to right the curve rises until we reach the point A, then it falls from A to B, and to the right of B it is always rising. Hence
(a) from x = $-\inf$ to x = 1 the function is increasing;
(b) from x = 1 to x = 2 the function is decreasing;
(c) from x = 2 to x = $+\inf$ the function is increasing.
The student should study the curve carefully in order to note the behavior of the function when x = 1 and x = 2. Evidently A and B are turning points. At A the function ceases to increase and commences to decrease; at B, the reverse is true. At A and B the tangent (or curve) is evidently parallel to the axis of X, and therefore the slope is zero.
81. Tests for determining when a function is increasing and when decreasing. It is evident from Fig. c that at a point, as C, where a function
    $y=f(x)$
is increasing, the tangent in general makes an acute angle with the axis of X; hence
    slope = tan $\tau ={\frac {dy}{dx}}=f'(x)=$ a positive number.
Similarly, at a point, as D, where a function is decreasing, the tangent in general makes an obtuse angle with the axis of X; therefore
    slope = tan $\tau ={\frac {dy}{dx}}=f'(x)=$ a negative number.
In order, then, that the function shall change from an increasing to a decreasing function, or vice versa, it is a necessary and sufficient condition that the first derivative shall change sign. But this can only happen for a continuous derivative by passing through the value zero. Thus in Fig. c, p. 107, as we pass along the curve the derivative (= slope) changes sign at A and B where it has the value zero. In general, then, we have at turning points
    (18) ${\frac {dy}{dx}}=f'(x)=0$.
The derivative is continuous in nearly all our important applications, but it is interesting to note the case when the derivative (= slope) changes sign by passing through $\inf$. This would evidently happen at the points B, E, G in the following figure, where the tangents (and curve) are perpendicular to the axis of X. At such exceptional turning points
    ${\frac {dy}{dx}}=f'(x)=\inf$;
or, what amounts to the same thing,
    ${\frac {1}{f'(x)}}=0$.
82. Maximum and minimum values of a function. A maximum value of a function is one that is greater than any values immediately preceding or following.
A minimum value of a function is one that is less than any values immediately preceding or following.
For example, in Fig. c, p. 107 [§80], it is clear that the function has a maximum value MA (= y = 2) when x = 1, and a minimum value NB (= y = l) when x = 2.
The student should observe that a maximum value is not necessarily the greatest possible value of a function nor a minimum value the least. For in Fig. c it is seen that the function (= y) has values to the right of B that are greater than the maximum MA, and values to the left of A that are less than the minimum NB.
A function may have several maximum and minimum values. Suppose that the above figure represents the graph of a function $f(x)$.
At B, D, G, I, K the function is a maximum, and at C, E, H, J a minimum. That some particular minimum value of a function may be greater than some particular maximum value is shown in the figure, the minimum values at C and H being greater than the maximum value at K.
At the ordinary turning points C, D, H, I, J, X the tangent (or curve) is parallel to OX; therefore
    slope = ${\frac {dy}{dx}}=f'(x)=0$.
At the exceptional turning points B, E, G the tangent (or curve) is perpendicular to OX, giving
    slope = ${\frac {dy}{dx}}=f'(x)=\inf$.
One of these two conditions is then necessary in order that the function shall have a maximum or a minimum value. But such a condition is not sufficient; for at F the slope is zero and at A it is infinite, and yet the function has neither a maximum nor a minimum value at either point. It is necessary for us to know, in addition, how the function behaves in the neighborhood of each point. Thus at the points of maximum value, B, D, G, I, X, the function changes from an increasing to a decreasing function, and at the points of minimum value, C, E, H, J, the function changes from a decreasing to an increasing function. It therefore follows from § 81 that at maximum points
    slope = ${\frac {dy}{dx}}=f'(x)$ must change from + to -,
and at minimum points
    slope = ${\frac {dy}{dx}}=f'(x)$ must change from - to +
when we move along the curve from left to right.
At such points as A and F where the slope is zero or infinite, but which are neither maximum nor minimum points,
    slope = ${\frac {dy}{dx}}=f'(x)$ does not change sign.
We may then state the conditions in general for maximum and minimum values of $f(x)$ for certain values of the variable as follows:
(19) $f(x)$ is a maximum if $f'(x)=0$, and $f'(x)$ changes from + to -.
(20) $f(x)$ is a minimum if $f'(x)=0$, and $f'(x)$ changes from - to +.
The values of the variable at the turning points of a function are called critical values; thus x = 1 and x = 2 are the critical values of the variable for the function whose graph is shown in Fig. c, p. 107. The critical values at turning points where the tangent is parallel to OX are evidently found by placing the first derivative equal to zero and solving for real values of x, just as under § 64, p. 73.
To determine the sign of the first derivative at points near a particular turning point, substitute in it, first, a value of the variable just a little less than the corresponding critical value, and then one a little greater. If the first gives + (as at L, Fig. d, p. 109 [§82]) and the second - (as at M), then the function (= y) has a maximum value in that interval (as at I).
If the first gives - (as at P) and the second + (as at N), then the function (= y) has a minimum value in that interval (as at C).
If the sign is the same in both cases (as at Q and R), then the function (= y) has neither a maximum nor a minimum value in that interval (as at F).
We shall now summarize our results into a compact working rule.
83. First method for examining a function for maximum and minimum values. Working rule.
FIRST STEP. Find the first derivative of the function.
SECOND STEP. Set the first derivative equal to zero and solve the resulting equation for real roots in order to find the critical values of the variable.
THIRD STEP. Write the derivative in factor form; if it is algebraic, write it in linear form.
FOURTH STEP. Considering one critical value at a time, test the first derivative, first for a value a trifle less and then for a value a trifle greater than the critical value. If the sign of the derivative is first + and then -, the function has a maximum value for that particular critical value of the variable; but if the reverse is true, then it has a minimum value. If the sign does not change, the function has neither.
In the problem worked out on p. 104 [§79] we showed by means of the graph of the function
    $A=x{\sqrt {100-x^{2}}}$
that the rectangle of maximum area inscribed in a circle of radius 5 inches contained 50 square inches. This may now be proved analytically as follows by applying the above rule.
| Solution. | Solution. | $\ f(x)$ | $=\ x{\sqrt {100-x^{2}}}$ |
| First step. | First step. | $\ f'(x)$ | $=\ {\frac {100-2x^{2}}{\sqrt {100-x^{2}}}}$. |
| Second step. | Second step. | ${\frac {100-2x^{2}}{\sqrt {100-x^{2}}}}$ | $=\ 0$. |
| | | $\ x$ | $=\ 5{\sqrt {2}}$ |
| which is the critical value. Only the positive sign of the radical is taken, since, from the nature of the problem, the negative sign has no meaning. ||||
| Third step. | Third step. | $\ f'(x)$ | $=\ {\frac {2(5{\sqrt {2}}-x)(5{\sqrt {2}}+x}{\sqrt {(10-x)(10+x)}}}$. |
| Fourth step | When $x<5{\sqrt {2}}$, | $\ f'(x)$ | $=\ {\frac {2(+)(+)}{\sqrt {(+)(+)}}}=+$. |
| | When $x>5{\sqrt {2}}$, | $\ f'(x)$ | $=\ {\frac {2(+)(+)}{\sqrt {(-)(+)}}}=-$. |
Since the sign of the first derivative changes from + to - at $x=5{\sqrt {2}}$, the function has a maximum value
    $f(5{\sqrt {2}})=5{\sqrt {2}}\cdot 5{\sqrt {2}}=50$. Ans.
84. Second method for examining a function for maximum and minimum values. From (19), p. 110 [§82], it is clear that in the vicinity of a maximum value of $f(x)$, in passing along the graph from left to right,
    $f'(x)$ changes from + to 0 to -.
Hence $f'(x)$ is a decreasing function, and by §81 we know that its derivative, i.e. the second derivative [= $f''(x)$] of the function itself, is negative or zero.
Similarly, we have, from (20), p. 110, that in the vicinity of a minimum value of $f(x)$
    $<math>f'(x)$ changes from - to 0 to +.
Hence $f'(x)$ is an increasing function and by §81 it follows that $f''(x)$ is positive or zero.
The student should observe that $f''(x)$ is positive not only at minimum points (as at A) but also at points such as P. For, as a point passes through P in moving from left to right,
slope = $\tan \tau ={\frac {dy}{dx}}=f'(x)$ is an increasing function.
At such a point the curve is said to be concave upwards.
Similarly, $f''(x)$ is negative not only at maximum points (as at B) but also at points such as Q. For, as a point passes through Q,
    slope = $\tan \tau ={\frac {dy}{dx}}=f'(x)$ is a decreasing function.
At such a point the curve is said to be concave downwards.
We may then state the sufficient conditions for maximum and minimum values of $f(x)$ for certain values of the variable as follows:
(21) $f(x)$ is a maximum if $f'(x)=0$ and $f''(x)$ = a negative number.
(22) $f(x)$ is a minimum if $f'(x)=0$ and $f''(x)$ = a positive number.
Following is the corresponding working rule.
FIRST STEP. Find the first de1ivative of the function.
SECOND STEP. Set the first derivative equal to zero and solve the resulting equation for real roots in order to find the critical values of the variable.
THIRD STEP. Find the second derivative.
FOURTH STEP. Substitute each critical value for the variable in the second de1ivative. If the result is negative, then the function is a maximum for that critical value; if the result is positive, the function is a minimum.
When $f''(x)=0$, or does not exist, the above process fails, although there may even then be a maximum or a minimum; in that case the first method given in the last section still holds, being fundamental. Usually this second method does apply, and when the process of finding the second derivative is not too long or tedious, it is generally the shortest method.
Let us now apply the above rule to test analytically the function
    $M=x^{2}+{\frac {432}{x}}$
found in the example worked out on p. 105 [§79].
| Solution. | $\ f(x)$ | $=\ x^{2}+{\frac {432}{x}}$. |
| First step. | $\ f'(x)$ | $=\ 2x-{\frac {432}{x^{2}}}$. |
| Second step. | $\ 2x-{\frac {432}{x^{2}}}$ | $=\ 0$, |
| Third step. | $\ f''(x)$ | $=\ 2+{\frac {864}{x^{3}}}$. |
| Fourth step. | $\ f''(6)$ | $=\ +$. Hence |
| | $\ f(6)$ | $=\ 108$, minimum value. |
The work of finding maximum and minimum values may frequently be simplified by the aid of the following principles, which follow at once from our discussion of the subject.
(a) The maximum and minimum values of a continuous function must occur alternately,
(b) When c is a positive constant, $c\cdot f(x)$ is a maximum or a minimum for such values of x, and such only, as make $f(x)$ a maximum or a minimum.
Hence, in determining the critical values of x and testing for maxima and minima, any constant factor may be omitted.
When c is negative, $c\cdot f(x)$ is a maximum when $f(x)$ is a minimum, and conversely.
(c) If c is a constant,
    $f(x)$ and $c+f(x)$
have maximum and minimum values for the same values of x.
Hence a constant term may be omitted when finding critical values of x and testing.
In general we must first construct, from the conditions given in the problem, the function whose maximum and minimum values are required, as was done in the two examples worked out on pp. 103-106 [§79]. This is sometimes a problem of considerable difficulty. No rule applicable in all cases can be given for constructing the function, but in a large number of problems we may be guided by the following
General directions.
(a) Express the function whose maximum or minimum is involved in the problem.
(b) If the resulting expression contains more than only variable, the conditions of the problem will furnish enough relations between the variables so that all may be expressed in terms of a single one.
(c) To the resulting function of a single variable apply one of our two rules jor finding maximum and minimum values.
(d) In practical problems it is usually easy to tell which critical value will give a maximum and which a minimum value, so it is not always necessary to apply the fourth step of our rules.
(e) Draw the graph of the function (p.l04) in order to check the work.
* ↑ There may be more than one of each, as illustrated on p. 109 [§82].
* ↑ The proofs given here depend chiefly on geometric intuition. The subject of Maxima and Minima will be treated analytically in §108, p. 167.
* ↑ Conversely, for any given value of x, if $f'(x)=+$, then $f(x)$ is increasing; if $f'(x)=-$, then $f(x)$ is decreasing. When $f'(x)=0$, we cannot decide without further investigation whether $f(x)$ is increasing or decreasing.
* ↑ By this is meant that its reciprocal passes through the value zero.
* ↑ Similarly, if we wish to examine a function at exceptional turning points where the tangent is perpendicular to OX, we set the reciprocal of the first derivative equal to zero and solve to find critical values.
* ↑ In this connection the term "little less," or "trifle less," means any value between the next smaller root (critical value) and the one under consideration; and the term "little greater," or "trifle greater," means any value between the root under consideration and the next larger one.
* ↑ A similar discussion will evidently hold for the exceptional turning points B, E, and A respectively.
* ↑ When the first derivative becomes infinite for a certain value of the independent variable, then the function should be examined for such a critical value of the variable, for it may give maximum or minimum values, as at B, E, or A (Fig. d, p. 109). See footnote on p. 108 [§81].
* ↑ At a point where the curve is concave upwards we sometimes say that the curve has a positive bending, and where it is concave downwards a negative bending.