LPERM Function

Computes the logarithm of the PERM function, which is the logarithm of the number of permutations of n objects, with the option of including r number of elements.

Category:Combinatorial

Syntax

LPERM(n <, r>)

Required Argument

n

is an integer that represents the total number of elements from which the sample is chosen.

Optional Argument

r

is an optional integer value that represents the number of chosen elements. If r is omitted, the function returns the factorial of n.

Restrictionr ≤ n

Details

The LPERM function computes the logarithm of the PERM function.

Example

data _null_;
   x=lperm(5000,500);
   y=lperm(100,10);
   put x= y=;
run;

These statements produce these results:

x=4232.7715946 y=45.586735935

See Also

Last updated: April 14, 2026