[petsc-users] PC FieldSplit - How to Count the Iterations
Matthew Knepley
knepley at gmail.com
Wed Mar 14 10:00:13 CDT 2018
On Wed, Mar 14, 2018 at 11:21 PM, Sonia Pozzi <sonia.pozzi at usi.ch> wrote:
> Dear Barry,
>
> thank you for the answer. That helped a lot. Just a second curiosity.
> I’m setting A00 to be solved with preonly+lu. I obtain the following
> ksp_0 KSPGetTotalIterations: 26
> ksp_1 KSPGetTotalIterations: 22
> Residual ksp_0: 0 Reason ksp_0: 4
> Solution ksp_0 : Convergence in 1 iterations.
> Residual ksp_1: 5.23074e-14 Reason ksp_1: 2
> Solution ksp_1 : Convergence in 11 iterations.
> Initial system linear residual: 9.904804e-09
>
> To me is clear that kps_0 iterations number is equal to 22*1+2*2.
> But why is the iterations number for the schur complement multiplied by
> two?
> I’m giving the mass matrix as a preconditioner for the schur complement.
>
Possible cause:
The preconditioner is applied once before the solve happens in order to
compute the preconditioned initial residual. Then
if you do just one iterate in the solve, you would have two applications
of the preconditioner.
Thanks,
Matt
> Sonia
>
> Ph.D. Student
> Group of Prof. Rolf Krause
> Institute of Computational Science
> Università della Svizzera italiana
> Center for Computation Medicine in Cardiology
> Via Giuseppe Buffi, 13
> <https://maps.google.com/?q=Via+Giuseppe+Buffi,+13+CH-6900+Lugano+Switzerland&entry=gmail&source=g>
> CH-6900 Lugano
> <https://maps.google.com/?q=Via+Giuseppe+Buffi,+13+CH-6900+Lugano+Switzerland&entry=gmail&source=g>
> Switzerland
> <https://maps.google.com/?q=Via+Giuseppe+Buffi,+13+CH-6900+Lugano+Switzerland&entry=gmail&source=g>
>
> Email: pozzis at usi.ch
> Phone: +41 58 666 4972 <+41%2058%20666%2049%2072>
>
> On 14 Mar 2018, at 14:52, Smith, Barry F. <bsmith at mcs.anl.gov> wrote:
>
> KSPGetIterationNumber
>
>
>
--
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.caam.rice.edu/~mk51/>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20180315/69b84c92/attachment-0001.html>
More information about the petsc-users
mailing list