[petsc-users] QCG and KSPSetPCSide

Hong hzhang at mcs.anl.gov
Mon Jun 29 09:53:53 CDT 2015


Carol,

I tested qcg with petsc/src/ksp/ksp/examples/tutorials/ex2.c and found it
crashes with np=2, pc=bjacobi.

Then I found in
http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/KSP/KSPQCG.html

Notes: This is rarely used directly
Currently we allow symmetric preconditioning with the following scaling
matricesPCNONE
<http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/PC/PCNONE.html#PCNONE>:
D = Identity matrix PCJACOBI
<http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/PC/PCJACOBI.html#PCJACOBI>:
D = diag [d_1, d_2, ...., d_n], where d_i = sqrt(H[i,i]) PCICC
<http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/PC/PCICC.html#PCICC>:
D = L^T, implemented with forward and backward solves. Here L is an
incomplete Cholesky factor of H.

Hong


On Mon, Jun 29, 2015 at 9:22 AM, <Carol.Brickley at awe.co.uk> wrote:

> All,
>
> I am trying to use KSPSolve for a QCG solver using petsc 3.4.3 and it
> gives me the error of "PC does not have left symmetric apply!". Further
> reading on the web pages suggest I need to use KSPSetPCSide to set up a
> symmetric side for the solver. However, this does not seem to work. I am
> doing the following in an F90 code:
>
> call KSPSetPCType(ksp_ptr%ksp, 'qcg', petsc_err)
> call KSPSetPCSide(ksp_ptr%ksp, PC_SYMMETRIC, petsc_err)
>
> but I still get the same failure message when I call
> KSPSolve(ksp_ptr%ksp..)  later on.
>
> Any ideas as to why this is not working?
>
> Carol
>
>
>
>
>
> Dr Carol Brickley
> BSc,PhD,ARCS,DIC,MBCS
>
> Senior Software Engineer
> Applied Computer Science
> DS+T,
> AWE
> Aldermaston
> Reading
> Berkshire
> RG7 4PR
>
> Direct: 0118 9855035
>
>
>
> ___________________________________________________
> ____________________________
>
> The information in this email and in any attachment(s) is
> commercial in confidence. If you are not the named addressee(s)
> or
> if you receive this email in error then any distribution, copying or
> use of this communication or the information in it is strictly
> prohibited. Please notify us immediately by email at
> admin.internet(at)awe.co.uk, and then delete this message from
> your computer. While attachments are virus checked, AWE plc
> does not accept any liability in respect of any virus which is not
> detected.
>
> AWE Plc
> Registered in England and Wales
> Registration No 02763902
> AWE, Aldermaston, Reading, RG7 4PR
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20150629/a8b5d968/attachment.html>


More information about the petsc-users mailing list