A Fast Method for the Off-Boundary Evaluation of Laplace Layer Potentials by Convolution Sums

: In off-boundary computations of layer potentials, the near-singularities in integrals near the boundary presents challenges for conventional quadrature methods in achieving high precision. Additionally, the significant complexity of O ( n 2 ) interactions between n targets and n sources reduces the efficiency of these methods. A fast and accurate numerical algorithm is presented for computing the Laplace layer potentials on a circle with a boundary described by a polar curve. This method can maintain high precision even when evaluating targets located at a close distance from the boundary. The radial symmetry of the integral kernels simplifies their description. By exploiting the polar form of the boundary and applying a one-dimensional exponential sum approximation along the radial direction, an approximation of layer potentials by the convolution sum is obtained. The algorithm uses FFT convolution to accelerate computation and employs a local quadrature to maintain accuracy for nearly singular terms. Consequently, it achieves spectral accuracy in regions outside of a sufficiently small neighborhood of the boundary and requires O ( n log n ) arithmetic operations. With the help of this algorithm, layer potentials can be efficiently evaluated on a computational domain.


Introduction
The boundary integral equation (BIE) method is attractive for addressing boundary value problems of partial differential equations (PDEs) like the Laplace equation [1,2], Helmholtz equation [3], biharmonic equation [4], and other classical elliptic equations in mathematical physics.It offers a number of numerically attractive properties, including reducing the dimension of the computational problem by one, enabling boundary-only discretizations for homogeneous problems, and being well-suited for problems involving infinite or semi-infinite domains.Moreover, the BIE method is widely applied in physics and engineering, including inverse acoustic and electromagnetic scattering problems [3], multimedia elasticity problems [5], wetting problems [6], Navier-Stokes equations [7,8], etc.
The BIE method seems to have less advantage in accuracy and computational complexity when it recovers the solutions of boundary value problems from the BIE solutions, requiring the evaluation of layer potentials both near and away from the source layer.This off-boundary evaluation, particularly with complex boundaries, presents two numerical challenges: 1.The accuracy of conventional quadrature methods diminishes rapidly as the target point approaches the boundary due to the near-singularity of boundary integrals.2. There is significant computing complexity for the O(n 2 ) interactions between n targets and n sources.To address the computational challenges posed by nearly singular integrals, many innovative computational methods have been proposed.These methods include quadrature by expansion [9][10][11][12], asymptotic approximation methods [13][14][15], barycentric-type formulas leveraging Cauchy's integral formula [16,17], singularity swapping methods [18,19], kernel regularization methods [20,21], a method using the Stokes theorem [22], nonlinear transformation methods [23,24], etc.However, due to the reliance of computations on target points, most of these methods are rarely developed into fast methods that are capable of facilitating the evaluation of O(n 2 ) interactions in linear or quasi-linear (linear up to a logarithmic factor) time.The scheme based on coupling quadrature by expansion and a fast multipole method [25,26] is one such fast algorithm that is capable of accurately computing layer potentials near boundaries.Nevertheless, in order to overcome extra geometry refinement, this scheme needs to be carefully designed in cases for which some parts of the source geometry come so close to other parts that they almost touch each other [25].
In this paper, we propose a fast and accurate numerical algorithm for computing the layer potentials for Laplace equations.This method requires only quasi-linear computational costs and still achieves high precision in regions that exclude a sufficiently small neighborhood of the boundary.Moreover, it permits discontinuities of layer potentials in the field across the boundary and is capable of handling cases for which some parts of the source geometry are close to other parts without too much additional work.Consider the surface integral operator A : L 2 (Γ 1 ) → L 2 (Γ 2 ) defined by where Γ 1 , Γ 2 ⊂ R 2 are simple closed curves and are of class C 2 , f ∈ L 2 (Γ 1 ) is a density function, and K is defined and continuous for all x ∈ Γ 2 , y ∈ Γ 1 , x ̸ = y.Many numerical applications of boundary integral equation methods require the computation of A f .For instance, solutions to boundary integral equations are frequently used to evaluate singleand double-layer potentials for applications in a broad range of simulations in physics and engineering.In addition, the application of Tikhonov regularization to solve boundary value problems using potentials with densities on curves different from the actual boundary of the underlying domain also necessitates the evaluation of A f [1].For cases wherein Γ 1 is a closed polar curve and Γ 2 is an origin-centered circle, two algorithm are presented in this paper.Notice that the integral kernel K for Laplace equations in (1) can be expressed as a product of a singular part and a finite sum of separable functions.In order to construct a fast method, we concentrate on approximating the singular part using convolution sums.Due to the radial symmetry of the singular part, this only requires approximation along the radial direction.By utilizing the polar form of Γ 1 , Γ 2 and applying exponential sum approximations to the singular part along the radial direction [27], we derive an efficient approximation using convolution sums.An error estimate for this approximation is provided in this paper.Leveraging this efficient approximation, we propose algorithms for computing the layer potentials for Laplace equations with a computational complexity of O(n log n) for the evaluation of O(n 2 ) interactions.Currently, there are few fast layer methods capable of accurately computing potentials near boundaries, among which an important one is the fast QBX method [25,26].Our proposed method also efficiently handles such cases.Unlike the fast QBX, our method does not require handling of the boundary partition.As noted in the summary of [25], some situations, such as when some parts of the source geometry come close to other parts, often require extra geometry refinement.
Our method effectively addresses such cases.Moreover, this method accommodates discontinuities in the field across the boundary, which is a feature that is not commonly addressed by existing methods.The structure of this paper is as follows.Section 2 introduces the approximation of A f by convolution sums and provides an analysis of the approximation error.We then propose two algorithms based on the approximation.Subsequently, in Section 3, we present some numerical experiments to examine the performance of the algorithms.Finally, we provide conclusions about the proposed methods and discuss their drawbacks in Section 4.

