<<

arXiv:2005.03251v1 [math.NA] 7 May 2020 ie data Given Introduction 1 o ah0 each for asmti ntrso akl opiz n ignlmatri diagonal and Toeplitz, Hankel, of decomp a terms obtain in to [11] Rost mass and Heinig by described matrices larry adrod arx[]t h enti basis. Bernstein the d to divided [4] standard the matrix av adapted Vandermonde [2] that Sanchez obta and algorithms to Ainsworth [8] and fast positive Mart´ıne totally and to strictly Marco is led matrix example, Vandermonde For has ill-conditioning. matrix the the t from appr of found polynomial structure is a the matrix as used Bernstein–Vandermonde often corresponding e is interpolant The differential the partial and of 6], approximation lin [1, high-order of for Bernst system Recently, tool a [10]. a as matrix Vandermonde-like expressed a be is matrix can problem interpolation the robert ∗ † eateto ahmtc,Byo nvriy n erPla Bear One University; Baylor Mathematics, of Department eateto ahmtc,Byo nvriy n erPla Bear One University; Baylor Mathematics, of Department n[] eue h eainhpbtenmnma B´ezout ma between relationship the used we [3], In [email protected]. orsodn oeusae oe nthe on nodes equispaced to corresponding sbte hni h tnad2nr.Adtoal,w s propert use we block Additionally, a 2-norm. derive standard to the de norm in stein t matrix than that nonstandard showing better matrix, the is Bernstein–Vandermonde use the also of p We of conditioning difference matrices. Bernst a diagonal the terms into of and matrix in properties Bernstein–Vandermonde matrix use the mass we of paper, Bernstein inverse this the In of matrices. inverse of diagonal the inverse of the decomposition and ill-conditio a B´ezout matrices d highly monomial initial be between or to relationship found boundary is of alg which approximation linear M matrix, polynomial interesting Bernstein–Vandermonde to a methods. rise find element give to finite approximation attempting in and interest interpolation in of lems become increasingly also have [email protected]. tutrdivrino h enti–adrod matrix Bernstein–Vandermonde the of inversion Structured enti oyoil,ln tpeo prxmto hoyadcom and theory approximation of staple a long polynomials, Bernstein ≤ p { f j fdegree of j } ≤ j n =0 n fabssfrtesaeo oyoil fdge tmost at degree of polynomials of space the for basis a If . n itntnodes distinct and n htsatisfies that ar Allen Larry LU { ∗ x eopsto fteBrsenVnemnematrix Bernstein–Vandermonde the of decomposition j p } Abstract d ( j n -simplex. x =0 j = ) 1 h neplto rbe ossso niga finding of consists problem interpolation the , oetC Kirby C. Robert f j nabdaoa atrzto fteinverse, the of factorization bidiagonal a in i oyoil aebe osdrdas considered been have polynomials ein 1]ue h atta h Bernstein– the that fact the used [15] z utosvatefiieeeetmethod element finite the via quations e#72;Wc,T 69-38 Email: 76798-7328. TX Waco, #97328; ce e#72;Wc,T 69-38 Email: 76798-7328. TX Waco, #97328; ce xmto fiiilo onaydata. boundary or initial of oximation sto fteivreo h Bernstein the of inverse the of osition ffrneagrtmfrtemonomial the for algorithm ifference e.I hsppr egnrlz an generalize we paper, this In ces. a qain,weetecoefficient the where equations, ear ehgl l-odtoe 5,but [5], ill-conditioned highly be o i–´zu arxt atrthe factor to ein–B´ezout matrix i oeo h susta arise that issues the of some oid rcsadteivreo Hankel of inverse the and trices out fHne,Toeplitz, Hankel, of roducts ecniinn nti case this in conditioning he aklmtie oobtain to matrices Hankel † e fmliait Bern- multivariate of ies ndi 3 osuythe study to [3] in fined fHne,Telt,and Toeplitz, Hankel, of e.I 3,w sdthe used we [3], In ned. t,oeecutr the encounters one ata, n udmna prob- fundamental any baqetos When questions. ebra uainlgeometry, putational n scoe,then chosen, is (1) argument made by Kaplan [12] to obtain a decomposition of the inverse of Vandermonde-like matrices in terms of their , a , and the corresponding B´ezout matrix. When applied to the Bernstein basis, this gives a decomposition of the inverse of the Bernstein– Vandermonde matrix in terms of Hankel, Toeplitz, and diagonal matrices, which in turn leads to a fast algorithm for solving the interpolation problem. Additionally, we use the nonstandard matrix norm defined in [3] to give an explanation for the relatively good performance of the Bernstein– Vandermonde matrix despite its massive condition number. Bernstein polynomials also extend naturally to give a basis for multivariate polynomials of total degree n. Properties of Bernstein polynomials lead to special recursive blockwise-structure for finite element matrices [13, 14]. In this paper, we use this structure to obtain a block LU decomposition of the Bernstein–Vandermonde matrix associated to equispaced nodes on the d-simplex.

2 Inverse Formulas

