[petsc-users] ASM for Saddle-point problems

Jed Brown jed at jedbrown.org
Wed Feb 26 13:19:19 CST 2014


Jed Brown <jed at jedbrown.org> writes:
> If you really want to check whether the user set this option via
> options, you can use
>
>     PCFieldSplitSchurPreType  schurpre;
>     PetscBool set;
>
>     ierr = PetscOptionsGetEnum(prefix,"-pc_fieldsplit_schur_precondition",PCFieldSplitSchurPreTypes,(PetscEnum*)&schurpre,&set);CHKERRQ(ierr);
>
>     if (set && schurpre == PC_FIELDSPLIT_SCHUR_PRE_USER) ...
>
>
> Looks like there should be a PCFieldSplitGetSchurPrecondition, though
> this name is too long.

I have merged the following two commits to 'next'.  Using
PCFieldSplitGetSchurPre() should be cleaner for your purposes.  Let me
know if you have any issues.


commit 29f8a81cebd6492cb691295cd39f6a1b6a980034
Author: Jed Brown <jed at jedbrown.org>
Date:   Wed Feb 26 09:46:16 2014 -0700

    PCFieldSplit: fix PCFieldSplitSchurPrecondition name
    
    Now symmetric with newly-added PCFieldSplitGetSchurPre.

 include/petscpc.h                            |  5 ++-
 .../website/documentation/changes/dev.html   |  1 +
 src/ksp/pc/impls/fieldsplit/fieldsplit.c     | 36 +++++++++---------
 src/ksp/pc/impls/lsc/lsc.c                   |  2 +-
 src/snes/examples/tutorials/ex70.c           |  2 +-
 5 files changed, 23 insertions(+), 23 deletions(-)

commit 37a82bf00f7431c104146914c636f11c334e6880
Author: Jed Brown <jed at jedbrown.org>
Date:   Wed Feb 26 09:28:50 2014 -0700

    PCFieldSplit: add accessor for Schur preconditioner configuration

 include/petscpc.h                        |  1 +
 src/ksp/pc/impls/fieldsplit/fieldsplit.c | 47 +++++++++++++++++++++-
 2 files changed, 47 insertions(+), 1 deletion(-)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 835 bytes
Desc: not available
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20140226/d2144109/attachment.pgp>


More information about the petsc-users mailing list