Fast Methods for the Evaluation of Layer Potentials
The kernel K of the integral (1) can be expressed as (2) In the context of certain layer potentials, such as those for the Laplace, biharmonic, and Stokes equations [1,4,28], the function ψ : Γ 2 × Γ 1 → C can be represented as a finite sum of separable functions.Specifically, ψ(x, y) = ∑ or ϕ is homogeneous of γ ∈ R; meaning that for all α > 0, or ϕ is a linear combination of a logarithmic function, a homogeneous function, and their products, as is the case for the biharmonic equation [4].In the case of the Laplace equation, the kernel for the single-layer potential can be expressed as (2), with ψ(x, y) ≡ 1 and ϕ(x) = − 1 4π log x.Similarly, the kernel for the double-layer potential can also be represented as (2), with ψ(x, y) = (y − x) • v(y), and ϕ(x) = − 1 2πx , where v(y) is the unit outer normal vector perpendicular to the curve Γ 1 at y.To handle other kernels for equations like the Helmholtz equation [3,9], the singularity subtraction method is often used.This involves splitting the kernel into two parts: K 1 , which has the same leading-order singularity as K, and a smoother function K − K 1 , which is easier to integrate numerically.The singular kernel K 1 often has the form (2). In this paper, we focus on the evaluation of the single-and double-layer potentials for the Laplace equation.
In the subsequent sections of this paper, we suppose that Γ 1 in (1) is a boundary of a star domain and is described by the parametrization r(t) := (r(t) cos(t), r(t) sin(t)), t ∈ where r is a twice-differentiable, 2π-periodic, positive function defined on R. We suppose that Γ 2 in (1) is a circle with a radius R > 0 defined by The assumption of polar parameterization is made here to enable the squared distance function to take a form that closely resembles a convolution, as expressed in (5).This form of the squared distance function is used to construct the layer potential in the form of convolution sums, with ϕ approximated by exponential sums.With the parametrizations (3) and ( 4), let us define where f (θ To ensure clarity, we adopt this definition of A : L 2 (Γ 1 ) → L 2 (I 2π ) throughout the subsequent discussions.It is important to note that when Γ 1 ∩ Γ 2 = ∅, meaning that the targets are distant from the sources, the layer potential A f is smooth.However, due to the jump relations of the layer potential across the boundary, when Γ 1 ∩ Γ 2 ̸ = ∅, A f is not smooth.Specifically, in the case of the Laplace single-layer potential, the derivative of A f is discontinuous at the intersection of Γ 1 and Γ 2 , and in the case of the Laplace double-layer potential, A f itself is discontinuous at the intersection [1].

An Approximation of A f by Convolution Sums
In this subsection, we propose an approximation of A f by convolution sums, which regularizes A f and is utilized in the development of a fast algorithm in the next subsection.With the parametrizations (3) and (4), we write the square of the distance function between the points at Γ 1 and Γ 2 as In order to utilize the exponential sum approximation described in the following content, we rewrite d(η, θ) as where with β > 0 denoting a scale parameter.
For the case of the Laplace single-layer potential, from ψ = 1 and ϕ(x) = − 1 4π log x in (2), it follows that According to Appendix A.1, the function ϕ can be approximated by M-term exponential sums on [1, ∞).This approximation is based on the techniques described in [27] and is given by where a k , b k , c k ∈ R, a 0 = log 2, and a k > 0 decreases with respect to k. Selecting an appropriate β and replacing ϕ in the first term on the right-hand side of ( 6) with ϕ M yields the approximation for the Laplace single-layer potential: The first term on the right-hand side of (8) can be represented as a sum of periodic convolutions, and this approximation is expressed as follows: where and I M,β f := For the case of the Laplace double-layer potential, from ψ(x, y) = (y where n(θ) := v(r(θ)).Here, the function ϕ can be approximated by M-term exponential sums: on [1, ∞), where a k , ck are defined in Appendix A.2. Similar to the evaluation method employed for the Laplace single-layer potential, replacing ϕ in (10) with ϕ M gives The function D M,β f can be rewritten as where f1 := n • r f /d 2,β , f2 := n f /d 2,β , and µ k,β , ω k,β are defined in (9).Notice that in higher dimensions, the principal singularity of the Laplace layer potential remains radially symmetric.Therefore, it suffices to work with exponential approximations of ϕ to develop higher-dimensional convolution approximations.
For convenience, we denote the operator A M,β = S M,β for the Laplace single-layer potential and A M,β = D M,β for the Laplace double-layer potential.It is noteworthy that A M,β f exhibits smoothness and approximates A f notably well at points distant from Γ 1 .The parameter M controls the accuracy of approximation, while β determines the distance from Γ 1 for approximating A f .Hence, A M,β f serves as regularization for A f and is governed by the parameters M and β.In Sections 2.3 and 2.4, we propose methods for computing A M,β f .Preceding that, in the upcoming section, we estimate the error between A M,β f and A f , which is referred to as the smoothing error in this paper.

The Smoothing Error
In this section, we estimate the smoothing error Rr max with some λ > 0 in (8), and r max := max θ∈I 2π r(θ).In order to present the smoothing error estimate, we define r min := min θ∈I 2π r(θ) and introduce the notation ∥g∥ ∞,H := sup x∈H |g(x)|, H ⊂ [1, ∞), for a continuous function g defined on [1, ∞).The next two theorems present the smoothing error estimate for the Laplace singleand double-layer potentials.The proofs of these theorems are in Appendix B.
Theorem 1.In the case of the Laplace single-layer potential, there exist positive constants In the case of the Laplace double-layer potential, there exist positive constants C 1 , C 2 such that for all λ, R > 0, M ∈ Z + and f ∈ L 2 (Γ 1 ), by choosing h = log(4πM)/M and Theorems 1 and 2 indicate that the smoothing error of A M,β f decreases exponentially on Γ 2 \Γ 1,λ as the parameters M and β increase.In these theorems, the selection strategy of h is based on the Sinc quadrature error estimates from Proposition 2.1 in [27], ensuring the exponential decay of the smoothing error with M. Notice that the second term on the right-hand side of ( 12) and (13) depends on s, and s = λ 2 /(βRr max ).Selecting a sufficiently small β ensures this second term becomes negligible.We choose β = λ 2 /(50Rr max ) to ensure 2 −s = 2 −50 ≈ 8.9 × 10 −16 , nearly reaching double precision relative to the machine epsilon.Thus, the second term on the right-hand side of ( 12) and ( 13) can be ignored relative to the first term within machine precision.The choice of β also determines ι = 50(R + r max ) 2 r max /(λ 2 r min ), which increases as λ decreases.Thus, in order to ensure that the first term on the right-hand side of ( 12) and ( 13) is sufficiently small, an appropriate value of M needs to be found based on ι.Theorem 1 suggests that selecting M = C(log ι) + (log ι) 2 with a positive constant C ensures the smoothing error in cases for which the single-layer potential remains bounded regardless of ι and λ.In addition, Theorem 2 suggests M = C(log ι) for the double-layer potential.In summary, in this paper, we select β = λ 2 /(50Rr max ), M = −C s (log β) + (log β) 2 for the single-layer potential and M = −C d (log β) for the double-layer potential, where C s , C d > 0 .

A Method for Computing A M,β f Using FFT Convolution
The function A M,β f , introduced in Section 2.1 for both the single-and double-layer potential cases, takes the form ], B M,β = 0 for the Laplace double potential.Notice that A M,β f consists of a periodic convolution sum.It is well known that applying the FFT convolution method leads to a fast evaluation of A M,β f .Denote We next present an estimate of the computational costs of Algorithm 1.Let M M,n denote the number of multiplications used in Algorithm 1.
Algorithm 1 An algorithm for computing A M,β f using n-point FFT convolution.
Input: M, n ∈ Z + , β, R > 0, a function f on S n , and r, |r ′ | defined on I 2π,n .Output: Approximate values of A M,β f on T R,n .
Step 2: Compute the integral B M,β using the n-point periodic trapezoidal rule.
Step 3: Compute the approximate values of Denote the output of Algorithm 1 as A M,β,FFT f (T R,n ).The computational error A f (T R,n ) − A M,β,FFT f (T R,n ) comprises both the smoothing error and the error in con- volution computation.We estimated the smoothing error in Γ 2 \Γ 1,λ in Section 2.2.We turn to discuss the convolution error.The aliasing error of the discrete Fourier transform and the truncation error of the Fourier series contribute to the convolution error when using FFT.The decay rates of the coefficients of the Fourier series of µ k,β and ω k,β g determine this convolution computation error.It is important to note that as β decreases, the decay rates of µ k,β and ω k,β g also decrease, as illustrated in Figure 1, indicating the near-singularity of the layer potential.This leads to a decrease in the accuracy of computing the convolution using the n-point FFT.Indeed, when a k /β is large, µ k,β (x) ≈ ∑ j∈Z G a k /β (x + 2jπ) for x ∈ R, where G a k /β := exp −a k x 2 /β .According to the Fourier transform of G a k /β , the jth Fourier coefficient of ∑ j∈Z G a k /β (x + 2jπ) is β/(2a k )exp −βj 2 /(4a k ) .Therefore, the Fourier coefficients of µ k,β decay nearly as O exp −βj 2 /(4a k ) .

An Improved Method for Computing A M,β f
In order to avoid inaccuracies in the computation of µ σ * (ω σ g) in ( 14) using the FFT convolution method with very small β values, we directly evaluate it using local quadrature methods.Let g ∈ L 1 (I 2π ) and σ ≥ 0. We define the periodic convolution as follows: where Rr(θ) , θ ∈ R.
The form (14) can be rewritten as We now address the computation of C σ g with large values of σ.Suppose C σ g can be accurately computed using the FFT convolution method with σ ≤ σ 0 for a sufficiently large σ 0 .Note that the function µ σ exhibits a sharp peak at θ = 0 with a large σ.Thus, instead of the convolution method, we apply the Gauss quadrature to C σ g.For the machine epsilon ϵ > 0, we define Here, we set Applying the m-point Gauss quadrature to the above integral, denoted by C m σ g(η), provides an evaluation of C σ g(η).Here, the values of g at the quadrature points can be obtained by the Fourier interpolation from g(S n ).This process can be accelerated by converting the Fourier interpolation to B-spline interpolation, allowing for the computation of the m quadrature points in linear time.We also write C m σ g(x), x = c R (η) in place of C m σ g(η) for simplicity.Given a continuous function g and a point x, C σ g(x) decays with respect to σ, as illustrated in Figure 2a. Figure 2b-d illustrate the relative error of the Gauss-Chebyshev quadrature against σ with 25, 40, and 55 integral points, respectively.As the number of integral points increases, the relative error decreases.In addition, the relative error remains bounded within a certain range of σ, indicating that the absolute error decays with respect to σ.This demonstrates that C σ g(x) with a large σ can be efficiently computed using the Gauss quadrature.Furthermore, due to the rapid decay of the integrand with a large σ, we neglect computing C m σ g at the points x in Γ 2 such that dist(x, Γ 1 ) > C ϵ √ Rr max /σ for the machine epsilon. Let ), and M x = 0 if x ≥ a 0 .The Algorithm 2 derived from the above discussion is as follows: Algorithm 2 An algorithm using the n-point FFT convolution and the m-point Gauss quadrature.
Input: M, m, n ∈ Z + , β, σ 0 , R > 0, a function f on S n , and r, |r ′ | defined on I 2π,n .Output: Approximate values of A M,β f on T R,n .
Step 1: Compute the periodic convolution of C a k β g(T R,n ) using the n-point FFT method, denoted as I k,β (T R,n ), for k = M βσ 0 , . . ., M.
Step 2: Compute Q m k g(T R,n ) by the Gauss quadrature for k = 0, . . ., Step 3: Compute the integral B M,β using the n-point periodic trapezoidal rule.
Step 4: Compute the approximate values of A M,β f on T R,n by To close this section, we present an estimate of the computational costs of Algorithm 2. Let M Q M,m,n,βσ 0 denote the number of multiplications used in Algorithm 2. Theorem 4.There exists C > 0 such that for all R, β, σ 0 > 0 and M, m, n ∈ Z + , In the next section, the performances of the periodic trapezoidal rule and Algorithms 1 and 2 are presented.The periodic trapezoidal rule is a straightforward quadrature method to implement.This quadrature is exponentially accurate for computing real analytic functions [29].Thus, it has high accuracy in computing layer potentials that are far from boundaries.However, when computing layer potentials near boundaries, the method converges very slowly due to the near-singularity of the integral.Additionally, its complexity is O(n 2 ) for computing interactions between n targets and n sources.Theorem 3 indicates that Algorithm 1 has a complexity of O(n log n).However, as discussed in Section 2.3, the convolution error for the nearly singular terms leads to inaccuracy near the boundary, similar to the periodic trapezoidal rule.Algorithm 2 improves the accuracy near the boundary by using the local Gauss quadrature for the nearly singular terms instead of the FFT convolution method .Moreover, Theorem 4 indicates that Algorithm 2 still maintains a complexity of O(n log n).

