/home/abui...lamchf77.f(3)

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

πŸ’… /home/abui...lamchf77.f(3)

okay bestie so this one is from the Library Functions Manual and it's the whole dlamchf77.f situation β€” a little Fortran family of subroutines that go sniffing around your machine to figure out how its floating-point arithmetic actually behaves 🧚✨. Basically a vibe check for your hardware, but for numbers.


✨ NAME ✨

/home/abuild/rpmbuild/BUILD/lapack-static-3.12.0-build/lapack-3.12.0/INSTALL/dlamchf77.f

no cap, that's the whole name 😭 it's literally a file path. iykyk β€” some man pages just are a path.


🌸 SYNOPSIS 🌸

Functions/Subroutines

double precision function DLAMCH (cmach)
    DLAMCH
subroutine DLAMC1 (beta, t, rnd, ieee1)
    DLAMC1
subroutine DLAMC2 (beta, t, rnd, eps, emin, rmin, emax, rmax)
    DLAMC2
double precision function DLAMC3 (a, b)
    DLAMC3
subroutine DLAMC4 (emin, start, base)
    DLAMC4
subroutine DLAMC5 (beta, p, emin, ieee, emax, rmax)
    DLAMC5

six little icons, all in one file 🫢


πŸ‘‘ Function/Subroutine Documentation πŸ‘‘

πŸŽ€ subroutine DLAMC1 (integer beta, integer t, logical rnd, logical ieee1)

DLAMC1 Purpose:

DLAMC1 determines the machine parameters given by BETA, T, RND, and IEEE1.

she's the detective of the group πŸ” β€” goes and figures out four whole machine parameters for you.

Parameters

  • BETA β€” the base of the machine. no notes.
  • T β€” how many ( BETA ) digits fit in the mantissa.
  • RND β€” tells you whether proper rounding ( RND = .TRUE. ) or chopping ( RND = .FALSE. ) happens in addition. and lowkey it says right there that this may not be a reliable guide to how the machine actually performs its arithmetic πŸ™ˆ so don't come for her if it's a lil off.
  • IEEE1 β€” a logical flag for whether rounding appears to be done in the IEEE 'round to nearest' style.

Author

LAPACK is a software package provided by Univ. of Tennessee, Univ. of California Berkeley, Univ. of Colorado Denver and NAG Ltd..

Further Details

The routine is based on the routine ENVRON by Malcolm and incorporates suggestions by Gentleman and Marovich. See Malcolm M. A. (1972) Algorithms to reveal properties of floating-point arithmetic. Comms. of the ACM, 15, 949-951. Gentleman W. M. and Marovich S. B. (1974) More on algorithms that reveal properties of floating point arithmetic units. Comms. of the ACM, 17, 276-277.

scholarly queen πŸ‘‘ citing her sources and everything.

Definition at line 207 of file dlamchf77.f.


πŸ¦‹ subroutine DLAMC2 (integer beta, integer t, logical rnd, double precision eps, integer emin, double precision rmin, integer emax, double precision rmax)

DLAMC2 Purpose:

DLAMC2 determines the machine parameters specified in its argument list.

like DLAMC1 but with a way bigger argument list, she's doing the most and we love her for it πŸ’…

Author

LAPACK is a software package provided by Univ. of Tennessee, Univ. of California Berkeley, Univ. of Colorado Denver and NAG Ltd..

Parameters

  • BETA β€” the base of the machine.
  • T β€” the number of ( BETA ) digits in the mantissa.
  • RND β€” proper rounding ( RND = .TRUE. ) vs chopping ( RND = .FALSE. ) in addition. same caveat as before: this may not be a reliable guide to the way in which the machine performs its arithmetic.
  • EPS β€” the smallest positive number such that
fl( 1.0 - EPS ) .LT. 1.0,

where fl denotes the computed value. tiny but mighty πŸ“

  • EMIN β€” the minimum exponent before (gradual) underflow occurs.
  • RMIN β€” the smallest normalized number for the machine, given by BASE**( EMIN - 1 ), where BASE is the floating point value of BETA.
  • EMAX β€” the maximum exponent before overflow occurs.
  • RMAX β€” the largest positive number for the machine, given by BASE**EMAX * ( 1 - EPS ), where BASE is the floating point value of BETA.

Further Details

The computation of EPS is based on a routine PARANOIA by W. Kahan of the University of California at Berkeley.

PARANOIA is honestly such a name, main character energy fr fr 😭

Definition at line 418 of file dlamchf77.f.


🌈 double precision function DLAMC3 (double precision a, double precision b)

DLAMC3 Purpose:

DLAMC3 is intended to force A and B to be stored prior to doing the addition of A and B , for use in situations where optimizers might hold one of these in a register.

she's the anti-optimizer icon βœ‹ a whole routine whose job is to make sure your compiler doesn't get cute and keep stuff in a register.

Author

LAPACK is a software package provided by Univ. of Tennessee, Univ. of California Berkeley, Univ. of Colorado Denver and NAG Ltd..

Parameters

  • A β€” A is a DOUBLE PRECISION
  • B β€” B is a DOUBLE PRECISION, and also: The values A and B.

Purpose:

DLAMC3 is intended to force A and B to be stored prior to doing the addition of A and B , for use in situations where optimizers might hold one of these in a register.

(yes bestie, the purpose is listed twice on this page. the docs said it twice so i said it twice. no i will not be taking questions 🫢)

Parameters

  • A
  • B
The values A and B.

Definition at line 171 of file dlamch.f.

