[ANN] RationalFunctionApproximation.jl, v0.2

I am pleased to announce a new version of RationalFunctionApproximation.jl, a package for the automatic approximation of functions by ratios of polynomials.

Unlike polynomials, rational function interpolants can use arbitrary node locations at high degree without suffering from Runge instability. The approximations can be made accurate to ten digits or more on arbitrary domains in the complex plane, in addition to ordinary intervals, even for functions that have nearly singular behavior.

In addition to the continuum AAA algorithm that was implemented in v0.1, the package now offers (1) linear least-squares approximation with prescribed poles (a la Trefethen and Costa) and (2) an implementation of the greedy Thiele continued-fraction interpolation suggested by Celis. The latter is interesting as an O(n^2) alternative to the O(n^4) runtime of AAA, although its stability is less consistent at the moment.

In addition, the package plays nicely with extended precision and is easily called from Python.

I invite you to check the documentation. Enjoy!

The RationalFunctionApproximation.jl package is now at version 0.4.0. Changes over the past year+ have brought many speed improvements, especially to the Thiele continued fraction implementation.

Continued fractions are now 8-40 times faster than AAA across a wide range of experiments, and they have become the default choice in the package. There is also a Python interface via JuliaCall. The RFA implementation of the AAA algorithm seems to be about twice as fast as the SciPy implementation—with continued fractions comfortably faster than both.

Thanks for making this package. I am quite interested the new algorithms. Can you give more information?

BTW, it seems some citations in the algorithm page Algorithms | RationalFunctionApproximation.jl have wrong numbers, like [6] should be [7]?

I’d not seen this package before but it looks really interesting. My work involves representing reaction kinetics as rational functions so having a tool to approximate arbitrary functions in the same form is potentially very useful.

Oof. Seems like I have a problem with DocumenterCitations. Thanks for the heads-up.

For the continued fractions, you can look at this preprint. There’s are older papers cited there that deal with the more technical aspects of the theory, before the stability of the new approach to selecting nodes was appreciated.