scipy.linalg.solve_toeplitz¶

scipy.linalg.
solve_toeplitz
(c_or_cr, b, check_finite=True)[source]¶ Solve a Toeplitz system using Levinson Recursion
The Toeplitz matrix has constant diagonals, with c as its first column and r as its first row. If r is not given,
r == conjugate(c)
is assumed.Parameters: c_or_cr : array_like or tuple of (array_like, array_like)
The vector
c
, or a tuple of arrays (c
,r
). Whatever the actual shape ofc
, it will be converted to a 1D array. If not supplied,r = conjugate(c)
is assumed; in this case, if c[0] is real, the Toeplitz matrix is Hermitian. r[0] is ignored; the first row of the Toeplitz matrix is[c[0], r[1:]]
. Whatever the actual shape ofr
, it will be converted to a 1D array.b : (M,) or (M, K) array_like
Righthand side in
T x = b
.check_finite : bool, optional
Whether to check that the input matrices contain only finite numbers. Disabling may give a performance gain, but may result in problems (result entirely NaNs) if the inputs do contain infinities or NaNs.
Returns: x : (M,) or (M, K) ndarray
The solution to the system
T x = b
. Shape of return matches shape of b.Notes
The solution is computed using LevinsonDurbin recursion, which is faster than generic leastsquares methods, but can be less numerically stable.