Mean Value Theorem Calculator - Find c Step by Step

Use ^ for powers and functions like sin, cos, tan, ln, exp, sqrt, abs.

Constants work too: pi, 2pi, pi/2, e.

Try:

Results

The 2 values of c

-1.1547 (−√(4/3)), 1.1547 (√(4/3))

f(a) and f(b)

-2 2

Average rate of change (f(b)−f(a))/(b−a)

1

Derivative f′(x)

3x^2 − 3

Hypothesis check

f is continuous on [-2, 2]

Sampled 601 points across the closed interval — every value is finite and the graph has no jumps.

f is differentiable on (-2, 2)

f′ is finite everywhere strictly between the endpoints. Endpoint behaviour is deliberately ignored — the open interval is all the theorem asks for.

Step-by-step solution

  1. f(a) = f(-2) = -2
  2. f(b) = f(2) = 2
  3. Average rate of change = (f(b) − f(a))/(b − a) = (2 − -2)/(2 − -2) = 1
  4. f′(x) = 3x^2 − 3
  5. Set f′(c) = 1 and solve for c inside (-2, 2)
  6. c = -1.154700538 (−√(4/3)), 1.154700538 (√(4/3))
  7. Check: f′(-1.1547) = 1 = the secant slope ✓

Dashed gray: the secant through the endpoints. Blue: the tangent at each c, parallel to it.

a = -2b = 2c = -1.155c = 1.155

All 2 solutions in (-2, 2)

cExact formf(c)f′(c)
-1.15470054−√(4/3)1.92451
1.15470054√(4/3)-1.92451

How to Use This Calculator

  1. Pick the version you need in “Which theorem” — the plain Mean Value Theorem, Rolle’s Theorem, or the integral form.
  2. Type your function into “Function f(x)” using ^ for powers: x^3 - 3x, sqrt(x), ln(x), sin(2x).
  3. Enter the interval in “Left endpoint a” and “Right endpoint b”. Constants such as pi, 2pi and e are accepted.
  4. Read the hypothesis check before the answer — if continuity or differentiability fails, the theorem guarantees nothing, and the panel says exactly where it broke.
  5. Compare the step-by-step block with your own work, then use the graph to confirm each blue tangent really is parallel to the dashed secant.

Share this calculator

Help others solve their calculations

Found this calculator helpful? Share it with your friends, students, or colleagues who might need it!

Mean Value Theorem Calculator: How to Find the Point c Where Slopes Match

About the Author

Marko Šinko - Co-Founder & Lead Developer

Marko Šinko

Co-Founder & Lead Developer, AI Math Calculator

Lepoglava, Croatia
Advanced Algorithm Expert

Croatian developer with a Computer Science degree from University of Zagreb and expertise in advanced algorithms. Co-founder of award-winning projects, ensuring precise mathematical computations and reliable calculator tools.

📅 Published:
Mean value theorem calculator graph showing a secant line through the endpoints and a parallel tangent line at the point c

A mean value theorem calculator settles a question that sounds like traffic-court trivia: you covered 120 miles in two hours, so was there an instant when your speedometer read exactly 60? Yes — and that yes is a theorem, not a hunch. The Mean Value Theorem says a smooth curve must, somewhere strictly between its endpoints, have a tangent line parallel to the straight line joining them. The calculator above finds every such point c for you, prints f′(x) symbolically, and — the part most tools skip — audits whether the theorem even applies before it hands you a number. This article walks through the statement, the three hypotheses that quietly decide everything, two problems solved by hand, and the places where the theorem is doing far more work than a first-year student realises.

The Statement, and Why the Speeding Ticket Is Real

Formally: if f is continuous on the closed interval [a, b] and differentiable on the open interval (a, b), then there exists at least one c in (a, b) with

f′(c) = (f(b) − f(a)) / (b − a)

