DLAMSH(l)
π DLAMSH π
okay so bestie, welcome to DLAMSH β it's a LAPACK auxiliary routine, version 1.5, and it is lowkey doing the most. it sends multiple shifts through a small (single node) matrix to see how consecutive small subdiagonal elements get modified by subsequent shifts, all in an effort to maximize the number of bulges that can be sent through. yes that's a lot of words. yes it's iconic. let's get into it π
β¨ SYNOPSIS β¨
SUBROUTINE DLAMSH ( S, LDS, NBULGE, JBLK, H, LDH, N, ULP )
INTEGER LDS, NBULGE, JBLK, LDH, N
DOUBLE PRECISION ULP
DOUBLE PRECISION S(LDS,*), H(LDH,*)
π¦ PURPOSE π¦
so here's the tea π« β DLAMSH sends multiple shifts through a small (single node) matrix to see how consecutive small subdiagonal elements are modified by subsequent shifts, in an effort to maximize the number of bulges that can be sent through.
and listen, it has rules. DLAMSH should only be called when there are multiple shifts/bulges (NBULGE > 1) and the first shift is starting in the middle of an unreduced Hessenberg matrix, because of two or more consecutive small subdiagonal elements. that's the vibe check. it passes or it doesn't. periodt β
π ARGUMENTS π
Sβ (local input/output)DOUBLE PRECISIONarray,(LDS,*). on entry, the matrix of shifts. only the 2x2 diagonal ofSis referenced, bestie. it's assumed thatShasJBLKdouble shifts (size 2). on exit, the data is rearranged in the best order for applying. she reorganized herself, main character energy πLDSβ (local input)INTEGER. on entry, the leading dimension ofS. unchanged on exit. also,1 < NBULGE <= JBLK <= LDS/2.NBULGEβ (local input/output)INTEGER. on entry, the number of bulges to send throughH(> 1).NBULGEshould be less than the maximum determined (JBLK).1 < NBULGE <= JBLK <= LDS/2. on exit, the maximum number of bulges that can be sent through. she comes in as a request and leaves as a whole verdict, honestly iconic β¨JBLKβ (local input)INTEGER. on entry, the number of shifts determined forS. unchanged on exit.Hβ (local input/output)DOUBLE PRECISIONarray(LDH,N). on entry, the local matrix to apply the shifts on.Hshould be aligned so that the starting row is 2. on exit, the data is destroyed π yeah. gone. that's not a drill.LDSβ (local input)INTEGER. on entry, the leading dimension ofS. unchanged on exit. (yes,LDSshows up twice in the argument list β the original said it twice so we're saying it twice, no cap, not me editing the lore π)Nβ (local input)INTEGER. on entry, the size ofH. if all the bulges are expected to go through,Nshould be at least4*NBULGE+2. otherwise,NBULGEmay be reduced by this routine. so either you bring enough room or she starts trimming, your call πULPβ (local input)DOUBLE PRECISION. on entry, machine precision. unchanged on exit.
ok real talk for a sec: H gets destroyed on exit. like, the data is destroyed. if you needed that matrix for something else, that is a you problem and you should have read this part first π
πΈ IMPLEMENTED BY πΈ
Implemented by: G. Henry, May 1, 1997
and that's the whole page, bestie π«Ά this was DLAMSH(l) from LAPACK version 1.5, dated 12 May 1997 β LAPACK auxiliary routine energy only, we love her, we thank her for her service πβ¨π
π¦ 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