ZLASCL(3)
π¦ ZLASCL β the "scale my matrix without blowing up my floats" queen
ok so bestie, real talk: this page is from the LAPACK crew, and it lives at /home/abuild/rpmbuild/BUILD/lapack-static-3.12.0-build/lapack-3.12.0/SRC/zlascl.f β that's the file name in the header and the NAME section, iykyk. She's part of the Library Functions Manual, and she's here to make your matrix β¨prettierβ¨ by a scalar. Slay.
β¨ SYNOPSIS β¨
Functions/Subroutines
subroutine ZLASCL (type, kl, ku, cfrom, cto, m, n, a, lda, info)
ZLASCL multiplies a general rectangular matrix by a real scalar defined as cto/cfrom. That's the whole vibe.
π Function/Subroutine Documentation π
subroutine ZLASCL (character type, integer kl, integer ku, double precision
cfrom, double precision cto, integer m, integer n, complex*16,
dimension( lda, * ) a, integer lda, integer info)
Again, for the people in the back: ZLASCL multiplies a general rectangular matrix by a real scalar defined as cto/cfrom.
π― Purpose
ok so here's the tea, straight from the source comments:
!>
!> ZLASCL multiplies the M by N complex matrix A by the real scalar
!> CTO/CFROM. This is done without over/underflow as long as the final
!> result CTO*A(I,J)/CFROM does not over/underflow. TYPE specifies that
!> A may be full, upper triangular, lower triangular, upper Hessenberg,
!> or banded.
!>
So she takes your matrix A and multiplies it by CTO/CFROM, and the whole point β the main character energy of this routine β is that she does it without over/underflow, as long as the final result CTO*A(I,J)/CFROM itself doesn't over/underflow. And TYPE tells her what kind of storage your A is rocking: full, upper triangular, lower triangular, upper Hessenberg, or banded. Versatile icon π
πΈ Parameters πΈ
TYPEβ she's aCHARACTER*1, and she indices the storage type of the input matrix. The lore:
!> TYPE is CHARACTER*1
!> TYPE indices the storage type of the input matrix.
!> = 'G': A is a full matrix.
!> = 'L': A is a lower triangular matrix.
!> = 'U': A is an upper triangular matrix.
!> = 'H': A is an upper Hessenberg matrix.
!> = 'B': A is a symmetric band matrix with lower bandwidth KL
!> and upper bandwidth KU and with the only the lower
!> half stored.
!> = 'Q': A is a symmetric band matrix with lower bandwidth KL
!> and upper bandwidth KU and with the only the upper
!> half stored.
!> = 'Z': A is a band matrix with lower bandwidth KL and upper
!> bandwidth KU. See ZGBTRF for storage details.
!>
(yes, the original really says "with the only the lower half stored" and "with the only the upper half stored" β we keep the words exactly, no cap π)
KLβ anINTEGER. The lower bandwidth ofA. Only referenced ifTYPE = 'B','Q'or'Z'β otherwise she's just standing there, gorgeous, unused.KUβ anINTEGER. The upper bandwidth ofA. Same deal: only referenced ifTYPE = 'B','Q'or'Z'.CFROMβ aDOUBLE PRECISION. That's it, that's the description. (The real deets live underCTObelow, bestie, keep reading π«Ά)CTOβ aDOUBLE PRECISION. The matrixAis multiplied byCTO/CFROM.A(I,J)is computed without over/underflow if the final resultCTO*A(I,J)/CFROMcan be represented without over/underflow.CFROMmust be nonzero. Like, non-negotiable. Zero is not the vibe.Mβ anINTEGER. The number of rows of the matrixA. Constraint:M >= 0.Nβ anINTEGER. The number of columns of the matrixA. Constraint:N >= 0.Aβ aCOMPLEX*16array, dimension(LDA,N). The matrix to be multiplied byCTO/CFROM. SeeTYPEfor the storage type β she needs to know how you're storing it, bestie.LDAβ anINTEGER. The leading dimension of the arrayA. Depends onTYPE, so pay attention:
!> If TYPE = 'G', 'L', 'U', 'H', LDA >= max(1,M);
!> TYPE = 'B', LDA >= KL+1;
!> TYPE = 'Q', LDA >= KU+1;
!> TYPE = 'Z', LDA >= 2*KL+KU+1.
INFOβ anINTEGER. The vibes report:
!> 0 - successful exit
!> <0 - if INFO = -i, the i-th argument had an illegal value.
π Author
- Univ. of Tennessee
- Univ. of California Berkeley
- Univ. of Colorado Denver
- NAG Ltd.
Definition at line 142 of file zlascl.f.
β Author (the meta one)
Generated automatically by Doxygen for LAPACK from the source code. Not a human, just a robot doing robot things π€β¨
so yeah, that's the whole page, bestie. go forth and scale responsibly π
sign-off szn: this lore drop is from LAPACK, Version 3.12.0, and the page itself is /home/abui...RC/zlascl.f(3). mwah, study hard, hydrate, and may your CFROM never be zero ππ¦
π¦ where this page comes from
- opensuse-leap 16.0: lapack-man 3.12.0-160000.2.2 Β· BSD-3-Clause
- opensuse-leap 16.0: lapack-man 3.12.0-160000.2.2 Β· BSD-3-Clause
- opensuse-leap 16.0: lapack-man 3.12.0-160000.2.2 Β· BSD-3-Clause
- opensuse-leap 16.0: lapack-man 3.12.0-160000.2.2 Β· BSD-3-Clause
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms