TESTING/LIN/spot02.f(3)

πŸ“¦
version 3.12.1 Β· 2 versions
, in arch rolling

πŸ’… TESTING/LIN/spot02.f(3) β€” the spot02 era

ok so bestie, welcome to the manual page for TESTING/LIN/spot02.f(3), aka the LAPACK library functions manual entry for a lil testing subroutine that has ONE job and does it gorgeously. come sit, i'll walk you through it πŸ’–


✨ NAME ✨

TESTING/LIN/spot02.f β€” like, literally that. that's the name. it's the file, it's the vibe, it's giving "i live in the TESTING/LIN directory and i'm proud" πŸŽ€


✨ SYNOPSIS ✨

Functions/Subroutines

  • subroutine spot02 (uplo, n, nrhs, a, lda, x, ldx, b, ldb, rwork, resid) β€” SPOT02. yes she's a subroutine, yes she takes eleven arguments, yes she ate πŸ”₯

✨ Function/Subroutine Documentation ✨

subroutine spot02 (character uplo, integer n, integer nrhs, real, dimension( lda, * ) a, integer lda, real, dimension( ldx, * ) x, integer ldx, real, dimension( ldb, * ) b, integer ldb, real, dimension( * ) rwork, real resid)

SPOT02 🫢 (the full signature in all its character/integer/real glory, dimension( lda, * ), dimension( ldx, * ), dimension( ldb, * ), dimension( * ) and all β€” no cap, that's the whole thing)


πŸ¦‹ Purpose πŸ¦‹

!> !> SPOT02 computes the residual for the solution of a symmetric system !> of linear equations A*x = b: !> !> RESID = norm(B - A*X) / ( norm(A) * norm(X) * EPS ), !> !> where EPS is the machine epsilon. !>

so basically she computes the residual for solving a symmetric system of linear equations A*x = b, and the formula is literally:

RESID = norm(B - A*X) / ( norm(A) * norm(X) * EPS )

where EPS is the machine epsilon, obviously πŸ’… it's giving "how wrong is my answer, scaled so the number actually means something" and honestly? iconic.


πŸŽ€ Parameters πŸŽ€

  • UPLO β€” ok so UPLO is CHARACTER*1 and it tells us whether the upper or lower triangular part of the symmetric matrix A is the one being stored:
    • = 'U': Upper triangular
    • = 'L': Lower triangular
  • N β€” N is INTEGER, and it's the number of rows and columns of the matrix A. constraint era: N >= 0. πŸ™ˆ
  • NRHS β€” NRHS is INTEGER, the number of columns of B, the matrix of right hand sides. also constrained: NRHS >= 0. ✨
  • A β€” A is REAL array, dimension (LDA,N) β€” and it's the original symmetric matrix A. the main character, lowkey πŸ‘‘
  • LDA β€” LDA is INTEGER, the leading dimension of the array A. rule of the land: LDA >= max(1,N) 🧚
  • X β€” X is REAL array, dimension (LDX,NRHS) β€” the computed solution vectors for the system of linear equations. bestie did her math and here's the receipts πŸ’–
  • LDX β€” LDX is INTEGER, the leading dimension of the array X. requirement: LDX >= max(1,N). note the double space in the original, we love a careless space 🌸
  • B β€” B is REAL array, dimension (LDB,NRHS). on entry, it's the right hand side vectors for the system of linear equations. on exit, B is overwritten with the difference B - A*X. ⚠️ girly gets DESTROYED β€” she comes in as the RHS and leaves as the difference. know that before you hand her over 😭
  • LDB β€” LDB is INTEGER, the leading dimension of the array B. requirement: LDB >= max(1,N) πŸ’œ
  • RWORK β€” RWORK is REAL array, dimension (N). that's it. that's the whole description. she's a workspace and she's mysterious πŸ“
  • RESID β€” RESID is REAL, and it's the maximum over the number of right hand sides of:
norm(B - A*X) / ( norm(A) * norm(X) * EPS )

so like, the worst-case residual across all your right hand sides. the final score. the vibe check result ⭐


πŸ‘‘ Author πŸ‘‘

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

a whole committee of legends, fr fr 🫢

Definition at line 125 of file spot02.f. πŸ“


🌈 Author 🌈

Generated automatically by Doxygen for LAPACK from the source code. (so nobody wrote this prose, a robot did, and honestly? she tried her best πŸ’€)


ok that's the whole page bestie, no details left behind, periodt. this came to you straight from TESTING/LIN/spot02.f(3) in LAPACK Version 3.12.0 β€” go forth and check those residuals, and remember: B gets overwritten, so don't come crying to me πŸ˜­πŸ’–βœ¨

πŸ“¦ where this page comes from