SSTEQR2(l)
π SSTEQR2 π
okay so bestie, gather round, because this one is a whole moment. we're looking at SSTEQR2, a LAPACK routine, version 2.0 β and no cap, she is a modified version of LAPACK routine SSTEQR. she's giving "yes i'm the same but also i'm different." π
β¨ NAME β¨
SSTEQR2β i a modified version of LAPACK routineSSTEQR
β¨ SYNOPSIS β¨
SUBROUTINE SSTEQR2( COMPZ, N, D, E, Z, LDZ, NR, WORK, INFO )
CHARACTER COMPZ
INTEGER INFO, LDZ, N, NR
REAL D( * ), E( * ), WORK( * ), Z( LDZ, * )
πΈ PURPOSE πΈ
so like, SSTEQR2 is a modified version of LAPACK routine SSTEQR. it computes all the eigenvalues and, if you want them, the eigenvectors of a symmetric tridiagonal matrix using the implicit QL or QR method. lowkey iconic. π
and then β running SSTEQR2 to perform updates on a distributed matrix Q. proper usage of SSTEQR2 can be gleaned from examination of ScaLAPACK's PSSYEV. iykyk. β¨
π ARGUMENTS π
COMPZ(input)CHARACTER*1= 'N': compute eigenvalues only. just the vibes, no vectors.= 'I': compute eigenvalues and eigenvectors of the tridiagonal matrix.Zmust be initialized to the identity matrix byPDLASETorDLASETprior to entering this subroutine. do not skip this step bestie, i'm begging. π
N(input)INTEGERthe order of the matrix.N >= 0.D(input/output)REALarray, dimension(N)on entry, the diagonal elements of the tridiagonal matrix. on exit, ifINFO = 0, the eigenvalues in ascending order. she ascends. πE(input/output)REALarray, dimension(N-1)on entry, the(n-1)subdiagonal elements of the tridiagonal matrix. on exit,Ehas been destroyed. gone. deceased. π not a drill β if you needed that data, it's over.Z(local input/local output)REALarray, global dimension(N, N), local dimension(LDZ, NR). on entry, ifCOMPZ = 'V', thenZcontains the orthogonal matrix used in the reduction to tridiagonal form. on exit, ifINFO = 0, then ifCOMPZ = 'V',Zcontains the orthonormal eigenvectors of the original symmetric matrix, and ifCOMPZ = 'I',Zcontains the orthonormal eigenvectors of the symmetric tridiagonal matrix. ifCOMPZ = 'N', thenZis not referenced. she's not even looking at it. π«ΆLDZ(input)INTEGERthe leading dimension of the arrayZ.LDZ >= 1, and if eigenvectors are desired, thenLDZ >= max(1,N).NR(input)INTEGERNR = MAX(1, NUMROC( N, NB, MYPROW, 0, NPROCS ) ). ifCOMPZ = 'N', thenNRis not referenced. again: ignored, ghosted, unbothered. πWORK(workspace)REALarray, dimension(max(1,2*N-2))ifCOMPZ = 'N', thenWORKis not referenced. honestly she's just chilling in the background.INFO(output)INTEGER= 0: successful exit. slay. π< 0: ifINFO = -i, thei-th argument had an illegal value. bestie. what did you do.> 0: the algorithm has failed to find all the eigenvalues in a total of30*Niterations; ifINFO = i, thenielements ofEhave not converged to zero; on exit,DandEcontain the elements of a symmetric tridiagonal matrix which is orthogonally similar to the original matrix. so like β not converged, not the end of the world, but read that carefully, fr fr.
β οΈ real talk:Egets destroyed on exit, and thatINFO > 0case is not a cute little warning, it's the algorithm genuinely not converging in30*Niterations. respect the caveats. π
mwah π that's the whole page. this one came from a modified LAPACK routine, dated 12 May 1997 β yes she's a vintage queen and she still ate. go forth and compute, bestie. πβ¨π¦
π¦ where this page comes from
- ubuntu jammy: scalapack-doc 1.5-11
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms