A368727
Number of non-isomorphic connected multiset partitions of weight n into singletons or strict pairs.
Original entry on oeis.org
1, 1, 2, 2, 5, 6, 15, 21, 49, 82, 184, 341, 766, 1530, 3428, 7249, 16394, 36009, 82492, 186485, 433096, 1001495, 2358182, 5554644, 13255532, 31718030, 76656602, 185982207, 454889643, 1117496012, 2764222322, 6868902152, 17172601190
Offset: 0
Non-isomorphic representatives of the a(1) = 1 through a(6) = 15 multiset partitions:
{1} {12} {2}{12} {12}{12} {2}{12}{12} {12}{12}{12}
{1}{1} {1}{1}{1} {13}{23} {2}{13}{23} {12}{13}{23}
{1}{2}{12} {3}{13}{23} {13}{23}{23}
{2}{2}{12} {1}{2}{2}{12} {13}{24}{34}
{1}{1}{1}{1} {2}{2}{2}{12} {14}{24}{34}
{1}{1}{1}{1}{1} {1}{2}{12}{12}
{1}{2}{13}{23}
{2}{2}{12}{12}
{2}{2}{13}{23}
{2}{3}{13}{23}
{3}{3}{13}{23}
{1}{1}{2}{2}{12}
{1}{2}{2}{2}{12}
{2}{2}{2}{2}{12}
{1}{1}{1}{1}{1}{1}
This is the connected case of
A339888.
A007716 counts non-isomorphic multiset partitions, into pairs
A007717.
A320732 counts factorizations into primes or semiprimes, strict
A339839.
-
sps[{}]:={{}};sps[set:{i_,_}]:=Join@@Function[s,Prepend[#,s]& /@ sps[Complement[set,s]]] /@ Cases[Subsets[set],{i,_}];
mpm[n_]:=Join@@Table[Union[Sort[Sort /@ (#/.x_Integer:>s[[x]])]&/@sps[Range[n]]], {s,Flatten[MapIndexed[Table[#2,{#1}]&,#]]& /@ IntegerPartitions[n]}];
csm[s_]:=With[{c=Select[Subsets[Range[Length[s]],{2}], Length[Intersection@@s[[#]]]>0&]}, If[c=={},s,csm[Sort[Append[Delete[s,List /@ c[[1]]],Union@@s[[c[[1]]]]]]]]];
brute[m_]:=First[Sort[Table[Sort[Sort /@ (m/.Rule@@@Table[{i,p[[i]]},{i,Length[p]}])], {p,Permutations[Union@@m]}]]];
Table[Length[Union[brute /@ Select[mpm[n],And@@UnsameQ@@@#&&Max@@Length/@#<=2&&Length[csm[#]]<=1&]]],{n,0,8}]
A054922
Number of connected unlabeled symmetric relations (graphs with loops) having n nodes such that complement is also connected.
Original entry on oeis.org
2, 0, 0, 10, 164, 2670, 56724, 1867860, 104538928, 10461483366, 1912179618740, 644464839239880, 402785011941549964, 468944407349226545614, 1021179521951204217530900, 4174755063830188009750183026
Offset: 1
-
A000666 = Cases[Import["https://oeis.org/A000666/b000666.txt", "Table"], {, }][[All, 2]];
A054921 = Cases[Import["https://oeis.org/A054921/b054921.txt", "Table"], {, }][[All, 2]];
a[n_] := 2*A054921[[n + 1]] - A000666[[n + 1]];
Array[a, 50] (* Jean-François Alcover, Aug 31 2019 *)
-
from functools import lru_cache
from itertools import combinations
from math import prod, factorial, gcd
from fractions import Fraction
from sympy.utilities.iterables import partitions
from sympy import mobius, divisors
def A054922(n):
@lru_cache(maxsize=None)
def b(n): return int(sum(Fraction(1<>1)+1)*r+(q*r*(r-1)>>1) for q, r in p.items()),prod(q**r*factorial(r) for q, r in p.items())) for p in partitions(n)))
@lru_cache(maxsize=None)
def c(n): return n*b(n)-sum(c(k)*b(n-k) for k in range(1,n))
return (sum(mobius(d)*c(n//d) for d in divisors(n,generator=True))//n<<1)-b(n) # Chai Wah Wu, Jul 10 2024
A320993
Number of connected self-dual marked graphs on 2n nodes.
Original entry on oeis.org
1, 1, 6, 81, 2796, 285205, 96322648, 112087066485, 458071927263177, 6665704296474517580, 349377209492189224235030, 66602723163954143548104716149, 46557323273646194397454383970079368, 120168498151800396724425771086539073209571, 1152049915423012273792614840558950392103437052846
Offset: 0
Cf.
A000666 (not necessarily connected marked graphs),
A000595 (self dual on 2n nodes),
A054921 (connected marked graphs).
a(0)=1 prepended and terms a(7) and beyond from
Andrew Howroyd, Jan 26 2020