File: PCFIELDSPLIT.html

package info (click to toggle)
petsc 3.4.2.dfsg1-8.1
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 129,104 kB
  • ctags: 516,422
  • sloc: ansic: 395,939; cpp: 47,201; python: 34,788; makefile: 17,193; fortran: 16,251; f90: 1,592; objc: 954; sh: 822; xml: 621; java: 381; lisp: 293; csh: 241
file content (114 lines) | stat: -rw-r--r-- 7,788 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML3.2 EN">
<HTML>
<HEAD> <link rel="canonical" href="http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/PC/PCFIELDSPLIT.html" />
<META NAME="GENERATOR" CONTENT="DOCTEXT">
<TITLE>PCFIELDSPLIT</TITLE>
</HEAD>
<BODY BGCOLOR="FFFFFF">
   <div id="version" align=right><b>petsc-3.4.2 2013-07-02</b></div>
<A NAME="PCFIELDSPLIT"><H1>PCFIELDSPLIT</H1></A>
Preconditioner created by combining separate preconditioners for individual fields or groups of fields. See the users manual section "Solving Block Matrices" for more details. To set options on the solvers for each block append -fieldsplit_ to all the <A HREF="../PC/PC.html#PC">PC</A>
options database keys. For example, -fieldsplit_pc_type ilu -fieldsplit_pc_factor_levels 1
<P>
To set the options on the solvers separate for each block call <A HREF="../PC/PCFieldSplitGetSubKSP.html#PCFieldSplitGetSubKSP">PCFieldSplitGetSubKSP</A>()
and set the options directly on the resulting <A HREF="../KSP/KSP.html#KSP">KSP</A> object
<P>

<P>
<H3><FONT COLOR="#CC3333">Options Database Keys</FONT></H3>
<TABLE border="0" cellpadding="0" cellspacing="0">
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B>-pc_fieldsplit_%d_fields &lt;a,b,..&gt; </B></TD><TD>- indicates the fields to be used in the %d'th split
</TD></TR>
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B>-pc_fieldsplit_default </B></TD><TD>- automatically add any fields to additional splits that have not
been supplied explicitly by -pc_fieldsplit_%d_fields
</TD></TR>
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B>-pc_fieldsplit_block_size &lt;bs&gt; </B></TD><TD>- size of block that defines fields (i.e. there are bs fields)
</TD></TR>
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B>-pc_fieldsplit_type &lt;additive,multiplicative,symmetric_multiplicative,schur&gt; </B></TD><TD>- type of relaxation or factorization splitting
</TD></TR>
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B>-pc_fieldsplit_schur_precondition &lt;self,user,a11&gt; </B></TD><TD>- default is a11
</TD></TR>
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B>-pc_fieldsplit_detect_saddle_point </B></TD><TD>- automatically finds rows with zero or negative diagonal and uses Schur complement with no preconditioner as the solver
</TD></TR>
<P>
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B>Options prefix for inner solvers when using Schur complement preconditioner are </B></TD><TD>- fieldsplit_0_ and -fieldsplit_1_
for all other solvers they are -fieldsplit_%d_ for the dth field, use -fieldsplit_ for all fields
</TD></TR></TABLE>
<P>
<H3><FONT COLOR="#CC3333">Notes</FONT></H3>
Use <A HREF="../PC/PCFieldSplitSetFields.html#PCFieldSplitSetFields">PCFieldSplitSetFields</A>() to set fields defined by "strided" entries and <A HREF="../PC/PCFieldSplitSetIS.html#PCFieldSplitSetIS">PCFieldSplitSetIS</A>()
to define a field by an arbitrary collection of entries.
<P>
If no fields are set the default is used. The fields are defined by entries strided by bs,
beginning at 0 then 1, etc to bs-1. The block size can be set with <A HREF="../PC/PCFieldSplitSetBlockSize.html#PCFieldSplitSetBlockSize">PCFieldSplitSetBlockSize</A>(),
if this is not called the block size defaults to the blocksize of the second matrix passed
to <A HREF="../KSP/KSPSetOperators.html#KSPSetOperators">KSPSetOperators</A>()/<A HREF="../PC/PCSetOperators.html#PCSetOperators">PCSetOperators</A>().
<P>
<pre>
    For the Schur complement preconditioner if J = ( A00 A01 )
</pre>
<pre>
                                                   ( A10 A11 )
</pre>
<pre>
    the preconditioner using full factorization is
</pre>
<pre>
             ( I   -A10 ksp(A00) ) ( inv(A00)     0  ) (     I          0  )
</pre>
<pre>
             ( 0         I       ) (   0      ksp(S) ) ( -A10 ksp(A00)  I  )