2.1 General Formulas For integers m,n 0, let bn(x) n be a basis for the space of univariate polynomials of degree at ≥ { j }j=0 most n, and let x Rm+1 with x < x for each 0 i

2 Therefore, if v has simple zeros at x and w(x ) = 0 for each 0 i n, then i i 6 ≤ ≤ n n T ′ n V (x) Bez(v, w) (V (x)) = diag(v (xj)w(xj ))j=0, (4) and so we have the following: Theorem 2.1. The inverse of V n(x) is given by 1 n (V n(x))−1 = Bez(v, w) (V n(x))T diag , (5) v′(x )w(x )  j j j=0 where v and w are any polynomials of degree n + 1 satisfying v(x ) = 0, v′(x ) = 0, and w(x ) = 0 i i 6 i 6 for each 0 i n. ≤ ≤ Corollary 2.2. The inverse of V n(x) is given by 1 n (V n(x))−1 = Bez(v, 1) (V n(x))T diag , (6) v′(x )  j j=0 where v is any polynomial of degree n + 1 that has simple zeros at x for each 0 i n. i ≤ ≤ 2.2 Bernstein–Vandermonde We now focus on the case where 0 x 1 for each 0 i n and the basis consists of the ≤ i ≤ ≤ ≤ polynomials Bn(x) n , where { j }j=0 n Bn(x)= xj(1 x)n−j (7) j j −   are the Bernstein polynomials of degree n. In order to apply Theorem 2.1 or Corollary 2.2, we need a method for computing the entries of the Bernstein–B´ezout matrix; in fact, they satisfy a recurrence relation involving the Bernstein coefficients of the polynomials. n+1 n+1 n+1 n+1 Theorem 2.3. If v(t) = i=0 viBi (t) and w(t) = i=0 wiBi (t) are polynomials of degree at most n + 1, then the entries b of the Bernstein–B´ezout matrix Bez(v, w) generated by v and w P ij P satisfy 1 b = j(n i)b + (n + 1)2 (v w v w ) . (8) ij (i + 1)(n j + 1) − i+1,j−1 i+1 j − j i+1 − Proof. By (7), we have that   j + 1 tBn(t)= Bn+1(t) (9) j n + 1 j+1 and n j + 1 j + 1 Bn(t)= − Bn+1(t)+ Bn+1(t). (10) j n + 1 j n + 1 j+1 Therefore, n n i + 1 s b Bn(s)Bn(t)= b Bn+1(s)Bn(t) ij i j n + 1 ij i+1 j i,jX=0 i,jX=0 n (i + 1)(n j + 1) = − b Bn+1(s)Bn+1(t) (n + 1)2 ij i+1 j i,jX=0 n (i + 1)(j + 1) + b Bn+1(s)Bn+1(t). (n + 1)2 ij i+1 j+1 i,jX=0

3 Similarly, we have that

n n j + 1 t b Bn(s)Bn(t)= b Bn(s)Bn+1(t) ij i j n + 1 ij i j+1 i,jX=0 i,jX=0 n (n i + 1)(j + 1) = − b Bn+1(s)Bn+1(t) (n + 1)2 ij i j+1 i,jX=0 n (i + 1)(j + 1) + b Bn+1(s)Bn+1(t). (n + 1)2 ij i+1 j+1 i,jX=0 This implies that

n n (i + 1)(n j + 1) (s t) b Bn(s)Bn(t)= − b Bn+1(s)Bn+1(t) − ij i j (n + 1)2 ij i+1 j i,jX=0 i,jX=0 n (n i + 1)(j + 1) − b Bn+1(s)Bn+1(t), − (n + 1)2 ij i j+1 i,jX=0 and so

n n+1 i(n j + 1) (s t) b Bn(s)Bn(t)= − b Bn+1(s)Bn+1(t) − ij i j (n + 1)2 i−1,j i j i,jX=0 i,jX=0 n+1 j(n i + 1) − b Bn+1(s)Bn+1(t). − (n + 1)2 i,j−1 i j i,jX=0 On the other hand,

n+1 v(s)w(t) v(t)w(s)= (v w v w )Bn+1(s)Bn+1(t), (11) − i j − j i i j i,jX=0 and so the result follows by comparing coefficients in (3).

We can form the first column and last row of Bez(v, w) by using (8) with j = 0 and i = n. The rest of the columns can then be built by applying the recurrence relation. Therefore,

Corollary 2.4. Bez(v, w) can be constructed in (n2) operations. O By repeatedly applying (8), we obtain a closed form for the entries of the Bernstein–B´ezout matrix.

n+1 n+1 n+1 n+1 Corollary 2.5. If v(t) = i=0 viBi (t) and w(t) = i=0 wiBi (t) are polynomials of degree at most n + 1, then the entries b of the Bernstein–B´ezout matrix Bez(v, w) generated by v and w P ij P are given by

mij 1 n + 1 n + 1 bij = n n (vi+k+1wj−k vj−kwi+k+1) , (12) i j i + k + 1 j k − Xk=0   −    where m = min j, n i . ij { − }

