Geant4.10
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Data Structures | Functions | Variables
G4ExpConsts Namespace Reference

Data Structures

union  ieee754
 

Functions

G4double uint642dp (uint64_t ll)
 
G4float uint322sp (G4int x)
 
uint32_t sp2uint32 (G4float x)
 
G4double fpfloor (const G4double x)
 
G4float fpfloor (const G4float x)
 

Variables

const G4double EXP_LIMIT = 708
 
const G4double PX1exp = 1.26177193074810590878E-4
 
const G4double PX2exp = 3.02994407707441961300E-2
 
const G4double PX3exp = 9.99999999999999999910E-1
 
const G4double QX1exp = 3.00198505138664455042E-6
 
const G4double QX2exp = 2.52448340349684104192E-3
 
const G4double QX3exp = 2.27265548208155028766E-1
 
const G4double QX4exp = 2.00000000000000000009E0
 
const G4double LOG2E = 1.4426950408889634073599
 
const G4float MAXLOGF = 88.72283905206835f
 
const G4float MINLOGF = -88.f
 
const G4float C1F = 0.693359375f
 
const G4float C2F = -2.12194440e-4f
 
const G4float PX1expf = 1.9875691500E-4f
 
const G4float PX2expf =1.3981999507E-3f
 
const G4float PX3expf =8.3334519073E-3f
 
const G4float PX4expf =4.1665795894E-2f
 
const G4float PX5expf =1.6666665459E-1f
 
const G4float PX6expf =5.0000001201E-1f
 
const G4float LOG2EF = 1.44269504088896341f
 

Function Documentation

G4double G4ExpConsts::fpfloor ( const G4double  x)
inline

A vectorisable floor implementation, not only triggered by fast-math. These functions do not distinguish between -0.0 and 0.0, so are not IEC6509 compliant for argument -0.0

Definition at line 154 of file G4Exp.hh.

References sp2uint32().

Referenced by G4Exp(), and G4Expf().

155  {
156  // no problem since exp is defined between -708 and 708. Int is enough for it!
157  int32_t ret = int32_t (x);
158  ret-=(sp2uint32(x)>>31);
159  return ret;
160  }
uint32_t sp2uint32(G4float x)
Definition: G4Exp.hh:141
G4float G4ExpConsts::fpfloor ( const G4float  x)
inline

A vectorisable floor implementation, not only triggered by fast-math. These functions do not distinguish between -0.0 and 0.0, so are not IEC6509 compliant for argument -0.0

Definition at line 168 of file G4Exp.hh.

References sp2uint32().

169  {
170  int32_t ret = int32_t (x);
171  ret-=(sp2uint32(x)>>31);
172  return ret;
173  }
uint32_t sp2uint32(G4float x)
Definition: G4Exp.hh:141
uint32_t G4ExpConsts::sp2uint32 ( G4float  x)
inline

Definition at line 141 of file G4Exp.hh.

References G4ExpConsts::ieee754::f, G4ExpConsts::ieee754::i, and test::x.

Referenced by fpfloor().

142  {
143  ieee754 tmp;
144  tmp.f[0]=x;
145  return tmp.i[0];
146  }
G4float G4ExpConsts::uint322sp ( G4int  x)
inline

Definition at line 131 of file G4Exp.hh.

References G4ExpConsts::ieee754::f, G4ExpConsts::ieee754::i, and test::x.

Referenced by G4Expf().

132  {
133  ieee754 tmp;
134  tmp.i[0]=x;
135  return tmp.f[0];
136  }
G4double G4ExpConsts::uint642dp ( uint64_t  ll)
inline

Definition at line 121 of file G4Exp.hh.

References G4ExpConsts::ieee754::d, and G4ExpConsts::ieee754::ll.

Referenced by G4Exp().

122  {
123  ieee754 tmp;
124  tmp.ll=ll;
125  return tmp.d;
126  }

Variable Documentation

const G4float G4ExpConsts::C1F = 0.693359375f

Definition at line 88 of file G4Exp.hh.

Referenced by G4Expf().

const G4float G4ExpConsts::C2F = -2.12194440e-4f

Definition at line 89 of file G4Exp.hh.

Referenced by G4Expf().

const G4double G4ExpConsts::EXP_LIMIT = 708

Definition at line 73 of file G4Exp.hh.

Referenced by G4Exp().

const G4double G4ExpConsts::LOG2E = 1.4426950408889634073599

Definition at line 83 of file G4Exp.hh.

Referenced by G4Exp().

const G4float G4ExpConsts::LOG2EF = 1.44269504088896341f

Definition at line 98 of file G4Exp.hh.

Referenced by G4Expf().

const G4float G4ExpConsts::MAXLOGF = 88.72283905206835f

Definition at line 85 of file G4Exp.hh.

Referenced by G4Expf().

const G4float G4ExpConsts::MINLOGF = -88.f

Definition at line 86 of file G4Exp.hh.

Referenced by G4Expf().

const G4double G4ExpConsts::PX1exp = 1.26177193074810590878E-4

Definition at line 75 of file G4Exp.hh.

Referenced by G4Exp().

const G4float G4ExpConsts::PX1expf = 1.9875691500E-4f

Definition at line 91 of file G4Exp.hh.

Referenced by G4Expf().

const G4double G4ExpConsts::PX2exp = 3.02994407707441961300E-2

Definition at line 76 of file G4Exp.hh.

Referenced by G4Exp().

const G4float G4ExpConsts::PX2expf =1.3981999507E-3f

Definition at line 92 of file G4Exp.hh.

Referenced by G4Expf().

const G4double G4ExpConsts::PX3exp = 9.99999999999999999910E-1

Definition at line 77 of file G4Exp.hh.

Referenced by G4Exp().

const G4float G4ExpConsts::PX3expf =8.3334519073E-3f

Definition at line 93 of file G4Exp.hh.

Referenced by G4Expf().

const G4float G4ExpConsts::PX4expf =4.1665795894E-2f

Definition at line 94 of file G4Exp.hh.

Referenced by G4Expf().

const G4float G4ExpConsts::PX5expf =1.6666665459E-1f

Definition at line 95 of file G4Exp.hh.

Referenced by G4Expf().

const G4float G4ExpConsts::PX6expf =5.0000001201E-1f

Definition at line 96 of file G4Exp.hh.

Referenced by G4Expf().

const G4double G4ExpConsts::QX1exp = 3.00198505138664455042E-6

Definition at line 78 of file G4Exp.hh.

Referenced by G4Exp().

const G4double G4ExpConsts::QX2exp = 2.52448340349684104192E-3

Definition at line 79 of file G4Exp.hh.

Referenced by G4Exp().

const G4double G4ExpConsts::QX3exp = 2.27265548208155028766E-1

Definition at line 80 of file G4Exp.hh.

Referenced by G4Exp().

const G4double G4ExpConsts::QX4exp = 2.00000000000000000009E0

Definition at line 81 of file G4Exp.hh.

Referenced by G4Exp().