randpart - Maple Help

combinat

 randpart
 construct a random partition

 Calling Sequence randpart(n)

Parameters

 n - positive integer

Description

 • The function randpart computes and returns a random partition of the positive integer n.  This consists of a random list of positive integers whose sum is n.
 • The command with(combinat,randpart) allows the use of the abbreviated form of this command.

Examples

 > $\mathrm{with}\left(\mathrm{combinat},\mathrm{randpart}\right)$
 $\left[{\mathrm{randpart}}\right]$ (1)
 > $\mathrm{randpart}\left(10\right)$
 $\left[{2}{,}{2}{,}{6}\right]$ (2)
 > $\mathrm{randpart}\left(10\right)$
 $\left[{1}{,}{1}{,}{4}{,}{4}\right]$ (3)
 > $\mathrm{randpart}\left(10\right)$
 $\left[{1}{,}{2}{,}{2}{,}{5}\right]$ (4)