Numerical Experiments
In this section, we present illustrative examples demonstrating the performance of the methods by evaluating layer potentials using the proposed methods.We begin by presenting the results for double-layer potentials when Γ 1 and Γ 2 intersect, showing errors near the intersection points with the periodic trapezoidal rule (PTR) and Algorithms 1 and 2. We then investigate the performance of these algorithms when Γ 2 is closed to Γ 1 .Finally, we employ these methods as components of an integral equation solver for Laplace Neumann boundary value problems.MATLAB (R2020a) is used for these implementations.All test computations are conducted on a PC equipped with a 3.6 GHz AMD Ryzen 5 3600 CPU and 32 GB memory.
The starfish curve of Figure 3a that we use for our numerical experiments is given by and the limaçon of Figure 3b is given by In each case, t ∈ I 2π .

Double-Layer Potential Evaluation
The experiments with intersecting curves in Figure 3 and curves in close proximity in Figure 6a examine the performance of the proposed algorithm near the boundary Γ 1 .
To this end, we employ these methods to compute the double-layer potential D f d with a source function f d .In order to derive an analytical expression of D f d in the interior and exterior domains for result verification, we chose f d = 1 on Γ 1 , and the corresponding double-layer potential satisfies where Ω is the domain enclosed by Γ 1 .
The geometries of the first two examples with the boundaries described by ( 15) and ( 16) are shown in Figure 3.We compute 10 4 equispaced points on the unit circle by employing n-point PTR and Algorithms 1 and 2, with n = 10 4 .In Algorithms 1 and 2, we set β = λ 2 /(50Rr max ), λ = 10 −3 , and M = −40 log 10 β according to the analysis in Section 2.2.Here, the selection of λ ensures the accuracy of the layer potentials at distances greater than 10 −3 from the boundary.In addition, we select m = 55 and σ 0 = 10 5 in Algorithm 2. The parameter m determines the number of integral points for the local Gauss quadrature used to handle the nearly singular terms.The relative errors shown in Figure 2 indicate that m = 55 is an appropriate choice, as the local quadrature error reaches double-precision.The σ 0 sets the range of σ values at which the fast convolution method is employed to compute C σ g, as discussed in Section 2.4.A larger σ 0 means more terms are evaluated using the FFT convolution method, which can result in a loss of accuracy due to the near singularity of some convolution terms.
The first example presents the error of computing D f d on a unit circle Γ 2 with a starfish Γ 1 in Figure 3a.For simplicity, we write D f d (η), η ∈ R instead of D f d (c 1 (η)).Figure 4a shows D f d (η) for η ∈ (0.09π, 0.11π).Note that the double-layer potential has a jump at η = π/10 since Γ 1 and Γ 2 intersect.Figure 4b-d   The second example presents the results with a limaçon Γ 1 in Figure 3b.The unit circle is inside the domain Ω except for a small segment near (1, 0).Note that the parts of limaç near (1, 0) are very close to each other, and some of the targets are inside the "slit".Algorithms 1 and 2 use the same parameter settings as the first example.The graph of D f d on (−π/10, π/10) is shown in Figure 5a.This function is piecewise, with only a small region centered at 0 with a width of 2 arccos(9/(10 − 0.999)) ≈ 0.03 being 0, while the remainder is −1 almost everywhere.Figure 5b,c show that the errors of PTR and Algorithm 1 are significant at the discontinuity points and are also not negligible in the central region.In comparison, Algorithm 2 computes accurately in the central region, though the error is still significant at the discontinuity points, as shown in Figure 5d.The computational results of this method can clearly distinguish the central region, with a width of only 0.03.We next show the evaluation errors of the proposed methods on a circle of radius R close to the starfish boundary described by (15).Here, we chose β = (R − r max ) 2 /(50Rr max ) in Algorithms 1 and 2, with the selection of other parameters following the same rules as in the first example.Figure 6a shows two curves Γ 1 and Γ 2 in this example, which are at a distance of 10 −4 from each other.Figure 6b,c illustrate that the results of PTR and Algorithm 1 are inaccurate at points near Γ 1 , whereas Algorithm 2 achieves a precision of 13 decimal places, as shown in Figure 6d.We denote the distance between Γ 1 and Γ 2 as dist(Γ 1 , Γ 2 ).Table 1 presents the ℓ ∞ errors on T 1.3001,n and the computation time for computing D f d on a circle with a radius of 1.3001 with different values of n.The errors of PTR and Algorithm 1 decay slowly, while the error of Algorithm 2 maintains a precision of 13 decimal places.The computing time for Algorithms 1 and 2 grows quasi-linearly as n increases, whereas the time of PTR grows quadratically.

