Skip to main content

Numerical Integration in Arbitrary-Precision Ball Arithmetic

  • Conference paper
  • First Online:
Mathematical Software – ICMS 2018 (ICMS 2018)

Part of the book series: Lecture Notes in Computer Science ((LNTCS,volume 10931))

Included in the following conference series:

Abstract

We present an implementation of arbitrary-precision numerical integration with rigorous error bounds in the Arb library. Rapid convergence is ensured for piecewise complex analytic integrals by use of the Petras algorithm, which combines adaptive bisection with adaptive Gaussian quadrature where error bounds are determined via complex magnitudes without evaluating derivatives. The code is general, easy to use, and efficient, often outperforming existing non-rigorous software.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 39.99
Price excludes VAT (USA)
  • Available as EPUB and PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 54.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Notes

  1. 1.

    Arb (http://arblib.org) is open source (GNU LGPL) software. For documentation and example code related to this paper, see http://arblib.org/acb_calc.html.

  2. 2.

    Clenshaw-Curtis or double exponential quadrature could be used instead of Gaussian quadrature, but typically require more points for equivalent accuracy. We could also use Taylor series, but this makes supplying f more cumbersome for the user, and computing \(f,f'\ldots ,f^{(n)}\) tends to be more costly than n evaluations of f.

  3. 3.

    In benchmark results, we omit the first-time nodes precomputation overhead.

  4. 4.

    For example, mpmath provides quadgl for Gaussian quadrature, which is 2–3 times faster on some examples, but its precomputations are prohibitive at high precision.

  5. 5.

    An exception is when f has an essential singularity inducing oscillation combined with slow decay. Oscillation with exponential decay is not a problem (as in \(E_4\)\(E_5\)), but integrals like \(\smash {\int _0^1\!\sin (1/x) dx \!=\! \int _1^{\infty } \!\sin (x)/x^2}\) (not benchmarked here) require \(\smash {2^{O(p)}\!}\) work, so we can only hope for 5–10 digits without specialized oscillatory algorithms.

  6. 6.

    As a means to improve performance, we note the standard trick of manually changing variables to turn algebraic growth or decay into exponential decay. Indeed, \(x \rightarrow \sinh (x)\) gives \(E_1 = E_3\). Similarly \(x \rightarrow \tanh (x)\) and \(\smash {x \rightarrow e^{-x}}\) can be used in \(E_0\), \(E_2\).

  7. 7.

    This works for integrating |f| when f is real, but since \(|\cdot |\) on \(\mathbb {C}\) is not holomorphic, integrating |f| for nonreal f must use direct enclosures, with \(2^{O(p)}\) cost. In that case, the user should instead construct complex-extensible real and imaginary parts \(f = g\!+\!h i\) (e.g. via Taylor polynomials if no closed forms exist) and integrate \(\sqrt{g^2 + h^2}\).

References

  1. Bailey, D.H., Borwein, J.M.: High-precision numerical integration: progress and challenges. J. Symbolic Comput. 46(7), 741–754 (2011)

    Article  MathSciNet  Google Scholar 

  2. Cranley, R., Patterson, T.N.L.: On the automatic numerical evaluation of definite integrals. Comput. J. 14(2), 189–198 (1971)

    Article  MathSciNet  Google Scholar 

  3. Hale, N.: Spike integral (2010). http://www.chebfun.org/examples/quad/SpikeIntegral.html

  4. Johansson, F.: Arb: efficient arbitrary-precision midpoint-radius interval arithmetic. IEEE Trans. Comput. 66, 1281–1292 (2017)

    Article  MathSciNet  Google Scholar 

  5. Johansson, F.: mpmath version 1.0 (2017). http://mpmath.org/

  6. Johansson, F., Mezzarobba, M.: Fast and rigorous arbitrary-precision computation of Gauss-Legendre quadrature nodes and weights (2018). arXiv:1802.03948

  7. Mahboubi, A., Melquiond, G., Sibut-Pinote, T.: Formally verified approximations of definite integrals. In: Blanchette, J.C., Merz, S. (eds.) ITP 2016. LNCS, vol. 9807, pp. 274–289. Springer, Cham (2016). https://doi.org/10.1007/978-3-319-43144-4_17

    Chapter  Google Scholar 

  8. Petras, K.: Self-validating integration and approximation of piecewise analytic functions. J. Comp. Appl. Math. 145(2), 345–359 (2002)

    Article  MathSciNet  Google Scholar 

  9. Rump, S.M.: Verification methods: rigorous results using floating-point arithmetic. Acta Numerica 19, 287–449 (2010)

    Article  MathSciNet  Google Scholar 

  10. The Pari group. Pari/GP version 2.9.4 (2017). http://pari.math.u-bordeaux.fr/

  11. The SageMath developers. SageMath version 8.2 (2018). http://sagemath.org/

Download references

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Fredrik Johansson .

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2018 Springer International Publishing AG, part of Springer Nature

About this paper

Check for updates. Verify currency and authenticity via CrossMark

Cite this paper

Johansson, F. (2018). Numerical Integration in Arbitrary-Precision Ball Arithmetic. In: Davenport, J., Kauers, M., Labahn, G., Urban, J. (eds) Mathematical Software – ICMS 2018. ICMS 2018. Lecture Notes in Computer Science(), vol 10931. Springer, Cham. https://doi.org/10.1007/978-3-319-96418-8_30

Download citation

  • DOI: https://doi.org/10.1007/978-3-319-96418-8_30

  • Published:

  • Publisher Name: Springer, Cham

  • Print ISBN: 978-3-319-96417-1

  • Online ISBN: 978-3-319-96418-8

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics