Extension of Chebfun to periodic functions

Grady B. Wright,Mohsin Javed,Hadrien Montanelli,Lloyd N. Trefethen
DOI: https://doi.org/10.1137/141001007
2015-11-01
Abstract:Algorithms and underlying mathematics are presented for numerical computation with periodic functions via approximations to machine precision by trigonometric polynomials, including the solution of linear and nonlinear periodic ordinary differential equations. Differences from the nonperiodic Chebyshev case are highlighted.
Numerical Analysis
What problem does this paper attempt to address?
The main problem that this paper attempts to solve is to extend the Chebfun software system from the Chebyshev polynomial representation that only supports non - periodic functions to the trigonometric polynomial representation that supports periodic functions. Specifically, the authors hope to achieve the following goals: 1. **Numerical Computation and Approximation**: Perform numerical computation and approximation of periodic functions with trigonometric polynomials at machine precision, including the solution of linear and nonlinear ordinary differential equations. 2. **Algorithms and Mathematical Foundations**: Develop and implement efficient algorithms for periodic functions and explore the mathematical principles behind these algorithms, especially the differences from non - periodic functions (such as Chebyshev polynomials). 3. **Software Implementation**: Add support for periodic functions in Chebfun to ensure that users can conveniently use these new features for scientific research and engineering calculations. To achieve these goals, the authors discuss in detail the following aspects: - **Choice of Basis Functions**: For non - periodic functions, the Chebyshev polynomial is the only required basis function; for periodic functions, there are two equivalent choices: the complex exponential \( \exp(ikt) \) and the sine - cosine \( \sin(kt), \cos(kt) \). - **Handling of Complex Coefficients**: In the complex exponential representation, the expansion coefficients of real periodic functions are complex numbers and satisfy certain symmetries. The software system needs to enforce these symmetries to avoid rounding errors in the imaginary part. - **Number of Parameters**: The degree \( n \) of an algebraic polynomial determines \( n + 1 \) parameters, while the degree \( n \) of a trigonometric polynomial determines \( 2n+ 1 \) parameters. - **Effect of Differentiation**: Differentiation reduces the degree of an algebraic polynomial, but does not reduce the degree of a trigonometric polynomial; instead, it enhances the weight of the highest - degree term. - **Resolution Consistency**: The trigonometric representation has uniform properties throughout the interval, while the polynomial has higher resolution at both ends of the interval. - **Periodicity and Translation Invariance**: Periodic functions can be perfectly evaluated on the entire real axis, while non - periodic functions do not have this global validity. - **Effect of Operations on Periodicity**: A smooth and periodic function may lose these properties after certain operations (such as taking a sub - interval, taking the absolute value, etc.). - **Selection of Interpolation Points**: For the interpolation of periodic functions, equally spaced points are usually used; for the interpolation of non - periodic functions, Chebyshev points should be used to avoid ill - conditioned problems. By solving these problems, the authors introduce powerful periodic function processing capabilities into Chebfun, making it a more comprehensive numerical computing tool.