Abstract. Radial basis function (RBF) approximation is an extremely powerful tool for representing smooth functions in non-trivial geometries, since the method is meshfree and can be spectrally accurate. A perceived practical obstacle is that the interpolation matrix becomes increasingly illconditioned as the RBF shape parameter becomes small, corresponding to flat RBFs. Two stable approaches that overcome this problem exist, the Contour-Padé method and the RBF-QR method. However, the former is limited to small node sets and the latter has until now only been formulated for the surface of the sphere. This paper focuses on an RBF-QR formulation for node sets in 1-D, 2-D, and 3-D. The algorithm is stable for arbitrarily small shape parameters. It can be used for thousands of node points in 2-D and more still in 3-D. A sample matlab code for the 2-D case is provided. Key words. RBF, radial basis function, ill-conditioning, shape parameter, stable AMS subject classifications. 65D05, 65D15, 65F35 1. Introduction. When using RBFs (radial basis functions), the best accuracy is often achieved when their shape parameter ε is small, meaning that the basis functions are relatively flat. It was for a number of years mistakenly believed by many RBF practitioners that this computational regime inevitably was associated with numerical ill-conditioning when, in fact, the only thing that was ill-conditioned was the most immediate numerical algorithm (denoted RBF-Direct in some of the current literature). So far, only two numerical algorithms have been presented that are able to compute stably even in the ε → 0 (increasingly flat) basis function limit: the Contour-Padé method [13] (see [15] for the significantly improved RBF-RA version) and the RBF-QR method [11] . These two methods are based on different principles, and have different limitations. The Contour-Padé/RBF-RA method is limited to a relatively low number of RBF nodes (N slightly less than a hundred in 2-D, more in 3-D). The RBF-QR algorithm has previously been developed only for the case when the nodes are distributed over the surface of a sphere, then allowing N -values in the thousands. The present paper describes how the RBF-QR approach can also be implemented for general domains in 1-D, 2-D and 3-D. With quasi-uniform nodes, the algorithm works well for tens of points in 1-D, hundreds of points in 2-D, and thousands of points in 3-D using double precision arithmetics. Using quad precision increases the ranges significantly. We can for example solve for N = 2700 points in 2-D retaining full double precision accuracy [8] . With quasi-uniform node distributions, errors in typical RBF implementations will eventually grow with the number of nodes for two reasons (i) increasing condition number, and (ii) an intrinsic ill-conditioning of spectrally accurate methods on quasi-uniform node sets leading to large errors near
The same pattern also occurs in the coefficients of the orthogonal expansion in the RBF-QR method proposed in REF .
Stable computations with Gaussian radial basis functions in 2-D
Mathematics Computer Science