Wolfram Research

Function Repository Resource:

ConjugatePartition (1.0.0) current version: 1.1.0 »

Source Notebook

Switch the rows and columns of a partition

Contributed by: Wolfram Staff

ResourceFunction["ConjugatePartition"][p]

gives the partition that switches the rows and columns of the integer partition p.

Details and Options

A partition of n is a list of weakly decreasing positive integers that add up to n. For instance, written compactly, these are the five partitions of 4: 4, 31, 22, 211, 1111.

Examples

Basic Examples

Here is a partition of 10 and its Ferrers diagram:

In[1]:=
p = {6, 3, 1};
In[2]:=
ResourceFunction[
ResourceObject[
Association[
   "Name" -> "FerrersDiagram", "UUID" -> "ff9f6ee9-e173-4868-997b-754fe2a50d9a", "ResourceType" -> "Function", "Version" -> "1.0.0", "Description" -> "Displays the Ferrers diagram of a partition \
with dots", "RepositoryLocation" -> URL[
     "https://www.wolframcloud.com/objects/resourcesystem/api/1.0"], "WolframLanguageVersionRequired" -> "10.0", "SymbolName" -> "FunctionRepository`$\
cfb969414cd645eaa8530fdec3494798`FerrersDiagram", "FunctionLocation" -> CloudObject[
     "https://www.wolframcloud.com/obj/bfd1afa3-668c-4583-9ee4-\
516df50e49c8"], "ShortName" -> "FerrersDiagram"], {
   ResourceSystemBase -> Automatic}]][p]
Out[2]=

Here is the conjugate partition and its Ferrers diagram:

In[3]:=
q = ResourceFunction["ConjugatePartition"]@p
Out[3]=
In[4]:=
ResourceFunction[
ResourceObject[
Association[
   "Name" -> "FerrersDiagram", "UUID" -> "ff9f6ee9-e173-4868-997b-754fe2a50d9a", "ResourceType" -> "Function", "Version" -> "1.0.0", "Description" -> "Displays the Ferrers diagram of a partition \
with dots", "RepositoryLocation" -> URL[
     "https://www.wolframcloud.com/objects/resourcesystem/api/1.0"], "WolframLanguageVersionRequired" -> "10.0", "SymbolName" -> "FunctionRepository`$\
cfb969414cd645eaa8530fdec3494798`FerrersDiagram", "FunctionLocation" -> CloudObject[
     "https://www.wolframcloud.com/obj/bfd1afa3-668c-4583-9ee4-\
516df50e49c8"], "ShortName" -> "FerrersDiagram"], {
   ResourceSystemBase -> Automatic}]][q]
Out[4]=

Some partitions are self-conjugate:

In[5]:=
s = {5, 2, 1, 1, 1};
In[6]:=
ResourceFunction["ConjugatePartition"]@s
Out[6]=

A self-conjugate partition has a symmetric Ferrers diagram:

In[7]:=
ResourceFunction[
ResourceObject[
Association[
   "Name" -> "FerrersDiagram", "UUID" -> "ff9f6ee9-e173-4868-997b-754fe2a50d9a", "ResourceType" -> "Function", "Version" -> "1.0.0", "Description" -> "Displays the Ferrers diagram of a partition \
with dots", "RepositoryLocation" -> URL[
     "https://www.wolframcloud.com/objects/resourcesystem/api/1.0"], "WolframLanguageVersionRequired" -> "10.0", "SymbolName" -> "FunctionRepository`$\
cfb969414cd645eaa8530fdec3494798`FerrersDiagram", "FunctionLocation" -> CloudObject[
     "https://www.wolframcloud.com/obj/bfd1afa3-668c-4583-9ee4-\
516df50e49c8"], "ShortName" -> "FerrersDiagram"], {
   ResourceSystemBase -> Automatic}]][s]
Out[7]=

Version History

  • 1.1.0 – 21 February 2024
  • 1.0.1 – 31 January 2022
  • 1.0.0 – 31 May 2019

Related Resources

License Information