Integral Equation Solvers
In this section, we examine the proposed methods in the context of solving integral equations of the second kind.A numerical experiment of the exterior Neumann boundary value problems for the Laplace equation is conducted.Let Ω ⊂ R 2 be the bounded open domain, with boundary Γ 1 described by (15), and let u ex (x) := (x 1 − 0.1)/|x − (0.1, 0.4)| 2 be the solution, where x ∈ R 2 \Ω.We use the single-layer potential representation u ex = S φ [1].Here, φ ∈ C(Γ 1 ) satisfies where In order to obtain the potential density function f , we solve the BIEs using the Fourier Galerkin method described in [2].The tested methods are employed to compute S φ on T\Ω, where The first column of Figure 7 shows the absolute error of the PTR with 256 points.The last two columns of Figure 7 illustrated the absolute error of Algorithms 1 and 2. Here, E ∞ in Figure 7 denotes the ℓ ∞ error of the evaluations on T\Ω.Algorithms 1 and 2 are employed with n = 256, β = λ 2 /(50Rr max ), λ = max{R − r max , 10 −6 }, and M = −28 log 10 β + log 2 10 β .In addition, we select m = 55 and σ 0 = 100 for Algorithm 2. Figure 7 illustrates that Algorithm 2 achieves a precision of nine digits in evaluating the single-layer potential, even for target points near the boundary with a distance of 1.4 × 10 −5 .Conversely, both the PTR and Algorithm 1 exhibit inaccuracies close to the boundary.

