Investment Studio > Expressions > Functions > Statistical > PERMUT

float permut(integer n, integer k)

Returns the number of ways that k items can be taken from a set of n >= k items, with regard to order (also known as the number of ordered k-tuples). k and n must be natural numbers (i.e. > 0).

A permutation is any set of k items, with regard to their internal order: the set {1, 2} is NOT the same as {2, 1}. If internal order is not important, use the combin (combination) function instead:

combin(n, k) = permut(n, k) / fact(k)

Example

The odds of selecting a winning 5-digit lottery number, where each digit can be in the range [0, 99], are

=1 / permut(100, 5)

or 1 / 9034502400 » 1.1E-10.

See also binomdist, combin, critbinom, fact, factdouble, hypgeomdist, negbinomdist.