image thumbnail

Tridiagonal Matrix Algorithm (Thomas Alg.) (tridiagonal)

version 4.0.0 (228 KB) by Tamas Kis
Solves the tridiagonal linear system Ax=d for x using the tridiagonal matrix algorithm (i.e. the Thomas algorithm).

150 Downloads

Updated 29 Aug 2021

From GitHub

View license on GitHub

tridiagonal View Tridiagonal Matrix Algorithm (Thomas Alg.) (tridiagonal) on File Exchange

Solves the tridiagonal linear system for using the tridiagonal matrix algorithm (i.e. the Thomas algorithm).

Syntax

x = tridiagonal(A,d)

Description

x = tridiagonal(A,d) solves the tridiagonal linear system for , where is a tridiagonal matrix and .

Tridiagonal Matrix Convention

For this implementation, I use the following convention for denoting the elements of the tridiagonal matrix :

Most other references have 's ranging from to both in the definition of the tridiagonal matrix and in the algorithm used to solve the corresponding linear system. In this implementation, I have the 's ranging from to ; this makes the algorithm slightly more straightforward to implement.

Examples and Additional Documentation

Cite As

Tamas Kis (2021). Tridiagonal Matrix Algorithm (Thomas Alg.) (tridiagonal) (https://github.com/tamaskis/tridiagonal-MATLAB/releases/tag/v4.0.0), GitHub. Retrieved .

MATLAB Release Compatibility
Created with R2021a
Compatible with any release
Platform Compatibility
Windows macOS Linux

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
To view or report issues in this GitHub add-on, visit the GitHub Repository.
To view or report issues in this GitHub add-on, visit the GitHub Repository.