- edited description
Using SLEPc PEPLinear
Hi,
I'm new using SLEPc via slepc4py interface (so maybe I am missing something, thank you in advance for your corrections). I try to solve a quadratic eigenvalue problem with PEP solver 'linear' (explicit linearization) via following code :
E = SLEPc.PEP().create()
E.setOperators([K,G,M])
E.setType('linear')
E.setProblemType(2)
E.solve()
And I get the following error :
File "PEP.pyx", line 540, in slepc4py.SLEPc.PEP.solve (src/slepc4py.SLEPc.c:34248)
petsc4py.PETSc.Error: error code 1
[0] PEPSolve() line 82 in .../slepc-3.5/src/pep/interface/pepsolve.c
[0] PEPSetUp() line 105 in .../slepc-3.5/src/pep/interface/pepsetup.c
[0] PEPSetUp_Linear() line 152 in .../slepc-3.5/src/pep/impls/linear/linear.c
[0] EPSSetUp() line 120 in .../slepc-3.5/src/eps/interface/epssetup.c
[0] EPSSetUp_KrylovSchur() line 95 in .../slepc- 3.5/src/eps/impls/krylov/krylovschur/krylovschur.c
[0] Wrong value of eps->which
Maybe I am missing some settings, but I can't find the related methods in slepc4py package (like PEPLinearsetCompanionForm
, PEPLinearsetEPS
or PEPLinearsetExplicitMatrix
described in SLEPc documentation...)
Thank you in advance,
Comments (10)
-
reporter -
reporter - edited description
-
Do you get the same if you add
E.setFromOptions()
beforeE.solve()
as in exampledemo/ex5.py
? -
reporter I get the same error message with :
E = SLEPc.PEP().create() E.setOperators([K,G,M]) E.setType('linear') E.setProblemType(2) E.setFromOptions() E.solve()
...
ex5.py
uses default 'TOAR' method, right ? -
Yes. Does TOAR work for you? If so, do not bother about LINEAR because you won't get any additional benefit.
-
reporter Yes it works. Ok, since my problem is hermitian, I though I could improve resolution using explicit linearization (TOAR method seems very general).
-
I have pushed a fix for this in slepc-master. Thanks for reporting.
-
- changed status to resolved
-
reporter Ok, how can I get an update for this ? Thanks
-
You are using the repository version of SLEPc, right? Have to
git pull
at$SLEPC_DIR
then rebuild SLEPc, then rerunsetup.py
in slepc4py. - Log in to comment