[petsc-users] BCs for a EPS solver

Emmanuel Ayala juaneah at gmail.com
Mon Feb 17 12:57:50 CST 2020


Hi, thanks for the quick answer.

I just did it, and it does not work. My problem is GNHEP and I use the
default solver (Krylov-Schur). Moreover I run the code with the options:
-st_ksp_type preonly -st_pc_type lu -st_pc_factor_mat_solver_type mumps

Any other suggestions?
Kind regards.

El lun., 17 de feb. de 2020 a la(s) 12:39, Jeremy Theler (
jeremy at seamplex.com) escribió:

> The usual trick is to set ones in one matrix and zeros in the other
> one.
>
>
> On Mon, 2020-02-17 at 12:35 -0600, Emmanuel Ayala wrote:
> > Hi everyone,
> >
> > I have an eigenvalue problem where I need to apply BCs to the
> > stiffness and mass matrix.
> >
> > Usually, for KSP solver, it is enough to set to zero the rows and
> > columns related to the boundary conditions. I used to apply it with
> > MatZeroRowsColumns, with a 1s on the diagonal. Then the solver works
> > well.
> >
> > There is something similar to KSP for EPS solver ?
> >
> > I already used MatZeroRowsColumns (for EPS solver), with a 1s on the
> > diagonal, and I got wrong result.
> >
> > Kind regards.
> >
> >
> >
> >
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20200217/4be24c1a/attachment.html>


More information about the petsc-users mailing list