Eigen solvers (Eig)
See also Eigen solvers in the BifurcationKit.jl documentation for more information, for example on how to implement your own eigensolver.
The eigensolver is specified through NewtonPar(eigsolver = ...) and is used to monitor the stability of the solutions during continuation (see Bifurcation detection (codim 1)).
Generic eigen solvers
BifurcationKit.jl provides a list of eigensolvers which are directly usable here:
DefaultEigfor small problems (dense).EigArpackfor sparse problems.EigArnoldiMethodfor sparse problems.EigKrylovKitfor matrix-free problems.
Generalized / DAE eigen solvers
For a differential-algebraic problem $M\dot z = F(z, p)$, the stability is given by the generalized eigenvalue problem
\[J\,\phi = \lambda\, M\,\phi,\]
see Mass matrix. When GridapBifProblem is used (it is an AbstractDAEBifProblem), BifurcationKit.jl automatically wraps the user eigensolver into EigenDAE and calls it with the mass matrix. One can also build the generalized solver explicitly:
EigenMassMatrix(M, eig)solves $J\phi = \lambda M\phi$ using the eigensolvereig. For example
using BifurcationKitM0 = GridapBifurcationKit.get_mass_matrix(prob)eig = EigenMassMatrix(M0, EigArnoldiMethod(sigma = 0.1, which = LM()))λ, vp, conv, iter = eig(J, 10)EigenDAE(eig)is the wrapper used internally forAbstractDAEBifProblem. Passing a plain eigensolver toNewtonParis enough, the mass matrix is added automatically.
With a shift-invert eigensolver (EigArpack, EigArnoldiMethod), which = LM() returns the eigenvalues closest to the shift sigma, not those with the largest real part. For stability, choose a shift close to the imaginary axis where the bifurcation is expected (for example sigma ≈ iω for a Hopf bifurcation).