4 Constructing Bez(v, w) by using (12) would require (n3) operations, and so Corollary 2.4 O n implies that (12) is not optimal for building Bez(v, w); however, since i = 0 whenever i>n, the upper limit of the sum in (12) can be replaced with k = n, and so we recognize that Bez(v, w) is  given by a difference of matrix products. n+1 n+1 n+1 n+1 Corollary 2.6. Let v(t)= i=0 viBi (t) and w(t)= i=0 wiBi (t) be polynomials of degree at most n + 1. Define the Toeplitz matrices T v,n and T w,n by P P n + 1 n + 1 T v,n = v and T w,n = w , ij j i j−i ij j i j−i  −   −  define the Hankel matrices Hv,n and Hw,n by n + 1 n + 1 Hv,n = v and Hw,n = w , ij i + j + 1 i+j+1 ij i + j + 1 i+j+1     n and let ∆n = diag n . Then the Bernstein–B´ezout matrix Bez(v, w) generated by v and w is j j=0 given by   Bez(v, w)=(∆n)−1 [Hv,nT w,n Hw,nT v,n] (∆n)−1 . (13) − Remark 2.7. In [3], it was shown that the inverse of the degree n Bernstein mass matrix M n has the decomposition (M n)−1 = (∆n)−1 T nHn T nHn (∆n)−1 , (14) − h i n where Hn and Hn are Hankel matrices, T n andeT n are Toeplitze matrices, and ∆n = diag n . j j=0 This decomposition was obtained from the monomial B´ezout matrix corresponding to polynomi-  als whosee coefficients are contained in thee last column of (M n)−1. It is interesting to note the similarities between (13) and (14) despite the different matrices and bases being considered. n+1 n+1 Given a polynomial v(t) = k=0 vkBk (t) of degree at most n + 1, we can express v in the monomial basis as v(t)= n+1 v tk. It was shown in [7] that k=0Pk k P 1 n ℓ + 1 ev = − v . (15) k n+1 k ℓ ℓ k Xℓ=0  −  This implies that  e

