complex_blas_level2(3)
π NAME π
complex_blas_level2 β it's giving complex, bestie. This is the LAPACK manual page for the entire complex LEVEL 2 BLAS squad, and we are doing all of them. Buckle up π
β¨ SYNOPSIS β¨
π«Ά The Functions (the whole girl group)
subroutine cgbmv (TRANS, M, N, KL, KU, ALPHA, A, LDA, X, INCX, BETA, Y, INCY)βCGBMVsubroutine cgemv (TRANS, M, N, ALPHA, A, LDA, X, INCX, BETA, Y, INCY)βCGEMVsubroutine cgerc (M, N, ALPHA, X, INCX, Y, INCY, A, LDA)βCGERCsubroutine cgeru (M, N, ALPHA, X, INCX, Y, INCY, A, LDA)βCGERUsubroutine chbmv (UPLO, N, K, ALPHA, A, LDA, X, INCX, BETA, Y, INCY)βCHBMVsubroutine chemv (UPLO, N, ALPHA, A, LDA, X, INCX, BETA, Y, INCY)βCHEMVsubroutine cher (UPLO, N, ALPHA, X, INCX, A, LDA)βCHERsubroutine cher2 (UPLO, N, ALPHA, X, INCX, Y, INCY, A, LDA)βCHER2subroutine chpmv (UPLO, N, ALPHA, AP, X, INCX, BETA, Y, INCY)βCHPMVsubroutine chpr (UPLO, N, ALPHA, X, INCX, AP)βCHPRsubroutine chpr2 (UPLO, N, ALPHA, X, INCX, Y, INCY, AP)βCHPR2subroutine ctbmv (UPLO, TRANS, DIAG, N, K, A, LDA, X, INCX)βCTBMVsubroutine ctbsv (UPLO, TRANS, DIAG, N, K, A, LDA, X, INCX)βCTBSVsubroutine ctpmv (UPLO, TRANS, DIAG, N, AP, X, INCX)βCTPMVsubroutine ctpsv (UPLO, TRANS, DIAG, N, AP, X, INCX)βCTPSVsubroutine ctrmv (UPLO, TRANS, DIAG, N, A, LDA, X, INCX)βCTRMVsubroutine ctrsv (UPLO, TRANS, DIAG, N, A, LDA, X, INCX)βCTRSV
π Detailed Description π
This is, and I quote, the group of complex LEVEL 2 BLAS routines. That's the whole vibe. A whole friend group of matrix-vector and rank-update legends π
π Function Documentation π
πΈ subroutine cgbmv πΈ
subroutine cgbmv (character TRANS, integer M, integer N, integer KL, integer
KU, complex ALPHA, complex, dimension(lda,*) A, integer LDA, complex,
dimension(*) X, integer INCX, complex BETA, complex, dimension(*) Y,
integer INCY)
CGBMV π«
Purpose:
CGBMV performs one of the matrix-vector operations
y := alpha*A*x + beta*y, or y := alpha*A**T*x + beta*y, or
y := alpha*A**H*x + beta*y,
where alpha and beta are scalars, x and y are vectors and A is an m by n band matrix, with kl sub-diagonals and ku super-diagonals. Band matrix representation, no cap π₯
Parameters
TRANSβTRANSisCHARACTER*1. On entry,TRANSspecifies the operation to be performed as follows:TRANS = 'N' or 'n'βy := alpha*A*x + beta*y.TRANS = 'T' or 't'βy := alpha*A**T*x + beta*y.TRANS = 'C' or 'c'βy := alpha*A**H*x + beta*y.
MβMisINTEGER. On entry,Mspecifies the number of rows of the matrixA.Mmust be at least zero.NβNisINTEGER. On entry,Nspecifies the number of columns of the matrixA.Nmust be at least zero.KLβKLisINTEGER. On entry,KLspecifies the number of sub-diagonals of the matrixA.KLmust satisfy0 .le. KL.KUβKUisINTEGER. On entry,KUspecifies the number of super-diagonals of the matrixA.KUmust satisfy0 .le. KU.ALPHAβALPHAisCOMPLEX. On entry,ALPHAspecifies the scalaralpha.AβAisCOMPLEXarray, dimension( LDA, N ). Before entry, the leading( kl + ku + 1 )bynpart of the arrayAmust contain the matrix of coefficients, supplied column by column, with the leading diagonal of the matrix in row( ku + 1 )of the array, the first super-diagonal starting at position2in rowku, the first sub-diagonal starting at position1in row( ku + 2 ), and so on. Elements in the arrayAthat do not correspond to elements in the band matrix (such as the top leftkubykutriangle) are not referenced. The following program segment will transfer a band matrix from conventional full matrix storage to band storage:
DO 20, J = 1, N
K = KU + 1 - J
DO 10, I = MAX( 1, J - KU ), MIN( M, J + KL )
A( K + I, J ) = matrix( I, J )
10 CONTINUE
20 CONTINUE
LDAβLDAisINTEGER. On entry,LDAspecifies the first dimension ofAas declared in the calling (sub) program.LDAmust be at least( kl + ku + 1 ).XβXisCOMPLEXarray, dimension at least( 1 + ( n - 1 )*abs( INCX ) )whenTRANS = 'N' or 'n'and at least( 1 + ( m - 1 )*abs( INCX ) )otherwise. Before entry, the incremented arrayXmust contain the vectorx.INCXβINCXisINTEGER. On entry,INCXspecifies the increment for the elements ofX.INCXmust not be zero.BETAβBETAisCOMPLEX. On entry,BETAspecifies the scalarbeta. WhenBETAis supplied as zero thenYneed not be set on input. (Lowkey a nice little shortcut, ngl.)YβYisCOMPLEXarray, dimension at least( 1 + ( m - 1 )*abs( INCY ) )whenTRANS = 'N' or 'n'and at least( 1 + ( n - 1 )*abs( INCY ) )otherwise. Before entry, the incremented arrayYmust contain the vectory. On exit,Yis overwritten by the updated vectory.INCYβINCYisINTEGER. On entry,INCYspecifies the increment for the elements ofY.INCYmust not be zero.
Author
- Univ. of Tennessee
- Univ. of California Berkeley
- Univ. of Colorado Denver
- NAG Ltd.
Further Details:
Level 2 Blas routine.
The vector and matrix arguments are not referenced when N = 0, or M = 0
-- 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.
πΈ subroutine cgemv πΈ
subroutine cgemv (character TRANS, integer M, integer N, complex ALPHA,
complex, dimension(lda,*) A, integer LDA, complex, dimension(*) X,
integer INCX, complex BETA, complex, dimension(*) Y, integer INCY)
CGEMV π«
Purpose:
CGEMV performs one of the matrix-vector operations
y := alpha*A*x + beta*y, or y := alpha*A**T*x + beta*y, or
y := alpha*A**H*x + beta*y,
where alpha and beta are scalars, x and y are vectors and A is an m by n matrix. The general-purpose icon of the group, periodt π
Parameters
TRANSβTRANSisCHARACTER*1. On entry,TRANSspecifies the operation to be performed as follows:TRANS = 'N' or 'n'βy := alpha*A*x + beta*y.TRANS = 'T' or 't'βy := alpha*A**T*x + beta*y.TRANS = 'C' or 'c'βy := alpha*A**H*x + beta*y.
MβMisINTEGER. On entry,Mspecifies the number of rows of the matrixA.Mmust be at least zero.NβNisINTEGER. On entry,Nspecifies the number of columns of the matrixA.Nmust be at least zero.ALPHAβALPHAisCOMPLEX. On entry,ALPHAspecifies the scalaralpha.AβAisCOMPLEXarray, dimension( LDA, N ). Before entry, the leading m by n part of the arrayAmust contain the matrix of coefficients.LDAβLDAisINTEGER. On entry,LDAspecifies the first dimension ofAas declared in the calling (sub) program.LDAmust be at leastmax( 1, m ).XβXisCOMPLEXarray, dimension at least( 1 + ( n - 1 )*abs( INCX ) )whenTRANS = 'N' or 'n'and at least( 1 + ( m - 1 )*abs( INCX ) )otherwise. Before entry, the incremented arrayXmust contain the vectorx.INCXβINCXisINTEGER. On entry,INCXspecifies the increment for the elements ofX.INCXmust not be zero.BETAβBETAisCOMPLEX. On entry,BETAspecifies the scalarbeta. WhenBETAis supplied as zero thenYneed not be set on input.YβYisCOMPLEXarray, dimension at least( 1 + ( m - 1 )*abs( INCY ) )whenTRANS = 'N' or 'n'and at least( 1 + ( n - 1 )*abs( INCY ) )otherwise. Before entry withBETAnon-zero, the incremented arrayYmust contain the vectory. On exit,Yis overwritten by the updated vectory.INCYβINCYisINTEGER. On entry,INCYspecifies the increment for the elements ofY.INCYmust not be zero.
Author
- Univ. of Tennessee
- Univ. of California Berkeley
- Univ. of Colorado Denver
- NAG Ltd.
Further Details:
Level 2 Blas routine.
The vector and matrix arguments are not referenced when N = 0, or M = 0
-- 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.
πΈ subroutine cgerc πΈ
subroutine cgerc (integer M, integer N, complex ALPHA, complex, dimension(*)
X, integer INCX, complex, dimension(*) Y, integer INCY, complex,
dimension(lda,*) A, integer LDA)
CGERC π«
Purpose:
CGERC performs the rank 1 operation
A := alpha*x*y**H + A,
where alpha is a scalar, x is an m element vector, y is an n element vector and A is an m by n matrix. Rank-1 update with the conjugate-transpose energy, obsessed β¨
Parameters
MβMisINTEGER. On entry,Mspecifies the number of rows of the matrixA.Mmust be at least zero.NβNisINTEGER. On entry,Nspecifies the number of columns of the matrixA.Nmust be at least zero.ALPHAβALPHAisCOMPLEX. On entry,ALPHAspecifies the scalaralpha.XβXisCOMPLEXarray, dimension at least( 1 + ( m - 1 )*abs( INCX ) ). Before entry, the incremented arrayXmust contain the m element vectorx.INCXINCXβINCX is INTEGER. On entry,INCXtells you the increment for the elements ofX, bestie.INCXmust not be zero. Like, zero is not the vibe here. πYβY is COMPLEX array, dimension at least( 1 + ( n - 1 )*abs( INCY ) ). Before entry, the incremented arrayYmust contain the n element vector y. π«ΆINCYβINCY is INTEGER. On entry,INCYspecifies the increment for the elements ofY.INCYmust not be zero. Same energy asINCX, no cap.AβA is COMPLEX array, dimension( LDA, N ). Before entry, the leading m by n part of the arrayAmust contain the matrix of coefficients. On exit,Ais overwritten by the updated matrix. She got a glow-up, she's not who she was. β¨LDAβLDA is INTEGER. On entry,LDAspecifies the first dimension ofAas declared in the calling (sub) program.LDAmust be at leastmax( 1, m ). π
Author π
- Univ. of Tennessee
- Univ. of California Berkeley
- Univ. of Colorado Denver
- NAG Ltd.
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.
subroutine cgeru π
subroutine cgeru (integer M, integer N, complex ALPHA, complex, dimension(*)
X, integer INCX, complex, dimension(*) Y, integer INCY, complex,
dimension(lda,*) A, integer LDA)
CGERU
Purpose π―
CGERU performs the rank 1 operation
A := alpha*x*y**T + A,
where alpha is a scalar, x is an m element vector, y is an n element vector and A is an m by n matrix. Literally the blueprint. π
Parameters π
MβM is INTEGER. On entry,Mspecifies the number of rows of the matrixA.Mmust be at least zero.NβN is INTEGER. On entry,Nspecifies the number of columns of the matrixA.Nmust be at least zero.ALPHAβALPHA is COMPLEX. On entry,ALPHAspecifies the scalar alpha. βXβX is COMPLEX array, dimension at least( 1 + ( m - 1 )*abs( INCX ) ). Before entry, the incremented arrayXmust contain the m element vector x.INCXβINCX is INTEGER. On entry,INCXspecifies the increment for the elements ofX.INCXmust not be zero.YβY is COMPLEX array, dimension at least( 1 + ( n - 1 )*abs( INCY ) ). Before entry, the incremented arrayYmust contain the n element vector y.INCYβINCY is INTEGER. On entry,INCYspecifies the increment for the elements ofY.INCYmust not be zero.AβA is COMPLEX array, dimension( LDA, N ). Before entry, the leading m by n part of the arrayAmust contain the matrix of coefficients. On exit,Ais overwritten by the updated matrix. πLDAβLDA is INTEGER. On entry,LDAspecifies the first dimension ofAas declared in the calling (sub) program.LDAmust be at leastmax( 1, m ).
Author π
- Univ. of Tennessee
- Univ. of California Berkeley
- Univ. of Colorado Denver
- NAG Ltd.
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.
subroutine chbmv π¦
subroutine chbmv (character UPLO, integer N, integer K, complex ALPHA,
complex, dimension(lda,*) A, integer LDA, complex, dimension(*) X,
integer INCX, complex BETA, complex, dimension(*) Y, integer INCY)
CHBMV
Purpose π―
CHBMV performs the matrix-vector operation
y := alpha*A*x + beta*y,
where alpha and beta are scalars, x and y are n element vectors and A is an n by n hermitian band matrix, with k super-diagonals. Band storage is giving efficiency, iykyk. π₯
Parameters π
UPLOβUPLO is CHARACTER*1. On entry,UPLOspecifies whether the upper or lower triangular part of the band matrixAis being supplied as follows:UPLO = 'U' or 'u'β The upper triangular part ofAis being supplied.UPLO = 'L' or 'l'β The lower triangular part ofAis being supplied.
NβN is INTEGER. On entry,Nspecifies the order of the matrixA.Nmust be at least zero.KβK is INTEGER. On entry,Kspecifies the number of super-diagonals of the matrixA.Kmust satisfy0 .le. K.ALPHAβALPHA is COMPLEX. On entry,ALPHAspecifies the scalar alpha. β¨AβA is COMPLEX array, dimension( LDA, N ). Okay bestie, this one is a whole saga, so buckle up:
Before entry with UPLO = 'U' or 'u', the leading ( k + 1 ) by n part of the array A must contain the upper triangular band part of the hermitian matrix, supplied column by column, with the leading diagonal of the matrix in row ( k + 1 ) of the array, the first super-diagonal starting at position 2 in row k, and so on. The top left k by k triangle of the array A is not referenced. π
The following program segment will transfer the upper triangular part of a hermitian band matrix from conventional full matrix storage to band storage:
DO 20, J = 1, N
M = K + 1 - J
DO 10, I = MAX( 1, J - K ), J
A( M + I, J ) = matrix( I, J )
10 CONTINUE
20 CONTINUE
Before entry with UPLO = 'L' or 'l', the leading ( k + 1 ) by n part of the array A must contain the lower triangular band part of the hermitian matrix, supplied column by column, with the leading diagonal of the matrix in row 1 of the array, the first sub-diagonal starting at position 1 in row 2, and so on. The bottom right k by k triangle of the array A is not referenced. π
The following program segment will transfer the lower triangular part of a hermitian band matrix from conventional full matrix storage to band storage:
DO 20, J = 1, N
M = 1 - J
DO 10, I = J, MIN( N, J + K )
A( M + I, J ) = matrix( I, J )
10 CONTINUE
20 CONTINUE
Note that the imaginary parts of the diagonal elements need not be set and are assumed to be zero. π§
LDAβLDA is INTEGER. On entry,LDAspecifies the first dimension ofAas declared in the calling (sub) program.LDAmust be at least( k + 1 ). πXβX is COMPLEX array, dimension at least( 1 + ( n - 1 )*abs( INCX ) ). Before entry, the incremented arrayXmust contain the vector x.INCXβINCX is INTEGER. On entry,INCXspecifies the increment for the elements ofX.INCXmust not be zero.BETAβBETA is COMPLEX. On entry,BETAspecifies the scalar beta. πΈYβY is COMPLEX array, dimension at least( 1 + ( n - 1 )*abs( INCY ) ). Before entry, the incremented arrayYmust contain the vector y. On exit,Yis overwritten by the updated vector y. She's transformed, periodt. πINCYβINCY is INTEGER. On entry,INCYspecifies the increment for the elements ofY.INCYmust not be zero.
Author π
- Univ. of Tennessee
- Univ. of California Berkeley
- Univ. of Colorado Denver
- NAG Ltd.
Further Details π
Level 2 Blas routine.
The vector and matrix arguments are not referenced when N = 0, or M = 0.
-- 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.
subroutine chemv π
subroutine chemv (character UPLO, integer N, complex ALPHA, complex,
dimension(lda,*) A, integer LDA, complex, dimension(*) X, integer INCX,
complex BETA, complex, dimension(*) Y, integer INCY)
CHEMV
Purpose π―
CHEMV performs the matrix-vector operation
y := alpha*A*x + beta*y,
where alpha and beta are scalars, x and y are n element vectors and A is an n by n hermitian matrix. Iconic behaviour, honestly. π
Parameters π
UPLOβUPLO is CHARACTER*1. On entry,UPLOspecifies whether the upper or lower triangular part of the arrayAis to be referenced as follows:UPLO = 'U' or 'u'β Only the upper triangular part ofAis to be referenced.UPLO = 'L' or 'l'β Only the lower triangular part ofAis to be referenced.
NβN is INTEGER. On entry,Nspecifies the order of the matrixA.Nmust be at least zero.ALPHAβALPHA is COMPLEX. On entry,ALPHAspecifies the scalar alpha. βAβ
A
okay so A is a COMPLEX array with dimension ( LDA, N ), and here's the tea π΅:
- entering with
UPLO = 'U'or'u'? then the leading n by n upper triangular part of the arrayAmust contain the upper triangular part of the hermitian matrix. the strictly lower triangular part ofA? not referenced. we simply do not perceive it, bestie π - entering with
UPLO = 'L'or'l'? then it's the leading n by n lower triangular part ofAthat must contain the lower triangular part of the hermitian matrix, and the strictly upper triangular part ofAis not referenced.
and one lil note: the imaginary parts of the diagonal elements need not be set and they're assumed to be zero. so like, don't stress abt them π
LDA
LDA is INTEGER.
On entry, LDA specifies the first dimension of A as declared in the calling (sub) program. and it must be at least max( 1, n ). no exceptions, no negotiations π«Ά
X
X is a COMPLEX array, dimension at least ( 1 + ( n - 1 )*abs( INCX ) ).
Before entry, the incremented array X must contain the n element vector x. that's the whole assignment. iconic, honestly π
INCX
INCX is INTEGER.
On entry, INCX specifies the increment for the elements of X. and INCX must not be zero. like. at all. ever. π«
BETA
BETA is COMPLEX.
On entry, BETA specifies the scalar beta. cute lil bonus: when BETA is supplied as zero, then Y need not be set on input. free real estate β¨
Y
Y is a COMPLEX array, dimension at least ( 1 + ( n - 1 )*abs( INCY ) ).
Before entry, the incremented array Y must contain the n element vector y. On exit, Y is overwritten by the updated vector y. the glow-up happens in place, as it should π
INCY
INCY is INTEGER.
On entry, INCY specifies the increment for the elements of Y. INCY must not be zero. periodt.
Author
- Univ. of Tennessee
- Univ. of California Berkeley
- Univ. of Colorado Denver
- NAG Ltd.
Further Details:
- Level 2 Blas routine.
- The vector and matrix arguments are not referenced when
N = 0, orM = 0
-- 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.
subroutine cher (character UPLO, integer N, real ALPHA, complex, dimension(*) X, integer INCX, complex, dimension(lda,*) A, integer LDA)
CHER π
Purpose:
CHER 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. rank one, one single outer product, doing the absolute most π
Parameters
UPLO
UPLO is CHARACTER*1.
On entry, UPLO specifies whether the upper or lower triangular part of the array A is to be referenced, like so:
UPLO = 'U'or'u'β Only the upper triangular part ofAis to be referenced.UPLO = 'L'or'l'β Only the lower triangular part ofAis to be referenced.
N
N is INTEGER.
On entry, N specifies the order of the matrix A. N must be at least zero.
ALPHA
ALPHA is REAL.
On entry, ALPHA specifies the scalar alpha. yes bestie, REAL β not complex β it's giving hermitian π
X
X is a COMPLEX array, dimension at least ( 1 + ( n - 1 )*abs( INCX ) ).
Before entry, the incremented array X must contain the n element vector x.
INCX
INCX is INTEGER.
On entry, INCX specifies the increment for the elements of X. INCX must not be zero.
A
A is a COMPLEX array, dimension ( LDA, N ).
- Before entry with
UPLO = 'U'or'u', the leading n by n upper triangular part of the arrayAmust contain the upper triangular part of the hermitian matrix, and the strictly lower triangular part ofAis not referenced. On exit, the upper triangular part of the arrayAis overwritten by the upper triangular part of the updated matrix. - Before entry with
UPLO = 'L'or'l', the leading n by n lower triangular part of the arrayAmust contain the lower triangular part of the hermitian matrix, and the strictly upper triangular part ofAis not referenced. On exit, the lower triangular part of the arrayAis overwritten by the lower triangular part of the updated matrix.
and note: 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 she cleans up after herself, we love that π§
LDA
LDA is INTEGER.
On entry, LDA specifies the first dimension of A as declared in the calling (sub) program. LDA must be at least max( 1, n ).
Author
- Univ. of Tennessee
- Univ. of California Berkeley
- Univ. of Colorado Denver
- NAG Ltd.
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.
subroutine cher2 (character UPLO, integer N, complex ALPHA, complex, dimension(*) X, integer INCX, complex, dimension(*) Y, integer INCY, complex, dimension(lda,*) A, integer LDA)
CHER2 π¦
Purpose:
CHER2 performs the hermitian rank 2 operation
A := alpha*x*y**H + conjg( alpha )*y*x**H + A,
where alpha is a scalar, x and y are n element vectors and A is an n by n hermitian matrix. two outer products, one conjugate, zero notes π
Parameters
UPLO
UPLO is CHARACTER*1.
On entry, UPLO specifies whether the upper or lower triangular part of the array A is to be referenced, as follows:
UPLO = 'U'or'u'β Only the upper triangular part ofAis to be referenced.UPLO = 'L'or'l'β Only the lower triangular part ofAis to be referenced.
N
N is INTEGER.
On entry, N specifies the order of the matrix A. N must be at least zero.
ALPHA
ALPHA is COMPLEX.
On entry, ALPHA specifies the scalar alpha. (yeah, complex this time β CHER had a REAL one, don't get it twisted π
)
X
X is a COMPLEX array, dimension at least ( 1 + ( n - 1 )*abs( INCX ) ).
Before entry, the incremented array X must contain the n element vector x.
INCX
INCX is INTEGER.
On entry, INCX specifies the increment for the elements of X. INCX must not be zero.
Y
Y is a COMPLEX array, dimension at least ( 1 + ( n - 1 )*abs( INCY ) ).
Before entry, the incremented array Y must contain the n element vector y.
INCY
INCY is INTEGER.
On entry, INCY specifies the increment for the elements of Y. INCY must not be zero.
A
A is a COMPLEX array, dimension ( LDA, N ).
- Before entry with
UPLO = 'U'or'u', the leading n by n upper triangular part of the arrayAmust contain the upper triangular part of the hermitian matrix, and the strictly lower triangular part ofAis not referenced. On exit, the upper triangular part of the arrayAis overwritten by the upper triangular part of the updated matrix. - Before entry with
UPLO = 'L'or'l', the leading n by n lower triangular part of the arrayAmust contain the lower triangular part of the hermitian matrix, and the strictly upper triangular part ofAis not referenced. On exit, the lower triangular part of the arrayAis overwritten by the lower triangular part of the updated matrix.
and again, for the record: 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 β¨
LDA
LDA is INTEGER.
On entry, LDA specifies the first dimension of A as declared in the calling (sub) program. LDA must be at least max( 1, n ).
Author
- Univ. of Tennessee
- Univ. of California Berkeley
- Univ. of Colorado Denver
- NAG Ltd.
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.
subroutine chpmv (character UPLO, integer N, complex ALPHA, complex, dimension(*) AP, complex, dimension(*) X, integer INCX, complex BETA, complex, dimension(*) Y, integer INCY)
CHPMV π
Purpose:
CHPMV performs the matrix-vector operation
y := alpha*A*x + beta*y,
where alpha and beta are scalars, x and y are n element vectors and A is an n by n hermitian matrix, supplied in packed form. packed!! no wasted zeros, she's efficient π
Parameters
UPLO
UPLO is CHARACTER*1.
On entry, UPLO specifies whether the upper or lower triangular part of the matrix A is supplied in the packed array AP as follows:
UPLO = 'U'or'u'β The upper triangular part ofAis supplied inAP.UPLO = 'L'or'l'β The lower triangular part ofAis supplied inAP.
N
N is INTEGER.
On entry, N specifies the order of the matrix A. N must be at least zero.
ALPHA
ALPHA is COMPLEX.
On entry, ALPHA specifies the scalar alpha.
AP
APβ COMPLEX array, dimension at least( ( n*( n + 1 ) )/2 ). π«Ά
Okay so before you come in with UPLO = 'U' or 'u', this array has to already hold the upper triangular part of the hermitian matrix, packed sequentially, column by column β meaning AP( 1 ) contains a( 1, 1 ), then AP( 2 ) and AP( 3 ) contain a( 1, 2 ) and a( 2, 2 ) respectively, and so on forever like that. β¨
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 ), and AP( 2 ) and AP( 3 ) contain a( 2, 1 ) and a( 3, 1 ) respectively, and so on. π
Heads up bestie: the imaginary parts of the diagonal elements need not be set β they're just assumed to be zero. π
Xβ COMPLEX array, dimension at least( 1 + ( n - 1 )*abs( INCX ) ). Before entry, the incremented array X must contain the n element vector x. π¦INCXβ INTEGER. On entry,INCXspecifies the increment for the elements of X.INCXmust not be zero β like, do not do that. πBETAβ COMPLEX. On entry,BETAspecifies the scalar beta. WhenBETAis supplied as zero then Y need not be set on input. (Free real estate, no cap. π)Yβ COMPLEX array, dimension at least( 1 + ( n - 1 )*abs( INCY ) ). Before entry, the incremented array Y must contain the n element vector y. On exit, Y is overwritten by the updated vector y. π₯INCYβ INTEGER. On entry,INCYspecifies the increment for the elements of Y.INCYmust not be zero either, same energy, same rule. π
π Author
- Univ. of Tennessee
- Univ. of California Berkeley
- Univ. of Colorado Denver
- NAG Ltd.
π Further Details:
Level 2 Blas routine.
The vector and matrix arguments are not referenced when N = 0, or M = 0
-- 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.
π subroutine chpr (character UPLO, integer N, real ALPHA, complex, dimension(*) X, integer INCX, complex, dimension(*) AP)
CHPR
β Purpose:
CHPR 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. π
π§ Parameters
UPLOβ CHARACTER*1. On entry,UPLOspecifies whether the upper or lower triangular part of the matrix A is 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,Nspecifies the order of the matrix A.Nmust be at least zero.ALPHAβ REAL. On entry,ALPHAspecifies the scalar alpha. (Yes, REAL β not complex, this one's special, periodt. β¨)Xβ COMPLEX array, dimension at least( 1 + ( n - 1 )*abs( INCX ) ). Before entry, the incremented array X must contain the n element vector x.INCXβ INTEGER. On entry,INCXspecifies the increment for the elements of X.INCXmust not be zero. π«APβ COMPLEX array, dimension at least( ( n*( n + 1 ) )/2 ).
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. The way it cleans up after itself? Iconic behavior. π
π Author
- Univ. of Tennessee
- Univ. of California Berkeley
- Univ. of Colorado Denver
- NAG Ltd.
πΈ 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.
π subroutine chpr2 (character UPLO, integer N, complex ALPHA, complex, dimension(*) X, integer INCX, complex, dimension(*) Y, integer INCY, complex, dimension(*) AP)
CHPR2
β Purpose:
CHPR2 performs the hermitian rank 2 operation
A := alpha*x*y**H + conjg( alpha )*y*x**H + A,
where alpha is a scalar, x and y are n element vectors and A is an n by n hermitian matrix, supplied in packed form. Two vectors, one glow-up, no cap. β¨
π§ Parameters
UPLOβ CHARACTER*1. On entry,UPLOspecifies whether the upper or lower triangular part of the matrix A is supplied in the packed array AP as follows:
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,Nspecifies the order of the matrix A.Nmust be at least zero.ALPHAβ COMPLEX. On entry,ALPHAspecifies the scalar alpha. (Yep, complex this time β different fromchpr, we love range. π)Xβ COMPLEX array, dimension at least( 1 + ( n - 1 )*abs( INCX ) ). Before entry, the incremented array X must contain the n element vector x.INCXβ INTEGER. On entry,INCXspecifies the increment for the elements of X.INCXmust not be zero. πYβ COMPLEX array, dimension at least( 1 + ( n - 1 )*abs( INCY ) ). Before entry, the incremented array Y must contain the n element vector y.INCYβ INTEGER. On entry,INCYspecifies the increment for the elements of Y.INCYmust not be zero. πAPβ COMPLEX array, dimension at least( ( n*( n + 1 ) )/2 ).
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. Same tidy queen energy as before. π«Ά
π Author
- Univ. of Tennessee
- Univ. of California Berkeley
- Univ. of Colorado Denver
- NAG Ltd.
πΈ 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.
π subroutine ctbmv (character UPLO, character TRANS, character DIAG, integer N, integer K, complex, dimension(lda,*) A, integer LDA, complex, dimension(*) X, integer INCX)
CTBMV
β Purpose:
CTBMV performs one of the matrix-vector operations
x := A*x, or x := A**T*x, or x := A**H*x,
where x is an n element vector and A is an n by n unit, or non-unit, upper or lower triangular band matrix, with ( k + 1 ) diagonals. Banded, triangular, and it does all three of those operations β it's giving versatility, it's giving main character. π₯
π§ Parameters
UPLOβ CHARACTER*1. On entry,UPLOspecifies whether the matrix is an upper or lower triangular matrix as follows:
UPLO = 'U' or 'u' A is an upper triangular matrix.
UPLO = 'L' or 'l' A is a lower triangular matrix.
TRANSβ CHARACTER*1. On entry,TRANSspecifies the operation to be performed as follows:
TRANS = 'N' or 'n' x := A*x.
TRANS = 'T' or 't' x := A**T*x.
TRANS = 'C' or 'c' x := A**H*x.
Three whole modes, pick your fighter. β
DIAGβ CHARACTER*1. On entry,DIAGspecifies whether or not A is unit triangular as follows:
DIAG = 'U' or 'u' A is assumed to be unit triangular.
DIAG = 'N' or 'n' A is not assumed to be unit
triangular.
Nβ INTEGER. On entry,Nspecifies the order of the matrix A.Nmust be at least zero.KKisINTEGERπ« WhenUPLO = 'U'or'u',Ktells you how many super-diagonals the matrixAhas. WhenUPLO = 'L'or'l',Kis the number of sub-diagonals ofA. And bestie,Khas to satisfy0 .le. K. That's the vibe check, no exceptions. πAisCOMPLEX array, dimension( LDA, N )π¦ On entry withUPLO = 'U'or'u', the leading( k + 1 )bynchunk ofAhas to hold the upper triangular band part of the coefficient matrix, supplied column by column, with the leading diagonal of the matrix sitting in row( k + 1 )of the array, the first super-diagonal starting at position 2 in rowk, and so on and so on. The top leftkbyktriangle ofAis not referenced β it's literally just sitting there, unbothered, not part of the plot. π This little program segment will move an upper triangular band matrix from conventional full matrix storage into band storage:
DO 20, J = 1, N
M = K + 1 - J
DO 10, I = MAX( 1, J - K ), J
A( M + I, J ) = matrix( I, J )
10 CONTINUE
20 CONTINUE
On entry with UPLO = 'L' or 'l', the leading ( k + 1 ) by n part of A has to contain the lower triangular band part of the coefficient matrix, supplied column by column, with the leading diagonal in row 1 of the array, the first sub-diagonal starting at position 1 in row 2, and so on. The bottom right k by k triangle of A is not referenced β we simply do not look at her. π And here's the segment for moving a lower triangular band matrix from conventional full matrix storage into band storage:
DO 20, J = 1, N
M = 1 - J
DO 10, I = J, MIN( N, J + K )
A( M + I, J ) = matrix( I, J )
10 CONTINUE
20 CONTINUE
Heads up though: when DIAG = 'U' or 'u', the elements of A that line up with the diagonal elements of the matrix are not referenced β they're assumed to be unity. So don't come for them, they're not even in the room. β¨
LDAisINTEGERπΈ On entry,LDAspecifies the first dimension ofAas declared in the calling (sub) program.LDAmust be at least( k + 1 ). That's the floor, bestie, don't go below it. π«ΆXisCOMPLEX array, dimension at least( 1 + ( n - 1 )*abs( INCX ) )π Before entry, the incremented arrayXmust contain thenelement vectorx. On exit,Xis overwritten with the transformed vectorx. She gets a whole new personality on the way out, iconic. πINCXisINTEGERβ On entry,INCXspecifies the increment for the elements ofX.INCXmust not be zero. Like, at all. Zero is not the move here. π«
Author π
Univ. of Tennessee
Univ. of California Berkeley
Univ. of Colorado Denver
NAG Ltd.
Further Details: π
Level 2 Blas routine.
The vector and matrix arguments are not referenced when N = 0, or M = 0
-- 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.
subroutine ctbsv (character UPLO, character TRANS, character DIAG, integer N, integer K, complex, dimension(lda,) A, integer LDA, complex, dimension() X, integer INCX) π¦
CTBSV
Purpose: β¨
CTBSV solves one of the systems of equations
A*x = b, or A**T*x = b, or A**H*x = b,
where b and x are n element vectors and A is an n by n unit, or non-unit, upper or lower triangular band matrix, with ( k + 1 ) diagonals.
Ok so real talk: there is no test for singularity or near-singularity in this routine. None. Zero. If that matters to you, you have to run those tests yourself before you call this. Not me being dramatic, that's just the rules. π
Parameters π
UPLOisCHARACTER*1π On entry,UPLOspecifies whether the matrix is an upper or lower triangular matrix, like this:UPLO = 'U'or'u'βAis an upper triangular matrix.UPLO = 'L'or'l'βAis a lower triangular matrix.
TRANSisCHARACTER*1π On entry,TRANSspecifies the equations to be solved, as follows:TRANS = 'N'or'n'βA*x = b.TRANS = 'T'or't'βA**T*x = b.TRANS = 'C'or'c'βA**H*x = b.
DIAGisCHARACTER*1πΈ On entry,DIAGspecifies whether or notAis unit triangular, like this:DIAG = 'U'or'u'βAis assumed to be unit triangular.DIAG = 'N'or'n'βAis not assumed to be unit triangular.
NisINTEGERβ On entry,Nspecifies the order of the matrixA.Nmust be at least zero.KisINTEGERπ« On entry withUPLO = 'U'or'u',Kspecifies the number of super-diagonals of the matrixA. On entry withUPLO = 'L'or'l',Kspecifies the number of sub-diagonals of the matrixA.Kmust satisfy0 .le. K.AisCOMPLEX array, dimension( LDA, N )π¦ Before entry withUPLO = 'U'or'u', the leading( k + 1 )bynpart of the arrayAmust contain the upper triangular band part of the matrix of coefficients, supplied column by column, with the leading diagonal of the matrix in row( k + 1 )of the array, the first super-diagonal starting at position 2 in rowk, and so on. The top leftkbyktriangle of the arrayAis not referenced. The following program segment will transfer an upper triangular band matrix from conventional full matrix storage to band storage:
DO 20, J = 1, N
M = K + 1 - J
DO 10, I = MAX( 1, J - K ), J
A( M + I, J ) = matrix( I, J )
10 CONTINUE
20 CONTINUE
Before entry with UPLO = 'L' or 'l', the leading ( k + 1 ) by n part of the array A must contain the lower triangular band part of the matrix of coefficients, supplied column by column, with the leading diagonal of the matrix in row 1 of the array, the first sub-diagonal starting at position 1 in row 2, and so on. The bottom right k by k triangle of the array A is not referenced. The following program segment will transfer a lower triangular band matrix from conventional full matrix storage to band storage:
DO 20, J = 1, N
M = 1 - J
DO 10, I = J, MIN( N, J + K )
A( M + I, J ) = matrix( I, J )
10 CONTINUE
20 CONTINUE
Note that when DIAG = 'U' or 'u' the elements of the array A corresponding to the diagonal elements of the matrix are not referenced, but are assumed to be unity. π
LDAisINTEGERπΈ On entry,LDAspecifies the first dimension ofAas declared in the calling (sub) program.LDAmust be at least( k + 1 ).XisCOMPLEX array, dimension at least( 1 + ( n - 1 )*abs( INCX ) )π Before entry, the incremented arrayXmust contain thenelement right-hand side vectorb. On exit,Xis overwritten with the solution vectorx. Glow up on exit, we love to see it. πINCXisINTEGERβ On entry,INCXspecifies the increment for the elements ofX.INCXmust not be zero.
Author π
Univ. of Tennessee
Univ. of California Berkeley
Univ. of Colorado Denver
NAG Ltd.
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.
subroutine ctpmv (character UPLO, character TRANS, character DIAG, integer N, complex, dimension() AP, complex, dimension() X, integer INCX) π§
CTPMV
Purpose: β¨
CTPMV performs one of the matrix-vector operations
x := A*x, or x := A**T*x, or x := A**H*x,
where x is an n element vector and A is an n by n unit, or non-unit, upper or lower triangular matrix, supplied in packed form. Packed, bestie, not banded β she's compact and she knows it. π
Parameters π
UPLOisCHARACTER*1π On entry,UPLOspecifies whether the matrix is an upper or lower triangular matrix, like this:UPLO = 'U'or'u'βAis an upper triangular matrix.UPLO = 'L'or'l'βAis a lower triangular matrix.
TRANSisCHARACTER*1π On entry,TRANSspecifies the operation to be performed, as follows:TRANS = 'N'or'n'βx := A*x.TRANS = 'T'or't'βx := A**T*x.TRANS = 'C'or'c'βx := A**H*x.
DIAGisCHARACTER*1πΈ On entry,DIAGspecifies whether or notAis unit triangular, like this:DIAG = 'U'or'u'βAis assumed to be unit triangular.DIAG = 'N'or'n'βAis not assumed to be unit triangular.
NisINTEGERβ On entry,Nspecifies the order of the matrixA.Nmust be at least zero.APAPβ AP isCOMPLEX array, dimension at least( ( n*( n + 1 ) )/2 ). π Before entry withUPLO = 'U'or'u', the arrayAPmust contain the upper triangular matrix packed sequentially, column by column, so thatAP( 1 )containsa( 1, 1 ),AP( 2 )andAP( 3 )containa( 1, 2 )anda( 2, 2 )respectively, and so on. column by column bestie, don't freestyle it π Before entry withUPLO = 'L'or'l', the arrayAPmust contain the lower triangular matrix packed sequentially, column by column, so thatAP( 1 )containsa( 1, 1 ),AP( 2 )andAP( 3 )containa( 2, 1 )anda( 3, 1 )respectively, and so on.
Note that whenDIAG = 'U'or'u', the diagonal elements of A are not referenced, but are assumed to be unity. It literally does not look at them, it just trusts β¨
Xβ X isCOMPLEX array, dimension at least( 1 + ( n - 1 )*abs( INCX ) ). Before entry, the incremented arrayXmust contain thenelement vectorx. On exit,Xis overwritten with the transformed vector x. π¦INCXβ INCX isINTEGER. On entry,INCXspecifies the increment for the elements ofX.INCXmust not be zero. π«
Author π
- Univ. of Tennessee
- Univ. of California Berkeley
- Univ. of Colorado Denver
- NAG Ltd.
Further Details:
Level 2 Blas routine.
The vector and matrix arguments are not referenced when N = 0, or M = 0
-- 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.
Ok so the vector/matrix arguments just do not get touched when N = 0, or M = 0. No reads, no vibes, nothing. And yes, the whole thing is a Level 2 BLAS routine β vintage 22-October-1986, but it still eats. π
subroutine ctpsv (character UPLO, character TRANS, character DIAG, integer N, complex, dimension(*) AP, complex, dimension(*) X, integer INCX)
CTPSV πΈ
Purpose:
CTPSV solves one of the systems of equations
A*x = b, or A**T*x = b, or A**H*x = b,
where b and x are n element vectors and A is an n by n unit, or non-unit, upper or lower triangular matrix, supplied in packed form. π«Ά
No test for singularity or near-singularity is included in this routine. Such tests must be performed before calling this routine. Read that again. She will not check if your matrix is a mess β you gotta check that yourself before you ring her up. ππ
Parameters π
UPLOβ UPLO isCHARACTER*1. On entry,UPLOspecifies whether the matrix is an upper or lower triangular matrix as follows:UPLO = 'U'or'u'β A is an upper triangular matrix.UPLO = 'L'or'l'β A is a lower triangular matrix.
TRANSβ TRANS isCHARACTER*1. On entry,TRANSspecifies the equations to be solved as follows:TRANS = 'N'or'n'βA*x = b.TRANS = 'T'or't'βA**T*x = b.TRANS = 'C'or'c'βA**H*x = b.
DIAGβ DIAG isCHARACTER*1. On entry,DIAGspecifies whether or not A is unit triangular as follows:DIAG = 'U'or'u'β A is assumed to be unit triangular.DIAG = 'N'or'n'β A is not assumed to be unit triangular.
Nβ N isINTEGER. On entry,Nspecifies the order of the matrix A.Nmust be at least zero.APβ AP isCOMPLEX array, dimension at least( ( n*( n + 1 ) )/2 ). π Before entry withUPLO = 'U'or'u', the arrayAPmust contain the upper triangular matrix packed sequentially, column by column, so thatAP( 1 )containsa( 1, 1 ),AP( 2 )andAP( 3 )containa( 1, 2 )anda( 2, 2 )respectively, and so on. Before entry withUPLO = 'L'or'l', the arrayAPmust contain the lower triangular matrix packed sequentially, column by column, so thatAP( 1 )containsa( 1, 1 ),AP( 2 )andAP( 3 )containa( 2, 1 )anda( 3, 1 )respectively, and so on.
Note that whenDIAG = 'U'or'u', the diagonal elements of A are not referenced, but are assumed to be unity.
Xβ X isCOMPLEX array, dimension at least( 1 + ( n - 1 )*abs( INCX ) ). Before entry, the incremented arrayXmust contain thenelement right-hand side vector b. On exit,Xis overwritten with the solution vector x. π¦INCXβ INCX isINTEGER. On entry,INCXspecifies the increment for the elements ofX.INCXmust not be zero. π«
Author π
- Univ. of Tennessee
- Univ. of California Berkeley
- Univ. of Colorado Denver
- NAG Ltd.
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.
(Yeah, this one is just "Level 2 Blas routine." and the 1986 credits. No N = 0/M = 0 footnote here β different routine, different fine print.) β
subroutine ctrmv (character UPLO, character TRANS, character DIAG, integer N, complex, dimension(lda,*) A, integer LDA, complex, dimension(*) X, integer INCX)
CTRMV πΈ
Purpose:
CTRMV performs one of the matrix-vector operations
x := A*x, or x := A**T*x, or x := A**H*x,
where x is an n element vector and A is an n by n unit, or non-unit, upper or lower triangular matrix. π
Parameters π
UPLOβ UPLO isCHARACTER*1. On entry,UPLOspecifies whether the matrix is an upper or lower triangular matrix as follows:UPLO = 'U'or'u'β A is an upper triangular matrix.UPLO = 'L'or'l'β A is a lower triangular matrix.
TRANSβ TRANS isCHARACTER*1. On entry,TRANSspecifies the operation to be performed as follows:TRANS = 'N'or'n'βx := A*x.TRANS = 'T'or't'βx := A**T*x.TRANS = 'C'or'c'βx := A**H*x.
DIAGβ DIAG isCHARACTER*1. On entry,DIAGspecifies whether or not A is unit triangular as follows:DIAG = 'U'or'u'β A is assumed to be unit triangular.DIAG = 'N'or'n'β A is not assumed to be unit triangular.
Nβ N isINTEGER. On entry,Nspecifies the order of the matrix A.Nmust be at least zero.Aβ A isCOMPLEX array, dimension( LDA, N ). π Before entry withUPLO = 'U'or'u', the leadingnbynupper triangular part of the arrayAmust contain the upper triangular matrix and the strictly lower triangular part ofAis not referenced. Before entry withUPLO = 'L'or'l', the leadingnbynlower triangular part of the arrayAmust contain the lower triangular matrix and the strictly upper triangular part ofAis not referenced.
Note that whenDIAG = 'U'or'u', the diagonal elements of A are not referenced either, but are assumed to be unity. She's ignoring the whole diagonal, no cap. π
LDAβ LDA isINTEGER. On entry,LDAspecifies the first dimension of A as declared in the calling (sub) program.LDAmust be at leastmax( 1, n ).Xβ X isCOMPLEX array, dimension at least( 1 + ( n - 1 )*abs( INCX ) ). Before entry, the incremented arrayXmust contain thenelement vectorx. On exit,Xis overwritten with the transformed vector x. π¦INCXβ INCX isINTEGER. On entry,INCXspecifies the increment for the elements ofX.INCXmust not be zero. π«
Author π
- Univ. of Tennessee
- Univ. of California Berkeley
- Univ. of Colorado Denver
- NAG Ltd.
Further Details:
Level 2 Blas routine.
The vector and matrix arguments are not referenced when N = 0, or M = 0
-- 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.
subroutine ctrsv (character UPLO, character TRANS, character DIAG, integer N, complex, dimension(lda,*) A, integer LDA, complex, dimension(*) X, integer INCX)
CTRSV πΈ
Purpose:
CTRSV solves one of the systems of equations
A*x = b, or A**T*x = b, or A**H*x = b,
where b and x are n element vectors and A is an n by n unit, or non-unit, upper or lower triangular matrix.
No test for singularity or near-singularity is included in this routine. Such tests must be performed before calling this routine. Same energy as before, bestie: the singularity check is your job, not hers. Do it before you call her or don't come crying to me. π
Parameters π
UPLOβ UPLO isCHARACTER*1. On entry,UPLOspecifies whether the matrix is an upper or lower triangular matrix as follows:UPLO = 'U'or'u'β A is an upper triangular matrix.UPLO = 'L'or'l'β A is a lower triangular matrix.
TRANSβ TRANS isCHARACTER*1. On entry,TRANSspecifies the equations to be solved as follows:TRANS = 'N'or'n'βA*x = b.TRANS = 'T'or't'βA**T*x = b.TRANS = 'C'or'c'βA**H*x = b.
DIAGβ DIAG isCHARACTER*1. On entry,DIAGspecifies whether or not A is unit triangular as follows:DIAG = 'U'or'u'β A is assumed to be unit triangular.DIAG = 'N'or'n'β A is not assumed to be unit triangular.
Nβ N isINTEGER. On entry,Nspecifies the order of the matrix A.Nmust be at least zero.A
A A is a COMPLEX array, dimension ( LDA, N ). π
Before entry with UPLO = 'U' or 'u', the leading n by n upper triangular part of the array A must contain the upper triangular matrix, and the strictly lower triangular part of A is not referenced. Slay, but only the upper part matters, bestie. β¨
Before entry with UPLO = 'L' or 'l', the leading n by n lower triangular part of the array A must contain the lower triangular matrix, and the strictly upper triangular part of A is not referenced. Lower energy only, periodt. π
Note that when DIAG = 'U' or 'u', the diagonal elements of A are not referenced either, but are assumed to be unity. So don't come for the diagonal β it's giving 1 automatically. π
LDA LDA is INTEGER. π
On entry, LDA specifies the first dimension of A as declared in the calling (sub) program. LDA must be at least max( 1, n ). No cap, it's the bare minimum. πΈ
X X is a COMPLEX array, dimension at least ( 1 + ( n - 1 )*abs( INCX ) ). π¦
Before entry, the incremented array X must contain the n element right-hand side vector b. On exit, X is overwritten with the solution vector x. She comes in as b, leaves as x β main character transformation. π
INCX INCX is INTEGER. β
On entry, INCX specifies the increment for the elements of X. INCX must not be zero. Zero is NOT the vibe. Do not pass zero. That's a whole warning, fr fr. π
Author
- Univ. of Tennessee
- Univ. of California Berkeley
- Univ. of Colorado Denver
- NAG Ltd.
Shoutout to the academic icons who made this happen. π«Ά
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.
Author
Generated automatically by Doxygen for LAPACK from the source code. π€
Doxygen did its little automated thing, and honestly? It ate. β¨
That's the whole page, bestie! Version 3.11.0, dated Sun Nov 27 2022, for complex_blas_level2(3). Stay complex, stay iconic. Mwah π
π¦ where this page comes from
- debian bookworm: liblapack-doc 3.11.0-2 Β· BSD-3-Clause
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms