[petsc-users] [SLEPc] non-deterministic behaviour in GHEP with Krylov-Schur

Jose E. Roman jroman at dsic.upv.es
Tue Mar 8 05:38:44 CST 2016


> El 8 mar 2016, a las 12:29, Denis Davydov <davydden at gmail.com> escribió:
> 
> 
>> On 8 Mar 2016, at 11:39, Jose E. Roman <jroman at dsic.upv.es> wrote:
>> 
>> 
>>> El 8 mar 2016, a las 11:28, Denis Davydov <davydden at gmail.com> escribió:
>>> 
>>> Dear all,
>>> 
>>> I have some issues with Krylov-Schur applied to GHEP, namely, that different runs on the same machine with the
>>> same number of MPI cores gives different eigenvectors results.
>>> Here is an example:
>>> 
>>> mass.InfNorm =15.625
>>> stiff.InfNorm=726.549
>>> eigenfunction[0].linf=0.459089
>>> eigenfunction[1].linf=0.318075
>>> eigenfunction[2].linf=0.326199
>>> eigenfunction[3].linf=0.312521
>>> eigenfunction[4].linf=0.271712
>>> eigenfunction[5].linf=0.280744
>>> eigenfunction[6].linf=0.315654
>>> eigenfunction[7].linf=0.192715
>>> eigenfunction[8].linf=0.194826
>>> 
>>> vs
>>> 
>>> mass.InfNorm =15.625
>>> stiff.InfNorm=726.549
>>> eigenfunction[0].linf=0.459089
>>> eigenfunction[1].linf=0.329682
>>> eigenfunction[2].linf=0.326199
>>> eigenfunction[3].linf=0.325289
>>> eigenfunction[4].linf=0.284252
>>> eigenfunction[5].linf=0.263418
>>> eigenfunction[6].linf=0.315756
>>> eigenfunction[7].linf=0.194826
>>> eigenfunction[8].linf=0.193074
>>> 
>>> Eigensolver tolerance is absolute and 1e-20. So it’s a bit surprising that there is a quite a big variation in L-inf norm of eigenvectors (0.318075 vs 0.329682).
>>> In either case, the biggest issue is non-deterministic behaviour.
>>> Is there anything I am missing in Krylov-Schur to make its behaviour as deterministic as possible?
>>> 
>>> p.s. shift-and-invert is done with LU from MUMPS. Shift value is lower than the exact lowest eigenvalue.
>>> 
>>> Kind regards,
>>> Denis 
>>> 
>> 
>> Which are the eigenvalues?
>> 
> 
> The eigenvalues are the same for the two runs up to the output precision:
> 
>      Eigenvalue 0 : 1.65635
>      Eigenvalue 1 : 4.71385
>      Eigenvalue 2 : 4.71385
>      Eigenvalue 3 : 4.71385
>      Eigenvalue 4 : 5.1974
>      Eigenvalue 5 : 5.1974
>      Eigenvalue 6 : 5.1974
>      Eigenvalue 7 : 7.77136
>      Eigenvalue 8 : 7.77136

As you can see, the eigenvector for the first eigenvalue (which is simple) is the same in both runs. The rest are multiple eigenvalues, so the corresponding eigenvectors are not uniquely determined simply by normalization. This means that, for instance, any linear combination of v1,v2,v3 is an eigenvector corresponding to 4.71385. Parallel computation implies slightly different numerical error in different runs, and that is why you are getting different eigenvectors. But in terms of linear algebra, both runs are correct.

Jose



More information about the petsc-users mailing list