128 REAL function
clansb( norm, uplo, n, k, ab, ldab,
141 COMPLEX ab( ldab, * )
148 parameter( one = 1.0e+0, zero = 0.0e+0 )
152 REAL absa, scale, sum, value
162 INTRINSIC abs, max, min, sqrt
168 ELSE IF(
lsame( norm,
'M' ) )
THEN
173 IF(
lsame( uplo,
'U' ) )
THEN
175 DO 10 i = max( k+2-j, 1 ), k + 1
176 sum = abs( ab( i, j ) )
177 IF(
VALUE .LT. sum .OR.
sisnan( sum ) )
VALUE = sum
182 DO 30 i = 1, min( n+1-j, k+1 )
183 sum = abs( ab( i, j ) )
184 IF(
VALUE .LT. sum .OR.
sisnan( sum ) )
VALUE = sum
188 ELSE IF( (
lsame( norm,
'I' ) ) .OR. (
lsame( norm,
'O' ) ) .OR.
189 $ ( norm.EQ.
'1' ) )
THEN
194 IF(
lsame( uplo,
'U' ) )
THEN
198 DO 50 i = max( 1, j-k ), j - 1
199 absa = abs( ab( l+i, j ) )
201 work( i ) = work( i ) + absa
203 work( j ) = sum + abs( ab( k+1, j ) )
207 IF(
VALUE .LT. sum .OR.
sisnan( sum ) )
VALUE = sum
214 sum = work( j ) + abs( ab( 1, j ) )
216 DO 90 i = j + 1, min( n, j+k )
217 absa = abs( ab( l+i, j ) )
219 work( i ) = work( i ) + absa
221 IF(
VALUE .LT. sum .OR.
sisnan( sum ) )
VALUE = sum
224 ELSE IF( (
lsame( norm,
'F' ) ) .OR. (
lsame( norm,
'E' ) ) )
THEN
231 IF(
lsame( uplo,
'U' ) )
THEN
233 CALL classq( min( j-1, k ), ab( max( k+2-j, 1 ), j ),
239 CALL classq( min( n-j, k ), ab( 2, j ), 1, scale,
248 CALL classq( n, ab( l, 1 ), ldab, scale, sum )
249 VALUE = scale*sqrt( sum )
logical function sisnan(sin)
SISNAN tests input for NaN.
real function clansb(norm, uplo, n, k, ab, ldab, work)
CLANSB returns the value of the 1-norm, or the Frobenius norm, or the infinity norm,...
subroutine classq(n, x, incx, scale, sumsq)
CLASSQ updates a sum of squares represented in scaled form.
logical function lsame(ca, cb)
LSAME