combinat
partition
partition an integer
Calling Sequence
Parameters
Description
Examples
partition(n, m)
n
-
non-negative integer; integer to partition
m
(optional) non-negative integer; maximum integer in partitions
The procedure partition partitions an integer n into all possible sums without regard to order. The output is a list of lists of integers where the sum of the elements in each list is n.
See the function numbpart , which computes the number of partitions.
The command with(combinat,partition) allows the use of the abbreviated form of this command.
with⁡combinat,partition
partition⁡0
partition⁡3
1,1,1,1,2,3
partition⁡6,3
1,1,1,1,1,1,1,1,1,1,2,1,1,2,2,2,2,2,1,1,1,3,1,2,3,3,3
See Also
combinat[numbpart]
type/partition
Download Help Document
AltStyle によって変換されたページ (->オリジナル) / アドレス: モード: デフォルト 音声ブラウザ ルビ付き 配色反転 文字拡大 モバイル