MCPcopy Create free account
hub / github.com/numpy/numpy / dlamch_

Function dlamch_

numpy/linalg/lapack_lite/f2c_config.c:36–162  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

34static real c_b66 = 0.f;
35
36doublereal dlamch_(char *cmach)
37{
38 /* Initialized data */
39
40 static logical first = TRUE_;
41
42 /* System generated locals */
43 integer i__1;
44 doublereal ret_val;
45
46 /* Local variables */
47 static doublereal t;
48 static integer it;
49 static doublereal rnd, eps, base;
50 static integer beta;
51 static doublereal emin, prec, emax;
52 static integer imin, imax;
53 static logical lrnd;
54 static doublereal rmin, rmax, rmach;
55 extern logical lsame_(char *, char *);
56 static doublereal small, sfmin;
57 extern /* Subroutine */ int dlamc2_(integer *, integer *, logical *,
58 doublereal *, integer *, doublereal *, integer *, doublereal *);
59
60
61/*
62 -- LAPACK auxiliary routine (version 3.2) --
63 Univ. of Tennessee, Univ. of California Berkeley and NAG Ltd..
64 November 2006
65
66
67 Purpose
68 =======
69
70 DLAMCH determines double precision machine parameters.
71
72 Arguments
73 =========
74
75 CMACH (input) CHARACTER*1
76 Specifies the value to be returned by DLAMCH:
77 = 'E' or 'e', DLAMCH := eps
78 = 'S' or 's , DLAMCH := sfmin
79 = 'B' or 'b', DLAMCH := base
80 = 'P' or 'p', DLAMCH := eps*base
81 = 'N' or 'n', DLAMCH := t
82 = 'R' or 'r', DLAMCH := rnd
83 = 'M' or 'm', DLAMCH := emin
84 = 'U' or 'u', DLAMCH := rmin
85 = 'L' or 'l', DLAMCH := emax
86 = 'O' or 'o', DLAMCH := rmax
87
88 where
89
90 eps = relative machine precision
91 sfmin = safe minimum, such that 1/sfmin does not overflow
92 base = base of the machine
93 prec = eps*base

Callers

nothing calls this directly

Calls 3

dlamc2_Function · 0.85
pow_diFunction · 0.85
lsame_Function · 0.85

Tested by

no test coverage detected