Skip to content
LoveToCalc

Definition — what does that mean?

Midpoint rule

Cut the area into strips and give each a rectangle as high as the curve is in the middle of the strip.

In Swedish: Mittpunktsregeln

Midpoint rule

The relation

Mn=b−an(nΣi=1f(a+(i−12)·b−an))

Split [a, b] into n equal strips and replace each by a rectangle as high as the curve is at the strip’s midpoint.

A function of x, for example x^2, sin(x) or e^(-x)

Mn≈0.3281

M n equals ((1 minus 0) divided by 4) times (the sum for i from 1 to 4 of (0 plus ((i minus (1 divided by 2)) times ((1 minus 0) divided by 4))) squared), equals ((1 minus 0) divided by 4) times ((0 plus ((1 minus (1 divided by 2)) times ((1 minus 0) divided by 4))) squared plus (0 plus ((2 minus (1 divided by 2)) times ((1 minus 0) divided by 4))) squared plus (0 plus ((3 minus (1 divided by 2)) times ((1 minus 0) divided by 4))) squared plus (0 plus ((4 minus (1 divided by 2)) times ((1 minus 0) divided by 4))) squared), equals (1 divided by 4) times ((0 plus ((1 minus 0.5) times (1 divided by 4))) squared plus (0 plus ((2 minus 0.5) times (1 divided by 4))) squared plus (0 plus ((3 minus 0.5) times (1 divided by 4))) squared plus (0 plus ((4 minus 0.5) times (1 divided by 4))) squared), equals 0.25 times ((0 plus (0.5 times 0.25)) squared plus (0 plus (1.5 times 0.25)) squared plus (0 plus (2.5 times 0.25)) squared plus (0 plus (3.5 times 0.25)) squared), equals 0.25 times ((0 plus 0.125) squared plus (0 plus 0.375) squared plus (0 plus 0.625) squared plus (0 plus 0.875) squared), equals 0.25 times (0.125 squared plus 0.375 squared plus 0.625 squared plus 0.875 squared), is approximately 0.25 times (0.0156 plus 0.1406 plus 0.3906 plus 0.7656), equals 0.25 times 1.3125, is approximately 0.3281

Working9 steps

The formula

a and b are the limits, n the number of strips and h their width. The point a + (i − ½)h is the middle of strip number i. Type your own function into the card above and it adds the n rectangles.

Worked example: x² from 0 to 1

The exact answer is 1/3 ≈ 0.333 333. With n = 4 the strips are 0.25 wide and the midpoints are 0.125, 0.375, 0.625 and 0.875:

The rule undershoots here, by 0.005 208. The trapezoidal rule overshoots by 0.010 417 on the same strips, twice as much and in the other direction.

n Mn Error
2 0.3125 −0.020 833
4 0.328 125 −0.005 208
8 0.332 031 −0.001 302

The error

For a continuous f″ the error is at most (b − a)h² / 24 · max |f″(x)|, half the trapezoidal bound. The trapezoidal bound has the factor 12 where this has 24.

Common mistakes

Frequently asked questions

Why is it better than the left or right rule? The errors on either side of the midpoint cancel to first order, which leaves an error that shrinks with h².

Looking for another letter? The formula solved for each one
Solved for each letter
Solve forRearranged
Mnb−an(nΣi=1f(a+(i−12)·b−an))

Last reviewed October 11, 2026 ·How pages are reviewed

Calculate it in practice

CalculusAll formulas

Put this formula on your site

Copy the code into your page where the formula card should appear. It loads from lovetocalc.com, so it stays current on its own — all we ask is that the credit line comes with it.