LAPACK 3.12.1
LAPACK: Linear Algebra PACKage
Loading...
Searching...
No Matches
cla_gerpvgrw.f
Go to the documentation of this file.
1*> \brief \b CLA_GERPVGRW multiplies a square real matrix by a complex matrix.
2*
3* =========== DOCUMENTATION ===========
4*
5* Online html documentation available at
6* http://www.netlib.org/lapack/explore-html/
7*
8*> Download CLA_GERPVGRW + dependencies
9*> <a href="http://www.netlib.org/cgi-bin/netlibfiles.tgz?format=tgz&filename=/lapack/lapack_routine/cla_gerpvgrw.f">
10*> [TGZ]</a>
11*> <a href="http://www.netlib.org/cgi-bin/netlibfiles.zip?format=zip&filename=/lapack/lapack_routine/cla_gerpvgrw.f">
12*> [ZIP]</a>
13*> <a href="http://www.netlib.org/cgi-bin/netlibfiles.txt?format=txt&filename=/lapack/lapack_routine/cla_gerpvgrw.f">
14*> [TXT]</a>
15*
16* Definition:
17* ===========
18*
19* REAL FUNCTION CLA_GERPVGRW( N, NCOLS, A, LDA, AF, LDAF )
20*
21* .. Scalar Arguments ..
22* INTEGER N, NCOLS, LDA, LDAF
23* ..
24* .. Array Arguments ..
25* COMPLEX A( LDA, * ), AF( LDAF, * )
26* ..
27*
28*
29*> \par Purpose:
30* =============
31*>
32*> \verbatim
33*>
34*>
35*> CLA_GERPVGRW computes the reciprocal pivot growth factor
36*> norm(A)/norm(U). The "max absolute element" norm is used. If this is
37*> much less than 1, the stability of the LU factorization of the
38*> (equilibrated) matrix A could be poor. This also means that the
39*> solution X, estimated condition numbers, and error bounds could be
40*> unreliable.
41*> \endverbatim
42*
43* Arguments:
44* ==========
45*
46*> \param[in] N
47*> \verbatim
48*> N is INTEGER
49*> The number of linear equations, i.e., the order of the
50*> matrix A. N >= 0.
51*> \endverbatim
52*>
53*> \param[in] NCOLS
54*> \verbatim
55*> NCOLS is INTEGER
56*> The number of columns of the matrix A. NCOLS >= 0.
57*> \endverbatim
58*>
59*> \param[in] A
60*> \verbatim
61*> A is COMPLEX array, dimension (LDA,N)
62*> On entry, the N-by-N matrix A.
63*> \endverbatim
64*>
65*> \param[in] LDA
66*> \verbatim
67*> LDA is INTEGER
68*> The leading dimension of the array A. LDA >= max(1,N).
69*> \endverbatim
70*>
71*> \param[in] AF
72*> \verbatim
73*> AF is COMPLEX array, dimension (LDAF,N)
74*> The factors L and U from the factorization
75*> A = P*L*U as computed by CGETRF.
76*> \endverbatim
77*>
78*> \param[in] LDAF
79*> \verbatim
80*> LDAF is INTEGER
81*> The leading dimension of the array AF. LDAF >= max(1,N).
82*> \endverbatim
83*
84* Authors:
85* ========
86*
87*> \author Univ. of Tennessee
88*> \author Univ. of California Berkeley
89*> \author Univ. of Colorado Denver
90*> \author NAG Ltd.
91*
92*> \ingroup la_gerpvgrw
93*
94* =====================================================================
95 REAL function cla_gerpvgrw( n, ncols, a, lda, af, ldaf )
96*
97* -- LAPACK computational routine --
98* -- LAPACK is a software package provided by Univ. of Tennessee, --
99* -- Univ. of California Berkeley, Univ. of Colorado Denver and NAG Ltd..--
100*
101* .. Scalar Arguments ..
102 INTEGER n, ncols, lda, ldaf
103* ..
104* .. Array Arguments ..
105 COMPLEX a( lda, * ), af( ldaf, * )
106* ..
107*
108* =====================================================================
109*
110* .. Local Scalars ..
111 INTEGER i, j
112 REAL amax, umax, rpvgrw
113 COMPLEX zdum
114* ..
115* .. Intrinsic Functions ..
116 INTRINSIC max, min, abs, real, aimag
117* ..
118* .. Statement Functions ..
119 REAL cabs1
120* ..
121* .. Statement Function Definitions ..
122 cabs1( zdum ) = abs( real( zdum ) ) + abs( aimag( zdum ) )
123* ..
124* .. Executable Statements ..
125*
126 rpvgrw = 1.0
127
128 DO j = 1, ncols
129 amax = 0.0
130 umax = 0.0
131 DO i = 1, n
132 amax = max( cabs1( a( i, j ) ), amax )
133 END DO
134 DO i = 1, j
135 umax = max( cabs1( af( i, j ) ), umax )
136 END DO
137 IF ( umax /= 0.0 ) THEN
138 rpvgrw = min( amax / umax, rpvgrw )
139 END IF
140 END DO
141 cla_gerpvgrw = rpvgrw
142*
143* End of CLA_GERPVGRW
144*
145 END
real function cla_gerpvgrw(n, ncols, a, lda, af, ldaf)
CLA_GERPVGRW multiplies a square real matrix by a complex matrix.