Main Page | Alphabetical List | Class List | File List | Class Members | File Members

float.h

Go to the documentation of this file.
00001 /*-------------------------------------------------------------------------------
00002  * /
00003  * / apeNEXT float definitions for nlcc
00004  * /
00005  * / $Id: float.h,v 1.20 2005/06/08 14:06:53 pleiter Exp $
00006  * /
00007  * / ISO/IEC 9899:1999 (E) Standard
00008  * / #include <float.h>
00009  * /
00010  * / IMPLEMENTATION for APEnext: possible                               (float.h)   
00011  * /----------------------------------------------------------------------------*/
00012 
00013 #ifndef _FLOAT_H
00014 #define _FLOAT_H
00015 
00016 #include <nlibc.h>
00017 
00018 /*-------------------------------------------------------------------------------
00019  * /
00020  * / This header-file gives the characteristics of floating-point numbers on 
00021  * / particular implementation. It specifies precision, range etc., 
00022  * / for all the floating-point data types available. 
00023  * /
00024  * / The initial FLT, DBL or LDBL refers to the three floating point 
00025  * / numeric data types. The items with MAX or MIN after the type 
00026  * / give the largest and smallest positive number, those with MANT_DIG 
00027  * / give the number of significant decimal digits, those with EPSILON 
00028  * / give the least number that can be added to 1.0 and cause a change. 
00029  * / 
00030  * / For understanding the other items remember that floating-point 
00031  * / numbers are stored internally in the following form: 
00032  * /    -float-number = {mantissa} multiplied by {radix} to the power {exponent},
00033  * /     where mantissa is always less than 1.
00034  * /    -The maximum and minimum exponent is defined both as a power of 10 
00035  * /     (MAX_10_EXP and MIN_10_EXP) and as a power of the radix 
00036  * /     (MAX_EXP and MIN_EXP), 
00037  * /    -the radix itself being FLT_RADIX. The number of radix digits 
00038  * /     (bits if the radix is 2) is defined by the MANT_DIG items. 
00039  * /
00040  * / Normalized means that the floating-point f not equal to zero if f>0;
00041  * / f is the non-negative intergers (< base or radix) or significand digits)
00042  * /
00043  * /----------------------------------------------------------------------------*/
00044 
00045 
00046 /*--------------------------------------------------------------------------------
00047  * / NAME   
00048  * /           FLT_ROUNDS - rounding modes
00049  * /
00050  * / SYNOPSIS
00051  * /           #include <float.h>
00052  * /
00053  * /           #define FLT_ROUNT {-1,0,1,2,3}
00054  * /
00055  * / DESCRIPTION
00056  * /           FLT_ROUNDS indicates to the rounding mode for floats point values: 
00057  * /           -1, undetermined 
00058  * /           0 toward zero 
00059  * /           1 to the nearest 
00060  * /           2 towards positive infinity 
00061  * /           3 towards negative infinity
00062  * /
00063  * / Notes
00064  * /           The floating-point representation in apeNEXT is inasmach as 
00065  * /           fixed hardware-impemented, we might not need to redefind its 
00066  * /           rounding modes. But at this prestage we cannot exclude the need
00067  * /           for rounding in certain claculation.
00068  * /            
00069  * / IMPLEMENTATION for APEnext: possible       (consulting)          (FLT_ROUNDS) 
00070  * /----------------------------------------------------------------------------*/
00071 #ifndef FLT_ROUNDS
00072 #define FLT_ROUNDS 1  
00073 #endif
00074 
00075 /*-------------------------------------------------------------------------------
00076  * / NAME   
00077  * /           FLT_EVAL_METHOD - evaluation formats
00078  * /
00079  * / SYNOPSIS
00080  * /           #include <float.h>
00081  * /
00082  * /           #define FLT_EVAL_METHOD {-1,0,1,2}
00083  * /
00084  * / DESCRIPTION
00085  * /           FLT_EVAL_METHOD defines the evaluation methos used to determine 
00086  * /           the evaluation formats of all floating types. It defines the 
00087  * /           precision/representation of operations proceeded with foating-point
00088  * /       
00089  * / RETURN VALUE
00090  * /           None
00091  * /
00092  * / Notes           
00093  * /           If-1, range and precision of evaluation are not determined.
00094  * /           If 0, all operations and constants will be 
00095  * /                 evaluated to the range and precisions of the current type.
00096  * /           If 1, all operations and constants of types 
00097  * /                 float and double will be evaluated to the range and precisions 
00098  * /                 of double (long double will be evaluated as long double also).
00099  * /                 Also the product of two floating_complex 
00100  * /                 operands is represented in double _Complex format, 
00101  * /                 and its parts are evaluated to double. 
00102  * /           If 2, all operations and constants will be 
00103  * /                 evaluated to the range and precision of long double.
00104  * /
00105  * / IMPLEMENTATION for APEnext:  possible                         FLT_EVAL_METHOD 
00106  * /-----------------------------------------------------------------------------*/
00107 #ifndef FLT_EVAL_METHOD
00108 #define FLT_EVAL_METHOD 0
00109 #endif
00110 
00111 /*----------------------------------------------------------------------------------
00112  * / NAME   
00113  * /           FLT_RADIX - (base) radix representation of the exponent
00114  * /
00115  * / SYNOPSIS
00116  * /           #include <float.h>
00117  * /
00118  * /           #define FLT_RADIX {2,8,10,16}
00119  * /
00120  * / DESCRIPTION
00121  * /           FLT_RADIX is the radix of exponent representing (or the base) 
00122  * /           typically defined as 2 (binary), 
00123  * /           but there are other definitions like  8, 10, 16
00124  * /              8  is octal,
00125  * /              10 is the normal decimal, 
00126  * /              16 is Hex, representations
00127  * /
00128  * / RETURN VALUE
00129  * /           None
00130  * /
00131  * / Notes    
00132  * /       
00133  * / IMPLEMENTATION for APEnext:  possible                            (FLT_RADIX) 
00134  * /----------------------------------------------------------------------------*/
00135 #ifndef FLT_RADIX
00136 #define FLT_RADIX 2
00137 #endif
00138 
00139 /*--------------------------------------------------------------------------------
00140  * / NAME   
00141  * /           FLT_MANT_DIG - number of base-FLT_RADIX digits
00142  * /
00143  * / SYNOPSIS
00144  * /           #include <float.h>
00145  * /
00146  * /           #define FLT_MANT_DIG 
00147  * /
00148  * / DESCRIPTION
00149  * /           FLT_MANT_DIG defines the number of base-FLT_RADIX digits 
00150  * /           in the floating-point significant p. 
00151  * /
00152  * / RETURN VALUE
00153  * /           None
00154  * /
00155  * / Notes    
00156  * /           It belongs to FLT_RADIX like DBL_MANT_DIG, LDBL_MANT_DIG.
00157  * /           According to EC 60559 FLT_MANT_DIG has 53 bit 
00158  * /           (where mantissa is always less than 1)
00159  * / 
00160  * / IMPLEMENTATION for APEnext:   possible                         (FLT_MANT_DIG) 
00161  * /-----------------------------------------------------------------------------*/
00162 #ifndef FLT_MANT_DIG 
00163 #define FLT_MANT_DIG 53  
00164 #endif
00165 
00166 /*--------------------------------------------------------------------------------
00167  * / NAME   
00168  * /           DBL_MANT_DIG - number of digits in the number
00169  * /
00170  * / SYNOPSIS
00171  * /           #include <float.h>
00172  * /
00173  * /           #define DBL_MANT_DIG 
00174  * /
00175  * / DESCRIPTION
00176  * /           DBL_MANT_DIG defines the number of base-FLT_RADIX digits 
00177  * /           in the double floating-point significant p. 
00178  * /
00179  * / RETURN VALUE
00180  * /           None
00181  * /
00182  * / Notes    
00183  * /           apeNEXT does not distengwish anywhere between LDBL, DBL and FLT
00184  * /    
00185  * / IMPLEMENTATION for APEnext:   possible                         (DBL_MANT_DIG) 
00186  * /-----------------------------------------------------------------------------*/
00187 #ifndef DBL_MANT_DIG 
00188 #define DBL_MANT_DIG FLT_MANT_DIG 
00189 #endif
00190 
00191 /*--------------------------------------------------------------------------------
00192  * / NAME   
00193  * /           LDBL_MANT_DIG - number of digits in the number
00194  * /
00195  * / SYNOPSIS
00196  * /           #include <float.h>
00197  * /
00198  * /           #define LDBL_MANT_DIG
00199  * /
00200  * / DESCRIPTION
00201  * /           LDBL_MANT_DIG defines the number of base-FLT_RADIX digits 
00202  * /           in the long double floating-point significant p. 
00203  * /
00204  * / RETURN VALUE
00205  * /           None
00206  * /
00207  * / Notes    
00208  * /          
00209  * / IMPLEMENTATION for APEnext:  possible                         (LDBL_MANT_DIG) 
00210  * /-----------------------------------------------------------------------------*/
00211 #ifndef LDBL_MANT_DIG  
00212 #define LDBL_MANT_DIG  DBL_MANT_DIG
00213 #endif
00214 
00215 /*--------------------------------------------------------------------------------
00216  * / NAME   
00217  * /           DECIMAL_DIG -  number of decimals
00218  * /
00219  * / SYNOPSIS
00220  * /           #include <float.h>
00221  * /
00222  * /           #define DECIMAL_DIG 
00223  * /
00224  * / DESCRIPTION
00225  * /           Number of decimal digits, n, such that any floating-point 
00226  * /           number in the widest supported floating type with pmax 
00227  * /           radix b digits can be rounded to a floating-point number 
00228  * /           with n decimal digits and back again without 
00229  * /           change to the value.
00230  * /              [p * log_{10} b]       if b is a power of 10
00231  * /              [1 + p * log_{10} b]   otherwise
00232  * /  
00233  * / RETURN VALUE
00234  * /           None
00235  * /
00236  * / Notes    
00237  * /
00238  * / IMPLEMENTATION for APEnext:    possible                         (DECIMAL_DIG) 
00239  * /-----------------------------------------------------------------------------*/
00240 #undef DECIMAL_DIG
00241 #if LDBL_MANT_DIG == 53
00242 #define DECIMAL_DIG  17
00243 #else
00244 #define DECIMAL_DIG  36
00245 #endif
00246 
00247 
00248 /*--------------------------------------------------------------------------------
00249  * / NAME   
00250  * /           FLT_DIG - minimun negative interger for exponent in FLT_RADIX
00251  * /
00252  * / SYNOPSIS
00253  * /           #include <float.h>
00254  * /
00255  * /           #define FLT_DIG 
00256  * /
00257  * / DESCRIPTION
00258  * /           FLT_DIG is the minimum negative integer value, q, such that 
00259  * /           any floaring-point number with q decimal digits can be rounded
00260  * /           into a floating-point number with p radix b digits and back 
00261  * /           again without change to the q decimal digits and the value
00262  * /                p*log_{10} b     + 1 if b is a power of 10 
00263  * /           [1 - p*log_{10} b]    + 0 otherwise
00264  * /
00265  * / RETURN VALUE
00266  * /           None
00267  * /
00268  * / Notes    
00269  * /           The value of this macro is supposed to be at least 6, 
00270  * /           to satisfy ISO c
00271  * /
00272  * / IMPLEMENTATION for APEnext:   possible                              (FLT_DIG) 
00273  * /-----------------------------------------------------------------------------*/
00274 #ifndef FLT_DIG 
00275 #define FLT_DIG 17
00276 #endif
00277 
00278 /*---------------------------------------------------------------------------------
00279  * / NAME   
00280  * /           DBL_DIG - minimun negative interger for exponent in FLT_RADIX
00281  * /
00282  * / SYNOPSIS
00283  * /           #include <float.h>
00284  * /
00285  * /           #define DBL_DIG 
00286  * /
00287  * / DESCRIPTION
00288  * /           DBL_DIG The minimum negative integer value for an exponent 
00289  * /           in base FLT_RADIX. DBL_DIG is number of digits of precision 
00290  * /           in a double type. 
00291  * /
00292  * / RETURN VALUE
00293  * /           None
00294  * /
00295  * / Notes    
00296  * /           Number of decimal digits, q, such that any floating-point number 
00297  * /           with q decimal digits can be rounded into a floating-point number 
00298  * /           with p radix b digits and back again without change to the q 
00299  * /           decimal digits.
00300  * /               [p log_{10} b]   [(p-1) log_{10} b]
00301  * /
00302  * / IMPLEMENTATION for APEnext:    possible                             (DBL_DIG) 
00303  * /-----------------------------------------------------------------------------*/
00304 #ifndef DBL_DIG 
00305 #define DBL_DIG FLT_DIG
00306 #endif
00307 
00308 /*---------------------------------------------------------------------------------
00309  * / NAME   
00310  * /           LDBL_DIG - minimun negative interger for exponent in FLT_RADIX
00311  * /
00312  * / SYNOPSIS
00313  * /           #include <float.h>
00314  * /
00315  * /           #define LDBL_DIG 
00316  * /
00317  * / DESCRIPTION
00318  * /           LDBL_DIG The minimum negative integer value for an exponent 
00319  * /           in base FLT_RADIX. LDBL_DIG is number of digits of precision 
00320  * /           in a double type. 
00321  * /
00322  * / RETURN VALUE
00323  * /           None
00324  * /
00325  * / Notes    
00326  * /           Number of decimal digits, q, such that any floating-point number 
00327  * /           with q decimal digits can be rounded into a floating-point number 
00328  * /           with p radix b digits and back again without change to the q 
00329  * /           decimal digits.
00330  * /               [p log_{10} b]   [(p-1) log_{10} b]
00331  * /
00332  * / IMPLEMENTATION for APEnext:   possible                             (LDBL_DIG) 
00333  * /-----------------------------------------------------------------------------*/
00334 #ifndef LDBL_DIG 
00335 #define LDBL_DIG DBL_DIG
00336 #endif
00337 
00338 /*---------------------------------------------------------------------------------
00339  * / NAME   
00340  * /           FLT_MIN_EXP - minimun negative that FLT_RADIX to n-1
00341  * /
00342  * / SYNOPSIS
00343  * /           #include <float.h>
00344  * /
00345  * /           #define FLT_MIN_EXP 
00346  * /
00347  * / DESCRIPTION  
00348  * /           Minimum negative integer such that FLT_RADIX raised to that power 
00349  * /           minus 1 is a normalized floating-point number e_{min}, 
00350  * /
00351  * / Notes    
00352  * /
00353  * / IMPLEMENTATION for APEnext:    possible                         (FLT_MIN_EXP) 
00354  * /-----------------------------------------------------------------------------*/
00355 #ifndef FLT_MIN_EXP 
00356 #define FLT_MIN_EXP (-1024)
00357 #endif
00358 
00359 /*--------------------------------------------------------------------------------
00360  * / NAME   
00361  * /           DBL_MIN_EXP - minimun negative that FLT_RADIX to n-1
00362  * /
00363  * / SYNOPSIS
00364  * /           #include <float.h>
00365  * /
00366  * /           #define DBL_MIN_EXP 
00367  * /
00368  * / DESCRIPTION  
00369  * /           Minimum negative integer such that FLT_RADIX raised to that power 
00370  * /           minus 1 is a normalized floating-point number e_{min}, 
00371  * /
00372  * / Notes    
00373  * /
00374  * / IMPLEMENTATION for APEnext:    possible                         (DBL_MIN_EXP) 
00375  * /-----------------------------------------------------------------------------*/
00376 #ifndef DBL_MIN_EXP
00377 #define DBL_MIN_EXP FLT_MIN_EXP 
00378 #endif
00379 
00380 /*---------------------------------------------------------------------------------
00381  * / NAME   
00382  * /           LDBL_MIN_EXP -  minimun negative that FLT_RADIX to n-1
00383  * /
00384  * / SYNOPSIS
00385  * /           #include <float.h>
00386  * /
00387  * /           #define LDBL_MIN_EXP 
00388  * /
00389  * / DESCRIPTION  
00390  * /           Minimum negative integer such that FLT_RADIX raised to that power 
00391  * /           minus 1 is a normalized floating-point number e_{min}, 
00392  * /
00393  * / Notes    
00394  * /
00395  * / IMPLEMENTATION for APEnext:    possible                        (LDBL_MIN_EXP) 
00396  * /-----------------------------------------------------------------------------*/
00397 #ifndef LDBL_MIN_EXP 
00398 #define LDBL_MIN_EXP DBL_MIN_EXP
00399 #endif
00400 
00401 /*---------------------------------------------------------------------------------
00402  * / NAME   
00403  * /           FLT_MIN_10_EXP - ninimum negative integer for exponent in base 10
00404  * /
00405  * / SYNOPSIS
00406  * /           #include <float.h>
00407  * /
00408  * /           #define FLT_MIN_10_EXP 
00409  * /
00410  * / DESCRIPTION  
00411  * /            FLT_MIN_10_EXP is the minimum negative integer value for an 
00412  * /            exponent in base 10 (float)
00413  * /
00414  * / Note
00415  * /            Minimum int x such that 10**x is a normalised float 
00416  * /            log_10 b^{e_min}
00417  * /  
00418  * / IMPLEMENTATION for APEnext:    possible                      (FLT_MIN_10_EXP) 
00419  * /-----------------------------------------------------------------------------*/
00420 #ifndef FLT_MIN_10_EXP 
00421 #define FLT_MIN_10_EXP (-307)
00422 #endif
00423 
00424 /*--------------------------------------------------------------------------------
00425  * / NAME   
00426  * /           DBL_MIN_10_EXP -  ninimum negative integer for exponent in base 10
00427  * /
00428  * / SYNOPSIS
00429  * /           #include <float.h>
00430  * /
00431  * /           #define DBL_MIN_10_EXP 
00432  * /
00433  * / DESCRIPTION  
00434  * /            DBL_MIN_10_EXP is the minimum negative integer value for an 
00435  * /            exponent in base 10 (double float)
00436  * /
00437  * / Note
00438  * /            Minimum int x such that 10**x is a normalised double float 
00439  * /  
00440  * / IMPLEMENTATION for APEnext:    possible                      (DBL_MIN_10_EXP) 
00441  * /-----------------------------------------------------------------------------*/
00442 #ifndef DBL_MIN_10_EXP
00443 #define DBL_MIN_10_EXP FLT_MIN_10_EXP
00444 #endif
00445 
00446 /*---------------------------------------------------------------------------------
00447  * / NAME   
00448  * /           LDBL_MIN_10_EXP - ninimum negative integer for exponent in base 10
00449  * /
00450  * / SYNOPSIS
00451  * /           #include <float.h>
00452  * /
00453  * /           #define LDBL_MIN_10_EXP 
00454  * /
00455  * / DESCRIPTION  
00456  * /            LDBL_MIN_10_EXP is the minimum negative integer value for an 
00457  * /            exponent in base 10 (long double float)
00458  * /
00459  * / Note
00460  * /            Minimum int x such that 10**x is a normalised long double float 
00461  * /  
00462  * / IMPLEMENTATION for APEnext: possible                        (LDBL_MIN_10_EXP) 
00463  * /-----------------------------------------------------------------------------*/
00464 #ifndef LDBL_MIN_10_EXP 
00465 #define LDBL_MIN_10_EXP FLT_MIN_10_EXP
00466 #endif
00467 
00468 /*--------------------------------------------------------------------------------
00469  * / NAME   
00470  * /           FLT_MAX_10_EXP - maximum negative integer for exponent in base 10
00471  * /
00472  * / SYNOPSIS
00473  * /           #include <float.h>
00474  * /
00475  * /           #define FLT_MAX_10_EXP 
00476  * /
00477  * / DESCRIPTION  
00478  * /            FLT_MAX_10_EXP is the maximum negative integer value for an 
00479  * /            exponent in base 10 (float)
00480  * /
00481  * / Note
00482  * /            Maximum int x such that 10**x is a normalised float 
00483  * /            log_10 ([1-b^{-p}] b^{e_max})
00484  * /  
00485  * / IMPLEMENTATION for APEnext:   possible                       (FLT_MAX_10_EXP) 
00486  * /-----------------------------------------------------------------------------*/
00487 #ifndef FLT_MAX_10_EXP 
00488 #define FLT_MAX_10_EXP (+308)
00489 #endif
00490 
00491 /*---------------------------------------------------------------------------------
00492  * / NAME   
00493  * /           DBL_MAX_10_EXP - maximum negative integer for exponent in base 10
00494  * /
00495  * / SYNOPSIS
00496  * /           #include <float.h>
00497  * /
00498  * /           #define DBL_MAX_10_EXP 
00499  * /
00500  * / DESCRIPTION  
00501  * /            DBL_MAX_10_EXP is the maximum negative integer value for an 
00502  * /            exponent in base 10 (double float)
00503  * /
00504  * / Note
00505  * /            Maximum int x such that 10**x is a normalised double float 
00506  * /  
00507  * / IMPLEMENTATION for APEnext:    possible                      (DBL_MAX_10_EXP) 
00508  * /-----------------------------------------------------------------------------*/
00509 #ifndef DBL_MAX_10_EXP 
00510 #define DBL_MAX_10_EXP FLT_MAX_10_EXP
00511 #endif
00512 
00513 /*--------------------------------------------------------------------------------
00514  * / NAME   
00515  * /           LDBL_MAX_10_EXP - maximum negative integer for exponent in base 10
00516  * /
00517  * / SYNOPSIS
00518  * /           #include <float.h>
00519  * /
00520  * /           #define LDBL_MAX_10_EXP 
00521  * /
00522  * / DESCRIPTION  
00523  * /            LDBL_MAX_10_EXP is the maximum negative integer value for an 
00524  * /            exponent in base 10 (long double float)
00525  * /
00526  * / Note
00527  * /            Maximum int x such that 10**x is a normalised long double float 
00528  * /  
00529  * / IMPLEMENTATION for APEnext:   possible                     (LDBL_MAX_10_EXP) 
00530  * /----------------------------------------------------------------------------*/
00531 #ifndef LDBL_MAX_10_EXP 
00532 #define LDBL_MAX_10_EXP FLT_MAX_10_EXP
00533 #endif
00534 
00535 /*--------------------------------------------------------------------------------
00536  * / NAME   
00537  * /           FLT_MAX_EXP - maximun negative that FLT_RADIX to n-1
00538  * /
00539  * / SYNOPSIS
00540  * /           #include <float.h>
00541  * /
00542  * /           #define FLT_MAX_EXP 
00543  * /
00544  * / DESCRIPTION  
00545  * /           FLT_MAX_EXP the maximum number n such that base to the power 
00546  * /           of n-1 (float). The minimum negative integer value for an 
00547  * /           exponent in base FLT_RADIX
00548  * /
00549  * / Notes    
00550  * /           Maximum negative integer such that FLT_RADIX raised to that power 
00551  * /           minus 1 is a normalized floating-point number e_{min}, 
00552  * /           In apeNEXT the exponent has 11 bit
00553  * /
00554  * / IMPLEMENTATION for APEnext:    possible                         (FLT_MAX_EXP) 
00555  * /-----------------------------------------------------------------------------*/
00556 #ifndef FLT_MAX_EXP
00557 #define FLT_MAX_EXP (+1023)
00558 #endif
00559 
00560 /*--------------------------------------------------------------------------------
00561  * / NAME   
00562  * /           DBL_MAX_EXP -  maximun negative that FLT_RADIX to n-1
00563  * /
00564  * / SYNOPSIS
00565  * /           #include <float.h>
00566  * /
00567  * /           #define DBL_MAX_EXP 
00568  * /
00569  * / DESCRIPTION  
00570  * /           DBL_MAX_EXP the maximum number n such that base to the power 
00571  * /           of n-1 (double float). The minimum negative integer value for an 
00572  * /           exponent in base FLT_RADIX
00573  * /
00574  * / Notes    
00575  * /           Maximum negative integer such that FLT_RADIX raised to that power 
00576  * /           minus 1 is a normalized floating-point number e_{min}, 
00577  * /           In apeNEXT the exponent has 11 bit
00578  * /
00579  * / IMPLEMENTATION for APEnext:    possible                         (DBL_MAX_EXP) 
00580  * /-----------------------------------------------------------------------------*/
00581 #ifndef DBL_MAX_EXP
00582 #define DBL_MAX_EXP FLT_MAX_EXP
00583 #endif
00584 
00585 
00586 /*---------------------------------------------------------------------------------
00587  * / NAME   
00588  * /           LDBL_MAX_EXP -  maximun negative that FLT_RADIX to n-1
00589  * /
00590  * / SYNOPSIS
00591  * /           #include <float.h>
00592  * /
00593  * /           #define LDBL_MAX_EXP 
00594  * /
00595  * / DESCRIPTION  
00596  * /           LDBL_MAX_EXP the maximum number n such that base to the power 
00597  * /           of n-1 (long double float). The minimum negative integer 
00598  * /           value for an exponent in base FLT_RADIX
00599  * /
00600  * / Notes    
00601  * /           Maximum negative integer such that FLT_RADIX raised to that power 
00602  * /           minus 1 is a normalized floating-point number e_{min}, 
00603  * /           In apeNEXT the exponent has 11 bit
00604  * /
00605  * / IMPLEMENTATION for APEnext:    possible                       (LDBL_MAX_EXP) 
00606  * /-----------------------------------------------------------------------------*/
00607 #ifndef LDBL_MAX_EXP 
00608 #define LDBL_MAX_EXP DBL_MAX_EXP
00609 #endif
00610 
00611 
00612 /*---------------------------------------------------------------------------------
00613  * / NAME   
00614  * /           FLT_MAX - maximum normalized finite representable value 
00615  * /                     of type float
00616  * /
00617  * / SYNOPSIS
00618  * /           #include <float.h>
00619  * /
00620  * /           #define FLT_MAX 
00621  * /
00622  * / DESCRIPTION  
00623  * /           Maximum floating-point value 
00624  * /
00625  * / Note
00626  * /           (1-b^{p}) b^{e_{max}} 
00627  * /           (1.-pow(2.,-52.))*pow(2.,1023) = 
00628  * /            8.9884656743115775E+307 
00629  * /
00630  * / IMPLEMENTATION for APEnext:    possible                            (FLT_MAX) 
00631  * /-----------------------------------------------------------------------------*/
00632 #ifndef FLT_MAX 
00633 #define FLT_MAX 1.7976931348623157E+308 
00634 #endif 
00635 
00636 /*--------------------------------------------------------------------------------
00637  * / NAME   
00638  * /           DBL_MAX - maximun normalized finite representable value 
00639  * /                     of type double float
00640  * /
00641  * / SYNOPSIS
00642  * /           #include <float.h>
00643  * /
00644  * /           #define DBL_MAX 
00645  * /
00646  * / DESCRIPTION  
00647  * /           Maximum floating-point value 
00648  * /
00649  * / Note
00650  * /           (1-b^{p}) b^{e_{max}} 
00651  * /
00652  * / IMPLEMENTATION for APEnext:    possible                            (DBL_MAX) 
00653  * /-----------------------------------------------------------------------------*/
00654 #ifndef DBL_MAX 
00655 #define DBL_MAX FLT_MAX    
00656 #endif
00657 
00658 /*--------------------------------------------------------------------------------
00659  * / NAME   
00660  * /           LDBL_MAX - maximun normalized finite representable value 
00661  * /                      of type long double float
00662  * /
00663  * / SYNOPSIS
00664  * /           #include <float.h>
00665  * /
00666  * /           #define LDBL_MAX 
00667  * /
00668  * / DESCRIPTION  
00669  * /           Maximum floating-point value 
00670  * /
00671  * / Note
00672  * /           (1-b^{p}) b^{e_{max}} 
00673  * /
00674  * / IMPLEMENTATION for APEnext:    possible                           (LDBL_MAX) 
00675  * /-----------------------------------------------------------------------------*/
00676 #ifndef LDBL_MAX
00677 #define LDBL_MAX DBL_MAX    
00678 #endif
00679 
00680 
00681 /*---------------------------------------------------------------------------------
00682  * / NAME   
00683  * /           FLT_MIN - minimum normalized finite representable value 
00684  * /                     of type float
00685  * /
00686  * / SYNOPSIS
00687  * /           #include <float.h>
00688  * /
00689  * /           #define FLT_MIN 
00690  * /
00691  * / DESCRIPTION  
00692  * /           Minimum floating-point value 
00693  * /
00694  * / Note
00695  * /           b^{e_{min}-1} = pow(2., -1023)
00696  * /
00697  * / IMPLEMENTATION for APEnext:  possible                              (FLT_MIN) 
00698  * /-----------------------------------------------------------------------------*/
00699 #ifndef FLT_MIN 
00700 #define FLT_MIN 2.2250738585072014E-308
00701 #endif
00702 
00703 /*--------------------------------------------------------------------------------
00704  * / NAME   
00705  * /           DBL_MIN - minimum normalized finite representable value of 
00706  * /                     type double float
00707  * /
00708  * / SYNOPSIS
00709  * /           #include <float.h>
00710  * /
00711  * /           #define DBL_MIN 
00712  * /
00713  * / DESCRIPTION  
00714  * /           Minimum floating-point value 
00715  * /
00716  * / Note
00717  * /           b^{e_{min}-1} 
00718  * /
00719  * / IMPLEMENTATION for APEnext:   possible                              (DBL_MIN) 
00720  * /-----------------------------------------------------------------------------*/
00721 #ifndef DBL_MIN
00722 #define DBL_MIN FLT_MIN 
00723 #endif
00724 
00725 /*--------------------------------------------------------------------------------
00726  * / NAME   
00727  * /           LDBL_MIN - minimum normalized finite representable value 
00728  * /                      of type long double float
00729  * /
00730  * / SYNOPSIS
00731  * /           #include <float.h>
00732  * /
00733  * /           #define LDBL_MIN 
00734  * /
00735  * / DESCRIPTION  
00736  * /           Minimum floating-point value 
00737  * /
00738  * / Note
00739  * /           b^{e_{min}-1} 
00740  * /
00741  * / IMPLEMENTATION for APEnext:    possible                           (LDBL_MIN) 
00742  * /-----------------------------------------------------------------------------*/
00743 #ifndef LDBL_MIN 
00744 #define LDBL_MIN DBL_MIN 
00745 #endif
00746 
00747 
00748 /*---------------------------------------------------------------------------------
00749  * / NAME   
00750  * /           FLT_EPSELON - smallest number
00751  * /
00752  * / SYNOPSIS
00753  * /           #include <float.h>
00754  * /
00755  * /           #define FLT_EPSILON 
00756  * /
00757  * / DESCRIPTION  
00758  * /           FLT_EPSILON is smallest number x such that 1.0+x!=1.0 defined as  
00759  * /           Least significant digit representable for floating-point. 
00760  * /
00761  * / Note
00762  * /           Difference between 1.0 and the least value greater that 
00763  * /           1.0 that is reperesentable in the given floating-point type 
00764  * /           (here float)   
00765  * /           b^{1-p}  pow(2.,1-52) = pow(2.,-51)
00766  * / 
00767  * / IMPLEMENTATION for APEnext:    possible                         (FLT_EPSILON) 
00768  * /-----------------------------------------------------------------------------*/
00769 #ifndef FLT_EPSILON 
00770 #define FLT_EPSILON 4.4408920985006272E-16 
00771 #endif
00772 
00773 /*--------------------------------------------------------------------------------
00774  * / NAME   
00775  * /           DBL_EPSELON - smallest number 
00776  * /
00777  * / SYNOPSIS
00778  * /           #include <float.h>
00779  * /
00780  * /           #define DBL_EPSILON 
00781  * /
00782  * / DESCRIPTION  
00783  * /           DBL_EPSILON is smallest number x such that 1.0+x!=1.0 defined as  
00784  * /           Least significant digit representable for floating-point. 
00785  * /
00786  * / Note
00787  * /           Difference between 1.0 and the least value greater that 
00788  * /           1.0 that is reperesentable in the given floating-point type 
00789  * /           (here double float)   
00790  * /           b^{1-p}
00791  * / 
00792  * / IMPLEMENTATION for APEnext:    possible                        (DBL_EPSILON) 
00793  * /-----------------------------------------------------------------------------*/
00794 #ifndef DBL_EPSILON  
00795 #define DBL_EPSILON  FLT_EPSILON 
00796 #endif
00797 
00798 
00799 /*---------------------------------------------------------------------------------
00800  * / NAME   
00801  * /           LDBL_EPSELON - smallest number 
00802  * /
00803  * / SYNOPSIS
00804  * /           #include <float.h>
00805  * /
00806  * /           #define LDBL_EPSILON 
00807  * /
00808  * / DESCRIPTION  
00809  * /           LDBL_EPSILON is smallest number x such that 1.0+ x!=1.0 defined as  
00810  * /           Least significant digit representable for floating-point. 
00811  * /
00812  * / Note
00813  * /           Difference between 1.0 and the least value greater that 
00814  * /           1.0 that is reperesentable in the given floating-point type 
00815  * /           (here long double float)   
00816  * /           b^{1-p}
00817  * / 
00818  * / IMPLEMENTATION for APEnext:     possible                      (LDBL_EPSILON) 
00819  * /----------------------------------------------------------------------------*/
00820 #ifndef LDBL_EPSILON 
00821 #define LDBL_EPSILON DBL_EPSILON     
00822 #endif
00823 
00824 
00825 #endif /* ifndef _FLOAT_H_ */
00826 /*                                                                           @AT*/
00827 
00828 
00829 
00830 
00831 

Generated on Fri Jul 14 10:51:31 2006 for nlibc by doxygen 1.3.5