270 SUBROUTINE dstebz( RANGE, ORDER, N, VL, VU, IL, IU, ABSTOL, D, E,
271 $ M, NSPLIT, W, IBLOCK, ISPLIT, WORK, IWORK,
279 CHARACTER ORDER, RANGE
280 INTEGER IL, INFO, IU, M, N, NSPLIT
281 DOUBLE PRECISION ABSTOL, VL, VU
284 INTEGER IBLOCK( * ), ISPLIT( * ), IWORK( * )
285 DOUBLE PRECISION D( * ), E( * ), W( * ), WORK( * )
291 DOUBLE PRECISION ZERO, ONE, TWO, HALF
292 PARAMETER ( ZERO = 0.0d0, one = 1.0d0, two = 2.0d0,
293 $ half = 1.0d0 / two )
294 DOUBLE PRECISION FUDGE, RELFAC
295 PARAMETER ( FUDGE = 2.1d0, relfac = 2.0d0 )
298 LOGICAL NCNVRG, TOOFEW
299 INTEGER IB, IBEGIN, IDISCL, IDISCU, IE, IEND, IINFO,
300 $ im, in, ioff, iorder, iout, irange, itmax,
301 $ itmp1, iw, iwoff, j, jb, jdisc, je, nb, nwl,
303 DOUBLE PRECISION ATOLI, BNORM, GL, GU, PIVMIN, RTOLI, SAFEMN,
304 $ TMP1, TMP2, TNORM, ULP, WKILL, WL, WLU, WU, WUL
312 DOUBLE PRECISION DLAMCH
313 EXTERNAL lsame, ilaenv, dlamch
319 INTRINSIC abs, int, log, max, min, sqrt
327 IF( lsame( range,
'A' ) )
THEN
329 ELSE IF( lsame( range,
'V' ) )
THEN
331 ELSE IF( lsame( range,
'I' ) )
THEN
339 IF( lsame( order,
'B' ) )
THEN
341 ELSE IF( lsame( order,
'E' ) )
THEN
349 IF( irange.LE.0 )
THEN
351 ELSE IF( iorder.LE.0 )
THEN
353 ELSE IF( n.LT.0 )
THEN
355 ELSE IF( irange.EQ.2 )
THEN
358 ELSE IF( irange.EQ.3 .AND. ( il.LT.1 .OR. il.GT.max( 1, n ) ) )
361 ELSE IF( irange.EQ.3 .AND. ( iu.LT.min( n, il ) .OR. iu.GT.n ) )
367 CALL xerbla(
'DSTEBZ', -info )
385 IF( irange.EQ.3 .AND. il.EQ.1 .AND. iu.EQ.n )
392 safemn = dlamch(
'S' )
395 nb = ilaenv( 1,
'DSTEBZ',
' ', n, -1, -1, -1 )
404 IF( irange.EQ.2 .AND. ( vl.GE.d( 1 ) .OR. vu.LT.d( 1 ) ) )
THEN
422 IF( abs( d( j )*d( j-1 ) )*ulp**2+safemn.GT.tmp1 )
THEN
423 isplit( nsplit ) = j - 1
428 pivmin = max( pivmin, tmp1 )
432 pivmin = pivmin*safemn
436 IF( irange.EQ.3 )
THEN
449 tmp2 = sqrt( work( j ) )
450 gu = max( gu, d( j )+tmp1+tmp2 )
451 gl = min( gl, d( j )-tmp1-tmp2 )
455 gu = max( gu, d( n )+tmp1 )
456 gl = min( gl, d( n )-tmp1 )
457 tnorm = max( abs( gl ), abs( gu ) )
458 gl = gl - fudge*tnorm*ulp*n - fudge*two*pivmin
459 gu = gu + fudge*tnorm*ulp*n + fudge*pivmin
463 itmax = int( ( log( tnorm+pivmin )-log( pivmin ) ) /
465 IF( abstol.LE.zero )
THEN
484 CALL dlaebz( 3, itmax, n, 2, 2, nb, atoli, rtoli, pivmin, d, e,
485 $ work, iwork( 5 ), work( n+1 ), work( n+5 ), iout,
486 $ iwork, w, iblock, iinfo )
488 IF( iwork( 6 ).EQ.iu )
THEN
504 IF( nwl.LT.0 .OR. nwl.GE.n .OR. nwu.LT.1 .OR. nwu.GT.n )
THEN
512 tnorm = max( abs( d( 1 ) )+abs( e( 1 ) ),
513 $ abs( d( n ) )+abs( e( n-1 ) ) )
516 tnorm = max( tnorm, abs( d( j ) )+abs( e( j-1 ) )+
520 IF( abstol.LE.zero )
THEN
526 IF( irange.EQ.2 )
THEN
555 IF( irange.EQ.1 .OR. wl.GE.d( ibegin )-pivmin )
557 IF( irange.EQ.1 .OR. wu.GE.d( ibegin )-pivmin )
559 IF( irange.EQ.1 .OR. ( wl.LT.d( ibegin )-pivmin .AND. wu.GE.
560 $ d( ibegin )-pivmin ) )
THEN
576 DO 40 j = ibegin, iend - 1
578 gu = max( gu, d( j )+tmp1+tmp2 )
579 gl = min( gl, d( j )-tmp1-tmp2 )
583 gu = max( gu, d( iend )+tmp1 )
584 gl = min( gl, d( iend )-tmp1 )
585 bnorm = max( abs( gl ), abs( gu ) )
586 gl = gl - fudge*bnorm*ulp*in - fudge*pivmin
587 gu = gu + fudge*bnorm*ulp*in + fudge*pivmin
591 IF( abstol.LE.zero )
THEN
592 atoli = ulp*max( abs( gl ), abs( gu ) )
597 IF( irange.GT.1 )
THEN
613 CALL dlaebz( 1, 0, in, in, 1, nb, atoli, rtoli, pivmin,
614 $ d( ibegin ), e( ibegin ), work( ibegin ),
615 $ idumma, work( n+1 ), work( n+2*in+1 ), im,
616 $ iwork, w( m+1 ), iblock( m+1 ), iinfo )
618 nwl = nwl + iwork( 1 )
619 nwu = nwu + iwork( in+1 )
620 iwoff = m - iwork( 1 )
624 itmax = int( ( log( gu-gl+pivmin )-log( pivmin ) ) /
626 CALL dlaebz( 2, itmax, in, in, 1, nb, atoli, rtoli, pivmin,
627 $ d( ibegin ), e( ibegin ), work( ibegin ),
628 $ idumma, work( n+1 ), work( n+2*in+1 ), iout,
629 $ iwork, w( m+1 ), iblock( m+1 ), iinfo )
635 tmp1 = half*( work( j+n )+work( j+in+n ) )
639 IF( j.GT.iout-iinfo )
THEN
645 DO 50 je = iwork( j ) + 1 + iwoff,
646 $ iwork( j+in ) + iwoff
659 IF( irange.EQ.3 )
THEN
661 idiscl = il - 1 - nwl
664 IF( idiscl.GT.0 .OR. idiscu.GT.0 )
THEN
666 IF( w( je ).LE.wlu .AND. idiscl.GT.0 )
THEN
668 ELSE IF( w( je ).GE.wul .AND. idiscu.GT.0 )
THEN
673 iblock( im ) = iblock( je )
678 IF( idiscl.GT.0 .OR. idiscu.GT.0 )
THEN
690 IF( idiscl.GT.0 )
THEN
692 DO 100 jdisc = 1, idiscl
695 IF( iblock( je ).NE.0 .AND.
696 $ ( w( je ).LT.wkill .OR. iw.EQ.0 ) )
THEN
704 IF( idiscu.GT.0 )
THEN
707 DO 120 jdisc = 1, idiscu
710 IF( iblock( je ).NE.0 .AND.
711 $ ( w( je ).GT.wkill .OR. iw.EQ.0 ) )
THEN
721 IF( iblock( je ).NE.0 )
THEN
724 iblock( im ) = iblock( je )
729 IF( idiscl.LT.0 .OR. idiscu.LT.0 )
THEN
738 IF( iorder.EQ.1 .AND. nsplit.GT.1 )
THEN
743 IF( w( j ).LT.tmp1 )
THEN
752 iblock( ie ) = iblock( je )
subroutine xerbla(srname, info)
subroutine dlaebz(ijob, nitmax, n, mmax, minp, nbmin, abstol, reltol, pivmin, d, e, e2, nval, ab, c, mout, nab, work, iwork, info)
DLAEBZ computes the number of eigenvalues of a real symmetric tridiagonal matrix which are less than ...
subroutine dstebz(range, order, n, vl, vu, il, iu, abstol, d, e, m, nsplit, w, iblock, isplit, work, iwork, info)
DSTEBZ