pentadiagonal
A pentadiagonal matrix is a square matrix in which all entries are zero except on five diagonals: the main diagonal, the two diagonals just above the main, and the two diagonals just below the main. Equivalently, an n×n pentadiagonal matrix has nonzero entries on the diagonals i, i±1, and i±2, for as many rows and columns as allowed by boundary conditions. It is a type of banded matrix with a bandwidth of 2 on each side.
Pentadiagonal matrices commonly arise in numerical linear algebra when discretizing certain differential equations, especially fourth-order problems,
Storage and computation: Because only five diagonals may be nonzero, these matrices require O(n) storage. Specialized
Boundary conditions affect the first and last two rows, which may have fewer nonzero entries. Inverse of