3
$\begingroup$

For periodic functions on a regularly spaced grid, the trapezoidal rule is supposed to converge incredibly quickly ( the error estimate decreasing as $O(e^{-\eta/h})$ for step size $h$ ).

However, I don't believe this is true for non-uniform grids. What is the error estimate for a non-uniform grid, and how does it converge? (specifically for a logarithmic grid, but more generally if possible).

$\endgroup$
  • $\begingroup$ Why would you use a logarithmic grid for a periodic function? Could you describe in a bit more detail what it is you want to do, and what you hope to achieve with it? $\endgroup$ – Pedro Feb 11 '14 at 22:16
  • $\begingroup$ @Pedro: I calculate a series of eigenvectors for a differential equation on a logarithmic grid (the differential equation has a singularity at r = 0, so the logarithmic grid helps to make it easier to calculate near the singularity). However, the positive eigenvalues (which are calculated on a logarithmic grid), are periodic, and I need to calculate the integral of products of these eigenvectors. ($\int_0^{\infty} f1(r)\; r\; f2(r)\; dr$). Besides all that though, I'm just curious about the error estimate qualities of the trapezoidal rule on a non-uniform grid. $\endgroup$ – Andrew Spott Feb 11 '14 at 23:51
  • $\begingroup$ @Pedro: see scicomp.stackexchange.com/questions/10741/… for the specific problem I'm having. $\endgroup$ – Andrew Spott Feb 11 '14 at 23:53
3
$\begingroup$

The trapezoidal rule is an interpolating quadrature where you incur an error on each interval that is independent from that of other intervals. In particular, if you have a set of disjoint intervals $I_i$ of size $h_i$ so that $\bigcup_i I_i = I=[a,b]$ is the interval that you want to integrate over, then the total error is given by an expression of the form $$ e = \sum_i h_i^3 \zeta_i $$ where $\zeta_i$ is a measure of the second derivative of your integrand on interval $i$. In particular, if the function is linear, then the error is zero. Also, since the number of intervals is proportional to $1/h$ in the case of a uniform mesh, you get an error bound of the form $$ e = {\cal O}(h^2). $$

| cite | improve this answer | |
$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.