Functions

factorial

Supported By

Syntax

[the] factorial of factor

factorial ( expression )

Factor and expression yield integers, numbers, or complexes.

Example

put the factorial of 5 -- yields 120

Description

The factorial function returns the factorial of its argument. For positive integers, the factorial is defined as the product of the integers from 1 to the specified integer, e.g. fact(5) = 1 * 2 * 3 * 4 * 5 = 120. For other real or complex numbers, the factorial is defined in terms of the gamma function, i.e. fact(n) = gamma(n+1).

Synonym

fact

See Also

gamma, beta, lnfactorial, lngamma, lnbeta