SRC/classq.f90(3)

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

🌸 NAME 🌸

SRC/classq.f90 β€” hi bestie πŸ’– this is the SRC/classq.f90(3) page from the Library Functions Manual, and it's all about the classq subroutine. No cap. ✨

✨ SYNOPSIS ✨

πŸ¦‹ Functions/Subroutines πŸ¦‹

  • subroutine classq (n, x, incx, scale, sumsq) β€” CLASSQ updates a sum of squares represented in scaled form.

πŸ’… Function/Subroutine Documentation πŸ’…

subroutine classq (integer n, complex(wp), dimension(*) x, integer incx,
    real(wp) scale, real(wp) sumsq)

CLASSQ updates a sum of squares represented in scaled form. 🫢

🌟 Purpose 🌟

Okay so CLASSQ returns the values scale_out and sumsq_out such that

(scale_out**2)*sumsq_out = x( 1 )**2 +...+ x( n )**2 + (scale**2)*sumsq,

where x( i ) = X( 1 + ( i - 1 )*INCX ). The value of sumsq is assumed to be non-negative. Important vibe check: scale and sumsq must be supplied in SCALE and SUMSQ, and scale_out and sumsq_out are overwritten on SCALE and SUMSQ respectively. πŸ’…

πŸŽ€ Parameters πŸŽ€

N

N is INTEGER. It's the number of elements to be used from the vector x. πŸ“

X

X is COMPLEX array, dimension (1+(N-1)*abs(INCX)). It's the vector for which a scaled sum of squares is computed:

x( i ) = X( 1 + ( i - 1 )*INCX ), 1 <= i <= n.

INCX

INCX is INTEGER. It's the increment between successive values of the vector x. πŸ¦‹

  • If INCX > 0, X(1+(i-1)*INCX) = x(i) for 1 <= i <= n
  • If INCX < 0, X(1-(n-i)*INCX) = x(i) for 1 <= i <= n
  • If INCX = 0, x isn't a vector so there is no need to call this subroutine. If you call it anyway, it will count x(1) in the vector norm N times. Not me warning you, but bestie, that's what it does. 😭

SCALE

SCALE is REAL. On entry, the value scale in the equation above. On exit, SCALE is overwritten by scale_out, the scaling factor for the sum of squares. ✨

SUMSQ

SUMSQ is REAL. On entry, the value sumsq in the equation above. On exit, SUMSQ is overwritten by sumsq_out, the basic sum of squares from which scale_out has been factored out. πŸ’–

πŸ–‹οΈ Author πŸ–‹οΈ

Edward Anderson, Lockheed Martin

πŸ‘― Contributors πŸ‘―

  • Weslley Pereira, University of Colorado Denver, USA
  • Nick Papior, Technical University of Denmark, DK

🌈 Further Details 🌈

Definition at line 123 of file classq.f90. πŸ‘‘

πŸ–‹οΈ Author πŸ–‹οΈ

Generated automatically by Doxygen for LAPACK from the source code.


okay bestie, that's the whole page πŸ’…βœ¨ the footer tea is LAPACK, Version 3.12.0, source SRC/classq.f90(3) β€” and there's no date in that footer, so I'm not inventing one, periodt. πŸ«ΆπŸŽ€

πŸ“¦ where this page comes from