Advanced maths

Local maximum and minimum calculator with derivative graph

Find numerical stationary candidates for an entered function, inspect its symbolic derivative and nearby sign changes, and export the function graph.

Your numbers

Use explicit multiplication, x, pi, e, arithmetic, sin, cos, tan, exp, natural log, sqrt or abs. Angles are radians.
Finite scanning and bracket refinement do not certify that all critical points were found.

Calculated on your device. Your inputs aren’t sent to us.

Your result

Ready when you are

Enter your inputs and select Calculate.

Try it, understand it

Explore the result

Inspect derivative sign evidence while keeping local candidates separate from a complete optimization proof.

Worked example comparison
ExampleOutputWhat to notice
Original cubic exampleIsolated stationary candidates detected2The local maximum is (−1,4) and the local minimum is (1,0).
Sine in radiansIsolated stationary candidates detected2Numerically recover the visible sine peak and valley from the cosine derivative.
Stationary without an extremumIsolated stationary candidates detected1The sampled zero at the origin is stationary but its derivative does not change sign.
Constant functionIsolated stationary candidates detected0A zero derivative throughout the valid domain does not create an isolated turning-point list.
Quartic with three stationary pointsIsolated stationary candidates detected3Compare two local minima with the local maximum at zero.

Check your understanding

Does increasing scan density certify all extrema?

No. A finite scan remains numerical evidence and can miss unresolved behavior.

Why test derivative signs after finding a candidate?

A zero derivative can occur without a change from increasing to decreasing or vice versa.

Behind the numbers

How this calculation works

Differentiate the entered expression symbolically, scan the selected interval and refine derivative sign-change brackets. Retain stationary candidates with a small derivative residual and inspect nearby derivative signs. Plot the function and detected candidates while listing window endpoints separately. The search is numerical evidence, not a global optimum proof.

THE FORMULAStationary candidates satisfy f′(x)≈0; inspect the derivative sign on both sides to distinguish local minimum and maximum candidates

A worked example

For f(x)=x³−3x+2, f′(x)=3x²−3. The stationary points are x=−1 with f=4 and x=1 with f=0. The derivative changes from positive to negative at −1, giving a local maximum, and from negative to positive at 1, giving a local minimum.

Good to know

Bounded symbolic grammar and finite numerical search on an increasing interval at least 10⁻⁶ wide. At most 4,000 scan intervals and 256 isolated candidates. Can miss unsampled stationary points, rapid oscillations and nondifferentiable extrema. Candidate labels do not certify continuity, all critical points or an absolute optimum. Undefined evaluations split known gaps; an unseen pole may remain between samples.

Find the stationary point before calling it an optimum

A differentiable function has a stationary point where its first derivative is zero. Such a point can be a local maximum, a local minimum or neither. The search therefore keeps the derivative equation and the classification step separate. A zero slope is information about the tangent, not by itself a guarantee of a peak or valley.

The page symbolically differentiates the bounded input expression and displays that derivative. It then samples the selected interval and refines brackets where the derivative changes sign. Exact derivative zeros at sampled points are also retained. The result is a list of numerical candidates with nearby sign evidence, not a complete symbolic solution of every possible derivative equation.

A little curiosity

Follow the cubic example through its two sign changes

For f(x)=x³−3x+2, the derivative is 3x²−3. Solving that simple derivative equation gives x=−1 and x=1. At −1, the function value is −1+3+2=4. At 1, the function value is 1−3+2=0. Those coordinates are marked on the original function graph.

To the left of −1 the derivative is positive, and just to its right the derivative is negative. The function changes from increasing to decreasing, giving a local maximum. Around 1 the derivative changes from negative to positive, giving a local minimum. The table records the candidate x, its function value, classification and derivative residual so the geometric statement remains connected to the calculation.

Distinguish a local extremum from a global question

A local maximum compares a value with nearby function values. An absolute maximum compares it with every value in the specified domain. The cubic example has both a local peak and a local valley, but no absolute maximum or minimum on the entire real line because its tails are unbounded.

Window endpoints can matter in a closed-interval absolute-extremum problem even when their derivatives are not zero. This tool lists those endpoint values separately, but does not certify the hypotheses needed for a closed-interval theorem or prove that every interior critical point was found. Comparing a few displayed values is not automatically a complete global optimization argument.

Retain stationary points that do not make a peak or valley

The function x³ has derivative 3x², which is zero at the origin but does not change sign there. The origin is stationary without being a local maximum or minimum. When such a point is sampled, it is kept in the other-stationary category instead of being forced into the maximum or minimum count.

A constant function has zero derivative wherever it is differentiable. It has non-strict local maxima and minima at every point, rather than a useful isolated list of turning points. When the symbolic derivative reduces to zero, the page states that situation explicitly. An empty isolated-candidate list must not be read as a claim that a constant function lacks non-strict extrema.

Treat scan density and root refinement as numerical evidence

A finite grid can miss a narrow feature or a root between samples that does not change sign. Rapid oscillations can also line up with the sampling pattern and hide extra extrema. Increasing the number of intervals provides another numerical view; it does not prove that the search is exhaustive.

A derivative sign change across a pole can resemble a root bracket. The refinement therefore checks a derivative residual before accepting a candidate, and known undefined evaluations interrupt brackets. Those checks reduce obvious false candidates but do not establish continuity between every sampled point. The graph likewise joins finite evaluations rather than certifying that the curve is smooth throughout each drawn segment.

Nondifferentiable extrema require separate analysis. Absolute value at zero is a familiar example: the function has a minimum but no ordinary derivative at its corner. This stationary-point search does not replace one-sided derivative, domain or cusp analysis.

Choose a mathematical model before a real-world objective

Optimization problems begin by identifying the quantity being optimized, its feasible domain, units and constraints. Entering a formula does not establish that it measures actual profit, physical cost or an attainable design. A detected local peak outside the feasible region is not a usable solution to the original practical problem.

The parabola vertex and axis of symmetry calculator solves a more specific quadratic geometry task analytically from coefficients. The Taylor polynomial calculator builds a local approximation from derivatives at a chosen center. Neither an approximate polynomial peak nor a visually attractive graph removes the need to check the original model and constraints.

The copied scenario and SVG export retain the entered function, interval and numerical candidate picture. Keep the scan density, derivative and search limitations with a shared result so a numerical exploration is not mistaken for a certified global optimum.

A few questions, answered

Does every zero derivative mean a maximum or minimum?

No. A stationary inflection such as x³ at zero has a zero derivative without a local extremum.

Can the search miss points?

Yes. Finite sampling can miss unsampled or unresolved stationary points and does not search every nondifferentiable extremum.

Are endpoints automatically local extrema?

No. They are listed as window endpoints and are separate from the two-sided interior sign test.

What happens for a constant function?

The page states that the derivative expression reduces to zero and does not manufacture a finite isolated-point list.

Is a reported candidate a certified global optimum?

No. Global optimization requires additional domain, completeness and model analysis.

Find your calculator

Start typing to explore the library.