Solves tridiagonal systems of equations.
Supports batch dimensions and multiple right-hand sides per each left-hand
side.
On CPU, solution is computed via Gaussian elimination with or without partial
pivoting, depending on partial_pivoting attribute. On GPU, Nvidia's cuSPARSE
library is used: https://docs.nvidia.com/cuda/cusparse/index.html#gtsv
Partial pivoting is not yet supported by XLA backends.
Args
diagonals
A Tensor. Must be one of the following types: float64, float32, complex64, complex128.
Tensor of shape [..., 3, M] whose innermost 2 dimensions represent the
tridiagonal matrices with three rows being the superdiagonal, diagonals, and
subdiagonals, in order. The last element of the superdiagonal and the first
element of the subdiagonal is ignored.
rhs
A Tensor. Must have the same type as diagonals.
Tensor of shape [..., M, K], representing K right-hand sides per each
left-hand side.
partial_pivoting
An optional bool. Defaults to True.
Whether to apply partial pivoting. Partial pivoting makes the procedure more
stable, but slower.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2024-01-23 UTC."],[],[]]