### Basic Examples

Basic Examples

The largest part is 4 and there are 3 parts; :

4-3=1

[{4,2,2}]

1

The largest part and the number of parts are both 5; :

5-5=0

[{5,2,1,1,1}]

In[]:=

0

Out[]=

### Neat Examples

Neat Examples

Ramanujan discovered and proved analytically that the number of partitions of is divisible by 5:

5m+4

PartitionsP[Range[4,44,5]]

In[]:=

{5,30,135,490,1575,4565,12310,31185,75175}

Out[]=

Dyson conjectured and Atkins-Swinnerton-Dyer proved that the partitions of a number of the form can be split into five sets of equal size according to the rank mod 5:

5m+4

Length/@GatherByIntegerPartitions[9],Mod

@#,5&

In[]:=

{6,6,6,6,6}

Out[]=

Here is another example:

Length/@GatherByIntegerPartitions[24],Mod

@#,5&

In[]:=

{315,315,315,315,315}

Out[]=

A similar result holds for 7; in this case the partitions of a number of the form can be split into 7 sets of equal size according to the rank mod 7:

7m+5

Length/@GatherByIntegerPartitions[12],Mod

@#,7&

In[]:=

{11,11,11,11,11,11,11}

Out[]=