PART::SplitPart
--
splits a partition into several ones
PART::SplitPart(part <,n>)
part | - | a partition |
n | - | a positive integer |
The PART::SplitPart
function returns the set of ways of splitting
the partition part
into two partitions.
Called with a second argument n
, the partition is splitted
into n
partitions, possibly empty.
>> muEC::PART::SplitPart( [4,2,1] );
{[[], [4, 2, 1]], [[1], [4, 2]], [[2], [4, 1]], [[4], [2, 1]], [[2, 1], [4]], [[4, 1], [2]], [[4, 2], [1]], [[4, 2, 1], []] }
>> muEC::PART::SplitPart( [2,1], 3 );
{[[], [], [2, 1]], [[], [1], [2]], [[], [2], [1]], [[], [2, 1], []], [[1], [], [2]], [[1], [2], []], [[2], [], [1]], [[2], [1], []], [[2, 1], [], []]}
MuPAD Combinat, an open source algebraic combinatorics package