ParallelMapMonitored[{#,Length[EnumerateSubstitutionSystemRules[#,2]]}&,{{11},{12},{13},{22},{23},{24},{33},{11,11},{12,11},{13,11},{12,12},{12,21},{13,31},{12,22},{13,22},{12,33},{11,11,11},{12,11,11}}]
In[]:=
Out[]=
Grid[%,FrameAll]
In[]:=
Out[]=
ParallelMapMonitored[{#,Length[EnumerateSubstitutionSystemRules[#,3]]}&,{{11},{12},{13},{22},{23},{24},{33},{11,11},{12,11},{13,11},{12,21},{13,31},{12,22},{13,22},{12,33}}]
In[]:=
Out[]=
EnumerateSubstitutionSystemRules[{11,11},2]
In[]:=
{{AA,AA},{AA,AB},{AA,BA},{AA,BB},{AB,AA},{AB,AB},{AB,BA},{AB,BB}}
Out[]=
(Rule@@@Partition[#,2])&/@Catenate[Permutations@*Reverse/@Select[IntegerPartitions[5],EvenQ@*Length]]
In[]:=
{{14},{41},{23},{32},{11,12},{11,21},{12,11},{21,11}}
Out[]=
(Rule@@@Partition[#,2])&/@Catenate[Permutations@*Reverse/@Select[IntegerPartitions[2],EvenQ@*Length]]
In[]:=
{{11}}
Out[]=
(Rule@@@Partition[#,2])&/@Catenate[Permutations@*Reverse/@Select[IntegerPartitions[3],EvenQ@*Length]]
In[]:=
{{12},{21}}
Out[]=
(Rule@@@Partition[#,2])&/@Catenate[Permutations@*Reverse/@Select[IntegerPartitions[4],EvenQ@*Length]]
In[]:=
{{13},{31},{22},{11,11}}
Out[]=
DeleteDuplicatesBy[(Rule@@@Partition[#,2])&/@Catenate[Permutations@*Reverse/@Select[IntegerPartitions[5],EvenQ@*Length]],Sort]
In[]:=
{{14},{41},{23},{32},{11,12},{11,21}}
Out[]=
DeleteDuplicatesBy[(Rule@@@Partition[#,2])&/@Catenate[Permutations@*Reverse/@Select[IntegerPartitions[6],EvenQ@*Length]],Sort]
In[]:=
{{15},{51},{24},{42},{33},{11,13},{11,31},{11,22},{12,12},{12,21},{21,21},{11,11,11}}
Out[]=
Catenate[Table[(Rule@@@Partition[#,2])&/@Catenate[Permutations@*Reverse/@Select[IntegerPartitions[n],EvenQ@*Length]],{n,8}]]
In[]:=
Out[]=
Select[%,SomeIncreasingQ]
In[]:=
Out[]=
SomeIncreasingQ[list_]:=AnyTrue[#2-#1&@@@list,Positive]||AllTrue[#2-#1&@@@list,#0&]
In[]:=
#2-#1&@@@{21,11,11}
In[]:=
{-1,0,0}
Out[]=
allsigs
In[]:=
Out[]=
ParallelMapMonitored[{#,Length[EnumerateSubstitutionSystemRules[#,2]]}&,allsigs]
In[]:=
Out[]=
Divisors[48]
In[]:=
{1,2,3,4,6,8,12,16,24,48}
Out[]=