168 SUBROUTINE dlaed0( ICOMPQ, QSIZ, N, D, E, Q, LDQ, QSTORE, LDQS,
169 $ WORK, IWORK, INFO )
176 INTEGER ICOMPQ, INFO, LDQ, LDQS, N, QSIZ
180 DOUBLE PRECISION D( * ), E( * ), Q( LDQ, * ), QSTORE( LDQS, * ),
187 DOUBLE PRECISION ZERO, ONE, TWO
188 parameter( zero = 0.d0, one = 1.d0, two = 2.d0 )
191 INTEGER CURLVL, CURPRB, CURR, I, IGIVCL, IGIVNM,
192 $ igivpt, indxq, iperm, iprmpt, iq, iqptr, iwrem,
193 $ j, k, lgn, matsiz, msd2, smlsiz, smm1, spm1,
194 $ spm2, submat, subpbs, tlvls
195 DOUBLE PRECISION TEMP
207 INTRINSIC abs, dble, int, log, max
215 IF( icompq.LT.0 .OR. icompq.GT.2 )
THEN
217 ELSE IF( ( icompq.EQ.1 ) .AND. ( qsiz.LT.max( 0, n ) ) )
THEN
219 ELSE IF( n.LT.0 )
THEN
221 ELSE IF( ldq.LT.max( 1, n ) )
THEN
223 ELSE IF( ldqs.LT.max( 1, n ) )
THEN
227 CALL xerbla(
'DLAED0', -info )
236 smlsiz = ilaenv( 9,
'DLAED0',
' ', 0, 0, 0, 0 )
245 IF( iwork( subpbs ).GT.smlsiz )
THEN
246 DO 20 j = subpbs, 1, -1
247 iwork( 2*j ) = ( iwork( j )+1 ) / 2
248 iwork( 2*j-1 ) = iwork( j ) / 2
255 iwork( j ) = iwork( j ) + iwork( j-1 )
263 submat = iwork( i ) + 1
265 d( smm1 ) = d( smm1 ) - abs( e( smm1 ) )
266 d( submat ) = d( submat ) - abs( e( smm1 ) )
270 IF( icompq.NE.2 )
THEN
275 temp = log( dble( n ) ) / log( two )
281 iprmpt = indxq + n + 1
282 iperm = iprmpt + n*lgn
283 iqptr = iperm + n*lgn
284 igivpt = iqptr + n + 2
285 igivcl = igivpt + n*lgn
288 iq = igivnm + 2*n*lgn
289 iwrem = iq + n**2 + 1
294 iwork( iprmpt+i ) = 1
295 iwork( igivpt+i ) = 1
309 submat = iwork( i ) + 1
310 matsiz = iwork( i+1 ) - iwork( i )
312 IF( icompq.EQ.2 )
THEN
313 CALL dsteqr(
'I', matsiz, d( submat ), e( submat ),
314 $ q( submat, submat ), ldq, work, info )
318 CALL dsteqr(
'I', matsiz, d( submat ), e( submat ),
319 $ work( iq-1+iwork( iqptr+curr ) ), matsiz, work,
323 IF( icompq.EQ.1 )
THEN
324 CALL dgemm(
'N',
'N', qsiz, matsiz, matsiz, one,
325 $ q( 1, submat ), ldq, work( iq-1+iwork( iqptr+
326 $ curr ) ), matsiz, zero, qstore( 1, submat ),
329 iwork( iqptr+curr+1 ) = iwork( iqptr+curr ) + matsiz**2
333 DO 60 j = submat, iwork( i+1 )
346 IF( subpbs.GT.1 )
THEN
355 submat = iwork( i ) + 1
356 matsiz = iwork( i+2 ) - iwork( i )
369 IF( icompq.EQ.2 )
THEN
370 CALL dlaed1( matsiz, d( submat ), q( submat, submat ),
371 $ ldq, iwork( indxq+submat ),
372 $ e( submat+msd2-1 ), msd2, work,
373 $ iwork( subpbs+1 ), info )
375 CALL dlaed7( icompq, matsiz, qsiz, tlvls, curlvl,
377 $ d( submat ), qstore( 1, submat ), ldqs,
378 $ iwork( indxq+submat ), e( submat+msd2-1 ),
379 $ msd2, work( iq ), iwork( iqptr ),
380 $ iwork( iprmpt ), iwork( iperm ),
381 $ iwork( igivpt ), iwork( igivcl ),
382 $ work( igivnm ), work( iwrem ),
383 $ iwork( subpbs+1 ), info )
387 iwork( i / 2+1 ) = iwork( i+2 )
399 IF( icompq.EQ.1 )
THEN
403 CALL dcopy( qsiz, qstore( 1, j ), 1, q( 1, i ), 1 )
405 CALL dcopy( n, work, 1, d, 1 )
406 ELSE IF( icompq.EQ.2 )
THEN
410 CALL dcopy( n, q( 1, j ), 1, work( n*i+1 ), 1 )
412 CALL dcopy( n, work, 1, d, 1 )
413 CALL dlacpy(
'A', n, n, work( n+1 ), n, q, ldq )
419 CALL dcopy( n, work, 1, d, 1 )
424 info = submat*( n+1 ) + submat + matsiz - 1
subroutine dlaed7(icompq, n, qsiz, tlvls, curlvl, curpbm, d, q, ldq, indxq, rho, cutpnt, qstore, qptr, prmptr, perm, givptr, givcol, givnum, work, iwork, info)
DLAED7 used by DSTEDC. Computes the updated eigensystem of a diagonal matrix after modification by a ...