how to find whether a matrix is bidiagonal matrix