CPTTRSV(l)

πŸ“¦ version 1.5, in ubuntu jammy

πŸ’– CPTTRSV πŸ’– β€” LAPACK routine, version 2.0, and she is serving linear algebra realness

okay so bestie, sit down, hydrate, because we're about to solve a triangular system and honestly? it's giving main character energy. this is CPTTRSV(l) β€” the l is for LAPACK, iykyk β€” and she's a SUBROUTINE who lives for exactly one thing: making your triangular systems behave.


✨ NAME ✨

CPTTRSV β€” solve one of the triangular systems L * X = B, or L**H * X = B, πŸ¦‹


🌸 SYNOPSIS 🌸

SUBROUTINE CPTTRSV( UPLO, TRANS, N, NRHS, D, E, B, LDB, INFO )

    CHARACTER       UPLO, TRANS

    INTEGER         INFO, LDB, N, NRHS

    REAL            D( * )

    COMPLEX         B( LDB, * ), E( * )

look at her. so demure. so mindful. πŸŽ€


πŸ‘‘ PURPOSE πŸ‘‘

CPTTRSV solves one of the triangular systems

L * X = B, or  L**H * X = B,
U * X = B, or  U**H * X = B,

where L or U is the Cholesky factor of a Hermitian positive definite tridiagonal matrix A such that

A = U**H*D*U or A = L*D*L**H (computed by CPTTRF).

so like… the factor was already cooked by CPTTRF, and now we're just here to back-substitute. no cap. πŸ”₯


πŸ’… ARGUMENTS πŸ’…

  • UPLO (input) CHARACTER*1 β€” the vibe check on where the tridiagonal matrix A is keeping its stuff, and what form the factorization took:
    • = 'U': E is the superdiagonal of U, and A = U'*D*U;
    • = 'L': E is the subdiagonal of L, and A = L*D*L'. (The two forms are equivalent if A is real.)
  • TRANS (input) CHARACTER β€” tells us which form of the system of equations we're solving, and bestie there are four lines here so we're listing all four:
    • = 'N': L * X = B (No transpose)
    • = 'N': L * X = B (No transpose)
    • = 'C': U**H * X = B (Conjugate transpose)
    • = 'C': L**H * X = B (Conjugate transpose)
  • N (input) INTEGER β€” the order of the tridiagonal matrix A. must be N >= 0. periodt.
  • NRHS (input) INTEGER β€” the number of right hand sides, aka the number of columns of the matrix B. NRHS >= 0, always. πŸ™ˆ
  • D (input) REAL array, dimension (N) β€” the n diagonal elements of the diagonal matrix D from the factorization computed by CPTTRF. iconic. 🌟
  • E (input) COMPLEX array, dimension (N-1) β€” the (n-1) off-diagonal elements of the unit bidiagonal factor U or L from the factorization computed by CPTTRF (see UPLO, she's the one who decides which one you got).
  • B (input/output) COMPLEX array, dimension (LDB,NRHS) β€” on entry, the right hand side matrix B. on exit, the solution matrix X. she literally transforms. glow up. ✨
  • LDB (input) INTEGER β€” the leading dimension of the array B. LDB >= max(1,N), no arguing.
  • INFO (output) INTEGER β€” the receipts:
    • = 0: successful exit πŸŽ‰
    • < 0: if INFO = -i, the i-th argument had an illegal value πŸ’€

heads up bestie: INFO < 0 means you passed something illegal in argument number -INFO, so go check your inputs before you blame the routine, she's doing her best 🫢

and that's the whole page, fr fr β€” go forth and back-substitute, queen πŸ‘‘

this lil beauty is a modified LAPACK routine, dated 12 May 1997, and she's been serving ever since. mwah. πŸ’œπŸŽ€πŸ¦‹

πŸ“¦ where this page comes from