Conclusions
In this paper, we introduce a convolution sum approximation of layer potentials and provide an approximation error analysis.A parameter selection scheme for the approximation is proposed in Section 2.2 to ensure high approximating accuracy outside a sufficiently small neighborhood of the boundary.Then two fast methods using convolution sums are presented for the evaluation of layer potentials in this paper.Due to the nearly singular convolution terms, Algorithm 1 exhibits inaccuracies near the boundary similar to PTR, as shown in the experiments in Section 3. Algorithm 2, which still maintains a complexity of O(n log n), improves the accuracy of the evaluation near the boundary via computing the nearly singular convolution terms by the Gauss quadrature.
The improved method offers several advantages: Firstly, this approach leverages periodic convolution sums to approximate layer potentials on a circle, enabling fast computation compared to traditional methods.This technique significantly reduces computational time.In the meantime, a local quadrature is applied to the nearly singular convolution terms in order to maintain the algorithm's accuracy near the boundary.Secondly, the algorithm allows for handling discontinuities in the field across the boundary, which is a feature that is not commonly addressed by existing methods.Lastly, our method is capable of handling scenarios where parts of the source geometry almost touch each other.This robustness is achieved without requiring much additional work, making the algorithm practical and efficient in real-world applications.
On the one hand, the algorithms proposed in this paper allow for fast off-boundary computation of layer potentials while accommodating discontinuities in the potential across the boundary.On the other hand, applications to practical problems when restricted to either the exterior or interior may result in redundant computations.Additionally, the assumption of a polar boundary limits the algorithm's applicability to practical scenarios.Nevertheless, this method still presents an opportunity to accelerate the evaluation of Remark A2.The function ϕ(x) = cx −α for c, α > 0 can also be approximated by exponential sums (see [27]).

