3

I am looking for a LAPACK routine that allows to find a non-trivial solution to the following equation:

A x = 0

provided that A is a n×n square singular non-symmetric band matrix.

In reality A matrix may not be exactly singular as it is based on some parameter and I use a root finding algorithm to find this parameter (requiring det(A) = 0, where the determinant is found with DGBTRF and multiplication of the diagonal elements).

The only solution I have came up so far is to consider A a dense matrix matrix, use DGEEV to find its eigenvalues and eigenvectors and take the eigenvector for the eigenvalue closest to zero. However, I believe this is strongly sub-optimal approach. Can anyone suggest a better one?

Maciek D.
  • 131
  • 2
  • 4
    Welcome to Scicomp.SE! Does the answer to this question help you? http://scicomp.stackexchange.com/questions/10185/solving-for-null-space-of-a-matrix-with-mkl-lapack – Christian Clason Nov 06 '15 at 10:29

2 Answers2

1

LAPACK has xSTERF as routines to find eigenvalues for band matrices.

If you are only interested in the smallest one, you might find the following answer interesting. However you need to implement the algorithm yourself.

Bort
  • 1,285
  • 7
  • 12
  • Could you actually link to the answer, not just the question (every answer has a share link, use that)? As it stands, I can't tell which one you refer to. – Christian Clason Nov 13 '15 at 16:26
  • Thanks a lot, but as I can see xSTERF is only for tridianonal symmetric matrix. My matrix unfortunatelly is neither tridiagonal nor symmetric. – Maciek D. Nov 14 '15 at 18:11
0

I'm not sure this would be much more efficient, but you can try to solve $Ax=v$ where $\|v\|<\varepsilon$. If the result $\|x\|$ is also $\|x\|<\epsilon$ the matrix may not be singular.