1 *> \brief \b ZLAUUM computes the product UUH or LHL, where U and L are upper or lower triangular matrices (blocked algorithm).
3 * =========== DOCUMENTATION ===========
5 * Online html documentation available at
6 * http://www.netlib.org/lapack/explore-html/
9 *> Download ZLAUUM + dependencies
10 *> <a href="http://www.netlib.org/cgi-bin/netlibfiles.tgz?format=tgz&filename=/lapack/lapack_routine/zlauum.f">
12 *> <a href="http://www.netlib.org/cgi-bin/netlibfiles.zip?format=zip&filename=/lapack/lapack_routine/zlauum.f">
14 *> <a href="http://www.netlib.org/cgi-bin/netlibfiles.txt?format=txt&filename=/lapack/lapack_routine/zlauum.f">
21 * SUBROUTINE ZLAUUM( UPLO, N, A, LDA, INFO )
23 * .. Scalar Arguments ..
25 * INTEGER INFO, LDA, N
27 * .. Array Arguments ..
28 * COMPLEX*16 A( LDA, * )
37 *> ZLAUUM computes the product U * U**H or L**H * L, where the triangular
38 *> factor U or L is stored in the upper or lower triangular part of
41 *> If UPLO = 'U' or 'u' then the upper triangle of the result is stored,
42 *> overwriting the factor U in A.
43 *> If UPLO = 'L' or 'l' then the lower triangle of the result is stored,
44 *> overwriting the factor L in A.
46 *> This is the blocked form of the algorithm, calling Level 3 BLAS.
54 *> UPLO is CHARACTER*1
55 *> Specifies whether the triangular factor stored in the array A
56 *> is upper or lower triangular:
57 *> = 'U': Upper triangular
58 *> = 'L': Lower triangular
64 *> The order of the triangular factor U or L. N >= 0.
69 *> A is COMPLEX*16 array, dimension (LDA,N)
70 *> On entry, the triangular factor U or L.
71 *> On exit, if UPLO = 'U', the upper triangle of A is
72 *> overwritten with the upper triangle of the product U * U**H;
73 *> if UPLO = 'L', the lower triangle of A is overwritten with
74 *> the lower triangle of the product L**H * L.
80 *> The leading dimension of the array A. LDA >= max(1,N).
86 *> = 0: successful exit
87 *> < 0: if INFO = -k, the k-th argument had an illegal value
93 *> \author Univ. of Tennessee
94 *> \author Univ. of California Berkeley
95 *> \author Univ. of Colorado Denver
98 *> \date September 2012
100 *> \ingroup complex16OTHERauxiliary
102 * =====================================================================
103 SUBROUTINE ZLAUUM( UPLO, N, A, LDA, INFO )
105 * -- LAPACK auxiliary routine (version 3.4.2) --
106 * -- LAPACK is a software package provided by Univ. of Tennessee, --
107 * -- Univ. of California Berkeley, Univ. of Colorado Denver and NAG Ltd..--
110 * .. Scalar Arguments ..
114 * .. Array Arguments ..
115 COMPLEX*16 A( LDA, * )
118 * =====================================================================
122 PARAMETER ( ONE = 1.0D+0 )
124 PARAMETER ( CONE = ( 1.0D+0, 0.0D+0 ) )
126 * .. Local Scalars ..
130 * .. External Functions ..
133 EXTERNAL LSAME, ILAENV
135 * .. External Subroutines ..
136 EXTERNAL XERBLA, ZGEMM, ZHERK, ZLAUU2, ZTRMM
138 * .. Intrinsic Functions ..
141 * .. Executable Statements ..
143 * Test the input parameters.
146 UPPER = LSAME( UPLO, 'U' )
147 IF( .NOT.UPPER .AND. .NOT.LSAME( UPLO, 'L' ) ) THEN
149 ELSE IF( N.LT.0 ) THEN
151 ELSE IF( LDA.LT.MAX( 1, N ) ) THEN
155 CALL XERBLA( 'ZLAUUM', -INFO )
159 * Quick return if possible
164 * Determine the block size for this environment.
166 NB = ILAENV( 1, 'ZLAUUM', UPLO, N, -1, -1, -1 )
168 IF( NB.LE.1 .OR. NB.GE.N ) THEN
172 CALL ZLAUU2( UPLO, N, A, LDA, INFO )
179 * Compute the product U * U**H.
182 IB = MIN( NB, N-I+1 )
183 CALL ZTRMM( 'Right', 'Upper', 'Conjugate transpose',
184 $ 'Non-unit', I-1, IB, CONE, A( I, I ), LDA,
186 CALL ZLAUU2( 'Upper', IB, A( I, I ), LDA, INFO )
188 CALL ZGEMM( 'No transpose', 'Conjugate transpose',
189 $ I-1, IB, N-I-IB+1, CONE, A( 1, I+IB ),
190 $ LDA, A( I, I+IB ), LDA, CONE, A( 1, I ),
192 CALL ZHERK( 'Upper', 'No transpose', IB, N-I-IB+1,
193 $ ONE, A( I, I+IB ), LDA, ONE, A( I, I ),
199 * Compute the product L**H * L.
202 IB = MIN( NB, N-I+1 )
203 CALL ZTRMM( 'Left', 'Lower', 'Conjugate transpose',
204 $ 'Non-unit', IB, I-1, CONE, A( I, I ), LDA,
206 CALL ZLAUU2( 'Lower', IB, A( I, I ), LDA, INFO )
208 CALL ZGEMM( 'Conjugate transpose', 'No transpose', IB,
209 $ I-1, N-I-IB+1, CONE, A( I+IB, I ), LDA,
210 $ A( I+IB, 1 ), LDA, CONE, A( I, 1 ), LDA )
211 CALL ZHERK( 'Lower', 'Conjugate transpose', IB,
212 $ N-I-IB+1, ONE, A( I+IB, I ), LDA, ONE,