The right-hand side is nothing exotic. It’s the slope of the secant line through the two endpoints — the average rate of change across the whole trip. The left-hand side is the slope of the tangent line at one specific interior point: the instantaneous rate. So the theorem is a promise that average and instantaneous rates must agree somewhere. Average-speed enforcement cameras are built on precisely that promise. Two cameras 20 miles apart, a journey time of 15 minutes, and the arithmetic says your average was 80 mph — the theorem then guarantees a moment when the needle actually sat on 80.

Three Boxes to Tick Before You Trust the Answer

Notice the asymmetry in the statement, because it is not sloppy phrasing: continuity is demanded on the closed interval, differentiability only on the open one. That gap is deliberate and generous. Take f(x) = √x on [0, 4]. Its derivative 1/(2√x) explodes at x = 0, so the function has a vertical tangent right at the left endpoint — and the theorem still applies, because x = 0 is excluded from the open interval. Run it: the secant slope is (2 − 0)/4 = 1/2, and 1/(2√c) = 1/2 gives c = 1, comfortably inside.

Break either hypothesis in the interior, though, and the guarantee evaporates. Here is what failure actually looks like:

Function on the intervalSecant slopeWhat breaksDoes a c exist?
|x| on [−1, 1]0Corner at 0 — no derivative thereNo. f′ is −1 or +1, never 0
1/x on [−1, 1]1Infinite discontinuity at 0No. f′ = −1/x² is always negative
x^(1/3) on [−1, 1]1Vertical tangent at 0Yes — c = ±0.1925 anyway
√x on [0, 4]1/2Nothing — endpoint blow-up is legalYes, c = 1

That third row is the one worth memorising. The hypotheses are sufficient, not necessary: failing them means the theorem stops promising anything, not that no c exists. Plenty of badly behaved functions still happen to have a matching tangent. The calculator’s hypothesis panel reflects that distinction — a red mark means the guarantee is void, and any c it lists is a numerical find, not a theorem-backed one.

Solving x³ − 3x on [−2, 2] Without a Mean Value Theorem Calculator

Polynomials are continuous and differentiable everywhere, so the hypotheses are free. Start with the endpoints: f(−2) = −8 + 6 = −2 and f(2) = 8 − 6 = 2. The secant slope is therefore (2 − (−2)) / (2 − (−2)) = 4/4 = 1. Now differentiate — by hand, or with the derivative calculator — to get f′(x) = 3x² − 3, and set it equal to that slope:

3c² − 3 = 1

3c² = 4

c² = 4/3

c = ±2/√3 ≈ ±1.1547

Both roots sit inside (−2, 2), so this interval has two valid answers. Students routinely lose marks here by solving the quadratic, finding two roots, and reporting only the positive one. The theorem promises at least one c; a polynomial of degree n can deliver up to n − 1 of them, and every root that lands strictly inside the interval counts. Roots that fall outside get discarded — that filtering step is the whole reason the answer depends on the interval and not just on f.

Second example, deliberately different in flavour. For f(x) = 1/x on [1, 3], the endpoints give f(1) = 1 and f(3) = 1/3, so the secant slope is (1/3 − 1)/2 = −1/3. With f′(x) = −1/x², solving −1/c² = −1/3 gives c² = 3 and c = √3 ≈ 1.732. Note where that lands: not at the midpoint 2, but pulled left, toward the steeper part of the curve. That asymmetry is typical, and it is the reason no general formula for c exists.

Rolle’s Theorem Is the Same Statement, Tilted

Rolle’s Theorem is the special case where the endpoints sit at the same height: if f(a) = f(b), then some interior c has f′(c) = 0 — a horizontal tangent. It looks weaker. It is actually the engine that proves the general version, and the proof fits in two lines. Subtract the secant line from f:

g(x) = f(x) − [ f(a) + m(x − a) ], where m = (f(b) − f(a))/(b − a)

g(a) = g(b) = 0 → Rolle gives g′(c) = 0 → f′(c) = m

Tilting the picture until the secant is flat turns any Mean Value Theorem problem into a Rolle problem. Try the classic: f(x) = x² − 4x + 3 on [1, 3]. Both endpoints evaluate to 0, so Rolle applies, and f′(x) = 2x − 4 = 0 gives c = 2 — the vertex of the parabola, which is exactly where you would expect the tangent to go flat. Every Rolle point is an interior critical point, so the two topics are really one topic seen from different angles. If you switch the calculator to Rolle mode with mismatched endpoints, it will say so plainly rather than quietly returning critical points as though they were Rolle points.

