[petsc-users] Norm of RHS in BCGS
Norihiro Watanabe
norihiro.w at gmail.com
Tue Mar 22 08:25:21 CDT 2016
Thank you Matt!
Actually I don't want to change a norm type used in a convergence
check. I just want to output a relative error which PETSc actually
used for a convergence check (for log output in my program without
-ksp_*) and thought I need to have a norm of a preconditioned RHS to
compute it by myself. Or is there any function available in PETSc
which returns the relative error or the tolerance multiplied by the
norm of a preconditioned RHS? I couldn't find it.
Best,
Nori
On Tue, Mar 22, 2016 at 1:51 PM, Matthew Knepley <knepley at gmail.com> wrote:
> On Tue, Mar 22, 2016 at 2:50 AM, Norihiro Watanabe <norihiro.w at gmail.com>
> wrote:
>>
>> Hi,
>>
>> Is it correct that a norm of a preconditioned RHS vector is used to
>> compute a relative error in BCGS?
>
>
> Yes, but you can verify this using -ksp_view
>
>>
>> I'm testing BCGS + BoomerAMG. With "-info", PETSc says "initial right
>> hand side norm" is 2.223619476717e+10 (see below) but an actual norm
>> of the RHS I passed is 4.059007e-02. If yes, is there any way to get a
>> norm of a preconditioned RHS?
>
>
> Do you mean unpreconditioned? You can try
>
>
> http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/KSP/KSPSetNormType.html
>
> or use
>
> -ksp_monitor_true_residual
>
> Thanks,
>
> Matt
>
>>
>> [0] KSPConvergedDefault(): Linear solver has converged. Residual norm
>> 2.036064453512e-02 is less than relative tolerance 9.999999960042e-13
>> times initial right hand side norm 2.223619476717e+10 at iteration 6
>>
>>
>> Regards,
>> Nori
>>
>> --
>> Norihiro Watanabe
>
>
>
>
> --
> 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
--
Norihiro Watanabe
More information about the petsc-users
mailing list