SRC/sstemr.f(3)
π SRC/sstemr.f π
Library Functions Manual β okay bestie, this is the manual page for SRC/sstemr.f, and we are gonna get through it together. π
πΈ NAME πΈ
SRC/sstemr.f
β¨ SYNOPSIS β¨
Functions/Subroutines
subroutine sstemr (jobz, range, n, d, e, vl, vu, il, iu, m, w, z, ldz,
nzc, isuppz, tryrac, work, lwork, iwork, liwork, info)
SSTEMR
π¦ Function/Subroutine Documentation π¦
subroutine sstemr (character jobz, character range, integer n, real,
dimension( * ) d, real, dimension( * ) e, real vl, real vu, integer il,
integer iu, integer m, real, dimension( * ) w, real, dimension( ldz, * )
z, integer ldz, integer nzc, integer, dimension( * ) isuppz, logical
tryrac, real, dimension( * ) work, integer lwork, integer, dimension( *
) iwork, integer liwork, integer info)
SSTEMR
SSTEMR
π₯ Purpose π₯
Okay so SSTEMR computes selected eigenvalues and, optionally, eigenvectors of a real symmetric tridiagonal matrix T. Any such unreduced matrix has a well-defined set of pairwise different real eigenvalues, and the corresponding real eigenvectors are pairwise orthogonal. That is the vibe. β¨
The spectrum may be computed either completely or partially by specifying either an interval (VL,VU] or a range of indices IL:IU for the desired eigenvalues.
Depending on the number of desired eigenvalues, these are computed either by bisection or the dqds algorithm. Numerically orthogonal eigenvectors are computed by the use of various suitable L D L^T factorizations near clusters of close eigenvalues β referred to as RRRs, Relatively Robust Representations. An informal sketch of the algorithm follows.
For each unreduced block (submatrix) of T:
- (a) Compute
T - sigma I = L D L^T, so thatLandDdefine all the wanted eigenvalues to high relative accuracy. This means that small relative changes in the entries ofDandLcause only small relative changes in the eigenvalues and eigenvectors. The standard (unfactored) representation of the tridiagonal matrixTdoes not have this property in general. - (b) Compute the eigenvalues to suitable accuracy. If the eigenvectors are desired, the algorithm attains full accuracy of the computed eigenvalues only right before the corresponding vectors have to be computed, see steps c) and d).
- (c) For each cluster of close eigenvalues, select a new shift close to the cluster, find a new factorization, and refine the shifted eigenvalues to suitable accuracy.
- (d) For each eigenvalue with a large enough relative separation compute the corresponding eigenvector by forming a rank revealing twisted factorization. Go back to (c) for any clusters that remain.
For more details, see:
- Inderjit S. Dhillon and Beresford N. Parlett: Linear Algebra and its Applications, 387(1), pp. 1-28, August 2004.
- Inderjit Dhillon and Beresford Parlett: SIAM Journal on Matrix Analysis and Applications, Vol. 25, 2004. Also LAPACK Working Note 154.
- Inderjit Dhillon: , Computer Science Division Technical Report No. UCB/CSD-97-971, UC Berkeley, May 1997.
Further Details
SSTEMRworks only on machines which follow IEEE-754 floating-point standard in their handling of infinities and NaNs. This permits the use of efficient inner loops avoiding a check for zero divisors.
π Parameters π
JOBZβJOBZisCHARACTER*1.= 'N':Compute eigenvalues only;= 'V':Compute eigenvalues and eigenvectors.
RANGEβRANGEisCHARACTER*1.= 'A':all eigenvalues will be found.= 'V':all eigenvalues in the half-open interval(VL,VU]will be found.= 'I':theIL-th throughIU-th eigenvalues will be found.
NβNisINTEGER. The order of the matrix.N >= 0.DβDisREALarray, dimension(N). On entry, theNdiagonal elements of the tridiagonal matrixT. On exit,Dis overwritten.EβEisREALarray, dimension(N). On entry, the(N-1)subdiagonal elements of the tridiagonal matrixTin elements1toN-1ofE.E(N)need not be set on input, but is used internally as workspace. On exit,Eis overwritten.VLβVLisREAL. IfRANGE='V', the lower bound of the interval to be searched for eigenvalues.VL < VU. Not referenced ifRANGE = 'A'or'I'.VUβVUisREAL. IfRANGE='V', the upper bound of the interval to be searched for eigenvalues.VL < VU. Not referenced ifRANGE = 'A'or'I'.ILβILisINTEGER. IfRANGE='I', the index of the smallest eigenvalue to be returned.1 <= IL <= IU <= N, ifN > 0. Not referenced ifRANGE = 'A'or'V'.IUβIUisINTEGER. IfRANGE='I', the index of the largest eigenvalue to be returned.1 <= IL <= IU <= N, ifN > 0. Not referenced ifRANGE = 'A'or'V'.MβMisINTEGER. The total number of eigenvalues found.0 <= M <= N. IfRANGE = 'A',M = N, and ifRANGE = 'I',M = IU-IL+1.WβWisREALarray, dimension(N). The firstMelements contain the selected eigenvalues in ascending order.ZβZisREALarray, dimension(LDZ, max(1,M) ). IfJOBZ = 'V', and ifINFO = 0, then the firstMcolumns ofZcontain the orthonormal eigenvectors of the matrixTcorresponding to the selected eigenvalues, with the i-th column ofZholding the eigenvector associated withW(i). IfJOBZ = 'N', thenZis not referenced. Note: the user must ensure that at leastmax(1,M)columns are supplied in the arrayZ; ifRANGE = 'V', the exact value ofMis not known in advance and can be computed with a workspace query by settingNZC = -1, see below.LDZβLDZisINTEGER. The leading dimension of the arrayZ.LDZ >= 1, and ifJOBZ = 'V', thenLDZ >= max(1,N).NZCβNZCisINTEGER. The number of eigenvectors to be held in the arrayZ. IfRANGE = 'A', thenNZC >= max(1,N). IfRANGE = 'V', thenNZC >=the number of eigenvalues in(VL,VU]. IfRANGE = 'I', thenNZC >= IU-IL+1. IfNZC = -1, then a workspace query is assumed; the routine calculates the number of columns of the arrayZthat are needed to hold the eigenvectors. This value is returned as the first entry of theZarray, and no error message related toNZCis issued byXERBLA.ISUPPZβISUPPZisINTEGERarray, dimension( 2*max(1,M) ). The support of the eigenvectors inZ, i.e., the indices indicating the nonzero elements inZ. The i-th computed eigenvector is nonzero only in elementsISUPPZ( 2*i-1 )throughISUPPZ( 2*i ). This is relevant in the case when the matrix is split.ISUPPZis only accessed whenJOBZis'V'andN > 0.TRYRACβTRYRACisLOGICAL. IfTRYRAC = .TRUE., indicates that the code should check whether the tridiagonal matrix defines its eigenvalues to high relative accuracy. If so, the code uses relative-accuracy preserving algorithms that might be (a bit) slower depending on the matrix. If the matrix does not define its eigenvalues to high relative accuracy, the code can uses possibly faster algorithms. IfTRYRAC = .FALSE., the code is not required to guarantee relatively accurate eigenvalues and can use the fastest possible techniques. On exit, a.TRUE. TRYRACwill be set to.FALSE.if the matrix does not define its eigenvalues to high relative accuracy.WORKβWORKisREALarray, dimension(LWORK). On exit, ifINFO = 0,WORK(1)returns the optimal (and minimal)LWORK.LWORKβLWORKisINTEGER. The dimension of the arrayWORK.LWORK >= max(1,18*N)ifJOBZ = 'V', andLWORK >= max(1,12*N)ifJOBZ = 'N'. IfLWORK = -1, then a workspace query is assumed; the routine only calculates the optimal size of theWORKarray, returns this value as the first entry of theWORKarray, and no error message related toLWORKis issued byXERBLA.IWORKβIWORKisINTEGERarray, dimension(LIWORK). On exit, ifINFO = 0,IWORK(1)returns the optimalLIWORK.LIWORKβLIWORKisINTEGER. The dimension of the arrayIWORK.LIWORK >= max(1,10*N)if the eigenvectors are desired, andLIWORK >= max(1,8*N)if only the eigenvalues are to be computed. IfLIWORK = -1, then a workspace query is assumed; the routine only calculates the optimal size of theIWORKarray, returns this value as the first entry of theIWORKarray, and no error message related toLIWORKis issued byXERBLA.
INFO
INFOβINTEGER. this is the β¨vibe checkβ¨ of the whole call, bestie. On exit,INFOtells u exactly what went down:= 0β π successful exit. we ate. no crumbs.< 0β ifINFO = -i, that means the i-th argument had an illegal value π like u passed something cursed and the routine is calling u out.> 0β ifINFO = 1X, that's an internal error inSLARRE. ifINFO = 2X, that's an internal error inSLARRV. and here, the digitX = ABS( IINFO ) < 10, whereIINFOis the nonzero error code thatSLARREorSLARRVreturned, respectively. π so like the tens digit is who fumbled and the ones digit is how they fumbled. iykyk.
π Author
- Univ. of Tennessee
- Univ. of California Berkeley
- Univ. of Colorado Denver
- NAG Ltd.
π«Ά Contributors:
- Beresford Parlett, University of California, Berkeley, USA
- Jim Demmel, University of California, Berkeley, USA
- Inderjit Dhillon, University of Texas, Austin, USA
- Osni Marques, LBNL/NERSC, USA
- Christof Voemel, University of California, Berkeley, USA
- Aravindh Krishnamoorthy, FAU, Erlangen, Germany
Definition at line 319 of file sstemr.f.
π Author
okay so this Author section is the meta one β it's not a person, it's the machine:
Generated automatically by Doxygen for LAPACK from the source code.
no human wrote this bit, it's literally Doxygen doing its little autopilot thing π§ slay for it honestly.
πΈ and that's the whole page, bestie! this beauty is from SRC/sstemr.f, running LAPACK Version 3.12.0, and the date is just whatever lil timestamp Doxygen stamped into the footer when it built this. go forth and compute ur eigenvalues, periodt. π
β¨π
π¦ where this page comes from
- arch rolling: lapack-doc 3.12.1-2 Β· custom
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms