File: cgssv_8c.html

package info (click to toggle)
superlu 4.3%2Bdfsg-3
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 13,100 kB
  • ctags: 6,351
  • sloc: ansic: 61,952; makefile: 398; csh: 141; fortran: 108; sh: 14
file content (202 lines) | stat: -rw-r--r-- 10,645 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
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
<title>SuperLU: SRC/cgssv.c File Reference</title>
<link href="doxygen.css" rel="stylesheet" type="text/css">
<link href="tabs.css" rel="stylesheet" type="text/css">
</head><body>
<!-- Generated by Doxygen 1.5.5 -->
<div class="navigation" id="top">
  <div class="tabs">
    <ul>
      <li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
      <li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
      <li class="current"><a href="files.html"><span>Files</span></a></li>
    </ul>
  </div>
</div>
<div class="contents">
<h1>SRC/cgssv.c File Reference</h1>Solves the system of linear equations A*X=B. <a href="#_details">More...</a>
<p>
<code>#include &quot;<a class="el" href="slu__cdefs_8h-source.html">slu_cdefs.h</a>&quot;</code><br>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="cgssv_8c.html#b592d134574c9813b7f8959026c94e8f">cgssv</a> (<a class="el" href="structsuperlu__options__t.html">superlu_options_t</a> *options, <a class="el" href="structSuperMatrix.html">SuperMatrix</a> *<a class="el" href="ilu__zdrop__row_8c.html#c900805a486cbb8489e3c176ed6e0d8e">A</a>, int *perm_c, int *perm_r, <a class="el" href="structSuperMatrix.html">SuperMatrix</a> *L, <a class="el" href="structSuperMatrix.html">SuperMatrix</a> *U, <a class="el" href="structSuperMatrix.html">SuperMatrix</a> *B, <a class="el" href="structSuperLUStat__t.html">SuperLUStat_t</a> *stat, int *info)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Driver routines.  <a href="#b592d134574c9813b7f8959026c94e8f"></a><br></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
<pre>
 -- SuperLU routine (version 3.0) --
 Univ. of California Berkeley, Xerox Palo Alto Research Center,
 and Lawrence Berkeley National Lab.
 October 15, 2003
 </pre> <hr><h2>Function Documentation</h2>
<a class="anchor" name="b592d134574c9813b7f8959026c94e8f"></a><!-- doxytag: member="cgssv.c::cgssv" ref="b592d134574c9813b7f8959026c94e8f" args="(superlu_options_t *options, SuperMatrix *A, int *perm_c, int *perm_r, SuperMatrix *L, SuperMatrix *U, SuperMatrix *B, SuperLUStat_t *stat, int *info)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void cgssv           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structsuperlu__options__t.html">superlu_options_t</a> *&nbsp;</td>
          <td class="paramname"> <em>options</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structSuperMatrix.html">SuperMatrix</a> *&nbsp;</td>
          <td class="paramname"> <em>A</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int *&nbsp;</td>
          <td class="paramname"> <em>perm_c</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int *&nbsp;</td>
          <td class="paramname"> <em>perm_r</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structSuperMatrix.html">SuperMatrix</a> *&nbsp;</td>
          <td class="paramname"> <em>L</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structSuperMatrix.html">SuperMatrix</a> *&nbsp;</td>
          <td class="paramname"> <em>U</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structSuperMatrix.html">SuperMatrix</a> *&nbsp;</td>
          <td class="paramname"> <em>B</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structSuperLUStat__t.html">SuperLUStat_t</a> *&nbsp;</td>
          <td class="paramname"> <em>stat</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int *&nbsp;</td>
          <td class="paramname"> <em>info</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td width="100%"></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
<pre>
 Purpose
 =======</pre><p>
<pre> CGSSV solves the system of linear equations A*X=B, using the
 LU factorization from CGSTRF. It performs the following steps:</pre><p>
<pre>   1. If A is stored column-wise (A-&gt;Stype = SLU_NC):</pre><p>
<pre>      1.1. Permute the columns of A, forming A*Pc, where Pc
           is a permutation matrix. For more details of this step, 
           see <a class="el" href="sp__preorder_8c.html" title="Permute and performs functions on columns of orginal matrix.">sp_preorder.c</a>.</pre><p>
<pre>      1.2. Factor A as Pr*A*Pc=L*U with the permutation Pr determined
           by Gaussian elimination with partial pivoting.
           L is unit lower triangular with offdiagonal entries
           bounded by 1 in magnitude, and U is upper triangular.</pre><p>
<pre>      1.3. Solve the system of equations A*X=B using the factored
           form of A.</pre><p>
<pre>   2. If A is stored row-wise (A-&gt;Stype = SLU_NR), apply the
      above algorithm to the transpose of A:</pre><p>
