This commit is contained in:
Salvatore Filippone
2017-07-20 14:07:52 +01:00
parent 7ec9000147
commit cbeff56b91
3 changed files with 47 additions and 46 deletions
+9 -9
View File
@@ -172,7 +172,7 @@ Furthermore, specifying block-Jacobi as coarsest-level
solver implies that the coarsest-level matrix is distributed
among the processes.
Figure&nbsp;<A HREF="#fig:ex3">4</A> shows how to set a W-cycle preconditioner which
applies no pre-smoother and 2 Gauss-Seidel sweeps as post-smoother,
applies 2 Gauss-Seidel sweeps as pre- and post-smoother,
and solves the coarsest-level system with the multifrontal LU factorization
implemented in MUMPS. It is specified that the coarsest-level
matrix is distributed, since MUMPS can be used on both
@@ -180,15 +180,15 @@ replicated and distributed matrices, and by default
it is used on replicated ones. Note the use of the parameter <code>pos</code>
to specify a property only for the pre-smoother or the post-smoother
(see Section&nbsp;<A HREF="node17.html#sec:precset">6.2</A> for more details).
Note also that a Krylov method different from CG must be used to solve
the preconditioned system, since the preconditione in nonsymmetric.
The code fragments shown in Figures&nbsp;<A HREF="#fig:ex2">3</A> and <A HREF="#fig:ex3">4</A> are
included in the example program file <code>mld_dexample_ml.f90</code> too.
<P>
Finally, Figure&nbsp;<A HREF="#fig:ex4">5</A> shows the setup of a one-level
additive Schwarz preconditioner, i.e., RAS with overlap 2. The
corresponding example program is available in the file
additive Schwarz preconditioner, i.e., RAS with overlap 2.
Note also that a Krylov method different from CG must be used to solve
the preconditioned system, since the preconditione in nonsymmetric.
The corresponding example program is available in the file
<code>mld_dexample_1lev.f90</code>.
<P>
@@ -242,20 +242,18 @@ setup of a multi-level preconditioner</CAPTION>
<PRE>
... ...
! build a W-cycle preconditioner with 2 Gauss-Seidel sweeps as
! post-smoother (and no pre-smoother), a distributed coarsest
! pre- and post-smoother, a distributed coarsest
! matrix, and MUMPS as coarsest-level solver
call P%init('ML',info)
call P%set('ML_TYPE','WCYCLE',info)
call P%set('SMOOTHER_TYPE','GS',info)
call P%set('SMOOTHER_SWEEPS',0,info,pos='PRE')
call P%set('SMOOTHER_SWEEPS',2,info,pos='PRE')
call P%set('SMOOTHER_SWEEPS',2,info,pos='POST')
call P%set('COARSE_SOLVE','MUMPS',info)
call P%set('COARSE_MAT','DIST',info)
call P%hierarchy_build(A,desc_A,info)
call P%smoothers_build(A,desc_A,info)
... ...
! solve Ax=b with preconditioned BiCGSTAB
call psb_krylov('BICGSTAB',A,P,b,x,tol,desc_A,info)
</PRE>
</TD></TR>
</TABLE>
@@ -282,6 +280,8 @@ setup of a one-level Schwarz preconditioner.</CAPTION>
call P%set('SUB_OVR',2,info)
call P%bld(A,desc_A,info)
... ...
! solve Ax=b with preconditioned BiCGSTAB
call psb_krylov('BICGSTAB',A,P,b,x,tol,desc_A,info)
</PRE>
</TD></TR>
</TABLE>