File: zgsrfs_8c.html

package info (click to toggle)
superlu 5.3.0%2Bdfsg1-2
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 11,976 kB
  • sloc: ansic: 59,420; makefile: 405; fortran: 185; csh: 141
file content (322 lines) | stat: -rw-r--r-- 19,360 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
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.15"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>SuperLU: SRC/zgsrfs.c File Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">SuperLU
   &#160;<span id="projectnumber">5.3.0</span>
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.15 -->
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
  initMenu('',false,false,'search.php','Search');
});
/* @license-end */</script>
<div id="main-nav"></div>
<div id="nav-path" class="navpath">
  <ul>
<li class="navelem"><a class="el" href="dir_1e771ff450ae847412a8c28572c155bb.html">SRC</a></li>  </ul>
</div>
</div><!-- top -->
<div class="header">
  <div class="summary">
<a href="#define-members">Macros</a> &#124;
<a href="#func-members">Functions</a>  </div>
  <div class="headertitle">
<div class="title">zgsrfs.c File Reference</div>  </div>
</div><!--header-->
<div class="contents">

<p>Improves computed solution to a system of inear equations.  
<a href="#details">More...</a></p>
<div class="textblock"><code>#include &lt;math.h&gt;</code><br />
<code>#include &quot;<a class="el" href="slu__zdefs_8h_source.html">slu_zdefs.h</a>&quot;</code><br />
</div><div class="textblock"><div class="dynheader">
Include dependency graph for zgsrfs.c:</div>
<div class="dyncontent">
<div class="center"><img src="zgsrfs_8c__incl.png" border="0" usemap="#SRC_2zgsrfs_8c" alt=""/></div>
<map name="SRC_2zgsrfs_8c" id="SRC_2zgsrfs_8c">
<area shape="rect"  title="Improves computed solution to a system of inear equations." alt="" coords="161,5,261,32"/>
<area shape="rect"  title=" " alt="" coords="5,155,68,181"/>
<area shape="rect"  href="slu__zdefs_8h.html" title="Header file for real operations." alt="" coords="341,80,431,107"/>
<area shape="rect"  title=" " alt="" coords="730,155,794,181"/>
<area shape="rect"  title=" " alt="" coords="573,229,634,256"/>
<area shape="rect"  title=" " alt="" coords="738,229,802,256"/>
<area shape="rect"  title=" " alt="" coords="243,155,308,181"/>
<area shape="rect"  title=" " alt="" coords="41,229,107,256"/>
<area shape="rect"  href="slu__Cnames_8h.html" title="Macros defining how C routines will be called." alt="" coords="333,155,439,181"/>
<area shape="rect"  href="supermatrix_8h.html" title="Matrix type definitions." alt="" coords="464,155,567,181"/>
<area shape="rect"  href="slu__util_8h.html" title="Utility header file." alt="" coords="143,155,218,181"/>
<area shape="rect"  href="slu__dcomplex_8h.html" title="Header file for complex operations." alt="" coords="591,155,706,181"/>
<area shape="rect"  title=" " alt="" coords="319,229,389,256"/>
<area shape="rect"  href="superlu__enum__consts_8h.html" title="enum constants header file" alt="" coords="131,229,295,256"/>
</map>
</div>
</div><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="define-members"></a>
Macros</h2></td></tr>
<tr class="memitem:a3641b6d4c21b7a852dbb32c2b693302e"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="zgsrfs_8c.html#a3641b6d4c21b7a852dbb32c2b693302e">ITMAX</a>&#160;&#160;&#160;5</td></tr>
<tr class="separator:a3641b6d4c21b7a852dbb32c2b693302e"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
Functions</h2></td></tr>
<tr class="memitem:ac21acad54459e74738cbca9f7f20a73b"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="zgsrfs_8c.html#ac21acad54459e74738cbca9f7f20a73b">zgsrfs</a> (<a class="el" href="superlu__enum__consts_8h.html#a0c4e17b2d5cea33f9991ccc6a6678d62">trans_t</a> trans, <a class="el" href="structSuperMatrix.html">SuperMatrix</a> *<a class="el" href="ilu__zdrop__row_8c.html#ac900805a486cbb8489e3c176ed6e0d8e">A</a>, <a class="el" href="structSuperMatrix.html">SuperMatrix</a> *L, <a class="el" href="structSuperMatrix.html">SuperMatrix</a> *U, int *perm_c, int *perm_r, char *equed, double *R, double *C, <a class="el" href="structSuperMatrix.html">SuperMatrix</a> *B, <a class="el" href="structSuperMatrix.html">SuperMatrix</a> *X, double *ferr, double *berr, <a class="el" href="structSuperLUStat__t.html">SuperLUStat_t</a> *stat, int *info)</td></tr>
<tr class="separator:ac21acad54459e74738cbca9f7f20a73b"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>Copyright (c) 2003, The Regents of the University of California, through Lawrence Berkeley National Laboratory (subject to receipt of any required approvals from U.S. Dept. of Energy)</p>
<p>All rights reserved.</p>
<p>The source code is distributed under BSD license, see the file License.txt at the top-level directory.</p>
<pre>
-- SuperLU routine (version 5.1) --
Univ. of California Berkeley, Xerox Palo Alto Research Center,
and Lawrence Berkeley National Lab.
October 15, 2003</pre><pre>Modified from lapack routine ZGERFS
Last modified: December 3, 2015
</pre> </div><h2 class="groupheader">Macro Definition Documentation</h2>
<a id="a3641b6d4c21b7a852dbb32c2b693302e"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a3641b6d4c21b7a852dbb32c2b693302e">&#9670;&nbsp;</a></span>ITMAX</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define ITMAX&#160;&#160;&#160;5</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>
<h2 class="groupheader">Function Documentation</h2>
<a id="ac21acad54459e74738cbca9f7f20a73b"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ac21acad54459e74738cbca9f7f20a73b">&#9670;&nbsp;</a></span>zgsrfs()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void zgsrfs </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="superlu__enum__consts_8h.html#a0c4e17b2d5cea33f9991ccc6a6678d62">trans_t</a>&#160;</td>
          <td class="paramname"><em>trans</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structSuperMatrix.html">SuperMatrix</a> *&#160;</td>
          <td class="paramname"><em>A</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structSuperMatrix.html">SuperMatrix</a> *&#160;</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> *&#160;</td>
          <td class="paramname"><em>U</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int *&#160;</td>
          <td class="paramname"><em>perm_c</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int *&#160;</td>
          <td class="paramname"><em>perm_r</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">char *&#160;</td>
          <td class="paramname"><em>equed</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">double *&#160;</td>
          <td class="paramname"><em>R</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">double *&#160;</td>
          <td class="paramname"><em>C</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structSuperMatrix.html">SuperMatrix</a> *&#160;</td>
          <td class="paramname"><em>B</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structSuperMatrix.html">SuperMatrix</a> *&#160;</td>
          <td class="paramname"><em>X</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">double *&#160;</td>
          <td class="paramname"><em>ferr</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">double *&#160;</td>
          <td class="paramname"><em>berr</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structSuperLUStat__t.html">SuperLUStat_t</a> *&#160;</td>
          <td class="paramname"><em>stat</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int *&#160;</td>
          <td class="paramname"><em>info</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<pre>
  Purpose   
  =======</pre><pre>  ZGSRFS improves the computed solution to a system of linear   
  equations and provides error bounds and backward error estimates for 
  the solution.</pre><pre>  If equilibration was performed, the system becomes:
          (diag(R)*A_original*diag(C)) * X = diag(R)*B_original.</pre><pre>  See <a class="el" href="supermatrix_8h.html" title="Matrix type definitions.">supermatrix.h</a> for the definition of '<a class="el" href="structSuperMatrix.html">SuperMatrix</a>' structure.</pre><pre>  Arguments   
  =========</pre><pre>trans   (input) trans_t
         Specifies the form of the system of equations:
         = NOTRANS: A * X = B  (No transpose)
         = TRANS:   A'* X = B  (Transpose)
         = CONJ:    A**H * X = B  (Conjugate transpose)</pre><pre>  A       (input) SuperMatrix*
          The original matrix A in the system, or the scaled A if
          equilibration was done. The type of A can be:
          Stype = SLU_NC, Dtype = SLU_Z, Mtype = SLU_GE.</pre><pre>  L       (input) SuperMatrix*
          The factor L from the factorization Pr*A*Pc=L*U. Use
          compressed row subscripts storage for supernodes, 
          i.e., L has types: Stype = SLU_SC, Dtype = SLU_Z, Mtype = SLU_TRLU.</pre><pre>  U       (input) SuperMatrix*
          The factor U from the factorization Pr*A*Pc=L*U as computed by
          <a class="el" href="slu__zdefs_8h.html#a2590dbb66d39c3055f88292f5f093be7">zgstrf()</a>. Use column-wise storage scheme, 
          i.e., U has types: Stype = SLU_NC, Dtype = SLU_Z, Mtype = SLU_TRU.</pre><pre>  perm_c  (input) int*, dimension (A-&gt;ncol)
          Column permutation vector, which defines the 
          permutation matrix Pc; perm_c[i] = j means column i of A is 
          in position j in A*Pc.</pre><pre>  perm_r  (input) int*, dimension (A-&gt;nrow)
          Row permutation vector, which defines the permutation matrix Pr;
          perm_r[i] = j means row i of A is in position j in Pr*A.</pre><pre>  equed   (input) Specifies the form of equilibration that was done.
          = 'N': No equilibration.
          = 'R': Row equilibration, i.e., A was premultiplied by diag(R).
          = 'C': Column equilibration, i.e., A was postmultiplied by
                 diag(C).
          = 'B': Both row and column equilibration, i.e., A was replaced 
                 by diag(R)*A*diag(C).</pre><pre>  R       (input) double*, dimension (A-&gt;nrow)
          The row scale factors for A.
          If equed = 'R' or 'B', A is premultiplied by diag(R).
          If equed = 'N' or 'C', R is not accessed.</pre><pre>  C       (input) double*, dimension (A-&gt;ncol)
          The column scale factors for A.
          If equed = 'C' or 'B', A is postmultiplied by diag(C).
          If equed = 'N' or 'R', C is not accessed.</pre><pre>  B       (input) SuperMatrix*
          B has types: Stype = SLU_DN, Dtype = SLU_Z, Mtype = SLU_GE.
          The right hand side matrix B.
          if equed = 'R' or 'B', B is premultiplied by diag(R).</pre><pre>  X       (input/output) SuperMatrix*
          X has types: Stype = SLU_DN, Dtype = SLU_Z, Mtype = SLU_GE.
          On entry, the solution matrix X, as computed by <a class="el" href="slu__zdefs_8h.html#a1b74304cd437572bbec487bc29422a90">zgstrs()</a>.
          On exit, the improved solution matrix X.
          if *equed = 'C' or 'B', X should be premultiplied by diag(C)
              in order to obtain the solution to the original system.</pre><pre>  FERR    (output) double*, dimension (B-&gt;ncol)   
          The estimated forward error bound for each solution vector   
          X(j) (the j-th column of the solution matrix X).   
          If XTRUE is the true solution corresponding to X(j), FERR(j) 
          is an estimated upper bound for the magnitude of the largest 
          element in (X(j) - XTRUE) divided by the magnitude of the   
          largest element in X(j).  The estimate is as reliable as   
          the estimate for RCOND, and is almost always a slight   
          overestimate of the true error.</pre><pre>  BERR    (output) double*, dimension (B-&gt;ncol)   
          The componentwise relative backward error of each solution   
          vector X(j) (i.e., the smallest relative change in   
          any element of A or B that makes X(j) an exact solution).</pre><pre>  stat     (output) SuperLUStat_t*
           Record the statistics on runtime and floating-point operation count.
           See util.h for the definition of '<a class="el" href="structSuperLUStat__t.html">SuperLUStat_t</a>'.</pre><pre>  info    (output) int*   
          = 0:  successful exit   
           &lt; 0:  if INFO = -i, the i-th argument had an illegal value</pre><pre>   Internal Parameters   
   ===================</pre><pre>   ITMAX is the maximum number of steps of iterative refinement.</pre><pre></pre> <div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="zgsrfs_8c_ac21acad54459e74738cbca9f7f20a73b_cgraph.png" border="0" usemap="#zgsrfs_8c_ac21acad54459e74738cbca9f7f20a73b_cgraph" alt=""/></div>
