unmtr(3)

πŸ’… unmtr(3) β€” Library Functions Manual

okay so bestie, welcome to unmtr(3) β€” this is the man page for the {un,or}mtr family, which is literally the "multiply by Q from hetrd" gang. yes, that's a lowercase hetrd in the literal title, we don't ask questions, we just vibe πŸ’–


✨ NAME ✨

unmtr β€” {un,or}mtr: multiply by Q from hetrd

like, it's giving "I built you a Q, now let me use it" energy πŸŽ€


🌸 SYNOPSIS 🌸

🫢 Functions

subroutine cunmtr (side, uplo, trans, m, n, a, lda, tau, c, ldc, work,
    lwork, info)

CUNMTR (the complex one, bestie πŸ’œ)

subroutine dormtr (side, uplo, trans, m, n, a, lda, tau, c, ldc, work,
    lwork, info)

DORMTR (double precision real, double the precision, double the slay πŸ’…)

subroutine sormtr (side, uplo, trans, m, n, a, lda, tau, c, ldc, work,
    lwork, info)

SORMTR (single precision real, small but mighty ✨)

subroutine zunmtr (side, uplo, trans, m, n, a, lda, tau, c, ldc, work,
    lwork, info)

ZUNMTR (double complex β€” Z, as in Z-list, as in main character energy πŸ‘‘)


Detailed Description

so this page is the Function Documentation for all four of these routines. they're four flavors of the exact same move, just in different precisions. pick the one that matches your data type and go off πŸ¦‹


πŸ”₯ Function Documentation πŸ”₯

πŸ’– subroutine cunmtr

subroutine cunmtr (character side, character uplo, character trans, integer
    m, integer n, complex, dimension( lda, * ) a, integer lda, complex,
    dimension( * ) tau, complex, dimension( ldc, * ) c, integer ldc,
    complex, dimension( * ) work, integer lwork, integer info)

CUNMTR β€” the complex unitary legend πŸ’«

🌈 Purpose

!> !> CUNMTR overwrites the general complex M-by-N matrix C with !> !> SIDE = 'L' SIDE = 'R' !> TRANS = 'N': Q * C C * Q !> TRANS = 'C': Q**H * C C * Q**H !> !> where Q is a complex unitary matrix of order nq, with nq = m if !> SIDE = 'L' and nq = n if SIDE = 'R'. Q is defined as the product of !> nq-1 elementary reflectors, as returned by CHETRD: !> !> if UPLO = 'U', Q = H(nq-1) . . . H(2) H(1); !> !> if UPLO = 'L', Q = H(1) H(2) . . . H(nq-1). !>

like, C is so getting overwritten. it's not a suggestion, it's a lifestyle πŸ’…

πŸŽ€ Parameters

  • SIDE β€” SIDE is CHARACTER*1
    • = 'L': apply Q or Q**H from the Left;
    • = 'R': apply Q or Q**H from the Right.
  • UPLO β€” UPLO is CHARACTER*1
    • = 'U': Upper triangle of A contains elementary reflectors from CHETRD;
    • = 'L': Lower triangle of A contains elementary reflectors from CHETRD.
  • TRANS β€” TRANS is CHARACTER*1
    • = 'N': No transpose, apply Q;
    • = 'C': Conjugate transpose, apply Q**H.
  • M β€” M is INTEGER the number of rows of the matrix C. M >= 0.
  • N β€” N is INTEGER the number of columns of the matrix C. N >= 0.
  • A β€” A is COMPLEX array, dimension
(LDA,M) if SIDE = 'L'
(LDA,N) if SIDE = 'R'

the vectors which define the elementary reflectors, as returned by CHETRD.

  • LDA β€” LDA is INTEGER the leading dimension of the array A. LDA >= max(1,M) if SIDE = 'L'; LDA >= max(1,N) if SIDE = 'R'.
  • TAU β€” TAU is COMPLEX array, dimension
(M-1) if SIDE = 'L'
(N-1) if SIDE = 'R'

