/home/abui...SRC/zhpr.f(3)

πŸ“¦ version 3.12.0, in opensuse-leap 16.0

πŸ¦‹ ZHPR β€” hermitian rank-1 update, the BLAS way πŸ’…

okay bestie, so this page lives at /home/abui...SRC/zhpr.f(3) in the Library Functions Manual, and it's literally the manual entry for the Fortran source file /home/abuild/rpmbuild/BUILD/lapack-static-3.12.0-build/lapack-3.12.0/BLAS/SRC/zhpr.f. yes that path is a whole journey, we're not gonna talk about it πŸ’€


✨ SYNOPSIS ✨

Functions/Subroutines, and the icon of the hour is:

subroutine ZHPR (uplo, n, alpha, x, incx, ap)

ZHPR. that's it. that's the name. πŸŽ€


🌸 Function/Subroutine Documentation 🌸

here's the full signature with all the types spelled out, no cap:

subroutine ZHPR (character uplo, integer n, double precision alpha,
    complex*16, dimension(*) x, integer incx, complex*16, dimension(*) ap)

ZHPR

πŸ’– Purpose πŸ’–

so the doc block says, and I quote:

!>
!> ZHPR    performs the hermitian rank 1 operation
!>
!>    A := alpha*x*x**H + A,
!>
!> where alpha is a real scalar, x is an n element vector and A is an
!> n by n hermitian matrix, supplied in packed form.
!>

translation: it takes your hermitian matrix A (which is living its best packed life, not a full 2D array), and it adds alpha*x*x**H to it. rank 1 update, hermitian edition, slay πŸ”₯ note that alpha is a real scalar here, and x**H is the conjugate transpose. she's doing math.

🧚 Parameters 🧚

  • UPLO β€” CHARACTER*1. on entry, UPLO tells the routine whether the upper or lower triangular part of A is the one supplied in the packed array AP, like this:
UPLO = 'U' or 'u'   The upper triangular part of A is
                    supplied in AP.

UPLO = 'L' or 'l'   The lower triangular part of A is
                    supplied in AP.
  • N β€” INTEGER. on entry, N specifies the order of the matrix A. and N must be at least zero, so no negative nonsense πŸ™ˆ
  • ALPHA β€” DOUBLE PRECISION. on entry, ALPHA specifies the scalar alpha. real one. πŸ’«
  • X β€” COMPLEX*16 array, dimension at least ( 1 + ( n - 1 )*abs( INCX ) ). before entry, the incremented array X must contain the n element vector x. so yeah, feed her the vector πŸ“
  • INCX β€” INTEGER. on entry, INCX specifies the increment for the elements of X. INCX must not be zero β€” like, that one is not a vibe, don't do it πŸ’€
  • AP β€” COMPLEX*16 array, dimension at least ( ( n*( n + 1 ) )/2 ). the packing rules are kinda the whole personality of this routine, so buckle up:
    • before entry with UPLO = 'U' or 'u', the array AP must contain the upper triangular part of the hermitian matrix packed sequentially, column by column, so that AP( 1 ) contains a( 1, 1 ), AP( 2 ) and AP( 3 ) contain a( 1, 2 ) and a( 2, 2 ) respectively, and so on. on exit, the array AP is overwritten by the upper triangular part of the updated matrix. ✨
    • before entry with UPLO = 'L' or 'l', the array AP must contain the lower triangular part of the hermitian matrix packed sequentially, column by column, so that AP( 1 ) contains a( 1, 1 ), AP( 2 ) and AP( 3 ) contain a( 2, 1 ) and a( 3, 1 ) respectively, and so on. on exit, the array AP is overwritten by the lower triangular part of the updated matrix. πŸ’œ
    • note that the imaginary parts of the diagonal elements need not be set β€” they are assumed to be zero, and on exit they are set to zero. so like, don't stress about 'em, she handles it 🫢
ok but actually pay attention to the AP packing and the INCX β‰  0 thing. those are the real ones. the imaginary-diagonal detail is lowkey iconic but also load-bearing.

πŸ‘‘ Author πŸ‘‘

  • Univ. of Tennessee
  • Univ. of California Berkeley
  • Univ. of Colorado Denver
  • NAG Ltd.

the whole squad fr fr 🫢

⭐ Further Details ⭐

!>
!>  Level 2 Blas routine.
!>
!>  -- Written on 22-October-1986.
!>     Jack Dongarra, Argonne National Lab.
!>     Jeremy Du Croz, Nag Central Office.
!>     Sven Hammarling, Nag Central Office.
!>     Richard Hanson, Sandia National Labs.
!>

Level 2 BLAS routine, written on 22-October-1986 by Jack Dongarra (Argonne National Lab), Jeremy Du Croz (Nag Central Office), Sven Hammarling (Nag Central Office), and Richard Hanson (Sandia National Labs). 1986!! these legends were out here doing hermitian rank-1 updates before some of us were even born 😭 main character energy, honestly.


🌈 Definition 🌈

definition at line 129 of file zhpr.f.


πŸŽ€ Author (the auto-generated one) πŸŽ€

Generated automatically by Doxygen for LAPACK from the source code. not a human, just vibes and a parser πŸ€–βœ¨


LAPACK β€” Version 3.12.0 β€” /home/abui...SRC/zhpr.f(3)

and that's the whole page bestie, go forth and pack your triangles correctly πŸ’–πŸ¦‹πŸŒΈ

πŸ“¦ where this page comes from