SPST01(3)

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

πŸ’… SPST01(3) β€” like, the LAPACK testing routine for reconstructing a symmetric positive semidefinite matrix, bestie ✨

okay so first things first: this page lives at /home/abuild/rpmbuild/BUILD/lapack-static-3.12.0-build/lapack-3.12.0/TESTING/LIN/spst01.f and it's part of the LAPACK library functions manual (3). That's the whole vibe. It's a testing routine, which means it exists to check that other routines did their job right β€” the hype squad of linear algebra, lowkey. πŸŽ€


✨ SYNOPSIS ✨

🌸 Functions/Subroutines

subroutine SPST01 (uplo, n, a, lda, afac, ldafac, perm, ldperm, piv,
    rwork, resid, rank)

SPST01 🫢


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

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

SPST01 ⭐

πŸ‘‘ Purpose:

!> !> SPST01 reconstructs a symmetric positive semidefinite matrix A !> from its L or U factors and the permutation matrix P and computes !> the residual !> 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. !>

So like, it takes your factors, rebuilds A from them, throws the permutation matrix P into the mix, and then measures how far off the reconstruction is from the original. It's giving "trust but verify" energy. πŸ’–

πŸ’œ Parameters

  • UPLO β€” okay so UPLO is CHARACTER*1 and it tells us which triangular half of the symmetric matrix A is actually stored:
    • = 'U': Upper triangular 🌈
    • = 'L': Lower triangular 🌸
  • N β€” N is INTEGER, the number of rows and columns of the matrix A (it's square, obvi). Constraint: N >= 0. ✨
  • A β€” A is REAL array, dimension (LDA,N). It's the original symmetric matrix A, the main character. πŸ‘‘
  • LDA β€” LDA is INTEGER, the leading dimension of the array A. Constraint: LDA >= max(1,N). Don't skimp on this one bestie. 🫢
  • AFAC β€” AFAC is REAL array, dimension (LDAFAC,N), holding the factor L or U from the L*L' or U'*U factorization of A. πŸŽ€
  • LDAFAC β€” LDAFAC is INTEGER, the leading dimension of the array AFAC. Constraint: LDAFAC >= max(1,N). πŸ’…
  • PERM β€” PERM is REAL array, dimension (LDPERM,N), and it gets overwritten with the reconstructed matrix, and then with the difference P*L*L'*P' - A (or P*U'*U*P' - A). So yeah, it's not coming back the same, fair warning πŸ™ˆ
  • LDPERM β€” LDPERM is INTEGER, the leading dimension of the array PERM. Constraint: LDAPERM >= max(1,N). (yes, the original really does spell it LDAPERM here β€” we don't fix, we report 🫑)
  • PIV β€” PIV is INTEGER array, dimension (N). PIV is such that the nonzero entries are P( PIV( K ), K ) = 1. That's the permutation, periodt. πŸ”₯
  • RWORK β€” RWORK is REAL array, dimension (N). That's it, that's the whole description. Scratch space doing its little job. 🧚
  • RESID β€” RESID is REAL, the actual residual:
    • If UPLO = 'L', it's norm(L*L' - A) / ( N * norm(A) * EPS )
    • If UPLO = 'U', it's norm(U'*U - A) / ( N * norm(A) * EPS )

iykyk πŸ’€

  • RANK β€” RANK is INTEGER, the number of nonzero singular values of A. πŸ’–

🌟 Author 🌟

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

Definition at line 132 of file spst01.f. πŸ“


πŸŽ€ Author (the meta one) πŸŽ€

Generated automatically by Doxygen for LAPACK from the source code. Not me writing fanfic, the robots did it. πŸ€–βœ¨


k bye bestie, go check those residuals πŸ’… β€” this iconic page is from LAPACK, Version 3.12.0, and it was served fresh from /home/abui...IN/spst01.f(3). Slay πŸ¦‹πŸŒΈ

πŸ“¦ where this page comes from