%I #18 Jul 19 2024 12:03:37
%S 1,0,3,3,3,7,9,12,14,22,30,39,41,57,86,87,121,179,164,225,300,362,433,
%T 571,624,846,968,1134,1391,1902,1992,2407,3043,3688,4321,5145,5811,
%U 7277,8627,10234,11895,14730,16091,19571,24026,27312,31490,37119,43197,52256,59349,68981,79711,94935,108360,126301,147204,169964,193594,227147
%N Number of conjugate-congruent partitions of n.
%C See reference for precise definition.
%C Let P be a partition of n and let Q denote its conjugate partition. Then P is said to be conjugate-congruent if there is an integer m>1 such that both P and Q give the same set R(P,m) of residues when their parts are reduced modulo m, where R(P,m) contains less than m elements. - _Augustine O. Munagi_, Dec 18 2008
%H A. O. Munagi, <a href="http://dx.doi.org/10.1016/j.disc.2007.05.022">Pairing conjugate partitions by residue classes</a>, Discrete Math., 308 (2008), 2492-2501.
%H Eric Weisstein's World of Mathematics, <a href="http://mathworld.wolfram.com/ConjugatePartition.html">Conjugate Partition</a>.
%e a(8) = 12: the 12 conjugate-congruent partitions of 8 are shown below, in conjugate pairs followed by their common residues. 8/1+1+1+1+1+1+1+1 by 1 mod 7, 1+7/1+1+1+1+1+1+2 by 1,2 mod 5, 2+6/1+1+1+1+2+2 by 1,2 mod 5, 4+4/2+2+2+2 by 0 mod 2, 1+1+6/1+1+1+1+1+3 by 0,1 mod 3, 2+3+3/2+3+3 by 0,2 mod 3, 1+1+2+4/1+1+2+4 by 1,2 mod 3. - _Augustine O. Munagi_, Dec 18 2008
%p with(combinat): isconjcong:=proc(P::partition) local m; option remember; if P[ -1]>=conjpart(P)[ -1] then for m from 2 to P[ -1]+1 do if {op(P mod m)}={op(conjpart(P) mod m)} and nops({op(P mod m)})<m then return true; end if; end do; else for m from 2 to conjpart(P)[ -1]+1 do if {op(P mod m)}={op(conjpart(P) mod m)} and nops({op(P mod m)})<m then return true; end if; end do; end if; false; end proc: seq(nops(select(isconjcong,partition(n))),n=1..30); # _Augustine O. Munagi_, Dec 18 2008
%t ConjugatePartition[e_List] := Length /@ Most[NestWhileList[Function[{s}, Select[s - 1, # > 0 &]], e, # =!= {} &]]; (* this ConjugatePartition code is due to Arnoud B. in MathWorld (see link) *)
%t isconjcong[P_] := isconjcong[P] = Module[{m, Q = ConjugatePartition[P]}, If[P[[1]] >= Q[[1]], For[m = 2, m <= P[[ 1]] + 1, m++, If[Union@Mod[P, m] == Union@Mod[Q, m] && Length[Union@Mod[P, m]] < m, Return[True]]], For[m = 2, m <= Q[[1]] + 1, m++, If[Union@Mod[P, m] == Union@Mod[Q, m] && Length[Union@Mod[P, m]] < m, Return[True]]]]; False];
%t a[n_] := a[n] = Length[Select[IntegerPartitions[n], isconjcong]];
%t Table[Print[n, " ", a[n]]; a[n], {n, 1, 60}] (* _Jean-François Alcover_, Jul 19 2024, after Maple code *)
%K nonn
%O 1,3
%A _N. J. A. Sloane_ May 07 2008
%E a(36)-a(40) from _Augustine O. Munagi_, Dec 18 2008
%E a(41)-a(60) from _Jean-François Alcover_, Jul 19 2024
|