LAPACK  3.5.0
LAPACK: Linear Algebra PACKage
stzt02.f File Reference

Go to the source code of this file.

Functions/Subroutines

real function stzt02 (M, N, AF, LDA, TAU, WORK, LWORK)
 STZT02 More...
 

Function/Subroutine Documentation

real function stzt02 ( integer  M,
integer  N,
real, dimension( lda, * )  AF,
integer  LDA,
real, dimension( * )  TAU,
real, dimension( lwork )  WORK,
integer  LWORK 
)

STZT02

Purpose:
 STZT02 returns
      || I - Q'*Q || / ( M * eps)
 where the matrix Q is defined by the Householder transformations
 generated by STZRQF.
Parameters
[in]M
          M is INTEGER
          The number of rows of the matrix AF.
[in]N
          N is INTEGER
          The number of columns of the matrix AF.
[in]AF
          AF is REAL array, dimension (LDA,N)
          The output of STZRQF.
[in]LDA
          LDA is INTEGER
          The leading dimension of the array AF.
[in]TAU
          TAU is REAL array, dimension (M)
          Details of the Householder transformations as returned by
          STZRQF.
[out]WORK
          WORK is REAL array, dimension (LWORK)
[in]LWORK
          LWORK is INTEGER
          length of WORK array. Must be >= N*N+N
Author
Univ. of Tennessee
Univ. of California Berkeley
Univ. of Colorado Denver
NAG Ltd.
Date
November 2011

Definition at line 93 of file stzt02.f.

93 *
94 * -- LAPACK test routine (version 3.4.0) --
95 * -- LAPACK is a software package provided by Univ. of Tennessee, --
96 * -- Univ. of California Berkeley, Univ. of Colorado Denver and NAG Ltd..--
97 * November 2011
98 *
99 * .. Scalar Arguments ..
100  INTEGER lda, lwork, m, n
101 * ..
102 * .. Array Arguments ..
103  REAL af( lda, * ), tau( * ), work( lwork )
104 * ..
105 *
106 * =====================================================================
107 *
108 * .. Parameters ..
109  REAL zero, one
110  parameter( zero = 0.0e0, one = 1.0e0 )
111 * ..
112 * .. Local Scalars ..
113  INTEGER i
114 * ..
115 * .. Local Arrays ..
116  REAL rwork( 1 )
117 * ..
118 * .. External Functions ..
119  REAL slamch, slange
120  EXTERNAL slamch, slange
121 * ..
122 * .. External Subroutines ..
123  EXTERNAL slatzm, slaset, xerbla
124 * ..
125 * .. Intrinsic Functions ..
126  INTRINSIC max, real
127 * ..
128 * .. Executable Statements ..
129 *
130  stzt02 = zero
131 *
132  IF( lwork.LT.n*n+n ) THEN
133  CALL xerbla( 'STZT02', 7 )
134  RETURN
135  END IF
136 *
137 * Quick return if possible
138 *
139  IF( m.LE.0 .OR. n.LE.0 )
140  $ RETURN
141 *
142 * Q := I
143 *
144  CALL slaset( 'Full', n, n, zero, one, work, n )
145 *
146 * Q := P(1) * ... * P(m) * Q
147 *
148  DO 10 i = m, 1, -1
149  CALL slatzm( 'Left', n-m+1, n, af( i, m+1 ), lda, tau( i ),
150  $ work( i ), work( m+1 ), n, work( n*n+1 ) )
151  10 CONTINUE
152 *
153 * Q := P(m) * ... * P(1) * Q
154 *
155  DO 20 i = 1, m
156  CALL slatzm( 'Left', n-m+1, n, af( i, m+1 ), lda, tau( i ),
157  $ work( i ), work( m+1 ), n, work( n*n+1 ) )
158  20 CONTINUE
159 *
160 * Q := Q - I
161 *
162  DO 30 i = 1, n
163  work( ( i-1 )*n+i ) = work( ( i-1 )*n+i ) - one
164  30 CONTINUE
165 *
166  stzt02 = slange( 'One-norm', n, n, work, n, rwork ) /
167  $ ( slamch( 'Epsilon' )*REAL( MAX( M, N ) ) )
168  RETURN
169 *
170 * End of STZT02
171 *
subroutine slaset(UPLO, M, N, ALPHA, BETA, A, LDA)
SLASET initializes the off-diagonal elements and the diagonal elements of a matrix to given values...
Definition: slaset.f:112
real function slange(NORM, M, N, A, LDA, WORK)
SLANGE returns the value of the 1-norm, Frobenius norm, infinity-norm, or the largest absolute value ...
Definition: slange.f:116
subroutine xerbla(SRNAME, INFO)
XERBLA
Definition: xerbla.f:62
real function slamch(CMACH)
SLAMCH
Definition: slamch.f:69
subroutine slatzm(SIDE, M, N, V, INCV, TAU, C1, C2, LDC, WORK)
SLATZM
Definition: slatzm.f:153
real function stzt02(M, N, AF, LDA, TAU, WORK, LWORK)
STZT02
Definition: stzt02.f:93

Here is the call graph for this function: