I'm using eigs with a shift SIGMA to compute a few interior eigenpairs of a (large and sparse) generalized eigenvalue problem with symmetric positive-definite matrices. Just for the record, I use a function handle that computes (A-SIGMA*I)\X , with A given by transforming the generalized eigenvalue problem into a standard eigenvalue problem (through Cholesky factorization of the mass matrix and LDL factorization of the shifted stiffness matrix). The value for SIGMA is (a + b)/2 with ]a,b[ the interval for which I want to compute all the eigenpairs. The number n of eigenpairs is determined by inertia count at a and inertia count at b (using LDL factorizations). This eigenvalue problem exhibits very clustered eigenvalues.
MATLAB successfully computes eigenvalues of this problem (I have a reference solution to verify the exactness). The issue is that some of them (let's say p of them) are out of the interval ]a,b[ (they are all to the left). And since MATLAB produces only n eigenpairs (as requested), p eigenpairs at the other end of the interval (to the right) are missing.
The default convergence tolerance of eigs is 1e-14 (which I'm using) and the above issue, equivalent to a shift in the eigenvalues, leads to a relative eigenvalue error in the order of up to 1e-2 . The shift aside, all the computed eigenvalues are exact; the p eigenvalues outside ]a,b[ are also exact. As a conclusion, the claim "If SIGMA is a real or complex scalar including 0, eigs finds the eigenvalues closest to SIGMA." is not satisfied here.
The function handle that returns (A-SIGMA*I)\X is correct since all the eigenvalues are correct. There are 87 eigenvalues in the interval ]2.395285793575430 , 2.402047359143023[ . There are 72 eigenvalues in the interval ]a,b[ = ]2.402047359143023 2.666048612636298[ . We can see that there is a cluster of eigenvalues at the left of ]a,b[ .
Has this issue been encountered before?
Many thanks. Olivier