<map name="zgsrfs_8c_ac21acad54459e74738cbca9f7f20a73b_cgraph" id="zgsrfs_8c_ac21acad54459e74738cbca9f7f20a73b_cgraph">
<area shape="rect"  title=" " alt="" coords="5,360,63,387"/>
<area shape="rect"  href="zlacon2_8c.html#a386accb9d3bf1919491ed242ff28657e" title=" " alt="" coords="114,132,190,159"/>
<area shape="rect"  href="dmach_8c.html#a9619845d75710daa0aa4549c2862bae5" title=" " alt="" coords="285,5,348,32"/>
<area shape="rect"  href="dcomplex_8c.html#af701b1c549ee8dcf6767742a91681b55" title="Returns sqrt(z.r^2 + z.i^2)" alt="" coords="486,157,543,184"/>
<area shape="rect"  href="ilu__zcopy__to__ucol_8c.html#aa2b708d27c2e905ddbb02a6eb38b8d1a" title=" " alt="" coords="285,208,349,235"/>
<area shape="rect"  href="ilu__zdrop__row_8c.html#a36e8ecb2120d3fbf44a32d1b93a4adcc" title=" " alt="" coords="120,309,184,336"/>
<area shape="rect"  href="input__error_8c.html#a5832852b8f6777484b6f55dd79e67d86" title=" " alt="" coords="471,461,558,488"/>
<area shape="rect"  href="slu__zdefs_8h.html#ae33b5268048e570c0cdf96498198e821" title=" " alt="" coords="241,461,392,488"/>
<area shape="rect"  href="memory_8c.html#a49bbe20102e5b541c8e8963afa2bd46a" title=" " alt="" coords="115,689,189,716"/>
<area shape="rect"  href="slu__zdefs_8h.html#a295a004dbce1f1b0aa48e7cb319da461" title="Performs one of the matrix&#45;vector operations y := alpha*A*x + beta*y, or y := alpha*A&#39;*x + beta*y." alt="" coords="111,411,193,437"/>
<area shape="rect"  href="dcomplex_8c.html#a47b00c33108809a1a9a94ffea7ef2097" title="Approximates the abs. Returns abs(z.r) + abs(z.i)" alt="" coords="119,740,185,767"/>
<area shape="rect"  href="slu__zdefs_8h.html#a1b74304cd437572bbec487bc29422a90" title=" " alt="" coords="123,639,181,665"/>
<area shape="rect"  href="izmax1_8c.html#aaf53fd062f8467a96cf58270c87e398a" title=" " alt="" coords="272,107,361,133"/>
<area shape="rect"  href="dzsum1_8c.html#af9cbf51b3cf3e66af143acf0ff920944" title=" " alt="" coords="270,56,363,83"/>
<area shape="rect"  href="zgstrs_8c.html#aafcbead526e1e4f1b7895d3c5abfe4ab" title=" " alt="" coords="273,563,360,589"/>
<area shape="rect"  href="slu__zdefs_8h.html#ab7683ac1617339478753ab308a7b0fc5" title=" " alt="" coords="440,664,589,691"/>
<area shape="rect"  href="slu__zdefs_8h.html#aeab3fd6b0df9000815d75ecdf2903d22" title=" " alt="" coords="285,765,348,792"/>
<area shape="rect"  href="slu__zdefs_8h.html#a7566d50f83608ee97bd5615d38ca010f" title="BLAS." alt="" coords="280,816,353,843"/>
<area shape="rect"  href="slu__zdefs_8h.html#afb6f65890b5348dc1692d01b087be35d" title="Solves a dense UNIT lower triangular system." alt="" coords="483,917,546,944"/>
<area shape="rect"  href="slu__zdefs_8h.html#a1165292a4e2a6c282638868bd503fb7a" title="Performs a dense matrix&#45;vector multiply: Mxvec = Mxvec + M * vec." alt="" coords="479,968,551,995"/>
<area shape="rect"  href="dcomplex_8c.html#a4cfde2671a83833a15c5b48517781db0" title="Complex Division c = a/b." alt="" coords="637,715,691,741"/>
<area shape="rect"  href="slu__zdefs_8h.html#ac9798dda11fa387039351d70fa59ce3b" title="Solves a dense upper triangular system." alt="" coords="481,715,548,741"/>
<area shape="rect"  href="slu__zdefs_8h.html#a4f8e25c2e20af0219ad6719db052f3d7" title="Solves one of the systems of equations A*x = b, or A&#39;*x = b." alt="" coords="281,867,353,893"/>
<area shape="rect"  href="slu__zdefs_8h.html#ae97174a10346e0629387c0f8ce9a9a08" title=" " alt="" coords="486,867,543,893"/>
<area shape="rect"  href="slu__zdefs_8h.html#aa25bbd36f5c52cf8df1db92545fe80b9" title=" " alt="" coords="480,816,549,843"/>
</map>
</div>

</div>
</div>
</div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.15
</small></address>
</body>
</html>