TAU(i) must contain the scalar factor of the elementary reflector H(i), as returned by CHETRD.

  • C β€” C is COMPLEX array, dimension (LDC,N) on entry, the M-by-N matrix C. on exit, C is overwritten by Q*C or Q**H*C or C*Q**H or C*Q.
  • LDC β€” LDC is INTEGER the leading dimension of the array C. LDC >= max(1,M).
  • WORK β€” WORK is COMPLEX array, dimension (MAX(1,LWORK)) on exit, if INFO = 0, WORK(1) returns the optimal LWORK.
  • LWORK β€” LWORK is INTEGER the dimension of the array WORK. if SIDE = 'L', LWORK >= max(1,N); if SIDE = 'R', LWORK >= max(1,M). for optimum performance LWORK >= N*NB if SIDE = 'L', and LWORK >= M*NB if SIDE = 'R', where NB is the optimal blocksize.
if LWORK = -1, then a workspace query is assumed; the routine only calculates the optimal size of the WORK array, returns this value as the first entry of the WORK array, and no error message related to LWORK is issued by XERBLA. (iconic behavior honestly β€” ask me my size and I'll tell you, no notes 🫢)
  • INFO β€” INFO is INTEGER
    • = 0: successful exit
    • < 0: if INFO = -i, the i-th argument had an illegal value

πŸ‘‘ Author

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

Definition at line 170 of file cunmtr.f.


πŸ¦‹ subroutine dormtr

subroutine dormtr (character side, character uplo, character trans, integer
    m, integer n, double precision, dimension( lda, * ) a, integer lda,
    double precision, dimension( * ) tau, double precision, dimension( ldc,
    * ) c, integer ldc, double precision, dimension( * ) work, integer
    lwork, integer info)

DORMTR β€” the double precision real orthogonal one, she's precise and she knows it πŸ’œ

🌈 Purpose

!> !> DORMTR overwrites the general real M-by-N matrix C with !> !> SIDE = 'L' SIDE = 'R' !> TRANS = 'N': Q * C C * Q !> TRANS = 'T': Q**T * C C * Q**T !> !> where Q is a real orthogonal matrix of order nq, with nq = m if !> SIDE = 'L' and nq = n if SIDE = 'R'. Q is defined as the product of !> nq-1 elementary reflectors, as returned by DSYTRD: !> !> if UPLO = 'U', Q = H(nq-1) . . . H(2) H(1); !> !> if UPLO = 'L', Q = H(1) H(2) . . . H(nq-1). !>

πŸŽ€ Parameters

  • SIDE β€” SIDE is CHARACTER*1
    • = 'L': apply Q or Q**T from the Left;
    • = 'R': apply Q or Q**T from the Right.
  • UPLO β€” UPLO is CHARACTER*1
    • = 'U': Upper triangle of A contains elementary reflectors from DSYTRD;
    • = 'L': Lower triangle of A contains elementary reflectors from DSYTRD.
  • TRANS β€” TRANS is CHARACTER*1
    • = 'N': No transpose, apply Q;
    • = 'T': Transpose, apply Q**T.
note bestie: 'T' here, not 'C' β€” real matrices don't need conjugating, that's a complex-girl thing πŸ’€
  • M β€” M is INTEGER the number of rows of the matrix C. M >= 0.
  • N β€” N is INTEGER the number of columns of the matrix C. N >= 0.
  • A β€” A is DOUBLE PRECISION array, dimension
(LDA,M) if SIDE = 'L'
(LDA,N) if SIDE = 'R'

the vectors which define the elementary reflectors, as returned by DSYTRD.

  • LDA β€” LDA is INTEGER the leading dimension of the array A. LDA >= max(1,M) if SIDE = 'L'; LDA >= max(1,N) if SIDE = 'R'.
  • TAU β€” TAU is DOUBLE PRECISION array, dimension
(M-1) if SIDE = 'L'
(N-1) if SIDE = 'R'

TAU(i) must contain the scalar factor of the elementary reflector H(i), as returned by DSYTRD.

  • C β€” C is DOUBLE PRECISION array, dimension (LDC,N) on entry, the M-by-N matrix C. on exit, C is overwritten by Q*C or Q**T*C or C*Q**T or C*Q.
  • LDC β€” LDC is INTEGER the leading dimension of the array C. LDC >= max(1,M).
  • WORK β€” WORK is DOUBLE PRECISION array, dimension (MAX(1,LWORK)) on exit, if INFO = 0, WORK(1) returns the optimal LWORK.
  • LWORK β€” LWORK is INTEGER the dimension of the array WORK. if SIDE = 'L', LWORK >= max(1,N); if SIDE = 'R', LWORK >= max(1,M). for optimum performance LWORK >= N*NB if SIDE = 'L', and LWORK >= M*NB if SIDE = 'R', where NB is the optimal blocksize.
if LWORK = -1, then a workspace query is assumed; the routine only calculates the optimal size of the WORK array, returns this value as the first entry of the WORK array, and no error message related to LWORK is issued by XERBLA.
  • INFO β€” INFO is INTEGER
    • = 0: successful exit
    • < 0: if INFO = -i, the i-th argument had an illegal value

πŸ‘‘ Author

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

Definition at line 169 of file dormtr.f.


🌸 subroutine sormtr

subroutine sormtr (character side, character uplo, character trans, integer
    m, integer n, real, dimension( lda, * ) a, integer lda, real, dimension(
    * ) tau, real, dimension( ldc, * ) c, integer ldc, real, dimension( * )
    work, integer lwork, integer info)

SORMTR β€” single precision real, tiny but she ate πŸ”₯

🌈 Purpose

!> !> SORMTR overwrites the general real M-by-N matrix C with !> !> SIDE = 'L' SIDE = 'R' !> TRANS = 'N': Q * C C * Q !> TRANS = 'T': Q**T * C C * Q**T !> !> where Q is a real orthogonal matrix of order nq, with nq = m if !> SIDE = 'L' and nq = n if SIDE = 'R'. Q is defined as the product of !> nq-1 elementary reflectors, as returned by SSYTRD: !> !> if UPLO = 'U', Q = H(nq-1) . . . H(2) H(1); !> !> if UPLO = 'L', Q = H(1) H(2) . . . H(nq-1). !>

πŸŽ€ Parameters

  • SIDE β€” SIDE is CHARACTER*1
    • = 'L': apply Q or Q**T from the Left;
    • = 'R': apply Q or Q**T from the Right.
  • UPLO β€” UPLO is CHARACTER*1
    • = 'U': Upper triangle of A contains elementary reflectors from SSYTRD;
    • = 'L': Lower triangle of A contains elementary reflectors from SSYTRD.
  • TRANS β€” TRANS is CHARACTER*1
    • = 'N': No transpose, apply Q;
    • = 'T': Transpose, apply Q**T.
  • M β€” M is INTEGER the number of rows of the matrix C. M >= 0.
  • N β€” N is INTEGER the number of columns of the matrix C. N >= 0.
  • A β€” A is REAL array, dimension
(LDA,M) if SIDE = 'L'
(LDA,N) if SIDE = 'R'

the vectors which define the elementary reflectors, as returned by SSYTRD.

Okay so we're still deep in SORMTR's parameter list β€” picking up at A because that's where this part starts, and yes bestie we're finishing every last one πŸ’…

  • A β€” A is REAL array, dimension (LDA,M) if SIDE = 'L', (LDA,N) if SIDE = 'R'. The vectors which define the elementary reflectors, as returned by SSYTRD.
  • LDA β€” LDA is INTEGER. The leading dimension of the array A. LDA >= max(1,M) if SIDE = 'L'; LDA >= max(1,N) if SIDE = 'R'.
  • TAU β€” TAU is REAL array, dimension (M-1) if SIDE = 'L', (N-1) if SIDE = 'R'. TAU(i) must contain the scalar factor of the elementary reflector H(i), as returned by SSYTRD.
  • C β€” C is REAL array, dimension (LDC,N). On entry, the M-by-N matrix C. On exit, C is overwritten by Q*C or Q**T*C or C*Q**T or C*Q.
  • LDC β€” LDC is INTEGER. The leading dimension of the array C. LDC >= max(1,M).
  • WORK β€” WORK is REAL array, dimension (MAX(1,LWORK)). On exit, if INFO = 0, WORK(1) returns the optimal LWORK.
  • LWORK β€” LWORK is INTEGER. The dimension of the array WORK. If SIDE = 'L', LWORK >= max(1,N); if SIDE = 'R', LWORK >= max(1,M). For optimum performance LWORK >= N*NB if SIDE = 'L', and LWORK >= M*NB if SIDE = 'R', where NB is the optimal blocksize.

And the special case, bestie: if LWORK = -1, then a workspace query is assumed; the routine only calculates the optimal size of the WORK array, returns this value as the first entry of the WORK array, and no error message related to LWORK is issued by XERBLA.

  • INFO β€” INFO is INTEGER. = 0: successful exit. < 0: if INFO = -i, the i-th argument had an illegal value.

πŸ‘‘ Author

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

Definition at line 170 of file sormtr.f.


🧚 subroutine zunmtr β€” the complex sibling, and she's iconic

subroutine zunmtr (character side, character uplo, character trans, integer
    m, integer n, complex*16, dimension( lda, * ) a, integer lda,
    complex*16, dimension( * ) tau, complex*16, dimension( ldc, * ) c,
    integer ldc, complex*16, dimension( * ) work, integer lwork, integer
    info)

ZUNMTR β€” okay so this one is the COMPLEX*16 version, and here's the glow-up:

🎯 Purpose

ZUNMTR overwrites the general complex M-by-N matrix C with

                SIDE = 'L'     SIDE = 'R'
TRANS = 'N':      Q * C          C * Q
TRANS = 'C':      Q**H * C       C * Q**H

where Q is a complex unitary matrix of order nq, with nq = m if SIDE = 'L' and nq = n if SIDE = 'R'. Q is defined as the product of nq-1 elementary reflectors, as returned by ZHETRD:

  • if UPLO = 'U', Q = H(nq-1) . . . H(2) H(1);
  • if UPLO = 'L', Q = H(1) H(2) . . . H(nq-1).

🌸 Parameters

  • SIDE β€” SIDE is CHARACTER*1. = 'L': apply Q or Q**H from the Left; = 'R': apply Q or Q**H from the Right.
  • UPLO β€” UPLO is CHARACTER*1. = 'U': Upper triangle of A contains elementary reflectors from ZHETRD; = 'L': Lower triangle of A contains elementary reflectors from ZHETRD.
  • TRANS β€” TRANS is CHARACTER*1. = 'N': No transpose, apply Q; = 'C': Conjugate transpose, apply Q**H.
  • M β€” M is INTEGER. The number of rows of the matrix C. M >= 0.
  • N β€” N is INTEGER. The number of columns of the matrix C. N >= 0.
  • A β€” A is COMPLEX*16 array, dimension (LDA,M) if SIDE = 'L', (LDA,N) if SIDE = 'R'. The vectors which define the elementary reflectors, as returned by ZHETRD.
  • LDA β€” LDA is INTEGER. The leading dimension of the array A. LDA >= max(1,M) if SIDE = 'L'; LDA >= max(1,N) if SIDE = 'R'.
  • TAU β€” TAU is COMPLEX*16 array, dimension (M-1) if SIDE = 'L', (N-1) if SIDE = 'R'. TAU(i) must contain the scalar factor of the elementary reflector H(i), as returned by ZHETRD.
  • C β€” C is COMPLEX*16 array, dimension (LDC,N). On entry, the M-by-N matrix C. On exit, C is overwritten by Q*C or Q**H*C or C*Q**H or C*Q.
  • LDC β€” LDC is INTEGER. The leading dimension of the array C. LDC >= max(1,M).
  • WORK β€” WORK is COMPLEX*16 array, dimension (MAX(1,LWORK)). On exit, if INFO = 0, WORK(1) returns the optimal LWORK.
  • LWORK β€” LWORK is INTEGER. The dimension of the array WORK. If SIDE = 'L', LWORK >= max(1,N); if SIDE = 'R', LWORK >= max(1,M). For optimum performance LWORK >= N*NB if SIDE = 'L', and LWORK >=M*NB if SIDE = 'R', where NB is the optimal blocksize.

If LWORK = -1, then a workspace query is assumed; the routine only calculates the optimal size of the WORK array, returns this value as the first entry of the WORK array, and no error message related to LWORK is issued by XERBLA.

  • INFO β€” INFO is INTEGER. = 0: successful exit. < 0: if INFO = -i, the i-th argument had an illegal value.

πŸ‘‘ Author

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

Definition at line 169 of file zunmtr.f.

🫢 Author

Generated automatically by Doxygen for LAPACK from the source code.


And that's a wrap on unmtr(3) from LAPACK Version 3.12.0 β€” generated straight from the source code by Doxygen, no cap. Bye bestie, go slay those reflectors πŸ’–βœ¨πŸ‘‘

πŸ“¦ where this page comes from