</pre>
where the action of inv(A00) is applied using the <A HREF="../KSP/KSP.html#KSP">KSP</A> solver with prefix -fieldsplit_0_. The action of
ksp(S) is computed using the <A HREF="../KSP/KSP.html#KSP">KSP</A> solver with prefix -fieldsplit_splitname_ (where splitname was given
in providing the SECOND split or 1 if not give). For PCFieldSplitGetKSP() when field number is 0,
it returns the <A HREF="../KSP/KSP.html#KSP">KSP</A> associated with -fieldsplit_0_ while field number 1 gives -fieldsplit_1_ <A HREF="../KSP/KSP.html#KSP">KSP</A>. By default
A11 is used to construct a preconditioner for S, use <A HREF="../PC/PCFieldSplitSchurPrecondition.html#PCFieldSplitSchurPrecondition">PCFieldSplitSchurPrecondition</A>() to turn on or off this
option. You can use the preconditioner <A HREF="../PC/PCLSC.html#PCLSC">PCLSC</A> to precondition the Schur complement with -fieldsplit_1_pc_type lsc. The
factorization type is set using -pc_fieldsplit_schur_fact_type &lt;diag, lower, upper, full&gt;. The full is shown above,
diag gives
<pre>
             ( inv(A00)     0   )
</pre>
<pre>
             (   0      -ksp(S) )
</pre>
note that slightly counter intuitively there is a negative in front of the ksp(S) so that the preconditioner is positive definite. The lower factorization is the inverse of
<pre>
             (  A00   0 )
</pre>
<pre>
             (  A10   S )
</pre>
where the inverses of A00 and S are applied using KSPs. The upper factorization is the inverse of
<pre>
             ( A00 A01 )
</pre>
<pre>
             (  0   S  )
</pre>
where again the inverses of A00 and S are applied using KSPs.
<P>
If only one set of indices (one <A HREF="../IS/IS.html#IS">IS</A>) is provided with <A HREF="../PC/PCFieldSplitSetIS.html#PCFieldSplitSetIS">PCFieldSplitSetIS</A>() then the complement of that <A HREF="../IS/IS.html#IS">IS</A>
is used automatically for a second block.
<P>
The fieldsplit preconditioner cannot currently be used with the BAIJ or SBAIJ data formats if the blocksize is larger than 1.
Generally it should be used with the AIJ format.
<P>
The forms of these preconditioners are closely related if not identical to forms derived as "Distributive Iterations", see,
for example, page 294 in "Principles of Computational Fluid Dynamics" by Pieter Wesseling. Note that one can also use <A HREF="../PC/PCFIELDSPLIT.html#PCFIELDSPLIT">PCFIELDSPLIT</A>
inside a smoother resulting in "Distributive Smoothers".
<P>
<P>
<H3><FONT COLOR="#CC3333">See Also</FONT></H3>
  <A HREF="../PC/PCCreate.html#PCCreate">PCCreate</A>(), <A HREF="../PC/PCSetType.html#PCSetType">PCSetType</A>(), <A HREF="../PC/PCType.html#PCType">PCType</A> (for list of available types), <A HREF="../PC/PC.html#PC">PC</A>, Block_Preconditioners, <A HREF="../PC/PCLSC.html#PCLSC">PCLSC</A>,
<BR><A HREF="../PC/PCFieldSplitGetSubKSP.html#PCFieldSplitGetSubKSP">PCFieldSplitGetSubKSP</A>(), <A HREF="../PC/PCFieldSplitSetFields.html#PCFieldSplitSetFields">PCFieldSplitSetFields</A>(), <A HREF="../PC/PCFieldSplitSetType.html#PCFieldSplitSetType">PCFieldSplitSetType</A>(), <A HREF="../PC/PCFieldSplitSetIS.html#PCFieldSplitSetIS">PCFieldSplitSetIS</A>(), <A HREF="../PC/PCFieldSplitSchurPrecondition.html#PCFieldSplitSchurPrecondition">PCFieldSplitSchurPrecondition</A>()
<P><B><P><B><FONT COLOR="#CC3333">Level:</FONT></B>intermediate
<BR><FONT COLOR="#CC3333">Location:</FONT></B><A HREF="../../../src/ksp/pc/impls/fieldsplit/fieldsplit.c.html#PCFIELDSPLIT">src/ksp/pc/impls/fieldsplit/fieldsplit.c</A>
<BR><A HREF="./index.html">Index of all PC routines</A>
<BR><A HREF="../../index.html">Table of Contents for all manual pages</A>
<BR><A HREF="../singleindex.html">Index of all manual pages</A>
<P><H3><FONT COLOR="#CC3333">Examples</FONT></H3>
<A HREF="../../../src/snes/examples/tutorials/ex55.c.html">src/snes/examples/tutorials/ex55.c.html</A><BR>
<A HREF="../../../src/snes/examples/tutorials/ex70.c.html">src/snes/examples/tutorials/ex70.c.html</A><BR>
</BODY></HTML>