i+j+1 n + 1 n k + 1 Hv,n = v = − v ij i + j + 1 i+j+1 i + j k + 1 k   Xk=0  −  i+j+1 n k + 1 e = − v . n i j k Xk=0  − −  Similarly, e j−i n k + 1 T v,n = − v . ij j i k k Xk=0  − −  By Vieta’s formula (see, for example, [16]), e n n (x x )= ( 1)n−k+1σ (x)xk, (16) − i − n−k+1 Yi=0 Xk=0 5 where 1, if k = 0; σk(x)= (17) xi0 xi , otherwise; ( 0≤i0<···

6 where s(n, k) are the (signed) Stirling numbers of the first kind [17]. In addition, we have that j!(n j)! (j/n i/n) = ( 1)n−j − . (21) − − nn i∈{0,...,nY}\{j} Corollary 2.9. Define the Hankel matrices Hn and Hn by

i+j+1 n + 1 e n k + 1 s(n + 1, k) Hn = and Hn = − , ij i + j + 1 ij n i j nn−k+1   Xk=0  − −  e define the Toeplitz matrices T n and T n by

j−i n + 1 e n k + 1 s(n + 1, k) T n = and T n = − , ij j i ij j i k nn−k+1  −  Xk=0  − −  and define the diagonal matrices Dn and ∆n bye n n n Dn = diag ( 1)n−j [j!(n j)!] and ∆n = diag . − − j=0 j  j=0  In addition, let V n be the scaled Bernstein–Vandermonde matrix

V n = ij(n i)n−j. e ij − n n Then the inverse of V = V (0, 1/n,...,e1) is given by T (V n)−1 = (∆n)−1 HnT n HnT n V n (Dn)−1 . (22) − h i   3 Applying the inverse e e e

Now, we describe several approaches to applying (V n(x))−1 to a vector.

LU factorization We can decompose V n(x) as

V n(x)= Ln(x)U n(x), (23) where Ln(x) and U n(x) are lower and upper triangular matrices, respectively. Widely available in libraries, computing Ln(x) and U n(x) requires (n3) operations, and each of the subsequent O triangular solves require (n2) operations to perform. O Exact inverse In light of Corollary 2.2, we can directly form (V n(x))−1. By Theorem 2.3, we can form the inverse in (n2) operations. The inverse can then be applied to any vector in (n2) O O operations using the standard algorithm.

DFT-based application By Theorem 2.8, we can express the inverse of V n(x) in terms of its (scaled) transpose and Hankel, Toeplitz, and diagonal matrices. The matrices Hn(x) and T n(x) can be formed in (n) operations, but the matrices Hn(x) and T n(x) require (n2) operations O O to form, since each entry involves a sum. Even though the Hankel and Toeplitz matrices can be applied to a vector in (n log n) operations via circulante embeddinge and a couple of FFT/iFFT O [18], the scaled transpose still requires (n2) operations to apply to a vector. O

7 Newton algorithm In [2], Ainsworth and Sanchez gave a fast algorithm for solving V n(x)c = b via a recursion relation for the B´ezier control points of the Newton form of the Lagrangian inter- polant. The numerical results given suggest that the algorithm is stable even for high polynomial degree, and so we include it for comparison.

4 Conditioning and accuracy

In [3], we gave a partial explanation of the relatively high accuracy, compared to its large 2-norm condition number, of working with the Bernstein mass matrix. We will use similar reasoning to investigate the performance of the Bernstein–Vandermonde matrix. Recall that for an integer n 0, the Bernstein mass matrix M n is the (n + 1) (n + 1) matrix ≥ × given by 1 n n n Mij = Bi (x)Bj (x)dx. (24) Z0 The mass matrix (for Bernstein or any other family of polynomials) plays an important role in connecting the L2 topology on the finite-dimensional space to . To see this, we first define mappings connecting polynomials of degree n to Rn+1. Given any c Rn+1, we let π(c) be ∈ the polynomial expressed in the Bernstein basis with coefficients contained in c:

n n π(c)(x)= ciBi (x). (25) Xi=0 We let Π be the inverse of this mapping, sending any polynomial of degree at most n to the vector of n + 1 coefficients with respect to the Bernstein basis. Now, let p(x) and q(x) be polynomials of degree n with expansion coefficients Π(p) = p and Π(q)= q. Then the L2 inner product of p and q is given by the M n-weighted inner product of p and q, for 1 n 1 n n T n p(x)q(x)dx = piqj Bi (x)Bj (x)dx = p M q. (26) 0 0 Z i,jX=0 Z Similarly, if p n = pT M np (27) k kM is the M n-weighted vector norm, then we have forpp = π(p),

p 2 = p n . (28) k kL k kM We can interpret the Bernstein–Vandermonde matrix V n(x) as an operator mapping polyno- mials of degree at most n to Rn+1 via p V n(x)Π(p). Therefore, it makes sense to measure p in 7→ the L2 norm and V n(x)Π(p) in the 2-norm. By (28), we can also consider Π(p) in the M n-norm, which leads us to define the operator norm

Ay 2 A M n→2 = max k k , (29) k k y6=0 y n k kM and going in the opposite direction,

Ay M n A 2→M n = max k k . (30) k k y6=0 y k k2

8 These two norms naturally combine to define a new condition number

−1 κ n (A)= A n A . (31) M →2 k kM →2 2→M n n Since M is symmetric and positive definite, it has a well-defined positive square root via the spectral decomposition.

Lemma 4.0.1. n n n −1/2 κM n→2 (V (x)) = κ2 V (x) (M ) . (32)   Proof. Observe that if y = 0, then 6 2 n −1 (V (x)) y T n −T n n −1 n y (V (x)) M (V (x)) y M = y 2 y 2 k k2 k k2 T (M n)1/2 (V n(x))−1 y (M n)1/2 (V n(x))−1 y = 2  y 2  k2 k (M n)1/2 (V n(x))−1 y = 2 , 2 y 2 k k and so (V n(x))−1 = (M n)1/2 (V n(x))−1 . (33) 2→M n 2

Let z = (M n)1/2 y. Then z = 0 and 6 n 2 T n T n V (x)y 2 y (V (x)) V (x)y k 2 k = T n y n y M y k kM T V n(x) (M n)−1/2 z V n(x) (M n)−1/2 z =  zT z  2 V n(x) (M n)−1/2 z = 2 , 2 z 2 k k and so n n n −1/2 V (x) M n→2 = V (x) (M ) . (34) k k 2

It follows that

n n n −1 κM n→2 (V (x)) = V (x) M n→2 (V (x)) k k 2→M n

= V n(x) (M n)− 1/2 (M n) 1/2 (V n(x))−1 2 2 − 1 n n −1/2 n n −1/2 = V (x) (M ) V (x) (M ) 2 2   = κ V n(x) (M n)− 1/2 . 2  

9 n n −1/2 To analyze κ2 V (x) (M ) , we will need reference to the Legendre polynomials, mapped from their typical home on [ 1, 1] to [0, 1]. For 0 j n, let Lj(x) denote the Legendre polynomial − ≤ ≤ of degree n over [0, 1], scaled so that Ln(1) = 1 and

j 2 1 L 2 = . (35) k kL 2j + 1

The Legendre–Vandermonde matrix is the (n + 1) (n + 1) matrix V n(x) given by × n j Vij (x)= L (xi). b (36)

Given any polynomial p of degree at mostb n, let Θ(p) denote the vector of n + 1 coefficients with respect to the Legendre basis. Define T n to be the (n+1) (n+1) matrix satisfying T nΘ(p)= Π(p) × for all polynomials p of degree at most n. In particular, we have the relationship

V n(x)= V n(x)T n. (37)

Let λn n be the set of eigenvalues of M n. In [3], it was shown that M n admits the spectral { j }j=0 b decomposition M n = QnΛn (Qn)T , (38) where n n n n Q = T diag (2j + 1)λj (39) j=0 qn  n n is an and Λ = diag λj contains the eigenvalues. This decomposition j=0 combined with Lemma 4.0.1 and the transformation  given in (37) suggest a relationship between the M n 2 condition number of V n(x) and the 2-norm condition number of V n(x) scaled by a → diagonal matrix. b Lemma 4.0.2. n n n κM n→2 (V (x)) = κ2 V (x) diag 2j + 1 . (40) j=0   p  Proof. We have that b

V n(x) (M n)−1/2 = V n(x)Qn (Λn)−1/2 (Qn)T n n n n n 1 n T = V (x)T diag (2j + 1)λj diag (Q ) j=0  n  λj q  j=0 n q  = V n(x) diag 2j + 1 (Qn)T . j=0 p  Since Qn is orthogonal, the resultb follows from Lemma 4.0.1.

In [9], Gautschi computed the condition number in the Frobenius norm for Vander- k · kF monde matrices associated with families of orthonormal polynomials. Since the diagonal matrix in Lemma 4.0.2 contains the reciprocal of the L2 norms of the Legendre polynomials, we can adapt −1 n x n his arguments to bound V ( ) diag √2j + 1 j=0 in the Frobenius norm. In addition, the j Legendre polynomials have the special property that L (x) 1 for all 0 x 1, and so we can b n x n | | ≤ ≤ ≤ bound the Frobenius norm of V ( ) diag √2j + 1 j=0.  b 10 For each integer 0 j n, let ℓj,n be the jth with respect to x; that is, ≤ ≤ x x ℓj,n(x)= − i . (41) xj xi i∈{0,...,nY}\{j} − Define wn Rn+1 by ∈ n j,n w = ℓ 2 . (42) j k kL Theorem 4.1. n 3/2 n κ n (V (x)) (n + 1) w . (43) M →2 ≤ k k2 Proof. Since Lj(x) 1 for all 0 x 1, we have that | |≤ ≤ ≤ 1/2 n n n j 2 V (x) diag 2j + 1 = (2j + 1) L (xi) j=0   F i,j=0 p  X  b  1/2  n (2j + 1) ≤   i,jX=0 = (n + 1)3/2. 

Since j,n 1, if i = j; ℓ (xi)= (44) (0, if i = j; 6

11 −1 we have that V n(x) = Θ ℓj,n . Therefore, by (35), we have that ij i    b 1/2 n wn = wn 2 k k2  j  j=0 X    1/2 n 1 2 = ℓj,n(x) dx   j=0 Z0 X    1/2 n 1 n j,n j,n i k = Θ(ℓ )iΘ(ℓ )kL (x)L (x)dx  0  Xj=0 Z i,kX=0   1/2 n n 1 j,n j,n i k = Θ(ℓ )iΘ(ℓ )k L (x)L (x)dx  0  Xj=0 i,kX=0 Z  1/2  n 1 j,n 2 i 2 = Θ(ℓ )i (L (x)) dx  0  i,jX=0 Z  1/2  n Θ(ℓj,n)2 = i  2i + 1  i,jX=0  1  n −1 = diag V n(x) √2i + 1  i=0 F   b n −1 = V n(x) diag 2j + 1 . j=0     F p b Since the condition number in the 2 norm is bounded above by the condition number in the Frobenius norm, the result follows from Lemma 4.0.2.

5 Higher dimensions

Now, in the case of equispaced nodes on the d-simplex, we can use block-recursive structure as discussed in [14] to give low-complexity algorithms for the inversion of simplicial Bernstein– Vandermonde matrices. This gives, at least for the equispaced lattice, an alternate algorithm for solving simplicial Bernstein interpolation problems to the one worked out in [1].

5.1 Notation and Preliminaries For an integer d 1, let S be a nondegenerate simplex in Rd. Let v d Rd be the vertices of ≥ d { i}i=0 ⊂ S , and let b d denote the barycentric coordinates of S . Each b is an affine map from Rd to d { i}i=0 d i R such that 1, if i = j; bi(vj)= (45) (0, if i = j; 6

12 8 10 n κM n→2(V (x)) Estimate 6 n 10 κ2(V (x))

104

102 Condition Numbers

100 5 10 15 20 n

Figure 1: Comparsion of the condition number of V n in the M n 2 norm and the 2 norm for → 1 n 20, where V n is the matrix described in Subsection 2.3. We also include the estimate ≤ ≤ n given in Theorem 4.1. We use Lemma 4.0.2 to compute κM n→2(V (x)).

for each vertex vj. Each bi is nonnegative on Sd, and

d bi = 1. (46) Xi=0 A multiindex β of length d + 1 is a (d + 1)-tuple of nonnegative integers, written

β = (β0,...,βd). (47)

The order of β, denoted β , is given by | | d β = β . (48) | | i Xi=0 The β! of a multiindex β is defined by

d β!= βi. (49) Yi=0 For a multiindex β of length d + 1, denote by β′ the multiindex of length d given by

′ β = (β1,...,βd). (50)

′ Given a nonnegative integer b and a multiindex β = (β1,...,βd) of length d, define a new multiindex b β of length d +1 by ⊢ b β′ = (b, β ,...,β ). (51) ⊢ 1 d In particular, β = β β′. (52) 0 ⊢

13 Multiindices have a natural partial ordering given by

β β if and only if β β for all 0 i d. (53) ≤ i ≤ i ≤ ≤

The Bernstein polynomialse of degree n on the d-simplexe Sd are defined by

d n! Bn = bβi . (54) β β! i Yi=0 The complete set of Bernstein polynomials Bn form a basis for polynomials in d variables { β }|β|=n of complete degree at most n. If n n, then any polynomial expressed in the basis Bn0 can also be expressed in the 0 ≤ { β }|β|=n0 n d,n0,n n+d n0+d basis Bβ |β|=n. We denote by E the d d matrix that maps the coefficients of the { } × d,n0,n degree n0 representation to the coefficients of the degree  n representation. The matrix E is sparse and can be applied matrix-free [13], if desired. For a nonnegative integer m and a set of distinct nodes xm S , define the Bernstein– { α }|α|=m ⊂ d Vandermonde matrix V d,m,n to be the m+d n+d matrix given by d × d d,m,n n m Vαβ = Bβ (xα ) (55) Theorem 5.1. Let d,m,n , and n be nonnegative integers with d 1 and n n, and let 0 ≥ 0 ≤ xm be distinct nodes contained in the d-simplex S . Then { α }|α|=m d V d,m,nEd,n0,n = V d,m,n0 . (56)

Proof. Given a polynomial p Span Bn0 , the matrix V d,m,n0 evaluates p at each of the ∈ { β }|β|=n0 m d,m,n d,n0,n nodes xα . On the other hand, the matrix V E evaluates the degree n representation of p m at each of the nodes xα . Since we are evaluating at the same nodes and the polynomial has not been modified, both evaluations must give the same result.

The partial ordering (53) implies a natural way to order the entries of V d,m,n and also imposes d,m,n a block structure on V by dividing the matrix into sections where α0 and β0 are constant. For d,m,n m−α0+d n−β0+d integers 0 α0 m and 0 β0 n, let Vα0β0 denote the d d submatrix of d,m,n ≤ ≤ ≤ ≤ × V whose entries satisfy   d,m,n d,m,n Vα0β0 = V ′ ′ . (57) α′β′ (α0⊢α )(β0⊢β )   5.2 Degree Reduction We now consider the case of equispaced nodes on the d-simplex Sd. For this case, the entries of the Bernstein–Vandermonde matrix are given by

d n! 1 V d,m,n = αβi . (58) αβ β! mn i Yi=0 d,m,n This representation of the entries allows us to represent the submatrix Vα0β0 in terms of a lower- dimensional Bernstein–Vandermonde matrix.

14 Theorem 5.2. Let d> 1 and m,n 0 be integers, and let α , β be integers with 0 α m and ≥ 0 0 ≤ 0 ≤ 0 β0 n. Then ≤ ≤ d,m,n d−1,m−α0,n−β0 Vα0β0 = mα0β0 V , (59) where n m = (α /m)β0 (1 α /m)n−β0 . (60) α0β0 β 0 − 0  0 Proof. If α = m and β = n, then both sides equal zero and we are done. Otherwise, by (58), we 0 0 6 have that d d−1,m−α0,n−β0 (n β0)! 1 βi V ′ ′ = − α . (61) α β ′ n−β0 i β ! (m α0) − Yi=1 On the other hand,

d,m,n d,m,n Vα0β0 = Vαβ α′β′   d n! 1 = αβi β! mn i Yi=0 d n! (n β )! αβ0 (m α )n−β0 1 = − 0 0 − 0 αβi , ′ β0 n−β0 n−β0 i β0!(n β0)! β ! m m (m α0) − − Yi=1 where we have separated terms containing α and β and multiplied and divided by (n β )! and 0 0 − 0 (m α )n−β0 . Since − 0

β0 n−β0 n! α0 (m α0) n β0 n−β0 − = (α0/m) (1 α0/m) , (62) β !(n β )! mβ0 mn−β0 β − 0 − 0  0 we have the desired result.

The fact that the blocks are multiples of lower-dimensional matrices is analogous to what has been observed for other matrices related to Bernstein polynomials. For example, the Bernstein– Vandermonde matrix associated with the zeroes of Legendre polynomials has a similar structure [14], and so does the Bernstein mass matrix [13].

We recognize that mα0β0 describes a univariate Bernstein polynomial of degree n being evaluated at equispaced points. Therefore, if V n is the one-dimensional Bernstein–Vandermonde matrix associated with equispaced nodes as described in Subsection 2.3, then we have that V d,n,n admits the block structure V n V d−1,n,n V n V d−1,n,n−1 V n V d−1,n,0 00 01 · · · 0n V n V d−1,n−1,n V n V d−1,n−1,n−1 V n V d−1,n−1,0 d,n,n 10 11 1n V =  . . ·. · · .  . (63) . . .. .    V n V d−1,0,n V n V d−1,0,n−1 V n V d−1,0,0   n0 n1 · · · nn    We can use this block structure and Theorem 5.1 to perform block Gaussian elimination on V d,n,n. This method was used in [13] to obtain the block LU decomposition of the Bernstein mass matrix. In the same way, we have the following:

15 Theorem 5.3. Let V n be the one-dimensional Bernstein–Vandermonde matrix associated with equispaced nodes as described in Subsection 2.3. Suppose V n = LnU n is the LU decomposition of V n. Then V d,n,n = Ld,nU d,n, (64) where Ld,n is the block lower with blocks given by

d,n n d−1,n−α0,n−β0 Lα0β0 = Lα0β0 V (65) and U d,n is the block upper triangular matrix with blocks given by

d,n n d−1,n−β0,n−α0 Uα0β0 = Uα0β0 E . (66) Proof. By Theorem 5.1, if 0 α , β n and γ β , then ≤ 0 0 ≤ 0 ≤ 0 d,n d,n n n d−1,n−α0,n−γ0 d−1,n−β0,n−γ0 Lα0γ0 Uγ0β0 = Lα0γ0 Uγ0β0 V E n n d−1,n−α0,n−β0 = Lα0γ0 Uγ0β0 V .

Therefore,

β0 d,n d,n d,n d,n L U = Lα0γ0 Uγ0β0 α0β0 γ   X0=0 β0 = Ln U n V d−1,n−α0,n−β0  α0γ0 γ0β0  γ0=0 X n d−1,n−α0,n−β0 = Vα0β0 V d,n,n = Vα0β0 .

6 Numerical results

Now, we consider the accuracy of the methods described above on several problems. For all of the problems, we chose random solution vectors, computed the right-hand side by , and then attempted to recover the solution. The numerical results are run in double arithmetic on a 2014 Macbook Air running macOS 10.13 and using Python 2.7.13. Cholesky factorization and FFTs are performed using the numpy (v1.12.0) function calls. Also, because our code is a mix of pure Python and low-level compiled libraries, timings are not terribly informative. Consequently, we focus on assessing the stability and accuracy of our methods. If future work leads to more stable fast algorithms, greater care will be afforded to tuning our implementations for performance. In Figure 2, we consider the case of equispaced nodes. When considering the Euclidean norm of the error (Figure 2a), the LU factorization and the Newton algorithm have the best perfomance, followed by the DFT-based application and multiplying by the inverse. We observe that the LU and Newton methods have comparable performance, as do the DFT-based algorithm and multiplying by the inverse. This is in contrast to what was observed in [3], where a similar DFT-based algorithm quickly became unstable. The same behavior can be observed when comparing the Euclidean norm of the residual (Figure 2c), although some separation does occur between the Newton method

16 10−3 10−3 B´ezout B´ezout DFT 10−6 DFT 10−6 LU n LU M 2 k k Newton

Newton c c

−9 k −9 k 10 10 / / n 2 k M c b k c −12 b −12 − 10 10 c − k c k 10−15 10−15

10−18 10−18 5 10 15 20 5 10 15 20 n n (a) Error in the 2-norm. (b) Error in the M n norm.

10−3 B´ezout

−6 DFT 10 LU

2 Newton k

b 10−9 − c b n −12 V 10 k

10−15

10−18 5 10 15 20 n (c) Residual in the 2-norm.

Figure 2: Error/residual in using the methods described in Section 3 to solve V nc = b for 1 ≤ n 20, where V n is the matrix described in Subsection 2.3 and b is a random vector in [ 1, 1]n+1. ≤ − B´ezout refers to Corollary 2.2, DFT refers to Corollary 2.9, LU refers to LU decomposition of V n, and Newton refers to the Ainsworth–Sanchez algorithm. We use c to denote the computed solution.

b and the LU factorization. Since the solution vector can be viewed as the Bernstein coefficients of the interpolation polynomial, we also measure the L2 difference between the exact and computed solutions (Figure 2b); equivalently, we measure the relative M n error, where M n is the Bernstein mass matrix given in (24). All four solution methods have very similar behavior in the M n norm as they do when considering the Euclidean norm of the residual. To ensure that the behavior of the solution methods does not depend on the choice of nodes, we also considered the case where the nodes xj are randomly selected from [j/(n+1), (j+1)/(n+1)) for each 0 j n (Figure 3); however, there was no significant difference in the quantities measured ≤ ≤ between this case and the equispaced case. We also used the block LU decomposition given in Theorem 5.3 combined with the one- dimensional LU algorithm to solve the interpolation problem for equispaced nodes on the d-simplex for d = 2 and d = 3 (Figure 4). Due to the recursive nature of the algorithm, the quantities mea- sured are very similar to the ones observed for equispaced nodes.

17 10−3 10−3 B´ezout B´ezout DFT −6 DFT −6

10 n 10 LU LU M 2 k k Newton

Newton c c k

k −9 −9

10 / 10 / n 2 k M c b k c −12 b −12 − 10 10 c − k c k 10−15 10−15

10−18 10−18 5 10 15 20 5 10 15 20 n n (a) Error in the 2-norm. (b) Error in the M n norm.

10−3 B´ezout DFT −6 10 LU 2 k Newton b −9 − 10 c b ) x (

n 10−12 V k 10−15

10−18 5 10 15 20 n (c) Residual in the 2-norm.

Figure 3: Error/residual in using the methods described in Section 3 to solve V n(x)c = b for 1 n 20, where V n(x) is the Bernstein–Vandermonde matrix associated to x, the nodes x are ≤ ≤ j randomly selected from [j/(n + 1), (j + 1)/(n + 1)) for 0 j n, and b is a random vector in ≤ ≤ [ 1, 1]n+1. B´ezout refers to Corollary 2.2, DFT refers to Theorem 2.8, LU refers to LU decom- − position of V n, and Newton refers to the Ainsworth–Sanchez algorithm. We use c to denote the computed solution. b

18 10−12 10−9 d = 2 d = 2 d = 3 d = 3 10−13 d,n −11 M 2 10 k k −14 c c 10 k k / / 2 −13 k 10 d,n −15 c b 10 M k − c b c −16 k −15 10 − 10 c k 10−17 10−17 10−18 5 10 15 20 5 10 15 20 n n (a) Error in the 2-norm. (b) Error in the M d,n norm.

d = 2 10−15 d = 3 2 k b

− −16 c b 10 d,n,n V k 10−17

10−18 5 10 15 20 n (c) Residual in the 2-norm.

Figure 4: Error/residual in using the block LU decomposition given in Theorem 5.3 to solve V d,n,nc = b for 1 n 20 and d = 2, 3, where V d,n,n is the Bernstein–Vandermonde matrix given ≤ ≤ n+d in (58) and b is a random vector in [ 1, 1]( d ). We use c to denote the computed solution. − b

19 7 Conclusion

We have studied several algorithms for the inversion of the univariate Bernstein–Vandermonde matrix. These algorithms, while less stable than algorithms discovered previously, provide insight into the structure of the Bernstein–Vandermonde matrix and are remarkably similar to algorithms derived for the Bernstein mass matrix. In addition, we have used a block LU decomposition of the Bernstein–Vandermonde matrix corresponding to equispaced nodes on the d-simplex to give a recursive, block-structured algorithm with comparable accuracy to the one-dimensional algorithm. Moreover, we have given a new perspective on the conditioning of the Bernstein–Vandermonde ma- trix, indicating that the interpolation problem is better-conditioned with respect to the L2 norm than the Euclidean norm. In the future, we hope to expand this perspective to other polyno- mial problems and continue the development of fast and accurate methods for problems involving Bernstein polynomials.

20 References

[1] Mark Ainsworth, Gaelle Andriamaro, and Oleg Davydov. Bernstein–B´ezier finite elements of arbitrary order and optimal assembly procedures. SIAM Journal on Scientific Computing, 33(6):3087–3109, 2011. [2] Mark Ainsworth and Manuel A. S´anchez. Computing the b´ezier control points of the lagrangain interpolant in arbitrary dimension. SIAM Journal on Scientific Computing, 38(3):A1682– A1700, 2016. [3] Larry Allen and Robert C. Kirby. Structured inversion of the bernstein mass matrix. SIAM Journal of Matrix Analysis and Applications, 41(2):413–431, April 2020. [4] Richard L. Burden and J. Douglas Faires. Numerical Methods. Cengage Learning, 4 edition, 2012. [5] Philip J. Davis. Interpolation and Approximation. Dover Publications, Inc., New York, 1975. [6] Michael G Duffy. Quadrature over a pyramid or cube of integrands with a singularity at a vertex. SIAM journal on Numerical Analysis, 19(6):1260–1262, 1982. [7] Rida T. Farouki. Legendre–Bernstein basis transformations. Journal of Computational and Applied Mathematics, 119(1-2):145–160, 2000. [8] Mariano Gasca and J. M. Pe˜na. Total positivity and neville elimination. Linear Algebra and its Applications, 165:25–44, 1992. [9] Walter Gautschi. The condition of vandermonde-like matrices involving orthogonal polynomi- als. Linear Algebra and its Applications, 52/53:293–300, 1983. [10] Walter Gautschi, Gene H. Golub, and Gerhard Opfer. Applications and Computation of Or- thogonal Polynomials. Springer, 1999. [11] Georg Heinig and Karla Rost. Algebraic methods for Toeplitz-like matrices and operators, volume 13. Birkh¨auser, 1984. [12] Shmuel Kaplan, Alexander Shapiro, and Mina Teicher. Several applications of b´ezout matrices, 2006. [13] Robert C. Kirby. Fast inversion of the simplicial Bernstein mass matrix. Numerische Mathe- matik, 135(1):73–95, 2017. [14] Robert C. Kirby and Kieu Tri Thinh. Fast simplicial quadrature-based finite element operators using Bernstein polynomials. Numerische Mathematik, 121(2):261–279, 2012. [15] Ana Marco and Jos´e-Javier Mart´ınez. A fast and accurate algorithm for solving bernstein– vandermonde linear systems. Linear Algebra and its Applications, 422(2):616–628, 2007. [16] Joseph J. Rotman. Advanced Modern Algebra. American Mathematical Society, 3 edition, 2015. [17] Irene A. Stegun. Handbook of Mathematical Functions with Formulas, Graphs, and Mathe- matical Tables. U.S. Government Printing Office, 1965. [18] Curtis R. Vogel. Computational Methods for Inverse Problems. SIAM, 2002.

21