Next: , Previous: , Up: glibc   [Index]


5.8 Mathematics

A binding for each of the following constants is exported by (vicare platform constants):

M_E         M_LOG2E     M_LOG10E
M_LN2       M_LN10      M_PI
M_PI_2      M_PI_4      M_1_PI
M_2_PI      M_2_SQRTPI  M_SQRT2
M_SQRT1_2

The following bindings are exported by the (vicare glibc) library. The functions are implemented by the GNU C library and are probably faster than the ones implemented by the R6RS libraries. All the arguments fl must be flonums, all the arguments cfl must be complex flonums.

Trigonometric functions

Function: csin cfl
Function: ccos cfl
Function: ctan cfl

Trigonometric functions for complex flonums.

Function: casin cfl
Function: cacos cfl
Function: catan cfl

Inverse trigonometric functions for complex flonums.

Exponents and logarithms

Function: cexp cfl

Return the base of the natural logarithms raised to the power of the operand.

Function: clog cfl

Return the natural logarithm of the operand.

Function: clog10 cfl

Return the base 10 logarithm of the operand.

Function: csqrt cfl

Return the square root of the operand.

Function: cpow cfl1 cfl2

Return cfl1 raised to the power of cfl2.

Hyperbolic functions

Function: sinh fl
Function: cosh fl
Function: tanh fl

Hyperbolic functions for flonums.

Function: asinh fl
Function: acosh fl
Function: atanh fl

Inverse hyperbolic functions for flonums.

Function: csinh cfl
Function: ccosh cfl
Function: ctanh cfl

Hyperbolic functions for complex flonums.

Function: casinh cfl
Function: cacosh cfl
Function: catanh cfl

Inverse hyperbolic functions for complex flonums.

Special functions

Function: erf fl
Function: erfc fl

Interfaces to the C functions erf() and erfc(), (libc)erf. Compute the error function.

Function: lgamma fl

Interface to the C function lgamma(), (libc)lgamma. Compute the natural logarithm of the absolute value of the gamma function of the operand. Return two values: a flonum being the result of the function and a fixnum representing the sign of the intermediate result.

Function: tgamma fl

Interface to the C function tgamma(), (libc)lgamma. Compute the gamma function of the operand.

Function: j0 fl
Function: j1 fl
Function: jn fx fl

Interfaces to the C functions j0(), j1() and jn(); (libc)j0. Compute the Bessel functions of the first kind. fx must be a fixnum.

Function: y0 fl
Function: y1 fl
Function: yn fx fl

Interfaces to the C functions y0(), y1() and yn(); (libc)y0. Compute the Bessel functions of the second kind. fx must be a fixnum.


Next: , Previous: , Up: glibc   [Index]