1818! ==================
1919! >
2020! > Weslley Pereira, University of Colorado Denver, USA
21- ! > Nick Papior, Technical University of Denmark, DNK
21+ ! > Nick Papior, Technical University of Denmark, DK
2222!
2323! > \par Further Details:
2424! =====================
3838! > \endverbatim
3939!
4040module LA_CONSTANTS
41- !
4241! -- LAPACK auxiliary module (version 3.9.0) --
4342! -- LAPACK is a software package provided by Univ. of Tennessee, --
4443! -- Univ. of California Berkeley, Univ. of Colorado Denver and NAG Ltd..--
4544! February 2021
46- !
45+
4746! Standard constants for
4847 integer , parameter :: sp = kind (1.e0 )
49- !
48+
5049 real (sp), parameter :: szero = 0.0_sp
5150 real (sp), parameter :: shalf = 0.5_sp
5251 real (sp), parameter :: sone = 1.0_sp
@@ -60,9 +59,8 @@ module LA_CONSTANTS
6059 complex (sp), parameter :: cone = ( 1.0_sp , 0.0_sp )
6160 character * 1 , parameter :: sprefix = ' S'
6261 character * 1 , parameter :: cprefix = ' C'
63- !
62+
6463! Scaling constants
65- !
6664 real (sp), parameter :: sulp = epsilon (0._sp )
6765 real (sp), parameter :: seps = sulp * 0.5_sp
6866 real (sp), parameter :: ssafmin = real (radix (0._sp ),sp)** max ( &
@@ -74,28 +72,22 @@ module LA_CONSTANTS
7472 real (sp), parameter :: sbignum = ssafmax * sulp
7573 real (sp), parameter :: srtmin = sqrt (ssmlnum)
7674 real (sp), parameter :: srtmax = sqrt (sbignum)
77- !
75+
7876! Blue's scaling constants
79- !
8077 real (sp), parameter :: stsml = real (radix (0._sp ), sp)** ceiling ( &
81- real (( minexponent (0._sp ) - 1_sp ) / 2 , sp) &
82- )
78+ (minexponent (0._sp ) - 1 ) * 0.5_sp )
8379 real (sp), parameter :: stbig = real (radix (0._sp ), sp)** floor ( &
84- real (( maxexponent (0._sp ) - digits (0._sp ) + 1_sp ) / 2 , sp) &
85- )
80+ (maxexponent (0._sp ) - digits (0._sp ) + 1 ) * 0.5_sp )
8681! ssml = 1/s, where s was defined in https://doi.org/10.1145/355769.355771
8782 real (sp), parameter :: sssml = real (radix (0._sp ), sp)** ( - floor ( &
88- real (( minexponent (0._sp ) - 1_sp ) / 2 ), sp) &
89- )
83+ (minexponent (0._sp ) - 1 ) * 0.5_sp ))
9084! ssml = 1/S, where S was defined in https://doi.org/10.1145/355769.355771
9185 real (sp), parameter :: ssbig = real (radix (0._sp ), sp)** ( - ceiling ( &
92- real (( maxexponent (0._sp ) - digits (0._sp ) + 1_sp ) / 2 ), sp) &
93- )
94- !
95- !
86+ (maxexponent (0._sp ) - digits (0._sp ) + 1 ) * 0.5_sp ))
87+
9688! Standard constants for
9789 integer , parameter :: dp = kind (1.d0 )
98- !
90+
9991 real (dp), parameter :: dzero = 0.0_dp
10092 real (dp), parameter :: dhalf = 0.5_dp
10193 real (dp), parameter :: done = 1.0_dp
@@ -109,9 +101,8 @@ module LA_CONSTANTS
109101 complex (dp), parameter :: zone = ( 1.0_dp , 0.0_dp )
110102 character * 1 , parameter :: dprefix = ' D'
111103 character * 1 , parameter :: zprefix = ' Z'
112- !
104+
113105! Scaling constants
114- !
115106 real (dp), parameter :: dulp = epsilon (0._dp )
116107 real (dp), parameter :: deps = dulp * 0.5_dp
117108 real (dp), parameter :: dsafmin = real (radix (0._dp ),dp)** max ( &
@@ -123,22 +114,17 @@ module LA_CONSTANTS
123114 real (dp), parameter :: dbignum = dsafmax * dulp
124115 real (dp), parameter :: drtmin = sqrt (dsmlnum)
125116 real (dp), parameter :: drtmax = sqrt (dbignum)
126- !
117+
127118! Blue's scaling constants
128- !
129119 real (dp), parameter :: dtsml = real (radix (0._dp ), dp)** ceiling ( &
130- real (( minexponent (0._dp ) - 1_sp ) / 2 , dp) &
131- )
120+ (minexponent (0._dp ) - 1 ) * 0.5_dp )
132121 real (dp), parameter :: dtbig = real (radix (0._dp ), dp)** floor ( &
133- real (( maxexponent (0._dp ) - digits (0._dp ) + 1_sp ) / 2 , dp) &
134- )
122+ (maxexponent (0._dp ) - digits (0._dp ) + 1 ) * 0.5_dp )
135123! ssml = 1/s, where s was defined in https://doi.org/10.1145/355769.355771
136- real (dp), parameter :: dssml = real (radix (0._dp ) ,dp)** ( - floor ( &
137- real (( minexponent (0._dp ) - 1_sp ) / 2 ), dp) &
138- )
124+ real (dp), parameter :: dssml = real (radix (0._dp ), dp)** ( - floor ( &
125+ (minexponent (0._dp ) - 1 ) * 0.5_dp ))
139126! ssml = 1/S, where S was defined in https://doi.org/10.1145/355769.355771
140127 real (dp), parameter :: dsbig = real (radix (0._dp ), dp)** ( - ceiling ( &
141- real (( maxexponent (0._dp ) - digits (0._dp ) + 1_sp ) / 2 ), dp) &
142- )
143- !
128+ (maxexponent (0._dp ) - digits (0._dp ) + 1 ) * 0.5_dp ))
129+
144130end module LA_CONSTANTS
0 commit comments