⚠️ heads up: that's dlamch.f, not dlamchf77.f. she's visiting from the other file. keep the receipt.

🧚 subroutine DLAMC4 (integer emin, double precision start, integer base)

DLAMC4 Purpose:

DLAMC4 is a service routine for DLAMC2.

supportive bestie role πŸ’– someone's gotta do it.

Parameters

  • EMIN β€” the minimum exponent before (gradual) underflow, computed by setting A = START and dividing by BASE until the previous A can not be recovered.
  • START β€” the starting point for determining EMIN.
  • BASE β€” the base of the machine.

Definition at line 688 of file dlamchf77.f.


⭐ subroutine DLAMC5 (integer beta, integer p, integer emin, logical ieee, integer emax, double precision rmax)

DLAMC5 Purpose:

DLAMC5 attempts to compute RMAX, the largest machine floating-point number, without overflow. It assumes that EMAX + abs(EMIN) sum approximately to a power of 2. It will fail on machines where this assumption does not hold, for example, the Cyber 205 (EMIN = -28625, EMAX = 28718). It will also fail if the value supplied for EMIN is too large (i.e. too close to zero), probably with overflow.
πŸ’€ okay so this one openly admits she can fail. two whole failure modes, spelled out. the Cyber 205 numbers are right there: EMIN = -28625, EMAX = 28718. and if you hand her an EMIN that's too large (i.e. too close to zero) she'll probably overflow. not subtle, not sorry, at least she told you.

Parameters

  • BETA β€” the base of floating-point arithmetic.
  • P β€” the number of base BETA digits in the mantissa of a floating-point value.
  • EMIN β€” the minimum exponent before (gradual) underflow.
  • IEEE β€” a logical flag specifying whether or not the arithmetic system is thought to comply with the IEEE standard.
  • EMAX β€” the largest exponent before overflow
  • RMAX β€” the largest machine floating-point number.

Definition at line 795 of file dlamchf77.f.


πŸ’œ double precision function DLAMCH (character cmach)

DLAMCH DLAMCHF77 deprecated

yes. deprecated. it's literally in the heading. read it and weep 😭 this is the f77 one, the legacy icon, she's still serving but she's officially marked.

Purpose:

DLAMCH determines double precision machine parameters.

Parameters

  • CMACH β€” CMACH is CHARACTER*1, and it specifies the value to be returned by DLAMCH:
= 'E' or 'e',   DLAMCH := eps
= 'S' or 's ,   DLAMCH := sfmin
= 'B' or 'b',   DLAMCH := base
= 'P' or 'p',   DLAMCH := eps*base
= 'N' or 'n',   DLAMCH := t
= 'R' or 'r',   DLAMCH := rnd
= 'M' or 'm',   DLAMCH := emin
= 'U' or 'u',   DLAMCH := rmin
= 'L' or 'l',   DLAMCH := emax
= 'O' or 'o',   DLAMCH := rmax

where

eps   = relative machine precision
sfmin = safe minimum, such that 1/sfmin does not overflow
base  = base of the machine
prec  = eps*base
t     = number of (base) digits in the mantissa
rnd   = 1.0 when rounding occurs in addition, 0.0 otherwise
emin  = minimum exponent before (gradual) underflow
rmin  = underflow threshold - base**(emin-1)
emax  = largest exponent before overflow
rmax  = overflow threshold  - (base**emax)*(1-eps)
⚠️ one char, one flag, ten possible answers. get the letter wrong and you get a whole different number back, so spell it right bestie.

Author

Univ. of Tennessee

Univ. of California Berkeley

Univ. of Colorado Denver

NAG Ltd.

Purpose:

DLAMCHF77 determines double precision machine parameters.

(same purpose, now under the DLAMCHF77 name. she contains multitudes ✨)

Parameters

  • CMACH β€” specifies the value to be returned by DLAMCH:
= 'E' or 'e',   DLAMCH := eps
= 'S' or 's ,   DLAMCH := sfmin
= 'B' or 'b',   DLAMCH := base
= 'P' or 'p',   DLAMCH := eps*base
= 'N' or 'n',   DLAMCH := t
= 'R' or 'r',   DLAMCH := rnd
= 'M' or 'm',   DLAMCH := emin
= 'U' or 'u',   DLAMCH := rmin
= 'L' or 'l',   DLAMCH := emax
= 'O' or 'o',   DLAMCH := rmax

where

eps   = relative machine precision
sfmin = safe minimum, such that 1/sfmin does not overflow
base  = base of the machine
prec  = eps*base
t     = number of (base) digits in the mantissa
rnd   = 1.0 when rounding occurs in addition, 0.0 otherwise
emin  = minimum exponent before (gradual) underflow
rmin  = underflow threshold - base**(emin-1)
emax  = largest exponent before overflow
rmax  = overflow threshold  - (base**emax)*(1-eps)

Author

Univ. of Tennessee

Univ. of California Berkeley

Univ. of Colorado Denver

NAG Ltd.

Definition at line 68 of file dlamch.f.


🌻 Author 🌻

Generated automatically by Doxygen for LAPACK from the source code.

(it was built by a robot, she's still iconic πŸ’…)


πŸŽ€ and that's the whole page bestie, every flag, every parameter, every failure mode. go forth and know your machine's floating-point lore 🌈

LAPACK β€” Version 3.12.0 β€” and the page itself is /home/abui...lamchf77.f(3). mwah, take care of her πŸ«ΆπŸ’–

πŸ“¦ where this page comes from