<pre>      2.1. Permute columns of transpose(A) (rows of A),
           forming transpose(A)*Pc, where Pc is a permutation matrix. 
           For more details of this step, see <a class="el" href="sp__preorder_8c.html" title="Permute and performs functions on columns of orginal matrix.">sp_preorder.c</a>.</pre><p>
<pre>      2.2. Factor A as Pr*transpose(A)*Pc=L*U with the permutation Pr
           determined by Gaussian elimination with partial pivoting.
           L is unit lower triangular with offdiagonal entries
           bounded by 1 in magnitude, and U is upper triangular.</pre><p>
<pre>      2.3. Solve the system of equations A*X=B using the factored
           form of A.</pre><p>
<pre>   See <a class="el" href="supermatrix_8h.html" title="Defines matrix types.">supermatrix.h</a> for the definition of 'SuperMatrix' structure.</pre><p>
<pre> Arguments
 =========</pre><p>
<pre> options (input) superlu_options_t*
         The structure defines the input parameters to control
         how the LU decomposition will be performed and how the
         system will be solved.</pre><p>
<pre> A       (input) SuperMatrix*
         Matrix A in A*X=B, of dimension (A-&gt;nrow, A-&gt;ncol). The number
         of linear equations is A-&gt;nrow. Currently, the type of A can be:
         Stype = SLU_NC or SLU_NR; Dtype = SLU_C; Mtype = SLU_GE.
         In the future, more general A may be handled.</pre><p>
<pre> perm_c  (input/output) int*
         If A-&gt;Stype = SLU_NC, column permutation vector of size A-&gt;ncol
         which defines the permutation matrix Pc; perm_c[i] = j means 
         column i of A is in position j in A*Pc.
         If A-&gt;Stype = SLU_NR, column permutation vector of size A-&gt;nrow
         which describes permutation of columns of transpose(A) 
         (rows of A) as described above.</pre><p>
<pre>         If options-&gt;ColPerm = MY_PERMC or options-&gt;Fact = SamePattern or
            options-&gt;Fact = SamePattern_SameRowPerm, it is an input argument.
            On exit, perm_c may be overwritten by the product of the input
            perm_c and a permutation that postorders the elimination tree
            of Pc'*A'*A*Pc; perm_c is not changed if the elimination tree
            is already in postorder.
         Otherwise, it is an output argument.</pre><p>
<pre> perm_r  (input/output) int*
         If A-&gt;Stype = SLU_NC, row permutation vector of size A-&gt;nrow, 
         which defines the permutation matrix Pr, and is determined 
         by partial pivoting.  perm_r[i] = j means row i of A is in 
         position j in Pr*A.
         If A-&gt;Stype = SLU_NR, permutation vector of size A-&gt;ncol, which
         determines permutation of rows of transpose(A)
         (columns of A) as described above.</pre><p>
<pre>         If options-&gt;RowPerm = MY_PERMR or
            options-&gt;Fact = SamePattern_SameRowPerm, perm_r is an
            input argument.
         otherwise it is an output argument.</pre><p>
<pre> L       (output) SuperMatrix*
         The factor L from the factorization 
             Pr*A*Pc=L*U              (if A-&gt;Stype = SLU_NC) or
             Pr*transpose(A)*Pc=L*U   (if A-&gt;Stype = SLU_NR).
         Uses compressed row subscripts storage for supernodes, i.e.,
         L has types: Stype = SLU_SC, Dtype = SLU_C, Mtype = SLU_TRLU.</pre><p>
<pre> U       (output) SuperMatrix*
	   The factor U from the factorization 
             Pr*A*Pc=L*U              (if A-&gt;Stype = SLU_NC) or
             Pr*transpose(A)*Pc=L*U   (if A-&gt;Stype = SLU_NR).
         Uses column-wise storage scheme, i.e., U has types:
         Stype = SLU_NC, Dtype = SLU_C, Mtype = SLU_TRU.</pre><p>
<pre> B       (input/output) SuperMatrix*
         B has types: Stype = SLU_DN, Dtype = SLU_C, Mtype = SLU_GE.
         On entry, the right hand side matrix.
         On exit, the solution matrix if info = 0;</pre><p>
<pre> stat   (output) SuperLUStat_t*
        Record the statistics on runtime and floating-point operation count.
        See util.h for the definition of 'SuperLUStat_t'.</pre><p>
<pre> info    (output) int*
	   = 0: successful exit
         &gt; 0: if info = i, and i is
             &lt;= A-&gt;ncol: U(i,i) is exactly zero. The factorization has
                been completed, but the factor U is exactly singular,
                so the solution could not be computed.
             &gt; A-&gt;ncol: number of bytes allocated when memory allocation
                failure occurred, plus A-&gt;ncol.
 </pre> 
</div>
</div><p>
</div>
<hr size="1"><address style="text-align: right;"><small>Generated on Thu Aug 25 13:43:49 2011 for SuperLU by&nbsp;
<a href="http://www.doxygen.org/index.html">
<img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.5.5 </small></address>
</body>
</html>