CPST01(3)

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

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

ok so bestie, we are deep in the LAPACK testing trenches today. this page lives at /home/abuild/rpmbuild/BUILD/lapack-static-3.12.0-build/lapack-3.12.0/TESTING/LIN/cpst01.f and honestly? it's giving "unsung hero of the test suite." she reconstructs stuff, she checks residuals, she does NOT get enough credit. let's get into it ✨


✨ SYNOPSIS ✨

Functions/Subroutines

  • subroutine CPST01 (uplo, n, a, lda, afac, ldafac, perm, ldperm, piv, rwork, resid, rank) β€” that's her! that's the girl!

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

subroutine CPST01 (character uplo, integer n, complex, dimension( lda, * )
    a, integer lda, complex, dimension( ldafac, * ) afac, integer ldafac,
    complex, dimension( ldperm, * ) perm, integer ldperm, integer,
    dimension( * ) piv, real, dimension( * ) rwork, real resid, integer
    rank)

CPST01

🌸 Purpose 🌸

ok so listen. CPST01 reconstructs an Hermitian positive semidefinite matrix A from its L or U factors and the permutation matrix P, and then it computes the residual. it's basically doing a vibe check on your factorization and ngl it does NOT miss 😀

norm( P*L*L'*P' - A ) / ( N * norm(A) * EPS ) or
norm( P*U'*U*P' - A ) / ( N * norm(A) * EPS ),

where EPS is the machine epsilon, L' is the conjugate transpose of L, and U' is the conjugate transpose of U. periodt πŸ’…


πŸŽ€ Parameters πŸŽ€

  • UPLO β€” UPLO is CHARACTER*1. it specifies whether the upper or lower triangular part of the Hermitian matrix A is stored:
    • = 'U': Upper triangular
    • = 'L': Lower triangular
  • N β€” N is INTEGER. the number of rows and columns of the matrix A. N >= 0. (no negatives bestie, we don't do that here 🚫)
  • A β€” A is COMPLEX array, dimension (LDA,N). the original Hermitian matrix A. the main character, truly πŸ‘‘
  • LDA β€” LDA is INTEGER. the leading dimension of the array A. LDA >= max(1,N).
  • AFAC β€” AFAC is COMPLEX array, dimension (LDAFAC,N). the factor L or U from the L*L' or U'*U factorization of A. she's the reconstructed glow-up ✨
  • LDAFAC β€” LDAFAC is INTEGER. the leading dimension of the array AFAC. LDAFAC >= max(1,N).
  • PERM β€” PERM is COMPLEX array, dimension (LDPERM,N). overwritten with the reconstructed matrix, and then with the difference P*L*L'*P' - A (or P*U'*U*P' - A). yes she gets overwritten TWICE, she's busy 😭
  • LDPERM β€” LDPERM is INTEGER. the leading dimension of the array PERM. LDAPERM >= max(1,N). (that's literally how the original spells it, don't come for me πŸ™ˆ)
  • PIV β€” PIV is INTEGER array, dimension (N). PIV is such that the nonzero entries are
P( PIV( K ), K ) = 1.
  • RWORK β€” RWORK is REAL array, dimension (N). that's it. that's the whole description. she's lowkey mysterious πŸ’€
  • RESID β€” RESID is REAL.
    • If UPLO = 'L', norm(L*L' - A) / ( N * norm(A) * EPS )
    • If UPLO = 'U', norm(U'*U - A) / ( N * norm(A) * EPS )
  • RANK β€” RANK is INTEGER. number of nonzero singular values of A.

πŸ‘‘ Author πŸ‘‘

  • Univ. of Tennessee
  • Univ. of California Berkeley
  • Univ. of Colorado Denver
  • NAG Ltd.
Definition at line 134 of file cpst01.f.

🌈 Author (the meta one) 🌈

Generated automatically by Doxygen for LAPACK from the source code. yeah she was birthed by a doc generator, we don't hold that against her 🫢


and that's the whole page bestie!! this was LAPACK, Version 3.12.0, served fresh from /home/abui...IN/cpst01.f(3) β€” mwah, go reconstruct something beautiful πŸ’–βœ¨πŸŽ€

πŸ“¦ where this page comes from