cheb_dctmat Subroutine

public subroutine cheb_dctmat(n, mat, rwrk)

Calculates the discrete Chebyshev transform matrix for a single variable. The matrix is not symmetric and assumes the nodal coordinates to be in ascending order.

Reference

  1. Canuto et al. (2006), 'Spectral Methods: Fundamentals in Single Domains', Chapter 2, pp. 86, eqn. (2.4.15)

  2. Gheorghiu, C. I. (2007), 'Spectral Methods for Differential Problems', Casa Cartii de Stiinta, Cluj-Napoca, ISBN 978-973-133-099-0 pp. 18, eqn. (1.40, 1.41)

Arguments

Type IntentOptional Attributes Name
integer, intent(in) :: n

Degree of polynomial

real(kind=rp), intent(out), dimension(:,:) :: mat

((n+1),(n+1)) Transform matrix.

real(kind=rp), intent(inout), dimension(:) :: rwrk

Workspace array of minimum size (n+1)