partitions: Enumerate the partitions of an integer

View source: R/partitions.R

partitionsR Documentation

Enumerate the partitions of an integer

Description

Determine all unrestricted partitions of an integer. This function is equivalent to the function parts in the partitions package.

Usage

partitions(n)

Arguments

n

an integer

Value

a matrix whose rows are the n-tuples

Author(s)

Robin K. S. Hankin, from package partitions

Examples

partitions(5)
str(partitions(5))

dkahle/mpoly documentation built on July 27, 2023, 11:44 p.m.