MTH 343 · 4.5 Romberg integration
Apply the composite trapezoidal rule with n = 1, 2, 4, …, 2k−1 subintervals, then use Richardson's extrapolation again and again. Each new column of the Romberg table removes the next term of the error K1h2 + K2h4 + K3h6 + …, without any new function values.
Type 10^-6, 1e-6 or 0.000001.
A common way to decide when to stop adding rows: stop once two consecutive diagonal entries agree to within a tolerance. The last column of the table shows these differences, and the first row that passes gets a stop mark on Ri,i.
Row i uses n = 2i−1 subintervals. Click an entry to see how it is computed; the entries it is built from are outlined.
Each entry uses the entry to its left and the one above that: Ri,j = Ri,j−1 + (Ri,j−1 − Ri−1,j−1)/(4j−1 − 1). Column 1 is the composite trapezoidal rule with n = 2i−1. Column 2 equals the composite Simpson's rule with the same n, and column 3 the composite Boole's rule. The table is built row by row; a new row needs f only at the new midpoints. The last column is the stopping test: |Ri,i − Ri−1,i−1| for each row, with a check mark when it is below the tolerance.