In
calculus
Calculus is the mathematics, mathematical study of continuous change, in the same way that geometry is the study of shape, and algebra is the study of generalizations of arithmetic operations.
Originally called infinitesimal calculus or "the ...
, a derivative test uses the
derivative
In mathematics, the derivative is a fundamental tool that quantifies the sensitivity to change of a function's output with respect to its input. The derivative of a function of a single variable at a chosen input value, when it exists, is t ...
s of a
function to locate the
critical points of a function and determine whether each point is a
local maximum, a
local minimum, or a
saddle point
In mathematics, a saddle point or minimax point is a Point (geometry), point on the surface (mathematics), surface of the graph of a function where the slopes (derivatives) in orthogonal directions are all zero (a Critical point (mathematics), ...
. Derivative tests can also give information about the
concavity of a function.
The usefulness of derivatives to find
extrema is proved mathematically by
Fermat's theorem of stationary points.
First-derivative test
The first-derivative test examines a function's
monotonic
In mathematics, a monotonic function (or monotone function) is a function between ordered sets that preserves or reverses the given order. This concept first arose in calculus, and was later generalized to the more abstract setting of ord ...
properties (where the function is increasing or decreasing), focusing on a particular point in its
domain. If the function "switches" from increasing to decreasing at the point, then the function will achieve a highest value at that point. Similarly, if the function "switches" from decreasing to increasing at the point, then it will achieve a least value at that point. If the function fails to "switch" and remains increasing or remains decreasing, then no highest or least value is achieved.
One can examine a function's monotonicity without calculus. However, calculus is usually helpful because there are
sufficient conditions that guarantee the monotonicity properties above, and these conditions apply to the vast majority of functions one would encounter.
Precise statement of monotonicity properties
Stated precisely, suppose that ''f'' is a
real-valued function defined on some
open interval
In mathematics, a real interval is the set (mathematics), set of all real numbers lying between two fixed endpoints with no "gaps". Each endpoint is either a real number or positive or negative infinity, indicating the interval extends without ...
containing the point ''x'' and suppose further that ''f'' is
continuous at ''x''.
* If there exists a positive number ''r'' > 0 such that ''f'' is weakly increasing on and weakly decreasing on , then ''f'' has a local maximum at ''x''.
* If there exists a positive number ''r'' > 0 such that ''f'' is strictly increasing on and strictly increasing on , then ''f'' is strictly increasing on and does not have a local maximum or minimum at ''x''.
Note that in the first case, ''f'' is not required to be strictly increasing or strictly decreasing to the left or right of ''x'', while in the last case, ''f'' is required to be strictly increasing or strictly decreasing. The reason is that in the definition of local maximum and minimum, the inequality is not required to be strict: e.g. every value of a
constant function
In mathematics, a constant function is a function whose (output) value is the same for every input value.
Basic properties
As a real-valued function of a real-valued argument, a constant function has the general form or just For example, ...
is considered both a local maximum and a local minimum.
Precise statement of first-derivative test
The first-derivative test depends on the "increasing–decreasing test", which is itself ultimately a consequence of the
mean value theorem
In mathematics, the mean value theorem (or Lagrange's mean value theorem) states, roughly, that for a given planar arc (geometry), arc between two endpoints, there is at least one point at which the tangent to the arc is parallel to the secant lin ...
. It is a direct consequence of the way the
derivative
In mathematics, the derivative is a fundamental tool that quantifies the sensitivity to change of a function's output with respect to its input. The derivative of a function of a single variable at a chosen input value, when it exists, is t ...
is defined and its connection to decrease and increase of a function locally, combined with the previous section.
Suppose ''f'' is a real-valued function of a real variable defined on some
interval containing the critical point ''a''. Further suppose that ''f'' is continuous at ''a'' and
differentiable on some open interval containing ''a'', except possibly at ''a'' itself.
* If there exists a positive number ''r'' > 0 such that for every ''x'' in (''a'' − ''r'', ''a'') we have and for every ''x'' in (''a'', ''a'' + ''r'') we have then ''f'' has a local maximum at ''a''.
* If there exists a positive number ''r'' > 0 such that for every ''x'' in (''a'' − ''r'', ''a'') we have and for every ''x'' in (''a'', ''a'' + ''r'') we have then ''f'' has a local minimum at ''a''.
* If there exists a positive number ''r'' > 0 such that for every ''x'' in (''a'' − ''r'', ''a'') ∪ (''a'', ''a'' + ''r'') we have then ''f'' is strictly increasing at ''a'' and has neither a local maximum nor a local minimum there.
* If none of the above conditions hold, then the test fails. (Such a condition is not
vacuous; there are functions that satisfy none of the first three conditions, e.g. ''f''(''x'') = ''x''
2 sin(1/''x'')).
Again, corresponding to the comments in the section on monotonicity properties, note that in the first two cases, the inequality is not required to be strict, while in the third, strict inequality is required.
Applications
The first-derivative test is helpful in solving
optimization problem
In mathematics, engineering, computer science and economics
Economics () is a behavioral science that studies the Production (economics), production, distribution (economics), distribution, and Consumption (economics), consumption of goo ...
s in physics, economics, and engineering. In conjunction with the
extreme value theorem
In calculus, the extreme value theorem states that if a real-valued function f is continuous on the closed and bounded interval ,b/math>, then f must attain a maximum and a minimum, each at least once.
That is, there exist numbers c and ...
, it can be used to find the absolute maximum and minimum of a real-valued function defined on a
closed and
bounded interval. In conjunction with other information such as concavity, inflection points, and
asymptote
In analytic geometry, an asymptote () of a curve is a line such that the distance between the curve and the line approaches zero as one or both of the ''x'' or ''y'' coordinates tends to infinity. In projective geometry and related contexts, ...
s, it can be used to sketch the
graph of a function.
Second-derivative test (single variable)
After establishing the
critical points of a function, the ''second-derivative test'' uses the value of the
second derivative
In calculus, the second derivative, or the second-order derivative, of a function is the derivative of the derivative of . Informally, the second derivative can be phrased as "the rate of change of the rate of change"; for example, the secon ...
at those points to determine whether such points are a local
maximum
In mathematical analysis, the maximum and minimum of a function (mathematics), function are, respectively, the greatest and least value taken by the function. Known generically as extremum, they may be defined either within a given Interval (ma ...
or a local minimum.
If the function ''f'' is twice-differentiable at a critical point ''x'' (i.e. a point where '(''x'') = 0), then:
* If
, then
has a local maximum at
.
* If
, then
has a local minimum at
.
* If
, the test is inconclusive.
In the last case,
Taylor's theorem
In calculus, Taylor's theorem gives an approximation of a k-times differentiable function around a given point by a polynomial of degree k, called the k-th-order Taylor polynomial. For a smooth function, the Taylor polynomial is the truncation a ...
may sometimes be used to determine the behavior of ''f'' near ''x'' using
higher derivative
In mathematics, the derivative is a fundamental tool that quantifies the sensitivity to change of a function's output with respect to its input. The derivative of a function of a single variable at a chosen input value, when it exists, is t ...
s.
Proof of the second-derivative test
Suppose we have
(the proof for
is analogous). By assumption,
. Then
:
Thus, for ''h'' sufficiently small we get
:
which means that
if
(intuitively, ''f'' is decreasing as it approaches
from the left), and that
if
(intuitively, ''f'' is increasing as we go right from ''x''). Now, by the
first-derivative test
In calculus, a derivative test uses the derivatives of a function to locate the critical points of a function and determine whether each point is a local maximum, a local minimum, or a saddle point. Derivative tests can also give information ab ...
,
has a local minimum at
.
Concavity test
A related but distinct use of second derivatives is to determine whether a function is
concave up or concave down at a point. It does not, however, provide information about
inflection points. Specifically, a twice-differentiable function ''f'' is concave up if
and concave down if
. Note that if
, then
has zero second derivative, yet is not an inflection point, so the second derivative alone does not give enough information to determine whether a given point is an inflection point.
Higher-order derivative test
The ''higher-order derivative test'' or ''general derivative test'' is able to determine whether a function's critical points are maxima, minima, or points of inflection for a wider variety of functions than the second-order derivative test. As shown below, the second-derivative test is mathematically identical to the special case of ''n'' = 1 in the higher-order derivative test.
Let ''f'' be a real-valued, sufficiently differentiable function on an interval
, let
, and let
be a
natural number
In mathematics, the natural numbers are the numbers 0, 1, 2, 3, and so on, possibly excluding 0. Some start counting with 0, defining the natural numbers as the non-negative integers , while others start with 1, defining them as the positive in ...
. Also let all the derivatives of ''f'' at ''c'' be zero up to and including the ''n''-th derivative, but with the (''n'' + 1)th derivative being non-zero:
:
There are four possibilities, the first two cases where ''c'' is an extremum, the second two where ''c'' is a (local) saddle point:
* If ''(n+1)'' is
even and
, then ''c'' is a local maximum.
* If ''(n+1)'' is even and
, then ''c'' is a local minimum.
* If ''(n+1)'' is
odd and
, then ''c'' is a strictly decreasing point of inflection.
* If ''(n+1)'' is odd and
, then ''c'' is a strictly increasing point of inflection.
Since ''(n+1)'' must be either odd or even, this analytical test classifies any stationary point of ''f'', so long as a nonzero derivative shows up eventually, where
is the first non-zero derivative.
Example
Say we want to perform the general derivative test on the function
at the point
. To do this, we calculate the derivatives of the function and then evaluate them at the point of interest until the result is nonzero.
:
,
:
,
:
,
:
,
:
,
:
,
As shown above, at the point
, the function
has all of its derivatives at 0 equal to 0, except for the 6th derivative, which is positive. Thus ''n'' = 5, and by the test, there is a local minimum at 0.
Multivariable case
For a function of more than one variable, the second-derivative test generalizes to a test based on the
eigenvalue
In linear algebra, an eigenvector ( ) or characteristic vector is a vector that has its direction unchanged (or reversed) by a given linear transformation. More precisely, an eigenvector \mathbf v of a linear transformation T is scaled by a ...
s of the function's
Hessian matrix at the critical point. In particular, assuming that all second-order partial derivatives of ''f'' are continuous on a
neighbourhood
A neighbourhood (Commonwealth English) or neighborhood (American English) is a geographically localized community within a larger town, city, suburb or rural area, sometimes consisting of a single street and the buildings lining it. Neighbourh ...
of a critical point ''x'', then if the eigenvalues of the Hessian at ''x'' are all positive, then ''x'' is a local minimum. If the eigenvalues are all negative, then ''x'' is a local maximum, and if some are positive and some negative, then the point is a
saddle point
In mathematics, a saddle point or minimax point is a Point (geometry), point on the surface (mathematics), surface of the graph of a function where the slopes (derivatives) in orthogonal directions are all zero (a Critical point (mathematics), ...
. If the Hessian matrix is
singular
Singular may refer to:
* Singular, the grammatical number that denotes a unit quantity, as opposed to the plural and other forms
* Singular or sounder, a group of boar, see List of animal names
* Singular (band), a Thai jazz pop duo
*'' Singula ...
, then the second-derivative test is inconclusive.
See also
*
Bordered Hessian
*
Convex function
In mathematics, a real-valued function is called convex if the line segment between any two distinct points on the graph of a function, graph of the function lies above or on the graph between the two points. Equivalently, a function is conve ...
*
Differentiability
*
Fermat's theorem (stationary points)
*
Inflection point
*
Karush–Kuhn–Tucker conditions
*
Maxima and minima
In mathematical analysis, the maximum and minimum of a function are, respectively, the greatest and least value taken by the function. Known generically as extremum, they may be defined either within a given range (the ''local'' or ''relative ...
*
Optimization (mathematics)
Mathematical optimization (alternatively spelled ''optimisation'') or mathematical programming is the selection of a best element, with regard to some criteria, from some set of available alternatives. It is generally divided into two subfiel ...
*
Phase line – virtually identical diagram, used in the study of ordinary differential equations
*
Saddle point
In mathematics, a saddle point or minimax point is a Point (geometry), point on the surface (mathematics), surface of the graph of a function where the slopes (derivatives) in orthogonal directions are all zero (a Critical point (mathematics), ...
*
Second partial derivative test
*
Stationary point
In mathematics, particularly in calculus, a stationary point of a differentiable function of one variable is a point on the graph of a function, graph of the function where the function's derivative is zero. Informally, it is a point where the ...
*
Second variation
Further reading
*
*
*
*
*
References
{{reflist
External links
"Second Derivative Test" at MathworldConcavity and the Second Derivative TestThomas Simpson's use of Second Derivative Test to Find Maxima and Minimaat Convergence
Differential calculus