The Integral Version Trades a Slope for a Height

There is a second theorem wearing the same name, and confusing the two costs exam marks every year. The Mean Value Theorem for Integrals says: if f is continuous on [a, b], then some c in (a, b) satisfies

f(c) = (1/(b − a)) · ∫ from a to b of f(x) dx

No derivative appears anywhere, so continuity is the only hypothesis — a genuinely lighter requirement. Geometrically, it says a rectangle of width (b − a) and height f(c) has exactly the same area as the region under the curve. The function reaches its own average value at least once.

Work f(x) = x² on [0, 3]. The definite integral is x³/3 evaluated from 0 to 3, which is 9. Divide by the width: the average value is 9/3 = 3. Now solve c² = 3, giving c = √3 ≈ 1.732. The midpoint of [0, 3] is 1.5, so once again c is not the middle — a guess that only works when f is linear, because only then is the curve symmetric about its own average. Switch the calculator to integral mode and the graph makes the equality visible: the shaded area under the parabola and the blue rectangle at height 3 cover the same amount of space.

What the Theorem Refuses to Tell You

The Mean Value Theorem is an existence theorem, and existence theorems are famously tight-lipped. Three limits are worth knowing before you lean on it:

  • It never tells you where c is. For polynomials you can solve for it, but for f(x) = x + sin(x) on [0, 5] you are reduced to numerical root-finding — which is exactly what the calculator does under the hood after printing f′(x).
  • It never tells you how many c values there are. One is guaranteed; sin(x) on [0, 4π] has four. The count depends on how many times f′ crosses the secant slope, not on the theorem.
  • It fails for vector-valued functions. Take the path (cos t, sin t) on [0, 2π]. Start and end coincide, so the “secant slope” is the zero vector, yet the velocity vector (−sin t, cos t) has length 1 at every single instant and is never zero. A point moving round a circle never stops, no matter how you slice the trip. The one-dimensional theorem simply does not survive the jump to higher dimensions.

There is also a quiet dependence worth noticing: c moves when the interval moves. Shrink b toward a and the c trapped between them has nowhere to go but toward a as well. That squeeze is not a curiosity — it is the seed of the Lagrange remainder in Taylor’s theorem, where the unknown c hides inside the error term for exactly this reason.

Where the Mean Value Theorem Does Real Work

Textbooks present the MVT as a chapter to survive, then rely on it silently for the rest of the course. A few of the debts:

  • Why “+ C” is legitimate. If f′(x) = 0 across an interval, then for any two points the MVT forces f(b) − f(a) = 0·(b − a) = 0, so f is constant. Two antiderivatives of the same function therefore differ by a constant — the fact every indefinite integral quietly depends on.
  • Why a positive derivative means increasing. Same argument with f′ > 0 makes f(b) − f(a) positive whenever b > a. That is the first-derivative test, and pairing it with the second derivative gives you the full concavity picture.
  • Error bounds in numerical work. Rearranged, the theorem reads |f(b) − f(a)| ≤ M·(b − a) where M bounds |f′|. That Lipschitz-style estimate is how step-size error gets bounded in Euler’s method and how the remainder term in a Taylor series is controlled.
  • The proof of L’Hôpital’s rule. Cauchy’s Mean Value Theorem — the two-function generalisation where f′(c)/g′(c) equals the ratio of the two secant slopes — is what makes L’Hôpital’s rule valid rather than merely convenient.

None of that requires you to ever locate c. The theorem earns its keep by guaranteeing that some c exists, and then letting the inequality do the rest. For the historical route from Rolle’s 1691 result to the modern statement, the Wikipedia entry on the mean value theorem traces the full lineage, including the Cauchy and integral variants.

Frequently Asked Questions

Still Have Questions?

The detailed content on this page provides comprehensive explanations and examples to help you understand better.