tmp commit - toward 0.0.1
This commit is contained in:
6
pina/chebyshev.py
Normal file
6
pina/chebyshev.py
Normal file
@@ -0,0 +1,6 @@
|
||||
from mpmath import chebyt, chop, taylor
|
||||
import numpy as np
|
||||
def chebyshev_roots(n):
|
||||
""" Return the roots of *n* Chebyshev polynomials (between [-1, 1]) """
|
||||
return np.roots(chop(taylor(lambda x: chebyt(n, x), 0, n))[::-1])
|
||||
|
||||
Reference in New Issue
Block a user