Appendix A.3. Error Estimates
In this subsection, we provide an error estimate for the M-term approximation of the exponential sums discussed in the preceding two subsections.To this end, we first estimate the truncated error between T h,M ( f k ) and T h,M ( f k ) for k = 2, 3, which represent the cases for ϕ(x) = log(x) and ϕ(x) = x −1 , respectively.We provide a lemma for estimating the error for the case of ϕ(x) = (−2πx) −1 for x ≥ s ≥ 1.
Lemma A1 (Function (−2πx) −1 ).There exists a positive constant C such that for all M ∈ Z + , s ≥ 1 and h > 0, Proof.Since . According to the triangle inequality, we have The error estimate of the right rectangle rule implies that for all x ∈ [s, ∞), Since it can be derived that there exists a positive constant C such that for all s ≥ 1 max it follows from (A11) and (A12) that Combining (A9), (A10), (A13) and (A14) leads to the result.
Similarly, we can derive the error estimate for the case when ϕ(x) = 1 4π log(x) for x ≥ s.

Lemma A2 (Logarithmic Function
).There exists a positive constant C such that for all M ∈ Z + , s ≥ 1 and h > 0, Proof.Note that with h = log(4πM)/M.Lemma A2 implies that there exists a positive constant C 2 independent of M, h, s, ι such that where f1 = r ′ • r f /d 2,β , f2 (η, θ) = r ′ (θ) where T h,M ( f 3 ) is defined by (A7), it remains to estimate ϕ − T h,M ( f 3 ) ∞,[s,ι] and . Lemma A3 ensures that there exists a positive constant C 1 independent of M, h, s, ι such that with h = log(4πM)/M.Lemma A1 implies that there exists a positive constant C 2 independent of M, h, s, ι such that ≤ 2 −s − 1 + e sinh(log(4πM)) −s /(2πs) + C 2 s2 −s log(4πM) 2 /M.(A36) the values of r and |r ′ | on I 2π,n := {2kπ/n : k ∈ Z n }, and the values of the density function on S n := {r(θ k ) : θ k ∈ I 2π,n }.We now present a fast algorithm for computing the values of A
illustrate the error of PTR and Algorithms 1 and 2, respectively, with n = 10 4 .Algorithms 1 and 2 use the parameter setting discussed above.Compared to PTR and Algorithm 1, Algorithm 2 shows higher accuracy near the intersection point at η = π/10.
β .There exists C > 0 such that for all M, n ∈ Z + , M M,n ≤ CMn log 2 n.Proof.The number of multiplications used in Step 1 is bounded by O(Mn log 2 n).The number of multiplications used in Step 2 is not greater than the amount of O(n).The number of multiplications used in Step 3 is bounded by O(Mn).Therefore, we obtain the O(Mn log 2 n) upper bound on the total number of multiplications used in Algorithm 1.
Step 1 is bounded by O((M − M βσ 0 + 1)n log 2 n).The number of multiplications used in Step 2 is not greater than O(M βσ 0 ξmn + n log 2 n).The number of multiplications used in Step 3 is bounded by O(n).The number of multiplications used in Step 4 is bounded by O((M − M βσ 0 + 1)n + M βσ 0 ξn).Therefore, we obtain the result.