1 <!-- ##### SECTION Title ##### -->
4 <!-- ##### SECTION Short_Description ##### -->
5 mathematical constants, and floating point decomposition
7 <!-- ##### SECTION Long_Description ##### -->
9 GLib offers mathematical constants such as #G_PI for the value of pi;
10 many platforms have these in the C library, but some don't, the GLib
11 versions always exist.
15 The #GFloatIEEE754 and #GDoubleIEEE754 unions are used to access the
16 sign, mantissa and exponent of IEEE floats and doubles. These
17 unions are defined as appropriate for a given platform.
18 IEEE floats and doubles are supported (used for
19 storage) by at least Intel, PPC and Sparc, for reference: <ulink url="http://cch.loria.fr/documentation/IEEE754/numerical_comp_guide/ncg_math.doc.html">http://cch.loria.fr/documentation/IEEE754/numerical_comp_guide/ncg_math.doc.html</ulink>
22 <!-- ##### SECTION See_Also ##### -->
24 <ulink url="http://cch.loria.fr/documentation/IEEE754/numerical_comp_guide/ncg_math.doc.html">http://cch.loria.fr/documentation/IEEE754/numerical_comp_guide/ncg_math.doc.html</ulink>
27 <!-- ##### SECTION Stability_Level ##### -->
30 <!-- ##### SECTION Image ##### -->
33 <!-- ##### MACRO G_IEEE754_FLOAT_BIAS ##### -->
35 See <ulink url="http://cch.loria.fr/documentation/IEEE754/numerical_comp_guide/ncg_math.doc.html">http://cch.loria.fr/documentation/IEEE754/numerical_comp_guide/ncg_math.doc.html</ulink>
40 <!-- ##### MACRO G_IEEE754_DOUBLE_BIAS ##### -->
42 See <ulink url="http://cch.loria.fr/documentation/IEEE754/numerical_comp_guide/ncg_math.doc.html">http://cch.loria.fr/documentation/IEEE754/numerical_comp_guide/ncg_math.doc.html</ulink>
47 <!-- ##### UNION GFloatIEEE754 ##### -->
49 The #GFloatIEEE754 and #GDoubleIEEE754 unions are used to access the
50 sign, mantissa and exponent of IEEE floats and doubles. These
51 unions are defined as appropriate for a given platform.
52 IEEE floats and doubles are supported (used for
53 storage) by at least Intel, PPC and Sparc, for reference:
54 <ulink url="http://cch.loria.fr/documentation/IEEE754/numerical_comp_guide/ncg_math.doc.html">http://cch.loria.fr/documentation/IEEE754/numerical_comp_guide/ncg_math.doc.html</ulink>
58 <!-- ##### UNION GDoubleIEEE754 ##### -->
60 The #GFloatIEEE754 and #GDoubleIEEE754 unions are used to access the
61 sign, mantissa and exponent of IEEE floats and doubles. These
62 unions are defined as appropriate for a given platform.
63 IEEE floats and doubles are supported (used for
64 storage) by at least Intel, PPC and Sparc, for reference:
65 <ulink url="http://cch.loria.fr/documentation/IEEE754/numerical_comp_guide/ncg_math.doc.html">http://cch.loria.fr/documentation/IEEE754/numerical_comp_guide/ncg_math.doc.html</ulink>
69 <!-- ##### MACRO G_E ##### -->
71 The base of natural logarithms.
76 <!-- ##### MACRO G_LN2 ##### -->
78 The natural logarithm of 2.
83 <!-- ##### MACRO G_LN10 ##### -->
85 The natural logarithm of 10.
90 <!-- ##### MACRO G_PI ##### -->
92 The value of pi (ratio of circle's circumference to its diameter).
97 <!-- ##### MACRO G_PI_2 ##### -->
104 <!-- ##### MACRO G_PI_4 ##### -->
111 <!-- ##### MACRO G_SQRT2 ##### -->
113 The square root of two.
118 <!-- ##### MACRO G_LOG_2_BASE_10 ##### -->
120 Used for fooling around with float formats, see
121 <ulink url="http://cch.loria.fr/documentation/IEEE754/numerical_comp_guide/ncg_math.doc.html">http://cch.loria.fr/documentation/IEEE754/numerical_comp_guide/ncg_math.doc.html</ulink>