Function Repository Resource:

OrthogonalPolynomialVandermondeMatrix

Source Notebook

Generate the orthogonal polynomial Vandermonde matrix corresponding to a given vector

Contributed by: Jan Mangaldan

ResourceFunction["OrthogonalPolynomialVandermondeMatrix"][poly,{a1,a2,}]

generates the orthogonal polynomial Vandermonde matrix V(a1,a2,) with respect to the basis represented by poly.

Details and Options

An orthogonal polynomial Vandermonde matrix is a square matrix with elements of the form pi-1(aj), where pi(x) is an orthogonal polynomial represented by poly.
The argument poly can be any of the following:
"ChebyshevFirst"Chebyshev polynomial of the first kind ChebyshevT[i,x]
"ChebyshevSecond"Chebyshev polynomial of the second kind ChebyshevU[i,x]
"Hermite"Hermite polynomial HermiteH[i,x]
"Laguerre"Laguerre polynomial LaguerreL[i,x]
"Legendre"Legendre polynomial LegendreP[i,x]
{"Gegenbauer",m}Gegenbauer polynomial GegenbauerC[i,m,x]
{"Laguerre",a}associated Laguerre polynomial LaguerreL[i,a,x]
{"Jacobi",a,b}Jacobi polynomial JacobiP[i,a,b,x]
Strings in specifications like "Legendre" and {"Jacobi",a,b} can be replaced with the corresponding symbols, as in LegendreP and {JacobiP,a,b}.
If the argument poly is set to "Monomial", the classical Vandermonde matrix is generated.
ResourceFunction["OrthogonalPolynomialVandermondeMatrix"][poly,m,{a1,a2,}] generates a matrix with m rows.
ResourceFunction["OrthogonalPolynomialVandermondeMatrix"][poly,{a1,a2,},"Transpose"True] generates a transposed version of the matrix.

Examples

Basic Examples (1) 

A Chebyshev–Vandermonde matrix:

In[1]:=
ResourceFunction["OrthogonalPolynomialVandermondeMatrix"][
  "ChebyshevFirst", {-1, -1/2, 1/2, 1}] // MatrixForm
Out[1]=

Scope (3) 

Jacobi–Vandermonde matrix with symbolic parameters and vector:

In[2]:=
ResourceFunction[
  "OrthogonalPolynomialVandermondeMatrix"][{"Jacobi", \[Alpha], \
\[Beta]}, {Subscript[x, 1], Subscript[x, 2]}] // MatrixForm
Out[2]=

An equivalent specification:

In[3]:=
ResourceFunction[
  "OrthogonalPolynomialVandermondeMatrix"][{JacobiP, \[Alpha], \
\[Beta]}, {Subscript[x, 1], Subscript[x, 2]}] // MatrixForm
Out[3]=

A numerical Hermite–Vandermonde matrix:

In[4]:=
ResourceFunction["OrthogonalPolynomialVandermondeMatrix"][
  "Hermite", {0., 0.1, 0.5, 1., 2.}] // MatrixForm
Out[4]=

A rectangular Legendre–Vandermonde matrix:

In[5]:=
ResourceFunction["OrthogonalPolynomialVandermondeMatrix"]["Legendre", 6, Subdivide[3]] // MatrixForm
Out[5]=

Options (1) 

Transpose (1) 

With "Transpose"True, OrthogonalPolynomialVandermondeMatrix generates a transposed matrix:

In[6]:=
MatrixForm /@ {ResourceFunction[
   "OrthogonalPolynomialVandermondeMatrix"]["Laguerre", {x1, x2, x3}, "Transpose" -> False], ResourceFunction["OrthogonalPolynomialVandermondeMatrix"][
   "Laguerre", {x1, x2, x3}, "Transpose" -> True]}
Out[6]=
In[7]:=
MatrixForm /@ {ResourceFunction[
   "OrthogonalPolynomialVandermondeMatrix"]["Laguerre", 4, {x1, x2, x3}, "Transpose" -> False], ResourceFunction["OrthogonalPolynomialVandermondeMatrix"][
   "Laguerre", 4, {x1, x2, x3}, "Transpose" -> True]}
Out[7]=

Version History

  • 1.0.1 – 27 April 2021

Source Metadata

Related Resources

License Information