SGETRS(3)

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

πŸ’… sgetrs.f(3) β€” LAPACK Library Functions Manual, bestie edition πŸŽ€

okay so this page lives in the LAPACK Library Functions Manual and it's literally all about one fortran file, no cap.


✨ NAME ✨

/home/abuild/rpmbuild/BUILD/lapack-static-3.12.0-build/lapack-3.12.0/SRC/sgetrs.f

like. that's the whole name. it's giving "my full government name is a file path" 😭 but that's genuinely what the manpage says, so we're keeping it exactly as-is, periodt.


🌸 SYNOPSIS 🌸

Functions/Subroutines

subroutine SGETRS (trans, n, nrhs, a, lda, ipiv, b, ldb, info)
    SGETRS

πŸ¦‹ Function/Subroutine Documentation πŸ¦‹

the actual signature, verbatim, don't @ me

subroutine SGETRS (character trans, integer n, integer nrhs, real,
    dimension( lda, * ) a, integer lda, integer, dimension( * ) ipiv, real,
    dimension( ldb, * ) b, integer ldb, integer info)
    SGETRS

πŸ‘‘ Purpose πŸ‘‘

so what does she do? quoting the source, with the !> comment markers intact because we respect the original:

!>
!> SGETRS solves a system of linear equations
!>    A * X = B  or  A**T * X = B
!> with a general N-by-N matrix A using the LU factorization computed
!> by SGETRF.
!>

translation bestie: she solves systems of linear equations using an LU factorization that you already got from SGETRF. she does not do the factorizing herself. she's the second half of the glow-up, not the whole makeover. πŸ’–


🌈 Parameters 🌈

TRANS

!>          TRANS is CHARACTER*1
!>          Specifies the form of the system of equations:
!>          = 'N':  A * X = B  (No transpose)
!>          = 'T':  A**T* X = B  (Transpose)
!>          = 'C':  A**T* X = B  (Conjugate transpose = Transpose)
!>

a single character that picks which version of the equation you want, and the three legal values are 'N', 'T' and 'C'. note the iconique detail: for real matrices 'C' means conjugate transpose which equals transpose, so it's the same thing as 'T'. slay.

N

!>          N is INTEGER
!>          The order of the matrix A.  N >= 0.
!>

the order of matrix A. constraint is N >= 0, so zero is allowed, negative is not, we don't do that here.

NRHS

!>          NRHS is INTEGER
!>          The number of right hand sides, i.e., the number of columns
!>          of the matrix B.  NRHS >= 0.
!>

the number of right hand sides β€” aka how many columns matrix B has. also NRHS >= 0. two zero-club members, we love to see it.

A

!>          A is REAL array, dimension (LDA,N)
!>          The factors L and U from the factorization A = P*L*U
!>          as computed by SGETRF.
!>

a REAL array, dimension (LDA,N). she holds the factors L and U from the factorization A = P*L*U, exactly as SGETRF computed them. so yeah, you gotta run SGETRF first. she is not doing that for you. πŸ™ˆ

LDA

!>          LDA is INTEGER
!>          The leading dimension of the array A.  LDA >= max(1,N).
!>

the leading dimension of array A, and the vibe check is LDA >= max(1,N). lowkey important, don't fumble it.

IPIV

!>          IPIV is INTEGER array, dimension (N)
!>          The pivot indices from SGETRF; for 1<=i<=N, row i of the
!>          matrix was interchanged with row IPIV(i).
!>

an INTEGER array, dimension (N). these are the pivot indices straight from SGETRF: for 1<=i<=N, row i of the matrix was interchanged with row IPIV(i). she remembers every swap, main character energy.

B

!>          B is REAL array, dimension (LDB,NRHS)
!>          On entry, the right hand side matrix B.
!>          On exit, the solution matrix X.
!>

a REAL array, dimension (LDB,NRHS). and this is the glow-up moment: on entry she's the right hand side matrix B, on exit she's the solution matrix X. same array, whole new identity. ate and left no crumbs. ✨

LDB

!>          LDB is INTEGER
!>          The leading dimension of the array B.  LDB >= max(1,N).
!>

the leading dimension of array B, with LDB >= max(1,N). same energy as LDA, different letter.

INFO

!>         INFO is INTEGER
!>         = 0:  successful exit
!>         < 0:  if INFO = -i, the i-th argument had an illegal value
!>

an INTEGER telling you how it went:

  • = 0: successful exit, we love a clean run 🫢
  • < 0: if INFO = -i, the i-th argument had an illegal value β€” so like, check your args bestie, one of them was not it πŸ’€
fr fr: watch your argument constraints. INFO < 0 means one of the arguments broke the rules, and the negative number tells you which one.

🧚 Author 🧚

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

Definition at line 120 of file sgetrs.f.


πŸ’œ Author πŸ’œ

Generated automatically by Doxygen for LAPACK from the source code.


and that's the whole page, bestie β€” LAPACK, Version 3.12.0, documented from /home/abui...RC/sgetrs.f(3). go forth and solve your systems. πŸ’…πŸŽ€

πŸ“¦ where this page comes from