[petsc-users] fieldsplit_0_ monitor in combination with selfp

Matthew Knepley knepley at gmail.com
Thu Sep 4 07:20:17 CDT 2014


On Thu, Sep 4, 2014 at 7:06 AM, Klaij, Christiaan <C.Klaij at marin.nl> wrote:

> I'm playing with the selfp option in fieldsplit using
> snes/examples/tutorials/ex70.c. For example:
>
> mpiexec -n 2 ./ex70 -nx 4 -ny 6 \
> -ksp_type fgmres \
> -pc_type fieldsplit \
> -pc_fieldsplit_type schur \
> -pc_fieldsplit_schur_fact_type lower \
> -pc_fieldsplit_schur_precondition selfp \
> -fieldsplit_1_inner_ksp_type preonly \
> -fieldsplit_1_inner_pc_type jacobi \
> -fieldsplit_0_ksp_monitor -fieldsplit_0_ksp_max_it 1 \
> -fieldsplit_1_ksp_monitor -fieldsplit_1_ksp_max_it 1 \
> -ksp_monitor -ksp_max_it 1
>
> gives the following output
>
>   0 KSP Residual norm 1.229687498638e+00
>     Residual norms for fieldsplit_1_ solve.
>     0 KSP Residual norm 2.330138480101e+01
>     1 KSP Residual norm 1.609000846751e+01
>   1 KSP Residual norm 1.180287268335e+00
>
> To my suprise I don't see anything for the fieldsplit_0_ solve,
> why?
>

Always run with -ksp_view for any solver question.

  Thanks,

    Matt


> Furthermore, if I understand correctly the above should be
> exactly equivalent with
>
> mpiexec -n 2 ./ex70 -nx 4 -ny 6 \
> -ksp_type fgmres \
> -pc_type fieldsplit \
> -pc_fieldsplit_type schur \
> -pc_fieldsplit_schur_fact_type lower \
> -user_ksp \
> -fieldsplit_0_ksp_monitor -fieldsplit_0_ksp_max_it 1 \
> -fieldsplit_1_ksp_monitor -fieldsplit_1_ksp_max_it 1 \
> -ksp_monitor -ksp_max_it 1
>
>   0 KSP Residual norm 1.229687498638e+00
>     Residual norms for fieldsplit_0_ solve.
>     0 KSP Residual norm 5.486639587672e-01
>     1 KSP Residual norm 6.348354253703e-02
>     Residual norms for fieldsplit_1_ solve.
>     0 KSP Residual norm 2.321938107977e+01
>     1 KSP Residual norm 1.605484031258e+01
>   1 KSP Residual norm 1.183225251166e+00
>
> because -user_ksp replaces the Schur complement by the simple
> approximation A11 - A10 inv(diag(A00)) A01. Beside the missing
> fielsplit_0_ part, the numbers are pretty close but not exactly
> the same. Any explanation?
>
> Chris
>
>
> dr. ir. Christiaan Klaij
> CFD Researcher
> Research & Development
> E mailto:C.Klaij at marin.nl
> T +31 317 49 33 44
>
>
> MARIN
> 2, Haagsteeg, P.O. Box 28, 6700 AA Wageningen, The Netherlands
> T +31 317 49 39 11, F +31 317 49 32 45, I www.marin.nl
>
>


-- 
What most experimenters take for granted before they begin their
experiments is infinitely more interesting than any results to which their
experiments lead.
-- Norbert Wiener
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20140904/a60873a8/attachment.html>


More information about the petsc-users mailing list