校园网页 · 学校官网
Fast structured Jacobi-Jacobi transforms
This is a free offprint provided to the author by the publisher. Copyright restrictions may apply . MA THEMA TICS OF COMPUT A TION V olume 88, Number 318, July 2019, Pages 1743–1772 https://doi.org/10.1090/mcom/3377 Article electronically published on August 27, 2018 FAST STRUCTURED JACOBI-JACOBI TRANSFORMS JIE SHEN, YINGWEI WANG, AND JIANLIN XIA Abstract. Jacobi polynomials are frequently used in scientific and engineer- ing applications, and often times, one needs to use the so-called Jacobi-Jacobi transforms which are transforms between two Jacobi expansions with different indices. In this paper, we develop a fast structured algorithm for Jacobi-Jacobi transforms. The algorithm is based on two main ingredients. (i) Derive ex- plicit formulas for connection matrices of two Jacobi expansions with arbitrary indices. In particular, if the indices have integer differences, the connection matrices are relatively sparse or highly structured. The benefit of simultaneous promotion or demotion of the indices is shown. (ii) If the indices have non- integer differences, we explore analytically or numerically a low-rank property hidden in the connection matrices. Combining these two ingredients, we de- velop a fast structured Jacobi-Jacobi transform with nearly linear complexity, after a one-time precomputation with quadratic complexity, between coeffi- cients of two Jacobi expansions with arbitrary indices. An important byprod- uct of the fast Jacobi-Jacobi transform is the fast Jacobi transform between the function values at a set of Chebyshev-Gauss-type points and coefficients of the Jacobi expansion with arbitrary indices. Ample numerical results are presented to illustrate the computational efficiency and accuracy of our algo- rithm. 1. Introduction Jacobi polynomials have been used in many areas of mathematics and applied sciences, e.g., approximation theory [15,16], the resolution of Gibbs’ phenomenon [13], electrocardiogram data compression [43], and spectral methods for numerical partial differential equations [8,18,35]. See also [29,44] which include extended lists of related work. Many applications of Jacobi polynomials require transforms between the coef- ficients of Jacobi expansions and the values at Jacobi-Gauss-type points, and/or between coefficients of Jacobi expansions with different indices. Some examples are as follows. In spectral/spectral-element methods with triangles or tetrahedrons [18,23], one uses the Koornwinder polynomials [21] (often known as Dubiner’s polynomials in the spectral community [11]) which involve Jacobi polynomials with varying indices. In solving prolate spheroidal equations with large zonal wave num- bers [6] which arise, e.g., from Helmholtz equations with large wave numbers, one Received by the editor April 16, 2017, and, in revised form, November 14, 2017, February 8, 2018, and April 11, 2018. 2010 Mathematics Subject Classification.Primary 65T50, 65D05, 65N35, 65F30. Key words and phrases.Jacobi-Jacobi transform, Chebyshev-Jacobi transform, recurrence for- mula, connection matrix, low-rank property, structured matrix. The work of the first author was partially supported by NSF grants DMS-1620262, DMS- 1720442 and AFOSR FA9550-16-1-0102. The researchof the third author was supported in part by NSF CAREER Award DMS-1255416. c⃝2018 American Mathematical Society 1743 This is a free offprint provided to the author by the publisher. Copyright restrictions may apply . 1744 J. SHEN, Y. WANG, AND J. XIA is led to use Jacobi polynomials with very large indices [1]. In dealing with sin- gular solutions such as corner singularities or fractional PDEs, one often needs to work with the approximation space spanned by{(1±x)kα} with α∈(0,1), which requires transformation between Jacobi polynomials with index (0,α)o r(α,0) and Legendre polynomials [36]. The Jacobi polynomials with index (10,10) outper- form those with index (0,0) (Legendre polynomials) for the approximation to the truncated standard Gaussian function (see Appendix C in [53]). Hence, it is highly desirable to develop algorithms which can perform these transforms as quickly and accurately as possible. Moreover, fast Jacobi-Jacobi transforms may also be useful for the development of fast spherical harmonic trans- forms which are of critical importance in many applications [31,47]. The purpose of this work is thus to design fast Jacobi-Jacobi transforms. Let P N be the set of polynomials with degrees less than or equal toN, and let (α1,β1), (α2,β2) be two pairs of Jacobi indices withαi,βi > −1( i =1 ,2). For f ∈PN, we can expandf(x) in Jacobi expansions with indices (α1,β1)a n d(α2,β2), namely: (1.1) f(x)= N∑ n=0 f(α1,β1) n J(α1,β1) n (x)= N∑ n=0 f(α2,β2) n J(α2,β2) n (x),x ∈[−1,1], where {J(αi,βi) n }N n=0 are Jacobi polynomials with indices (αi,βi), i =1 ,2. By the orthogonal properties of Jacobi polynomials, one can easily determine the connection matricesK(α1,β1)→(α2,β2) and K(α2,β2)→(α1,β1) such that (1.2) f(α2,β2) = K(α1,β1)→(α2,β2)f(α1,β1), f(α1,β1) = K(α2,β2)→(α1,β1)f(α2,β2), where f(αi,βi) = {f(αi,βi) n }N n=0, i =1 ,2. However, the connection matrices are full upper triangular matrices so that a direct Jacobi-Jacobi transform will costO(N2). The main question we want to address in this paper is how to quickly and accurately perform the Jacobi-Jacobi transforms (1.2). A pioneering work in this direction was done by Alpert and Rokhlin in [2] where a fast transform between Legendre and Chebyshev coefficients was proposed based on the fast multipole method (FMM). Another approach to compute the connec- tion between classical orthogonal polynomials or associated functions is based on the observation that the corresponding connection matrixK can be represented as a properly scaled semiseparable eigenvector matrix. Employing a divide-and- conquer algorithm [10] to compute this eigen-decomposition enables us to perform the matrix-vector productKf efficiently for any column vectorf. This approach has been used for the transform between associated Legendre functions [31], Gegen- bauer polynomials [19,20], and any families of Hermite, Laguerre, and Gegenbauer polynomials with single parameters [4]. However, there is no efficient extension of this approach to Jacobi transforms which have two parameters. 1 Another important category of methods for a fast Chebyshev-Legendre trans- form is to use asymptotic expansions [17,27,30]. A significant advantage of this methodology is that it does not require an expensive initialization phase. However, the approach with asymptotic expansions is somewhat limited to the Legendre case, and it is generally difficult to extend to Jacobi polynomials with arbitrary indices. We note that the asymptotic approach was generalized to the Chebyshev-Jacobi 1It was brought to our attention by one of the referees that the authors of [45] developed very recently a fast polynomial transform based on Toeplitz and Hankel transforms. This is a free offprint provided to the author by the publisher. Copyright restrictions may apply . FAST STRUCTURED JACOBI-JACOBI TRANSFORMS 1745 transform in [37], which also yields fast evaluations of Jacobi expansions at Gauss- Chebyshev nodes. The main goal of this paper is to develop fast algorithms, with nearly linear complexity after possibly a one-time nearly quadratic-complexity precomputation step, for Jacobi-Jacobi transforms with arbitrary Jacobi indices. Explicit formulas are derived for connection matrices of two Jacobi expansions with arbitrary indices. We show that, if the indices have integer differences, the connection matrices have banded forms in the promotion case (from lower indices to higher ones) or are related to certain highly structured forms in the demotion case. These banded or structured forms can be used to conveniently perform the Jacobi-Jacobi transforms in O(N) operations. We also show that, when it needs to promote or demote both indices αand β, it is more desirable to perform the promotion or demotion simultaneously for both indices, instead of performing one by one. We show how the simultaneous promotion/demotion is done and demonstrate the saving in the cost. If the indices have non-integer differences such as in the Chebyshev-Legendre transform and more general cases, the connection matrices are dense. We explore a more general structure that is data sparse. This is based on a so-calledlow- rank propertyof the connection matrices, i.e., their appropriate off-diagonal blocks have small (numerical) ranks. This property can be verified either analytically or numerically. For connection matrices in Chebyshev-Legendre transforms, we can rigorously show an off-diagonal rank bound by deriving certain expansions of the relevant generating functions. A useful feature for matrices with the low-rank property is that they can be ap- proximated by rank structured matrices such ashierarchically semiseparable(HSS) forms [9,50]. The HSS approximations enable us to perform the desired trans- forms withO(rN)m e m o r ya n dO(rN)fl o p s ,w h e r er is the maximum off-diagonal numerical rank. The HSS form also has another benefit in the numerical stability. That is, the numerical errors propagate along a binary tree instead of sequentially. Thus, the backward error of the matrix-vector multiplication in the transforms is proportional to log 2 N and a low-degree term ofr [48]. In contrast, direct dense transforms may suffer from large numerical errors since the backward stability depends on the condition number which could be very large in some cases. In Jacobi-spectral methods, one often needs to transform between the coefficients of the Jacobi expansion to the values at a given set of collocation points. An im- portant byproduct of the proposed fast Jacobi-Jacobi transform is a fast algorithm to perform the Jacobi transform between the function values at a set of Chebyshev- Gauss-type points and coefficients of the Jacobi expansion with arbitrary indices. More precisely, letf ∈P N and {xj ∈[−1,1]}N j=0 be a set of Chebyshev-Gauss-type points. We need to determine{f(α,β) n }N n=0 from {f(xj)}N j=0 or vice versa through (1.3) f(xj)= N∑ n=0 f(α,β) n J(α,β) n (xj), 0 ≤j ≤N. To obtain the coefficients of the Jacobi expansion{f(α,β) n }N n=0 from the function values {f(xj)}N j=0, we proceed in two steps: This is a free offprint provided to the author by the publisher. Copyright restrictions may apply . 1746 J. SHEN, Y. WANG, AND J. XIA •First, obtain the coefficients{f t n}N n=0 of the Chebyshev expansion: f(x)= N∑ n=0 f t nTn(x) using the Fast Fourier Transform (FFT) inO(N logN)o p e r a t i o n s . •Second, use the proposed Jacobi-Jacobi transform to determine{f(α,β) n }N n=0 from {f t n}N n=0 through the identity (1.4) f(x)= N∑ n=0 f t nTn(x)= N∑ n=0 f(α,β) n J(α,β) n (x),x ∈[−1,1]. Conversely, one can determine the function values{f(xj)}N j=0 from the coefficients of the Jacobi expansion{f(α,β) n }N n=0 by reversing the above steps. Thus, the Jacobi transforms with arbitrary indices can be performed also in nearly linear complexity. The remaining sections are organized as follows. In Section 2, we derive explicit recurrence formulas of the connection matrices for Jacobi-Jacobi transforms with arbitrary indices, and for Jacobi-Jacobi transforms of indices with integer differ- ences. In Section 3, we explore the low-rank property of the connection matrices. We describe the algorithms for the proposed fast structured Jacobi-Jacobi trans- forms in Section 4, and present several numerical experiments in Section 5. Finally, we present some conclusions and possible directions for future research in the last section. We list below some notation used throughout the paper: •P n: the space of polynomials of degree at mostn. •deg(·): the degree of a polynomial. •δi,j: the Kronecker delta. •Γ(·): Gamma function defined as Γ(t)= ∫∞ 0 xt−1e−xdx. •⟨ ·,·⟩ω: the inner product with respect to the weight ω, e.g., ⟨f,g ⟩ω =∫1 −1 f(x)g(x)ω(x)dx. •J(α,β) n (x): Jacobi polynomial of degreen with indicesj =( α,β). •Ln(x)= J(0,0) n (x): Legendre polynomial of degreen, or equivalently, Jacobi polynomial of degreen with indicesl =( 0,0). •Tn(x)= cnJ(−1/2,−1/2) n (x): Chebyshev polynomial (of the first kind) of de- gree n, which is proportional to Jacobi polynomial of degreen with indices t =( −1/2,−1/2) (see (2.14) for details). •K(α1,β1)→(α2,β2) or Kj1→ j2 with j1 =( α1,β1)a n dj2 =( α2,β2): the con- nection matrix from{J(α1,β1) n } to {J(α2,β2) n }. •f(α,β): the expansion coefficients of a polynomialf(x) in terms of Jacobi polynomials {J(α,β) n };i np a r t i c u l a r ,f l meansthecoefficientsoftheLegendre expansion andf t means the coefficients of the Chebyshev expansion. 2. Connection coefficients First, let us recall some basic properties of Jacobi polynomials{J(α,β) n (x)} asso- ciated with real indicesα,β >−1. This is a free offprint provided to the author by the publisher. Copyright restrictions may apply . FAST STRUCTURED JACOBI-JACOBI TRANSFORMS 1747 (1) The three-term recurrence relations for Jacobi polynomials {J(α,β) n (x)} read: J(α,β) 0 (x)=1 ,J (α,β) 1 (x)= 1 2(α+β+2)x+ 1 2(α−β), J(α,β) n+1 (x)= ( p(α,β) n x−q(α,β) n ) J(α,β) n (x)−r(α,β) n J(α,β) n−1 (x),n ≥1,(2.1) where the constants are p(α,β) n = (2n+α+β+1)(2n+α+β+2) 2(n+1)(n+α+β+1) ,(2.2) q(α,β) n = (β2 −α2)(2n+α+β+1) 2(n+1)(n+α+β+1)(2n+α+β),(2.3) r(α,β) n = (n+α)(n+β)(2n+α+β+2) (n+1)(n+α+β+1)(2n+α+β).(2.4) (2) Jacobi polynomials {J(α,β) n (x)}n=0 are orthogonal with respect to their weights ω(α,β): (2.5) ⟨J(α,β) k ,J (α,β) j ⟩ω(α,β) = γ(α,β) k δkj, where ω(α,β) =( 1−x)α(1+ x)β,(2.6) γ(α,β) k = 2α+β+1Γ(α+k +1)Γ(β+k +1) (α+β+2k +1)k!Γ(α+β+k +1) .(2.7) Definition 2.1(Connection coefficients). Let J1 = {J(α1,β1) n (x)}N n=0 and J2 = {J(α2,β2) n (x)}N n=0 with deg(J(α1,β1) n )=d e g (J(α2,β2) n )= n be two sequences of Jacobi polynomials with respect to inner products ⟨·,·⟩ω(α1,β1) and ⟨·,·⟩ω(α2,β2), respec- tively. (The weight functions are defined following (2.6).) Then eachJ(α1,β1) j ∈J1 can be represented as a linear combination of the polynomials{J(α2,β2) i }j i=0 ⊂J2, i.e., J(α1,β1) j = j∑ i=0 κj1→ j2 i,j J(α2,β2) i ,j =0 ,1,...,N, where j1 =( α1,β1)a n dj2 =( α2,β2). Here, the polynomials inJ1 (and J2)a r e called source(and target) polynomials, and the following matrix is called thematrix of connection coefficientsor connection matrixof degreeN from J1 to J2: Kj1→ j2 = ( κj1→ j2 i,j )N i,j=0 ∈R(N+1)×(N+1). The following lemma then immediately follows. Lemma 2.2. The connection matrixKj1→ j2 defined in Definition2.1 is given by κj1→ j2 i,j = ⟨J(α1,β1) i ,J (α2,β2) j ⟩ω(α2,β2) ⟨J(α2,β2) i ,J (α2,β2) i ⟩ω(α2,β2) = ⟨J(α2,β2) i ,J (α1,β1) j ⟩ω(α2,β2) γ(α2,β2) i . Remark 1. By the orthogonality, we observe that fori>j , κj1→ j2 i,j =0 ,w h i c h means thatKj1→ j2 is an upper triangular matrix. This is a free offprint provided to the author by the publisher. Copyright restrictions may apply . 1748 J. SHEN, Y. WANG, AND J. XIA With the matrixKj1→ j2 in hand, we can handle the so-calledconnection prob- lem, i.e., given any polynomial expressed in the basis of one set of orthogonal poly- nomials, to compute the coefficients with respect to a different set of orthogonal polynomials. This can be rigorously stated as follows. Lemma 2.3. Let f(x) ∈PN,a n dJ1,J2 be the Jacobi polynomial sets given in Definition2.1. Consider two expansions off(x) as follows: (2.8) f(x)= N∑ n=0 f j1 n J(α1,β1) n (x)= N∑ n=0 f j2 n J(α2,β2) n (x). Then the matrix Kj1→ j2 given in Lemma 2.2 leads to the transform between two column vectorsf j1 =( f j1 n )N n=0 and f j2 =( f j2 n )N n=0, i.e.,f j2 = Kj1→ j2f j1. Determining these connection coefficients has been studied extensively as a theo- retical problem [5,22,25,26,28,32,41,42]. Below we focus on two special cases that are useful in our algorithms, namely, recurrence formulas ofJacobi-Jacobi trans- forms with arbitrary indices, and explicit formulas ofJacobi-Jacobi transforms with indices that have integer differences. Generally speaking, computing the entries of the connection matrixK defined in Lemma 2.3 explicitly and then applying it to a vector both requireO(N 2) storage and O(N2) operations. In order to obtain fast transforms, we proceed with the following strategies: •For the transforms between any two Jacobi expansions with indices close to each other, we find that the connection matrixK enjoys the low-rank property and thus can be approximated by a rank structured matrix. The rank structured approximation can be quickly applied to a vector in linear complexity. •For the problem between Jacobi polynomials with integer differences, we find that either the matrix itself can be written as the product of banded matrices, or the off-diagonal blocks of the matrix are low-rank, which im- plies that the Jacobi-Jacobi transforms can be done in linear complexity. 2.1. Jacobi-Jacobi transforms with arbitrary indices.In this subsection, we consider the transform between the coefficients of two Jacobi expansions with differ- ent indices, which is a generalization of theforward and backward Chebyshev-Jacobi transforms (FCJT and BCJT) in (1.4). Consider two Jacobi expansions for anyf(x) ∈P N shown in (2.8). The connec- tion matricesKj1→ j2 and Kj2→ j1 satisfy the following relations: (2.9) f j1 = Kj2→ j1f j2, f j2 = Kj1→ j2f j1. Note that explicit formulae for the connection matrices are available (cf. Lemma 7.1.1 in [3]). However, the formulae involve the generalized hypergeometric function which is not easy to deal with. On the other hand, there are also explicit formulae for the connection matrices with the same second index (cf. Theorem 7.1.3 in [3]), but it is not easy to extend it to the general case. Therefore, we shall derive re- currence relations for the general connection matrices using the recurrence relation (2.1) and the orthogonal property (2.5). Note that some recurrence relations for the connection matrices have been de- rived in [33]. Since the recurrence relations are frequently used in what follows, we provide them and their proofs below for the reader’s convenience and completeness. This is a free offprint provided to the author by the publisher. Copyright restrictions may apply . FAST STRUCTURED JACOBI-JACOBI TRANSFORMS 1749 Theorem 2.4 (Recurrence formulas for Jacobi-Jacobi transform). The non-zero entries ofKj2→ j1 and Kj1→ j2 in (2.9) can be generated recursively as follows: κj2→ j1 i,j+1 = εj2→ j1 1 κj2→ j1 i,j−1 +εj2→ j1 2 κj2→ j1 i−1,j +εj2→ j1 3 κj2→ j1 i,j +εj2→ j1 4 κj2→ j1 i+1,j ,j ≥i, κj1→ j2 i,j+1 = εj1→ j2 1 κj1→ j2 i,j−1 +εj1→ j2 2 κj1→ j2 i−1,j +εj1→ j2 3 κj1→ j2 i,j +εj1→ j2 4 κj1→ j2 i+1,j ,j ≥i, where the coefficients{εjm→ jˆm k }k=1,2,3,4 with (m, ˆm)=( 1,2) or (2,1) are given by εjm→ jˆm 1 = −rm j ,ε jm→ jˆm 2 = { 0,i =0 , πˆm 2 (i)pm j ,i ≥1, εjm→ jˆm 3 = πˆm 3 (i)pm j −qm j ,ε jm→ jˆm 4 = πˆm 4 (i)pm j , with the parameters{pj,qj,rj} given in (2.2)–(2.4),a n d πm 2 (k)= 2k(k +αm +βm) (2k +αm +βm −1)(2k +αm +βm), πm 3 (k)= β2 m −α2 m (2k +αm +βm)(2k +αm +βm +2) , πm 4 (k)= 2(k +αm +1)(k +βm +1) (2k +αm +βm +2)(2k +αm +βm +3) , for m =1 ,2 and k =0 ,1,2,... . Moreover, the starting points of the above recurrence formulas are κj2→ j1 0,0 =1 ,κ j2→ j1 0,1 = (β1 −α1)(α2 +β2 +2) 2(α1 +β1 +2) −β2 −α2 2 , κj2→ j1 1,0 =0 ,κ j2→ j1 1,1 = α2 +β2 +2 α1 +β1 +2 , κj1→ j2 0,0 =1 ,κ j1→ j2 0,1 = (α1 +β1 +2)(β2 −α2) 2(α2 +β2 +2) −β1 −α1 2 , κj1→ j2 1,0 =0 ,κ j1→ j2 1,1 = α1 +β1 +2 α2 +β2 +2 . Proof. To simplify notation in this proof, denote Jm n := J(αm,βm) n (x),ω m := (1+x)αm(1−x)βm,γ m n := γαm,βm n , pm n := pαm,βm n ,q m n := qαm,βm n ,r m n := rαm,βm n , where n =0 ,1,2,... and m =1 ,2. The entries of the matrices Kj2→ j1 =( κj2→ j1 i,j )N i,j=0 and Kj1→ j2 = ( κj1→ j2 i,j )N i,j=0 are (2.10) κj2→ j1 i,j = ⟨J1 i ,J 2 j ⟩ω1 ∥J1 i ∥2 ω1 ,κ j1→ j2 i,j = ⟨J2 i ,J 1 j ⟩ω2 ∥J2 i ∥2 ω2 , respectively. We focus on {κj2→ j1 i,j }N i,j=0 first. Denote ˜κj2→ j1 i,j = ⟨J1 i ,J 2 j ⟩ω1. Note that the relation betweenκj2→ j1 i,j and ˜κj2→ j1 i,j is (2.11) ˜ κj2→ j1 i,j = ∥J1 i ∥2 ω1κj2→ j1 i,j . This is a free offprint provided to the author by the publisher. Copyright restrictions may apply . 1750 J. SHEN, Y. WANG, AND J. XIA Then forj ≥i ≥1, ˜κj2→ j1 i,j+1 = ⟨J1 i ,J 2 j+1⟩ω1 = ⟨J1 i ,(p2 jx−q2 j)J2 j −r2 jJ2 j−1⟩ω1 = ⟨xJ1 i ,p2 j J2 j ⟩ω1 −⟨J1 i ,q2 jJ2 j ⟩ω1 −⟨J1 i ,r2 jJ2 j−1⟩ω1 = p2 j p1 i [ ⟨J1 i+1,J 2 j ⟩ω1 +q1 i ⟨J1 i ,J 2 j ⟩ω1 +r1 i ⟨J1 i−1,J 2 j ⟩ω1 ] −q2 j⟨J1 i ,J 2 j ⟩ω1 −r2 j⟨J1 i ,J 2 j−1⟩ω1 = 1 p1 i [ p2 j˜κj2→ j1 i+1,j +(p2 jq1 i −p1 iq2 j)˜κj2→ j1 i,j +p2 jr1 i ˜κj2→ j1 i−1,j ] −r2 j ˜κj2→ j1 i,j−1 . It follows that (2.12) κj2→ j1 i,j+1 = p2 jγ1 i+1 p1 iγ1 i κj2→ j1 i+1,j + p2 jq1 i −p1 iq2 j p1 i κj2→ j1 i,j + p2 jr1 i γ1 i−1 p1 iγ1 i κj2→ j1 i−1,j −r2 jκj2→ j1 i,j−1 . Recall thatx = 2J1 1−(α1−β1) α1+β1+2 .F o ri = 0, the formula becomes (2.13) κj2→ j1 0,j+1 = 2p2 jγ1 1 (α1 +β1 +2)γ1 0 κj2→ j1 1,j+1 − ( p2 j(α1 −β1) α1 +β1 +2 +q2 j ) κj2→ j1 0,j −r2 jκj2→ j1 0,j−1,j ≥1. Besides, for{κj1→ j2 i,j }N i,j=0, we just need to interchange the indices 1 and 2 in (2.12)– (2.13). □ Remark 2. Thanks to the symmetry property of Jacobi polynomials J(α,β) n (−x)=( −1)nJ(β,α) n (x), the Jacobi polynomialJ(α,α) n (x) (up to a constant, referred to as the Gegenbauer or ultra-spherical polynomial) is an odd function for oddn a n da ne v e nf u n c t i o n for evenn. Therefore, for the Chebyshev-Jacobi transforms shown in (1.4), we have κt→(α,α) ij = κ(α,α)→ t ij =0f o ro d di+j. Note that the Chebyshev polynomials and Jacobi polynomials with indicest = (−1/2,−1/2) are proportional to each other, i.e., (2.14) Tn(x) ≡Γ(1/2)Γ(n+1) Γ(n+1/2) J(−1/2,−1/2) n (x) ∀n =0 ,1,.... Hence, we can derive, as a special case of Theorem 2.4, the recurrence relation for the connection matrices between Chebyshev and Jacobi expansions. Now let us consider the Legendre polynomialsLn(x) ≡J(0,0) n (x) as a special case of Jacobi polynomials with indicesl =( 0,0). Corollary 2.5 (Recurrence formulas for Chebyshev-Legendre transforms). The non-zero entries of the connection coefficients of the backward and forward Cheby- shev-Legendre transforms, i.e.,Kl→ t =( κl→ t i,j ) and Kt→ l =( κt→ l i,j ) can be obtained recursively by κl→ t i,j = 2 ciπ˜κl→ t i,j ,κ t→ l i,j =( i+1/2)˜κt→ l i,j , This is a free offprint provided to the author by the publisher. Copyright restrictions may apply . FAST STRUCTURED JACOBI-JACOBI TRANSFORMS 1751 where c0 =2 ,ci =1 for i ≥1 and ˜κl→ t i,j+1 = 2j +1 2j +2 ( ˜κl→ t i+1,j +˜κl→ t i−1,j ) − j j +1 ˜κl→ t i,j−1, ˜κt→ l i,j+1 = 2i+2 2i+1 ˜κt→ l i+1,j + 2i 2i+1 ˜κt→ l i−1,j −˜κt→ l i,j−1. In particular, for Chebyshev-Legendre transforms, explicit formulas are given in [2]. Lemma 2.6 (Explicit formulas for Chebyshev-Legendre transforms). The explicit formula for the entries of backward and forward Chebyshev-Legendre transforms, i.e., Kl→ t =( κl→ t i,j ) and Kt→ l =( κt→ l i,j ), respectively, are given by the following: κl→ t i,j = ⎧ ⎨ ⎩ 1 π [ Λ (j 2 )]2 if 0= i ≤j<n and j is even, 2 πΛ (j−i 2 ) Λ (j+i 2 ) if 0 <i ≤j<n and i+j is even, 0 otherwise, κt→ l i,j = ⎧ ⎪⎪ ⎪ ⎨ ⎪⎪⎪⎩ 1 if i = j =0 , 1 2 √π Λ(i) if 0 <i = j<n , −j(i+1/2) (j+i+1)(j−i)Λ (j−i−2 2 ) Λ (j+i−1 2 ) if 0 ≤i<j<n and i+j is even, 0 otherwise, where the functionΛ(·) is defined as (2.15) Λ( z)= Γ(z +1/2) Γ(z +1) . Remark 3. The explicit formula for the entries of connection coefficients between Gegenbauer polynomials, which are Jacobi polynomials with indicesα= β,c a nb e found in [20]. Since it is costly to numerically evaluate the function Λ(·) defined above, the recurrence formulas given in Corollary 2.5 and Theorem 2.4 are usually employed to generate the corresponding connection coefficients (see, for instance, [34]). On the other hand, the explicit formulas given in Lemma 2.6 are useful in analyzing the low-rank property hidden in the matricesK l→ t and Kt→ l in Section 3.2. 2.2. Jacobi-Jacobi transforms for indices with integer differences.In this subsection, we consider the connection coefficients between the following Jacobi expansions with indices of integer differences: f(x)= N∑ n=0 f(α,β) n J(α,β) n (x)= N∑ n=0 f(α+1,β) n J(α+1,β) n (x) = N∑ n=0 f(α,β+1) n J(α,β+1) n (x)= N∑ n=0 f(α+1,β+1) n J(α+1,β+1) n (x). For simplicity, let us denote four cases of Jacobi indices with integer differences as follows: u00 =( α,β), u10 =( α+1,β), u01 =( α,β+1), u11 =( α+1,β+1). Then the column vectors of the expansion coefficients above are f u00 =( f(α,β) n )N n=0 , f u10 =( f(α+1,β) n )N n=0 , f u01 =( f(α,β+1) n )N n=0 , f u11 =( f(α+1,β+1) n )N n=0 . This is a free offprint provided to the author by the publisher. Copyright restrictions may apply . 1752 J. SHEN, Y. WANG, AND J. XIA First, let us consider the promotion case, i.e., from coefficients of lower indices to those of higher ones. Lemma 2.7 (Promotion relation [40]). The Jacobi polynomials withn ≥0 satisfy (1−x)J(α+1,β) n (x)= ξ(α,β,n) 1 J(α,β) n (x)−ξ(α,β,n) 0 J(α,β) n+1 (x), (1+ x)J(α,β+1) n (x)= ξ(α,β,n) 2 J(α,β) n (x)+ ξ(α,β,n) 0 J(α,β) n+1 (x), where ξ(α,β,n) 0 = 2(n+1) 2n+α+β+2 ,ξ (α,β,n) 1 = 2(n+α+1) 2n+α+β+2 ,ξ (α,β,n) 2 = 2(n+β+1) 2n+α+β+2 . Note that all of the coefficientsξ(α,β,n) 0 ,ξ(α,β,n) 1 ,ξ(α,β,n) 0 ,a r ex-independent, allowing us to compute these connection coefficients explicitly. Theorem 2.8. The promotion coefficientsKu00→ u10 and Ku00→ u01 in f u01 = Ku00→ u10f u00 and f u11 = Ku00→ u01f u00, respectively, are bidiagonal matrices as follows: Ku00→ u10 = ⎛ ⎜⎜⎜⎜ ⎜⎜⎜⎝ μ (α,β,0) ν(α,β,0) 1 μ(α,β,1) ν(α,β,1) 1 ... ... ... ν(α,β,N−1) 1 μ(α,β,N) ⎞ ⎟⎟⎟⎟ ⎟⎟⎟⎠ (N+1)×(N+1) , Ku00→ u01 = ⎛ ⎜⎜⎜⎜ ⎜⎜⎜⎝ μ (α,β,0) ν(α,β,0) 2 μ(α,β,1) ν(α,β,1) 2 ... ... ... ν(α,β,N−1) 2 μ(α,β,N) ⎞ ⎟⎟⎟⎟ ⎟⎟⎟⎠ (N+1)×(N+1) , where μ(α,β,i) = α+β+i+1 α+β+2i+1 ,ν(α,β,i) 1 = − β+i+1 α+β+2i+3 ,ν(α,β,i) 2 = α+i+1 α+β+2i+3 . Proof. Similar to the procedure in the proof of Theorem 2.4, we have κu00→ u10 i,j = ⟨J(α+1,β) i ,J (α,β) j ⟩ω(α+1,β) ∥Jα+1,β i ∥2 ω(α+1,β) = ⟨(1−x)J(α+1,β) i ,J (α,β) j ⟩ω(α,β) γα+1,β i = ⟨ξ(α,β,i) 1 J(α,β) i −ξ(α,β,i) 0 J(α,β) i+1 ,J (α,β) j ⟩ω(α,β) γα+1,β i = γ(α,β) i ξ(α,β,i) 1 γ(α+1,β) i δi,j −γ(α,β) i+1 ξ(α,β,i) 0 γ(α+1,β) i δi+1,j := μ(α,β,i)δi,j +ν(α,β,i) 1 δi+1,j. A l s o ,i ti se a s yt os e et h a t κu00→ u01 i,j = γ(α,β) i ξ(α,β,i) 2 γ(α,β+1) i δi,j + γ(α,β) i+1 ξ(α,β,i) 0 γ(α,β+1) i δi+1,j := μ(α,β,i)δi,j +ν(α,β,i) 2 δi+1,j. This is a free offprint provided to the author by the publisher. Copyright restrictions may apply . FAST STRUCTURED JACOBI-JACOBI TRANSFORMS 1753 Finally, the parametersμ(α,β,i),ν(α,β,i) 1 ,a n dν(α,β,i) 2 can be easily computed thanks to the definitions of{γ(α,β) i } in (2.7) and{ξ(α,β,n) j } in Lemma 2.7. □ The result above implies that the flops to promote an index by one is about 3N. Next, we consider promoting both indices (α,β) simultaneously. Lemma 2.9(Simultaneous promotion). The relation between{J(α+1,β+1) n }n=0 and {J(α,β) n }n=0 is (1−x)(1+ x)J(α+1,β+1) n (x)= λα,β,n 1 J(α,β) n (x)+ λα,β,n 2 J(α,β) n+1 (x)+ λ(α,β,n) 3 J(α,β) n+2 (x), where λ(α,β,n) 1 = 4(n+α+1)(n+β+1) (2n+α+β+2)(2n+α+β+3) , λ(α,β,n) 2 = 4(n+1)(α−β) (2n+α+β+2)(2n+α+β+4) , λ(α,β,n) 3 = − 4(n+1)(n+2) (2n+α+β+3)(2n+α+β+4) . Proof. Applying Lemma 2.7 twice leads to (1+ x)(1−x)J(α+1,β+1) n =( 1+x) ( ξ(α,β+1,n) 1 J(α,β+1) n −ξ(α,β+1,n) 0 J(α,β+1) n+1 ) = ξ(α,β+1,n) 1 ξ(α,β,n) 2 J(α,β) n + ( ξ(α,β+1,n) 1 ξ(α,β,n) 0 −ξ(α,β+1,n) 0 ξ(α,β,n+1) 2 ) J(α,β) n+1 −ξ(α,β+1,n) 0 ξ(α,β,n+1) 0 J(α,β) n+2 . It implies that λ(α,β,n) 1 = ξ(α,β+1,n) 1 ξ(α,β,n) 2 , λ(α,β,n) 2 = ξ(α,β+1,n) 1 ξ(α,β,n) 0 −ξ(α,β+1,n) 0 ξ(α,β,n+1) 2 , λ(α,β,n) 3 = −ξ(α,β+1,n) 0 ξ(α,β,n+1) 0 . By algebraic computations, we can get the expressions for the parametersλ(α,β,n) 1 , λ(α,β,n) 2 ,a n dλ(α,β,n) 3 . □ Theorem 2.10. The promotion coefficient matrix Ku00→ u11 in the transform f u11 = Ku00→ u11f u00 is a banded upper triangular matrix with upper bandwidth 2 of the form Ku00→ u11 = ⎛ ⎜⎜⎜ ⎜⎜⎜ ⎜⎜⎝ ˜λ (α,β,0) 1 ˜λ(α,β,0) 2 ˜λ(α,β,0) 3 ˜λ(α,β,1) 1 ˜λ(α,β,1) 2 ... ... ... ˜λ(α,β,N−2) 3 ... ˜λ(α,β,N−1) 2 ˜λ(α,β,N) 1 ⎞ ⎟⎟⎟ ⎟⎟⎟ ⎟⎟⎠ (N+1)×(N+1) , This is a free offprint provided to the author by the publisher. Copyright restrictions may apply . 1754 J. SHEN, Y. WANG, AND J. XIA where the entries are ˜λ(α,β,i) 1 = (α+β+i+1)(α+β+i+2) (α+β+2i+1)(α+β+2i+2) , ˜λ(α,β,i) 2 = (α−β)(α+β+i+2) (α+β+2i+2)(α+β+2i+4) , ˜λ(α,β,i) 3 = − (α+i+2)(β+i+2) (α+β+2i+4)(α+β+2i+5) . Proof. Let us denoteKu00→ u11 =( κu00→ u11 i,j ). Then it is easy to see that κu00→ u11 i,j = ⟨J(α+1,β+1) i ,J (α,β) j ⟩ω(α+1,β+1) ∥J(α+1,β+1) i ∥2 ω(α+1,β+1) = ⟨(1−x)(1+ x)J(α+1,β+1) i ,J (α,β) j ⟩ω(α,β) γ(α+1,β+1) i = ⟨λ(α,β,i) 1 J(α,β) i +λ(α,β,i) 2 J(α,β) i+1 +λ(α,β,i) 3 J(α,β) i+2 ,J (α,β,i) j ⟩ω(α,β) γ(α+1,β+1) i = γ(α,β) i λ(α,β,i) 1 γ(α+1,β+1) i δi,j + γ(α,β) i+1 λ(α,β,i) 2 γ(α+1,β+1) i δi+1,j + γ(α,β) i+2 λ(α,β,i) 3 γ(α+1,β+1) i δi+2,j := ˜λ(α,β,i) 1 δi,j + ˜λ(α,β,i) 2 δi+1,j + ˜λ(α,β,i) 3 δi+2,j, where the parameters˜λ(α,β,i) 1 , ˜λ(α,β,i) 2 ,a n d˜λ(α,β,i) 3 can be calculated easily. □ Remark 4. In many cases, we may need the promotion transform fromf(α,β) to f(α+m,β+m),w h e r em is a positive integer. If we promote the indices αand β separately, then the total cost is about 6mN flops. However, if we promote them simultaneously, then the total cost is about 5mN. Now, let us consider the demotion case, i.e., from coefficients of higher indices to those of lower ones. There are two strategies. One is to treat the demotion coef- ficient matrices as inverses of appropriate promotion coefficient matrices. Another is to explicitly write the structured forms of the corresponding matrices. Lemma 2.11 (Demotion relation [40]). The Jacobi polynomials satisfy J (α+1,β) n (x)= n∑ j=0 κ(α+1,β)→(α,β) nj J(α,β) j (x), J(α,β+1) n (x)= n∑ j=0 κ(α,β+1)→(α,β) nj J(α,β) j (x), where κ(α+1,β)→(α,β) nj = Γ(n+β+1) Γ(n+α+β+2) · (2j +α+β+1)Γ(j +α+β+1) Γ(j +β+1) , κ(α,β+1)→(α,β) nj =( −1)n+j Γ(n+α+1) Γ(n+α+β+2) · (2j +α+β+1)Γ(j +α+β+1) Γ(j +α+1) . This is a free offprint provided to the author by the publisher. Copyright restrictions may apply . FAST STRUCTURED JACOBI-JACOBI TRANSFORMS 1755 Corollary 2.12. The matricesKu10→ u00 and Ku01→ u00 are upper triangular ma- trices with their upper triangular parts given by those ofρ1ηT 1 and ρ2ηT 2 , respec- tively, where ρ1= ((2i+α+β+1)Γ(i+α+β+1) Γ(i+β+1) )N i=0 , η1= ( Γ(i+β+1) Γ(i+α+β+2) )N i=0 , ρ2= ( (−1)i(2i+α+β+1)Γ(i+α+β+1) Γ(i+α+1) )N i=0 , η2= ( (−1)i Γ(i+α+1) Γ(i+α+β+2) )N i=0 . To compute the entries in the vectorsρ1,ρ2,η1,η2 accurately and efficiently, we should not evaluate the Gamma function Γ(·) repeatedly. Instead, we could make use of the recurrence relations. For example, for the vectorρ1 =( ρj)N i=0,w eh a v e ρ0 = Γ(α+β+2) Γ(β+1) ,ρ i+1 = (2i+α+β+3)(i+α+β+1) (2i+α+β+1)(i+β+1) ρi,i =0 ,...,N −1. We can computeρ2,η1,η2 in a similar manner. Remark 5. Since Ku10→ u00 and Ku01→ u00 correspond to the upper triangular parts of two rank-1 matrices, they are the so-calledsemiseparablematrices and are highly structured. Simple HSS representations can be analytically written down for these matrices. The demotion case can also be considered in another way. That is, we can treat K u10→ u00 and Ku01→ u00 as inverses of the bidiagonal promotion coefficient matricesKu00→ u10 and Ku00→ u01, respectively. Thus, the matrix-vector multiplication involves bidiagonal solution. In either case, the computational cost for demoting fromfα+mα,β+mβ to fα,βis then no more than 3(mα+mβ)N flops, for integersmα and mβ. 3. Low-rank property of the connection matrices In this section, we show that the Jacobi-Jacobi connection matrices given in Sec- tion 2.1 enjoyalow-rank property, which allows us to construct HSS representations or approximations for the matrices. The HSS forms are data sparse in the sense that the dense off-diagonal blocks are in compressed low-rank format. This helps to significantly reduce the algorithmic complexity and storage, and yields structured Jacobi-Jacobi transforms that are both efficient and stable. The matrices in Sec- tion 2.2 are banded or have small off-diagonal ranks. The related transforms can be conveniently done. The matrices can also be considered as special HSS forms. Thus, we focus on the connection matrices in Section 2.1 for Jacobi-Jacobi trans- forms with arbitrary indices. We show that the maximum off-diagonal numerical ranks of those matrices grow polylogarithmically by numerical verification in Sec- tion 3.1 and by theoretical analysis in Section 3.2. 3.1. Low-rank property of Jacobi-Jacobi connection matrices: Numeri- cal verification.In order to gain some intuition, let us present the results of a few numerical experiments on the off-diagonal numerical ranks of the connection matrices K. Each matrix is hierarchically partitioned intol max levels of HSS blocks [51], which are block rows or columns excluding the diagonal blocks. (See Figure 2 for an illustration.) At levelsl =0 ,1,...,l max (from the root to the leaf levels), the HSS block rows have row sizesNl and maximum numerical rankrl.F o rc o n - venience, suppose the partition is uniform andNl ≈N/2l.W ew i l ls e et h a tw h e n This is a free offprint provided to the author by the publisher. Copyright restrictions may apply . 1756 J. SHEN, Y. WANG, AND J. XIA l decreases andNl roughly doubles,rl only increases slightly. Hererl is said to be a rank patternwith respect tol in [50]. We consider (α,β) in two square regions: •Ω1 =[ −1,0]2 with center t =( −1/2,−1/2), which corresponds to the Chebyshev-Jacobi case; •Ω2 =[ α∗−1/2,α∗+1/2]×[β∗−1/2,β∗+1/2]with j∗:= (α∗,β∗)=( 3 √ 3,π). In Figure 1, we show the rank patternsrl (versus Nl) for the HSS block rows at level l of the HSS partition, where the relative tolerance for computing the numerical ranks isτ=1 0−8,a n dNlmax = 20. Some randomly chosen pointsj in the regions are used for the tests. For comparison purposes, we also plot reference lines forO(logNl)a n dO(loglog Nl). We can observe the following: (1) In all of the three cases, the numerical ranksrl for HSS blocks at levell increaseveryslowly, infact, muchslowerthan O(logNl). Instead, itroughly follows the pattern ofO(loglog Nl) initially in our computation, although not yet analytically justified. The numerical ranks stop to increase when Nl is sufficiently large. (2) The numerical rank patternsrl related to two sets of indices (α,β)a n d (α∗,β∗) appear to depend only on their relative locations, by the compari- son of the results from Ω1 in Figure 1(c-d) and Ω2 in Figure 1(e-f). 3.2. Low-rank property of Chebyshev-Legendre connection matrices: The- oretical analysis. We then focus on the Chebyshev-Legendre case and show the low-rank property analytically. The following result is well known and its variations are frequently used in the FMM (see, e.g., [14]). Here, we make it slightly more precise for our case. Lemma 3.1. For a given toleranceϵ> 0, suppose the entries of anm×n matrix A satisfy the following: (3.1) A ij = r∑ k=1 fk(i)gk(j)+ bi,j, 1 ≤i ≤m, 1 ≤j ≤n, where r< min(m,n), |bi,j|≤ ϵ,a n d{fk}r k=1 and {gk}r k=1 are continuous functions defined on[1,m] and [1,n], respectively. That is,Aij is defined by a function with a separable approximation. Then the numerical rank ofA with respect to the tolerance ϵ√mn is bounded byr. Proof. The proof is relatively obvious. Equation (3.1) means thatA can be written as A = FGT +B, where F =( fj(i))m×r, G =( gj(i))n×r, B =( bi,j)m×n. Clearly, ||B||2 ≤√mn||B||max ≤ϵ√mn, where ∥B∥max is the largest entry of the matrix|B|. Thus, the numerical rank of A with respect to the toleranceϵ√mn is at mostr. □ Let us then consider some useful properties of the function Λ(z) defined in (2.15). This is a free offprint provided to the author by the publisher. Copyright restrictions may apply . FAST STRUCTURED JACOBI-JACOBI TRANSFORMS 1757 Nl 101 102 103 104 rl 10 20 30 40 50 O(logNl) O(loglogNl) Chebyshev-Legendre Nl 101 102 103 104 rl 10 20 30 40 50 O(logNl) O(loglog Nl)) Chebyshev-Legendre (a) Kt→ l (b) Kl→ t Nl 101 102 103 104 rl 10 20 30 40 50 O(logNl) O(loglogNl) Nl 101 102 103 104 rl 10 20 30 40 50 O(logNl)) O(loglogNl) (c) Kt→ j (d) Kj→ t Nl 101 102 103 104 rl 10 20 30 40 50 O(logNl) O(loglogNl) Nl 101 102 103 104 rl 10 20 30 40 50 O(logNl) O(loglogNl) (e) Kj∗→ j (f) Kj→ j∗ Figure 1. Numerical ranksrl of the HSS block rows (of row sizes Nl)a tl e v e ll of the hierarchical partition of the (a-b) Chebyshev- Legendre, (c-d) Chebyshev-Jacobi, and (e-f) Jacobi-Jacobi connec- tion matrices, where randomly selected indicesj =( α,β) ∈Ω 1 and j =( α,β) ∈Ω2 are used for the solid lines in (c-d) and (e-f), respectively. This is a free offprint provided to the author by the publisher. Copyright restrictions may apply . 1758 J. SHEN, Y. WANG, AND J. XIA •Λ(z) decreases with respect toz and is bounded, i.e., for anyz ≥1, (3.2) Λ( z +1) ≤Λ(z) ≤Λ(1) = Γ (3 2 ) = √π 2 . •It can be shown that for integerz, (3.3) lim z→∞ Λ(z)=0 . •Λ(z) has an asymptotic expansion in the following form for anyz ≥ 1 [12,46]: (3.4) Λ( z)= n−1∑ m=0 amz−(m+1/2) + ˆEn(z), where (3.5) am =( −1)m Γ(m+1/2) Γ(m+1)Γ(1/2)B(1/2) m (1 2 ) , ˆEn(z)= O(z−(n+1/2)), with B(μ) m (x) being the generalized Bernoulli polynomials [29]. •The first order approximation to Λ(z)i s (3.6) Λ( z)= z−1/2 +O(z−3/2), as z →∞ .I ti m p l i e st h a tf o ra n yg i v e n0<ϵ< 1, there exists an integer (3.7) ˜Nϵ = O(ϵ−2), such that (3.8) |Λ(z)| <ϵ for any z> ˜Nϵ. The following lemma shows the asymptotic behavior ofam for sufficiently large m. Lemma 3.2. The coefficients{am} in (3.4) satisfy |am| = O(mm−1(2πe)−m) as m →∞ . Proof. We observe from (3.2) that, form ≥1, (3.9) Γ(m+1/2) Γ(m+1)Γ(1/2) = Λ(m) Γ(1/2) ≤ √π/2√π = 1 2. In addition, the first order approximation to theB(1/2) m (1/2) is [24] B(1/2) m (1/2) = 2(m!) m1/2(2π)mΓ(1/2) [ cos (π 2(3−m) ) +O(m−1) ] . By Stirling’s formula, we have (3.10) ⏐⏐⏐ ⏐B (1/2) m (1 2 )⏐⏐⏐ ⏐ = O ( m m (2πe)m ) . One can easily draw the conclusion from (3.9) and (3.10). □ Remark 6. The function Λ(z) can be computed efficiently in the following way: •For z< 15, one can compute Λ(z) directly using the Γ function. •For z ≥15, one can compute Λ(z) via the approximate expansion Λ(z) ≈∑5 m=0 amz−m−1/2, where the coefficients{am}5 m=0 for z in different inter- vals are given in double precision in the Appendix of [2]. This is a free offprint provided to the author by the publisher. Copyright restrictions may apply . FAST STRUCTURED JACOBI-JACOBI TRANSFORMS 1759 Lemma 3.3([7]). The functionz−θwith θ>0, z ∈[1,R] can be approximated by a sum of exponentials withr terms, i.e., z−θ= r∑ i=1 si exp(−tiz)+ Er,[1,R](z), where {si}r i=1 and {ti}r i=1 are non-negative real numbers independent ofz,a n dt h e error bound is given by (3.11) |Er,[1,R](z)|≤ 23+θexp ( − π2r log(8R) ) . Moreover, for the same coefficients{sk}r k=1 and {tk}r k=1, the error bound forz ∈ [1,∞) is (3.12) |Er,[1,∞)(z)| =m a x { |Er,[1,R](z)|,R−θ} . Next, we consider the approximation of Λ(z) by exponential sums. Lemma 3.4. The function Λ(z) defined in(2.15) can be approximated by anr term sum of exponentials with respect to a toleranceϵ: (3.13) Λ( z)= r∑ k=1 wke−vkz +Er,[2,N](z), ⏐⏐Er,[2,N](z) ⏐⏐ <ϵ , where {wk}r k=1 and {vk}r k=1 are non-negative real numbers independent ofz,a n d for 2 ≤z ≤N, (3.14) r = O ( log2 1 ϵ loglog 1 ϵ logN ) . Moreover, ther term approximation in (3.13) can be extended fromz ∈[2,N ] to z ∈[2,∞) with the error bound (3.15) ⏐⏐Er,[2,∞)(z) ⏐⏐ < max{ϵ,Λ(N)}. Besides, ⏐⏐Er,[2,∞)(z) ⏐⏐ <ϵ with (3.16) r =˜rϵ := O ( log3 1 ϵ loglog 1 ϵ ) . Proof. By settingθ= m+1/2 in Lemma 3.3, we have forz ∈[2,N ], (3.17) z−(m+1/2) = rm∑ i=1 sm,ie−tm,iz +Erm,[2,N](z), where we use the subscriptm in rm,sm,i,Erm,[2,N] to indicate the dependence on m, and the error bound is (3.18) |Erm,[2,N](z)|≤| Erm,[1,N](z)|≤ 2m+7/2 exp ( − π2rm log(8N) ) . By (3.4), Λ(z)= n−1∑ m=0 am ( rm∑ i=1 sm,ie−tm,iz +Erm,[2,N](z) ) + ˆEn(z) = n−1∑ m=0 rm∑ i=1 amsm,ie−tm,iz + n−1∑ m=0 amErm,[2,N](z)+ ˆEn(z). This is a free offprint provided to the author by the publisher. Copyright restrictions may apply . 1760 J. SHEN, Y. WANG, AND J. XIA Thus, Λ(z) can be rewritten in the form of (3.13) with Er,[2,N](z)= n−1∑ m=0 amErm,[2,N](z)+ ˆEn(z), r = n−1∑ m=0 rm.(3.19) We choose n and r so that |Er,[2,N](z)| <ϵ in (3.13) holds for any z ≥ 2. A c c o r d i n gt o( 3 . 5 ) ,w ec a nc h o o s en so that |ˆEn(z)|≤| ˆEn(2)| = O(2−(n+1/2)). That is, (3.20) n = O ( log 1 ϵ ) . According to (3.18), we can chooserm so that |am|2m+7/2 exp ( − π2rm log(8N) ) = O (ϵ n ) . That is, rm = O ( logN(log|am|+log n ϵ +m) ) = O ( logN(log|am|+log 1 ϵ +log n+m) ) = O ( logN(log|am|+log 1 ϵ +n) ) . For sufficiently largem, the estimate in Lemma 3.2 yields (3.21) rm = O ( (log 1 ϵ +nlogn)log N ) . For m that is not very large, a smaller estimaterm = O((log(1/ϵ)+ n)log N)i s obtained sincen is the dominate term as compared with log|am|. Combining (3.19), (3.20), and (3.21), we have r = n−1∑ m=0 O ( (log 1 ϵ +nlogn)log N ) = O ( log2 1 ϵ loglog 1 ϵ logN ) . Thus, by choosingr in (3.19) to be (3.14), we can ensure that (3.13) holds. Moreover, by (3.4), (3.12), and the non-negativity of ∑r i=1 wke−vkz,w ec a n conclude (3.15). Finally, from (3.6) and˜Nϵ defined in (3.7)–(3.8), if we replaceN in (3.14) and (3.15) by ˜Nϵ, we can obtain ⏐⏐Er,[2,∞)(z) ⏐⏐ <ϵ with the estimate ofr in (3.16). □ We are now ready to present the following theorem regarding the Chebyshev- Legendre connection matrices. This is a free offprint provided to the author by the publisher. Copyright restrictions may apply . FAST STRUCTURED JACOBI-JACOBI TRANSFORMS 1761 Theorem 3.5. The off-diagonal blocks of the backward and forward Chebyshev- Legendre transform matricesKl→ t =( κl→ t i,j ) and Kt→ l =( κt→ l i,j ) are of low nu- merical ranks. More precisely, for a given toleranceϵ, the numerical ranks of the HSS blocks are r = O ( log6 1 ϵ log2(log 1 ϵ) ) with respect to the tolerance1 2Nϵ. A1 (1) A1 (2) A2 (2) (a) 1-level partition (b) 2-level partition Figure 2. Two levels of partition ofA := Kl→ t,w h e r et h eb l o c k rows without the diagonal subblocks are HSS blocks, as marked in blue color. Proof. Since Kl→ t is the inverse ofKt→ l, we only need to show the off-diagonal numerical rank bounds for one of them, and the same bounds also apply to theother case. We focus onA := Kl→ t.N o t et h a tA is upper triangular. We partitionA as in Figure 2 following different levels of hierarchical partition. The HSS block rows at levell are denoted byA(l) m , m =1 ,2,..., 2l −1. For convenience, assume each A(l) m has row sizeNl. We study the numerical ranks of all the blocksA(l) m . According to Lemma 2.6, each entry ofA(l) m has the form (A(l) m )ij = κl→ t (m−1)Nl+i, mNl+j, i =1 ,2,...,N l,j =1 ,2,..., (2l −m)Nl, and (A(l) m )ij can be generated by a scalar multiple of the following function: φl,m(x,y)=Λ (1 2(Nl +y −x) ) Λ (1 2((2m−1)Nl +y +x) ) ,(3.22) (x,y) ∈Θl,m ∪Ωl,m ⊂R2, where Θl,m := [1,Nl]×[1,3], Ωl,m := [1,Nl]×[4,(2l −m)Nl]. Here, (A(l) m )ij = 1 πφl,m(i,j)i f i =1 ,a n d(A(l) m )ij = 2 πφl,m(i,j)i f i> 1. The difference in the scalar for generating the first row does not impact the study of the rank structure. Besides, the points (i,j) ∈Θ l,m correspond to the first three columns in the block (A(l) m )ij, the rank of which is at most 3. We will focus on the numerical rank of theA(l) m from the fourth column to theNth column, where the indices (i,j)a r e located in the the subdomain Ωl,m. This is a free offprint provided to the author by the publisher. Copyright restrictions may apply . 1762 J. SHEN, Y. WANG, AND J. XIA Furthermore, we define˜Ωl,1 =[ 1,Nl]×[4,2N]. It is easy to see that Ωl,2l ⊂···⊂ Ωl,m+1 ⊂Ωl,m ⊂···⊂ Ωl,1 ⊂˜Ωl,1. For fixedl, on each domain Ωl,m, we consider the following two functions: V− m (x,y)= 1 2(Nl +y −x),V + m (x,y)= 1 2((2m−1)Nl +y +x) ∀(x,y) ∈Ωl,m. It implies thatφl,m(x,y)=Λ (V− m (x,y))Λ(V+ m(x,y)) ∀(x,y) ∈Ωl,m. (1) For any (x,y) ∈Ωl,m, we can findx′ − = x,y′ − = y such that (x′ −,y′ −) ∈Ωl,1 and (3.23) V− m (x,y)= V− 1 (x′ −,y′ −). (2) For any (x,y) ∈Ωl,m, we can findx′ + = x,y′ + =2 (m−1)Nl +y such that (x′ +,y′ +) ∈˜Ωl,1 and (3.24) V+ m (x,y)= V+ 1 (x′ +,y′ +). This indicates that we can consider the case m = 1 first. That is, we con- sider the approximation of Λ(V− 1 (x,y)) on Ωl,1 and Λ(V+ 1 (x,y)) on ˜Ωl,1 by sum of exponentials. It is easy to know that 2 ≤V− 1 (x,y) ≤1 2(N −1), (x,y) ∈Ωl,1,(3.25) 1 2(Nl +5) ≤V+ 1 (x,y) ≤1 2(N +Nl), (x,y) ∈˜Ωl,1.(3.26) For sufficiently largeN,w eh a v em i n {1 2(N −1), 1 2(N +Nl) } > ˜Nϵ for ϵ in (3.7). Setting z = V± 1 (x,y) in Lemma 3.4 leads to the following approximations: Λ ( V− 1 (x,y) ) = F− l (x,y)+ Er−,[2,∞),(3.27) Λ ( V+ 1 (x,y) ) = F+ l (x,y)+ Er+,[2,∞),(3.28) where F− l (x,y)= r− ∑ k=1 w− k e−1 2v− k Nle 1 2v− k xe−1 2v− k y,(3.29) F+ l (x,y)= r+ ∑ k=1 w+ k e−1 2v+ k Nle−1 2v+ k xe−1 2v+ k y,(3.30) and the superscripts−and + are added to the constants in (3.13) to distinguish the two cases. Moreover, for a given toleranceϵ, by (3.16), we can chooser± such that (3.31) r± = O ( log3 1 ϵ loglog 1 ϵ ) , max { Er−,[2,∞), Er+,[2,∞) } ≤ϵ. It follows that φl,1(x,y)=Λ ( V− 1 (x,y) ) Λ ( V+ 1 (x,y) ) = ( F− l (x,y)+ Er−,[2,∞) )( F+ l (x,y)+ Er+,[2,∞), ) = r∑ k=1 ˜wk,le˜v(1) k,lxe˜v(2) k,ly + ˜Er,(3.32) This is a free offprint provided to the author by the publisher. Copyright restrictions may apply . FAST STRUCTURED JACOBI-JACOBI TRANSFORMS 1763 where the coefficients ˜wk,l,˜v(1) k,l ,˜v(2) k,l are obtained from the coefficients in (3.29)– (3.30), and r = r−r+ = O ( log6 1 ϵ log2(log 1 ϵ) ) ,(3.33) |˜Er|≤ max { Er−,[2,∞), Er+,[2,∞) } max { Λ ( V− 1 (x,y) ) ,Λ ( V+ 1 (x,y) )} (3.34) ≤ϵΛ(1) = √π 2 ϵ<ϵ . We are done for the case withm =1 . For the case withm ≥2, by the relation (3.23), we know that the approximation (3.27) and (3.29) still hold for Λ(V− m (x,y))∀(x,y) ∈Ωl,m, with the same estimates of r− l and the approximation error in (3.31). Besides, due to (3.24), (3.28), and (3.30), the function Λ(V+ m (x,y))∀(x,y) ∈Ωl,m, can be approximated by Λ(V+ m(x,y)) = Λ(V+ 1 (x,2(m−1)Nl +y))(3.35) = r+ ∑ k=1 w+ k e−1 2v+ k (2m−1)Nle−1 2v+ k xe−1 2v+ k y +Er+,[2,∞), where r+ is still given in (3.31). The estimates ofr± and approximation errors then do no depend onm. Thus, the rank estimate shown in (3.33) and error estimate shown in (3.34) hold for anym ≥1. Therefore, the functionφl,m(x,y) that generatesA(l) m has a separable approxi- mation as in (3.32) with the error bounded byϵ. According to Lemma 3.1, the numerical rank of the HSS block A(l) m is then r with respect to the tolerance ϵ √ Nl(N −Nl) ≤1 2Nϵ. □ The result above rigorously establishes the low-rank property for the transform matrices of the Chebyshev-Legendre case. The rank bound may be grossly overes- timated since the numerical tests indicate much smaller ranks. For more general Chebyshev-Jacobi and Jacobi-Jacobi cases, it is difficult to rigorously prove their low-rank property due to the lack of explicit generating functions for the connection matrices. However, we showed numerically in Figure 1(c-f) that they also enjoy the low-rank property. The detailed HSS matrix-vector multiplication algorithm can be found in [9,48]. Since the upper bound of the numerical HSS rank is a constant for a fixed tolerance ϵ, we can conclude that the computational cost of HSS matrix-vector multiplication is linearO(N). 4. F ast structured Jacobi-Jacobi transforms In this section, we present our fast structured Jacobi-Jacobi transforms (FSJJT) and fast structured Jacobi transforms (FSJT). The studies of the low-rank in the previoussectionmeanthatHSSrepresentationsorapproximations canbecomputed for the connection matrices. For the case where the differences in the indices are integers, the connection matrices are banded or highly structured with analytical HSS forms. When the differences in the indices are not integers, a one-time HSS construction is needed. There are two popular ways to construct such an HSS form: direct block compres- sion [51] and randomized sampling [52]. If the maximum off-diagonal numerical This is a free offprint provided to the author by the publisher. Copyright restrictions may apply . 1764 J. SHEN, Y. WANG, AND J. XIA rank is r, the constructions costO(rN2) flops. For cases like in Theorem 3.5,r is a constant for a fixed toleranceϵ. Here, since our main purpose is to compute Jacobi-Jacobi transforms, to ensure stability, we spend a one-time cost in the pre- computation stage to construct the HSS approximation based on the method in [51]. The method uses rank-revealing factorizations to compress the off-diagonal blocks, which is known to usually yield nearly optimal low-rank approximations. The resulting HSS form can be used to compute matrix-vector multiplications with superior efficiency and stability. The cost to multiply the HSS form and a vector is O(rN). 4.1. Fast structured Jacobi-Jacobi transforms (FSJJT). We consider the following forward FSJJT: f (α2,β2) = Kj1→ j2f(α1,β1),w h e r ej1 =( α1,β1), j2 = (α2,β2). Letmα= α2−α1, mβ= β2−β1 be the difference parameters. Depending on mα and mβ, our algorithm works as follows: •Both mα and mβare positive integers.We can quickly perform the integer promotion with linear cost based on Theorem 2.8. The algorithm has two steps: (1) Initialization. Compute the vectors as in Theorem 2.8 that define the bidiagonal matrices K (α1+i,β1)→(α1+i+1,β), K(α2,β1+i)→(α2,β1+i+1). (2) Multiplication. Promote the index fromα1 to α2 while fixingβ1 via bidiagonal multiplication: f(α2,β1) = mα−1∏ i=0 K(α1+i,β1)→(α1+i+1,β1)f(α1,β1). Promote the index fromβ1 to β2 while fixingα2 via bidiagonal multi- plication: f(α2,β2) = mβ−1∏ i=0 K(α2,β1+i)→(α2,β1+i+1)f(α2,β1). Thetotalcostisabout3( mα+mβ)N flops. Thiscanbefurtherreduced when simultaneous promotion as in Theorem 2.10 is used. •Both mα and mβ are integers, with one or both negative. (1) Initialization. Following Remark 5, get the HSS representations based on Corollary 2.12 (for multiplications), or the bidiagonal ma- trices based on Theorem 2.8 (for solutions). (2) Multiplication. Then perform the transform via fast HSS matrix- vector multiplications or bidiagonal solutions. The total cost isO((m α+mβ)N)fl o p s . •mα, mβ∈(−1,1). (1) Initialization. Compute an HSS approximation toKj1→ j2 via direct or randomized HSS construction in a precomputation. (2) Multiplication. Then perform fast HSS matrix-vector multiplica- tions for the corresponding transform. After the one-time HSS construction, the multiplication cost is at most O(rN), wherer is the maximum numerical rank of the HSS blocks. This is a free offprint provided to the author by the publisher. Copyright restrictions may apply . FAST STRUCTURED JACOBI-JACOBI TRANSFORMS 1765 •Other cases. For a general difference parameter, we can split it into the sum of an integer and a number in (−1,1). This can then be handled by combining the procedures above. 4.2. Fast structured Jacobi transforms (FSJT). We now consider the fast structured Jacobi transform (FSJT) between function values f 0 at Chebyshev- Gauss-type points and expansion coefficientsf(α,β) of Jacobi polynomials with any indices α,β: (4.1) f 0 DCT ←→f t FSCJT ←→ f(α,β), where f t is the vector of Chebyshev expansion coefficients as mentioned at the end of Section 1. DCT means discrete cosine transform which can be done inO(logN) operations, and FSCJT denotes the fast structured Chebyshev-Jacobi transform which is a special case of FSJJT. The algorithm also has two steps: (1) Initialization. Given the function valuesf 0, perform the forward Cheby- shev transform to obtain the expansion coefficientsf t, and compute an HSS representation/approximation for Chebyshev-Jacobi transform. (2) Multiplication. Perform the forward FSCJTf(α,β) = Kt→(α,β)f t using fast HSS matrix-vector multiplications. Some additional remarks are in order. •The initialization stage of the above algorithms hasO((mα+mβ)N)c o m - plexity ifmα and mβ are integers. Otherwise, a one-time precomputation (HSS construction) of costO(rN2)i su s e d . •According to Remark 4, for the integer parametersmα and mβ satisfying, say,mα≤mβ, we should first promote the indicesα,βsimultaneously, and then promote the indexβ, i.e.,f(α,β) → f(α+mα,β+mα) → f(α+mα,β+mβ). •Our method works for more general Jacobi transforms than the method by Hale and Townsend in [17] for the Chebyshev-Legendre transform (see also [37] for the Chebyshev-Jacobi transform) based on an asymptotic formula. For the special case of Chebyshev-Legendre transform, the method in [17] costsO(N log 2 N/loglog N), andourmethodcosts O(N)aftertheone-time HSS construction. •In the direct Jacobi transform (1.1), the matrixJ(α,β) =( J(α,β) n (xj))N−1 n,j=0 generally does not have the low-rank property. However, by employing the Chebyshev transform as the intermediate step as in (4.1), we can take advantage of the low-rank property of the connection matricesKt→(α,β) and K(α,β)→ t, and obtain FSJT together with FFT. •HSS multiplication has superior stability, as shown in [48,49]. In fact, the backward error only depends on log2 N and a low-degree term ofr.I n comparison, in standard dense matrix-vector multiplication, the backward error depends on the condition number of the matrix. 5. Numerical experiments We now present some numerical experiments to illustrate the efficiency and ac- curacy of our fast structured transforms. When HSS constructions are needed for am a t r i xA in the tests, a relative toleranceτ=1 0−12 is used, and the finest level HSS block row size is about 40. This is a free offprint provided to the author by the publisher. Copyright restrictions may apply . 1766 J. SHEN, Y. WANG, AND J. XIA First, let us start with the Chebyshev-Legendre transform. We test these meth- ods: •FSCLT: our proposed fast structured Chebyshev-Legendre transform; •CLTAF:t h eO(N log2 N/loglog N) complexity method in [17] (which can apply in this special case); •Direct: the direct Chebyshev-Legendre transform. In FSCLT, a connection matrixK is approximated by an HSS form in a precom- putation stage. We perform the forward and backward Chebyshev-Legendre transforms with the three methods. The flop counts are given in Figure 3, together with reference lines forO(N 2), O(N log2 N/loglog N), andO(N). The results roughly follow the estimates. WhenN increases, both FSCLTand CLTAFare much faster thanDirect. Besides, FSCLT also has a significant advantage overCLTAFfor largeN,a n db o t h methods achieve comparable accuracies. See Table 1. 10 1 10 2 10 3 10 4 10 5 N 10 4 10 5 10 6 10 7 10 8 10 9 10 10 Flops Direct CLTAF FSCLT O(N2) O(Nlog2(N)/log(log(N))) O(N) 10 1 10 2 10 3 10 4 10 5 N 10 4 10 5 10 6 10 7 10 8 10 9 10 10 Flops Direct CLTAF FSCLT O(N2) O(N log2(N)/log(log(N))) O(N) (a) Kt→ l (b) Kl→ t Figure 3. Flops of Chebyshev-Legendre transforms. Table 1. Accuracies of FSCLT and CLTAF for Chebyshev- Legendre transforms of random vectors. N Kt→ l Kl→ t FSCLT CLTAF FSCLT CLTAF 160 6.1466e-14 1.5815e-14 4.3208e-14 2.1671e-14 320 2.7861e-13 3.1610e-14 3.0375e-13 1.5178e-13 640 2.2266e-13 2.7652e-14 3.0139e-13 8.5224e-13 1280 1.7845e-13 5.3438e-14 5.7378e-13 7.1993e-13 2560 2.2830e-13 9.9047e-14 1.5104e-12 1.3362e-11 5120 4.1844e-13 1.1875e-13 1.2649e-12 1.3817e-11 Our proposedFSCLTalso applies to more general Jacobi-Jacobi transforms than CLTAF. For example, we show the numerical results for the Chebyshev-Jacobi trans- form with (α,β)=( − √ 2 2 , π 4) in Figure 4(a-b) and the Jacobi-Jacobi transform be- tween (α1,β1)=( 2,1) and (α2,β2)=( 3 √ 3,π) in Figure 4(c-d). We can observe that the costs of our proposed fast structured transforms are nearly linear inN. This is a free offprint provided to the author by the publisher. Copyright restrictions may apply . FAST STRUCTURED JACOBI-JACOBI TRANSFORMS 1767 10 1 10 2 10 3 10 4 10 5 N 10 4 10 5 10 6 10 7 10 8 10 9 Flops Direct FSCJT O(N2) O(N) 10 1 10 2 10 3 10 4 10 5 N 10 4 10 5 10 6 10 7 10 8 10 9 Flops Direct FSCJT O(N2) O(N) (a) Kt→ (α,β) (b) K(α,β)→ t 10 1 10 2 10 3 10 4 10 5 N 10 4 10 5 10 6 10 7 10 8 10 9 Flops Direct FSJJT O(N2) O(N) 10 1 10 2 10 3 10 4 10 5 N 10 4 10 5 10 6 10 7 10 8 10 9 Flops Direct FSJJT O(N2) O(N) (c) K(α1,β1)→ (α2,β2 ) (d) K(α2,β2 )→ (α1,β1) Figure 4. Flops of (a-b) Chebyshev-Jacobi transforms and (c-d) Jacobi-Jacobi transforms. Next, we demonstrate the benefit of numerical stability of the fast transform method. For relatively largeαand/or β, a straightforward Jacobi transform based on the explicit evaluation of the connection matrices as in Lemma 2.2 may have numerical stability issues due to the large values ofJ(α,β) n (±1) asn increases. On the other hand, our structured transform has nice stability as mentioned before. To illustrate this, we perform a forward transform followed by a backward one as in K(α2,β2)→(α1,β1)K(α1,β1)→(α2,β2)f(α1,β1), and measure the error ∥K(α2,β2)→(α1,β1)K(α1,β1)→(α2,β2)f(α1,β1) −f(α1,β1)∥ ∥f(α1,β1)∥ , where the norm is the Jacobi weighted norm (5.1) ∥f(α,β)∥ = √ N∑ n=0 (f(α,β) k )2γ(α,β) k , with γ(α,β) k defined in (2.7). Since we are usually interested in Jacobi transforms of functions with certain smoothness, i.e., with decaying Jacobi coefficients, we take random vectorsf(α,β) and scale their entries so that they decay like:n−1, n−1.5, n−6.5,o re x p (−36n/N). This is a free offprint provided to the author by the publisher. Copyright restrictions may apply . 1768 J. SHEN, Y. WANG, AND J. XIA 10 2 10 3 10 4 10 5 N 10 -18 10 -16 10 -14 10 -12 10 -10 Errors 10 2 10 3 10 4 10 5 N 10 -18 10 -16 10 -14 10 -12 10 -10 Errors (a) ∥Kt→ l Kl→ t f l−f l∥ ∥f l∥ (b) ∥Kl→ t Kt→ lf t−f t∥ ∥f t∥ 10 2 10 3 10 4 10 5 N 10 -16 10 -14 10 -12 10 -10 Errors 10 2 10 3 10 4 10 5 N 10 -16 10 -14 10 -12 10 -10 Errors (c) ∥Kt→ (α,β)K(α,β)→ t f(α,β)−f(α,β)∥ ∥f(α,β)∥ (d) ∥K(α,β)→ t Kt→ (α,β)f t−f t∥ ∥f t∥ 10 2 10 3 10 4 10 5 N 10 -16 10 -14 10 -12 10 -10 Errors 10 2 10 3 10 4 10 5 N 10 -16 10 -14 10 -12 10 -10 Errors (e) ∥Kt→ (α,β)K(α,β)→ t f(α,β)−f(α,β)∥ ∥f(α,β)∥ (f) ∥K(α,β)→ tKt→ (α,β) f t−f t∥ ∥f t∥ Figure 5. Stability test for (a-b) Chebyshev-Legendre trans- forms, (c-d) Chebyshev-Jacobi transforms with (α,β)=( − √ 2 2 , π 4), and (e-f) Chebyshev-Jacobi transforms with (α,β)=( 1 0 √ 3,10π). We perform three different transforms (i) Chebyshev-Legendre transform ((α,β)= (0,0)); (ii) Chebyshev-Jacobi transform with small indices ((α,β)=( − √ 2 2 , π 4)); (iii) Chebyshev-Jacobi transform with large indices ((α,β)=( 1 0 √ 3,10π)). As discussed in Section 4.1, the case (iii) can be split into two steps: the first one is the Chebyshev-Jacobi transform with indices (¯α,¯β)=( 1 0 √ 3−17,10π−31) ≈ This is a free offprint provided to the author by the publisher. Copyright restrictions may apply . FAST STRUCTURED JACOBI-JACOBI TRANSFORMS 1769 (0.32,0.42), and the second one is the Jacobi-Jacobi transform with integer differ- ences (mα= 17,mβ= 31) between (α,β)a n d(¯α,¯β). The results are shown in Figure 5. Nice accuracies are observed. For some cases, the errors only slightly increase with the matrix size. This indicates the stability of our fast structured transform, even with respect to relatively largeαand/or β. 6. Concluding remarks In this paper, we developed efficient and robust algorithms for Jacobi-Jacobi transforms with arbitrary indices. To achieve this, we derived explicit formulas for the connection matrices between two Jacobi polynomials with different indices, and then showed that these matrices have the low-rank property. After a one-time precomputation with quadratic complexity, the Jacobi-Jacobi transforms can be accomplished in nearly linear complexity, which is verified either analytically or numerically. Animportant byproduct ofthe proposed fast Jacobi-Jacobi transform is a fast al- gorithmtoperformthetransformbetweenthefunctionvaluesatasetofChebyshev- Gauss-type points and coefficients of the Jacobi expansion with arbitrary indices. Numerical results indicate that our algorithm achieves the desired complexity, and is numerically stable for Jacobi transforms with relatively large indices. It is apparent that the main techniques and strategies developed in this paper can be applied to many other situations. Indeed, we are currently working on the following situations: •The strategy of fast structured Jacobi-Jacobi transforms can be used to develop fast transforms between the family of generalized Laguerre polyno- mials. •Amoredifficult problem istoconstructafast sphericalharmonictransform. Many attempts have been made in this regard [31,38,39,47], but they are still not fully satisfactory. The main difficulty, as compared with the Jacobi case, is that the spherical harmonic expansion involves associated Legendre polynomials with a full range of indices, rather than a fixed index. It is hopeful that, by exploring the relations between associated Legendre polynomials and Chebyshev polynomials, one can construct a robust and fast structured spherical harmonic transform. References [1] H. Alıcı and J. Shen,Highly accurate pseudospectral approximations of the prolate spheroidal wave equation for any bandwidth parameter and zonal wavenumber,J .S c i .C o m p u t .71 (2017), no. 2, 804–821, DOI 10.1007/s10915-016-0321-7. MR3627542 [2] B. K. Alpert and V. Rokhlin,A fast algorithm for the evaluation of Legendre expansions, SIAM J. Sci. Statist. Comput.12 (1991), no. 1, 158–179, DOI 10.1137/0912009. MR1078802 [ 3 ]G .E .A n d r e w s ,R .A s k e y ,a n dR .R o y ,Special Functions, Encyclopedia of Mathematics and its Applications, vol. 71, Cambridge University Press, Cambridge, 1999. MR1688958 [4] T. Bella and J. Reis,The spectral connection matrix for classical orthogonal polynomials of a single parameter, Linear Algebra Appl.458 (2014), 161–182, DOI 10.1016/j.laa.2014.06.002. MR3231813 [5] J. Reis, The spectral connection matrix for classical real orthogonal polynomials,P r o Q u e s t LLC, Ann Arbor, MI, 2015. Thesis (Ph.D.)–University of Rhode Island. MR3358129 [ 6 ] J .P .B o y d ,Algorithm 840: computation of grid points,quadrature weights and derivatives for spectral element methods using prolate spheroidal wave functions—prolate elements,A C M Trans. Math. Software31 (2005), no. 1, 149–165,DOI 10.1145/1055531.1055538. MR2291545 This is a free offprint provided to the author by the publisher. Copyright restrictions may apply . 1770 J. SHEN, Y. WANG, AND J. XIA [7] D. Braess and W. Hackbusch,On the efficient computation of high-dimensional integrals and the approximation by exponential sums, Multiscale, nonlinear and adaptive approximation, Springer, Berlin, 2009, pp. 39–74, DOI 10.1007/978-3-642-03413-83. MR2648371 [8] C. Canuto, M. Y. Hussaini, A. Quarteroni, and T. A. Zang, Spectral Methods, Scientific Computation, Springer-Verlag, Berlin,2006. Fundamentals in single domains. MR2223552 [9] S. Chandrasekaran, M. Gu, and T. Pals,A fast ULV decomposition solver for hierarchically semiseparable representations, SIAM J. Matrix Anal. Appl.28 (2006), no. 3, 603–622, DOI 10.1137/S0895479803436652. MR2262971 [10] S. Chandrasekaran and M. Gu,A divide-and-conquer algorithm for the eigendecomposition of symmetric block-diagonal plus semiseparable matrices,N u m e r .M a t h .96 (2004), no. 4, 723–731, DOI 10.1007/s00211-002-0199-1. MR2036363 [11] M. Dubiner, Spectral methods on triangles and other domains, J. Sci. Comput. 6 (1991), no. 4, 345–390, DOI 10.1007/BF01060030. MR1154903 [12] C. L. Frenzen,Error bounds for asymptotic expansions of the ratio of two gamma functions, SIAM J. Math. Anal.18 (1987), no. 3, 890–896, DOI 10.1137/0518067. MR883576 [13] D. Gottlieb and C.-W. Shu,On the Gibbs phenomenon and its resolution,S I A MR e v .39 (1997), no. 4, 644–668, DOI 10.1137/S0036144596301390. MR1491051 [14] L. Greengard and V. Rokhlin, A fast algorithm for particle simulations [ MR0918448 (88k:82007)], J. Comput. Phys. 135 (1997), no. 2, 279–292, DOI 10.1006/jcph.1997.5706. With an introduction by John A. Board, Jr.; Commemoration of the 30th anniversary{of J. Comput. Phys.}. MR1486277 [15] B.-y. Guo, Jacobi approximations in certain Hilbert spaces and their applications to singular differential equations, J. Math. Anal. Appl. 243 (2000), no. 2, 373–408, DOI 10.1006/jmaa.1999.6677. MR1741531 [16] B.-y. Guo and L.-l. Wang, Jacobi approximations in non-uniformly Jacobi-weighted Sobolev spaces, J. Approx. Theory 128 (2004), no. 1, 1–41, DOI 10.1016/j.jat.2004.03.008. MR2063010 [17] N. Hale and A. Townsend, A fast, simple, and stable Chebyshev-Legendre transform us- ing an asymptotic formula ,S I A MJ .S c i .C o m p u t .36 (2014), no. 1, A148–A167, DOI 10.1137/130932223. MR3163249 [18] G. E. Karniadakis and S. J. Sherwin,Spectral/hp Element Methods for CFD,2 n de d . ,N u - merical Mathematics and Scientific Computation, Oxford University Press, Oxford, 2013. MR3088105 [19] J. Keiner, Gegenbauer polynomials and semiseparable matrices, Electron. Trans. Numer. Anal. 30 (2008), 26–53. MR2480068 [20] J. Keiner,Computing with expansions in Gegenbauer polynomials,S I A MJ .S c i .C o m p u t .31 (2009), no. 3, 2151–2171, DOI 10.1137/070703065. MR2516147 [21] T. Koornwinder,Two-variable analogues of the classical orthogonal polynomials, Theory and application of special functions (Proc. Advanced Sem., Math. Res. Center, Univ. Wisconsin, Madison, Wis., 1975), Academic Press, New York, 1975, pp. 435–495. Math. Res. Center, Univ. Wisconsin, Publ. No. 35. MR0402146 [22] S. Lewanowicz,Quick construction of recurrence relations for the Jacobi coefficients,J .C o m - put. Appl. Math.43 (1992),no. 3, 355–372,DOI 10.1016/0377-0427(92)90021-O. MR1193813 [23] H. Li and J. Shen, Optimal error estimates in Jacobi-weighted Sobolev spaces for polyno- mial approximations on the triangle,M a t h .C o m p .79 (2010), no. 271, 1621–1646, DOI 10.1090/S0025-5718-09-02308-4. MR2630005 [24] J. L. L´opez and N. M. Temme, Large degree asymptotics of generalized Bernoulli and Euler polynomials , J. Math. Anal. Appl. 363 (2010), no. 1, 197–208, DOI 10.1016/j.jmaa.2009.08.034. MR2559053 [25] P. Maroni and Z. da Rocha, Connection coefficients between orthogonal polynomials and the canonical sequence: an approach based on symbolic computation, Numer. Algorithms47 (2008), no. 3, 291–314, DOI 10.1007/s11075-008-9184-9. MR2385739 [26] P. Maroni and Z. da Rocha, Connection coefficients for orthogonal polynomials: symbolic computations, verifications and demonstrations in the Mathematica language, Numer. Algo- rithms 63 (2013), no. 3, 507–520, DOI 10.1007/s11075-012-9634-2. MR3071188 [27] A. Mori, R. Suda, and M. Sugihara,An improvement on Orszag’s fast algorithm for Legendre polynomial transform(Japanese, with English and Japanese summaries), Trans. Inform. Pro- cess. Soc. Japan40 (1999), no. 9, 3612–3615. MR1724286 This is a free offprint provided to the author by the publisher. Copyright restrictions may apply . FAST STRUCTURED JACOBI-JACOBI TRANSFORMS 1771 [28] A. Narayan and J. S. Hesthaven,Computation of connection coefficients and measure mod- ifications for orthogonal polynomials,B I T52 (2012), no. 2, 457–483, DOI 10.1007/s10543- 011-0363-z. MR2931359 [29] F. W. J. Olver,Airy and related functions, NIST handbook of mathematical functions, U.S. Dept. Commerce, Washington, DC, 2010, pp. 193–213. MR2655349 [30] S. A. Orszag, Fast eigenfunction transforms, Science and Computers, Adv. Math. Supple- mentary Studies (G. C. Rota, ed.), vol. 10, Academic Press, New York, USA, 1986, pp. 23–30. [31] V. Rokhlin and M. Tygert,Fast algorithms for spherical harmonic expansions,S I A MJ .S c i . Comput. 27 (2006), no. 6, 1903–1928, DOI 10.1137/050623073. MR2211433 [ 3 2 ]A .R o n v e a u x ,A .Z a r z o ,a n dE .G o d o y ,Recurrence relations for connection coefficients be- tween two families of orthogonal polynomials, J. Comput. Appl. Math. 62 (1995), no. 1, 67–73, DOI 10.1016/0377-0427(94)00079-8. MR1361274 [33] H. E. Salzer,A recurrence scheme for converting from one orthogonal expansion into another, Comm. ACM 16 (1973), no. 11, 705–707, DOI 10.1145/355611.362548. MR0395158 [34] J. Shen,Effcient Chebyshev-Legendre Galerkin methods for elliptic problems, Proceedings of ICOSAHOM’95 34 (1996), 233–239. [35] J. Shen, T. Tang, and L.-L. Wang,Spectral Methods: Algorithms, Analysis and Applications, Springer Series in Computational Mathematics, no. 41, Springer-Verlag, Berlin-Heidelberg, 2011. [36] J. Shen and Y. Wang,M¨untz-Galerkin methodsand applications to mixed Dirichlet-Neumann boundary value problems, SIAM J. Sci. Comput. 38 (2016), no. 4, A2357–A2381, DOI 10.1137/15M1052391. MR3531734 [37] R. M. Slevinsky,On the use of Hahn’s asymptotic formula and stabilized recurrence for a fast, simple and stable Chebyshev–Jacobi transform, IMA Journal of Numerical Analysis (2017), drw070. [38] R. Suda and M. Takami,A fast spherical harmonics transform algorithm,M a t h .C o m p .71 (2002), no. 238, 703–715, DOI 10.1090/S0025-5718-01-01386-2. MR1885622 [39] P. N. Swarztrauber and W. F. Spotz,Generalized discrete spherical harmonic transforms,J . Comput. Phys. 159 (2000), no. 2, 213–230, DOI 10.1006/jcph.2000.6431. MR1752616 [40] G. Szeg¨o, Orthogonal Polynomials, American Mathematical Society Colloquium Publications, Vol. 23. Revised ed, American Mathematical Society, Providence, R.I., 1959. MR0106295 [41] R. Szwarc,Connection coefficients of orthogonal polynomials, Canad. Math. Bull.35 (1992), no. 4, 548–556, DOI 10.4153/CMB-1992-071-3. MR1191515 [42] R. Szwarc, Connection coefficients of orthogonal polynomials with applications to classical orthogonal polynomials, Applications of hypergroups and related measure algebras (Seattle, WA, 1993), Contemp. Math., vol. 183, Amer. Math. Soc., Providence, RI, 1995, pp. 341–346, DOI 10.1090/conm/183/02071. MR1334788 [43] D. Tchiotsop, D. Wolf, V. Louis-Dorr, and R. Husson,ECG data compression using Jacobi polynomials, Proceedings of the 29th Annual International Conference of the IEEE EMBS (Lyon France), 2007, pp. 1863–1867. [44] N. M. Temme, Special Functions, A Wiley-Interscience Publication, John Wiley & Sons, Inc., New York, 1996. An introduction to the classical functions of mathematical physics. MR1376370 [45] A. Townsend, M. Webb, and S. Olver,Fast polynomial transforms based on Toeplitz and Hankel matrices,M a t h .C o m p .87 (2018), no. 312, 1913–1934, DOI 10.1090/mcom/3277. MR3787396 [46] F. G. Tricomi and A. Erd´elyi, The asymptotic expansion of a ratio of gamma functions, Pacific J. Math. 1 (1951), 133–142. MR0043948 [47] M. Tygert, Fast algorithms for spherical harmonic expansions. II, J. Comput. Phys. 227 (2008), no. 8, 4260–4279, DOI 10.1016/j.jcp.2007.12.019. MR2403883 [48] Y. Xi and J. Xia,On the stability of some hierarchical rank structured matrix algorithms, SIAM J. Matrix Anal. Appl. 37 (2016), no. 3, 1279–1303, DOI 10.1137/15M1026195. MR3549882 [49] Y. Xi, J. Xia, S. Cauley, and V. Balakrishnan,Superfast and stable structured solvers for Toeplitz least squares via randomized sampling, SIAM J. Matrix Anal. Appl.35 (2014), no. 1, 44–72, DOI 10.1137/120895755. MR3152737 [50] J. Xia,On the complexity of some hierarchical structured matrix algorithms,S I A MJ .M a t r i x Anal. Appl. 33 (2012), no. 2, 388–410, DOI 10.1137/110827788. MR2970212 This is a free offprint provided to the author by the publisher. Copyright restrictions may apply . 1772 J. SHEN, Y. WANG, AND J. XIA [51] J. Xia, S. Chandrasekaran, M. Gu, and X. S. Li,Fast algorithms for hierarchically semisepa- rable matrices, Numer. Linear Algebra Appl.17 (2010), no. 6, 953–976, DOI 10.1002/nla.691. MR2759603 [52] J. Xia, Y. Xi, and M. Gu, A superfast structured solver for Toeplitz linear systems via randomized sampling, SIAM J. Matrix Anal. Appl. 33 (2012), no. 3, 837–858, DOI 10.1137/110831982. MR3023454 [53] D. Xiu and G. E. Karniadakis,Supersensitivity due to uncertain boundary conditions,I n - ternat. J. Numer. Methods Engrg. 61 (2004), no. 12, 2114–2138, DOI 10.1002/nme.1152. MR2101601 Department of Mathematics, Purdue University, West Lafayette, Indiana 47907 Email address: shen7@purdue.edu Department of Mathematics, University of Wisconsin-Madison, Madison, Wisconsin 53706 Email address: wywshtj@gmail.com Department of Mathematics, Purdue University, West Lafayette, Indiana 47907 Email address: xiaj@purdue.edu
采集于
查看校方原文 ↗