5.0

5.0 | 1 rating Rate this file 7 Downloads (last 30 days) File Size: 2.69 KB File ID: #13623

Calculate roots of Chebyshev polynomials.

by Russell Francis

 

10 Jan 2007 (Updated 20 May 2009)

Calculate the roots of a Chebyshev polynomial of arbitrary degree.

| Watch this File

File Information
Description

This function will calculate and optionally scale and translate the roots of a Chebyshev polynomial of type T_n(x) or U_n(x) of arbitrary degree.

MATLAB release MATLAB 7.1.0 (R14SP3)
Tags for This File  
Everyone's Tags
approximation, chebyshev(3), interpolation, polynomial, root, roots
Tags I've Applied
Add New Tags Please login to tag files.
Please login to add a comment or rating.
Comments and Ratings (3)
19 Jan 2007 John D'Errico

Cleaned up, it works well. My tests show the correct roots. Its always nice to see the references. Both families of polynomials are now implemented in one place.

18 Jan 2007 Russell Francis

John,

thanks for taking the time to look at and provide feedback on this relatively small and simple function. I have recently uploaded a new file which should address the 2 issues which you brought up. The function now can calculate both T_n(x) as well as U_n(x). Also the copyright notice is no longer displayed within the help inside of Matlab, which should make the function a little nicer to learn about. Please let me know if you see anything else which would improve the function.

Kind regards,
Russell Francis

17 Jan 2007 John D'Errico

I wish the author had spent as much time documenting his code as he did in writing the extensive copyright notice, disclaimer of warranty, etc. Depressingly, more than 50% of the help section of the code is taken up by those notices.

What could he have provided that might have been useful to know? There are two distinct families of Chebyshev polynomials, yet the help refers only to a Chebyshev polynomial as if you have no choice. Take a quick read through chapter 22 of Abramowiz and Stegun. Which kind is this? (Hint: T_n)

Even better, provide a flag that lets the user decide which polynomial family they will get. Yes, this might double the size of the code, but only a single set of disclaimers and copyright notices would be "needed".

Updates
19 Jan 2007

* Added the ability to support both Chebyshev polynomials of type 1 Tn(x) and type 2 Un(x).
* Improved documentation and includes references to sources used.

19 Jan 2007

* Minor issue in previous submit, failed to sort the result. This now sorts the roots so that they are returned from least to greatest.

19 Jan 2007

* Tightened up string comparison in one location.

20 May 2009

Removed GPL license.

Contact us