The error function is described in Abramowitz and Stegun, Chapter 7. The functions are defined in the error.ss file in the special-functions sub-collection of the science collection and are made available using the form:

Information on the exponential integrals can be found in Abramowitz and Stegun, Chapter 5. The functions are defined in the exponential-integral.ss file in the special-functions sub-collection of the science collection and are made available using the form:

Note that the gamma functions (Section 5.2), psi functions (Section 5.3), and the zeta functions (Section 5.4) are defined in the same module, gamma.ss. This is because their definitions are interdependent and PLT Scheme does not allow circular module dependencies.

It is related to the factorial function by Gamma(n) = (n- 1)! for positive integer n. Further information on the gamma function can be found in Abramowitz & Stegun, Chapter 6.

gamma

Function:

(gammax)

Contract:

(->real?real?)

This function computes the gamma function, Gamma(x), subject to x not being a negative integer. The function is computed using the real Lanczos method. The maximum value of x such that Gamma(x) is not considered an overflow is given by the constant gamma-xmax and is 171.0.

This function computes the logarithm of the gamma function, log(Gamma(x)), subject to x not being a negative integer. For x < 0, the real part of log(Gamma(x)) is returned, which is equivalent to log(|Gamma(x)|). The function is computed using the real Lanczos method.

lngamma-sgn

Function:

(lngamma-sgnx)

Contract:

(->real? (valuesreal? (integer-in-11))

This function computes the logarithm of the magnitude of the gamma function and its sign, subject to x not being a negative integer, and returns them as multiple values. The function is computed using the real Lanczos method. The value of the gamma function can be reconstructed using the relation Gamma(x) = sgn * exp(resultlg), where resultlg and sgn are the returned values.

Note that the gamma functions (Section 5.2), psi functions (Section 5.3), and zeta functions (Section 5.4) are defined in the same module, gamma.ss. This is because their definitions are interdependent and PLT Scheme does not allow circular module dependencies.

The Riemann zeta function is defined in Abramowitz and Stegun, Section 23.2. The zeta functions are defined in the gamma.ss file in the special-functions sub-collection of the science collection and are made available using the form:

Note that the gamma functions (Section 5.2), psi functions (Section 5.3), and zeta functions (Section 5.4) are defined in the same module, gamma.ss. This is because their definitions are interdependent and PLT Scheme does not allow circular module dependencies.