Determinant of sparse matrix with four nonempty subdiagonals

188 Views Asked by At

So I have a matrix that I want to calculate the determinant of. It is zero other than the diagonal and four subdiagonals, two on either side of the matrix. Like this:

$$\begin{bmatrix} a & & b & & & & c & & & & \\ & a & & b & & & & c& & & \\ & & \ddots& & \ddots & & & & \ddots & & \\ d&&&&&&&&&c&\\ &d&&&&&&&&&c\\ &&\ddots&&&&&&&&\\ e&&&&&&&&\ddots&&\\ &e&&&&&&&&b&\\ &&\ddots&&&\ddots&&&\ddots&&b\\ &&&e&&&d&&&a&\\ &&&&e&&&d&&&a \end{bmatrix}$$

I know in the case of one subdiagonal on either side of the matrix and the length of the diagonals are coprime, the determinant is just the product of the diagonal entries minus the product of the subdiagonal entries, but how does this generalize to two subdiagonals?