[petsc-users] KSP not converge when turn on ksp_monitor_true_residual

Matthew Knepley knepley at gmail.com
Fri Jun 5 05:48:09 CDT 2020


On Fri, Jun 5, 2020 at 6:12 AM Y. Shidi <ys453 at cam.ac.uk> wrote:

> Dear developers,
>
> We are using filed splitting method solve saddle point problem.
> Below is our ksp configuration:
>
>    PetscOptionsSetValue(NULL,"-ksp_type","gmres");
>    PetscOptionsSetValue(NULL,"-ksp_initial_guess_nonzero","");
>    PetscOptionsSetValue(NULL,"-ksp_rtol","1e-20");
>

This algebraic tolerance is strange. Why put it below unit roundoff?


>    PetscOptionsSetValue(NULL,"-ksp_converged_reason", "");
>    PetscOptionsSetValue(NULL,"-pc_type", "fieldsplit");
>    PetscOptionsSetValue(NULL,"-pc_fieldsplit_type", "schur");
>    PetscOptionsSetValue(NULL,"-pc_fieldsplit_schur_fact_type", "lower");
>    PetscOptionsSetValue(NULL,"-pc_fieldsplit_schur_precondition",
> "selfp");
>    PetscOptionsSetValue(NULL,"-fieldsplit_0_ksp_type", "preonly");
>    PetscOptionsSetValue(NULL,"-fieldsplit_0_pc_type", "hypre");
>    PetscOptionsSetValue(NULL,"-fieldsplit_1_ksp_type", "preonly");
>    PetscOptionsSetValue(NULL,"-fieldsplit_1_pc_type", "hypre");
>
> It can be converged. However, when we turn on the ksp monitor:
>
>    PetscOptionsSetValue(NULL,"-ksp_monitor_true_residual", "");
>
> It won't converge. It seems very odd, I am wondering why it happens.
>

Can you try it with a relative tolerance of 1e-10, and send the output
(with -ksp_view as well).

  Thanks,

     Matt


> Thank you for your time and help.
>
> Kind regards,
> Shidi
>


-- 
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

https://www.cse.buffalo.edu/~knepley/ <http://www.cse.buffalo.edu/~knepley/>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20200605/02b00e2f/attachment.html>


More information about the petsc-users mailing list