cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A322700 Number of unlabeled graphs with loops spanning n vertices.

This page as a plain text file.
%I A322700 #13 Jul 15 2024 10:22:31
%S A322700 1,1,4,14,70,454,4552,74168,2129348,111535148,10812483376,
%T A322700 1945437208224,650378721156736,404749938336404704,
%U A322700 470163239887698967104,1022592854829028311090816,4177826139658552046627175072,32163829440870460348768023969632
%N A322700 Number of unlabeled graphs with loops spanning n vertices.
%C A322700 The span of a graph is the union of its edges. The not necessarily spanning case is A000666.
%H A322700 Andrew Howroyd, <a href="/A322700/b322700.txt">Table of n, a(n) for n = 0..80</a>
%H A322700 Gus Wiseman, <a href="/A322700/a322700.png">Non-isomorphic representatives of the a(4) = 70 spanning graphs with loops.</a>
%F A322700 First differences of A000666.
%t A322700 Table[Sum[2^PermutationCycles[Ordering[Map[Sort,Select[Tuples[Range[n],2],OrderedQ]/.Rule@@@Table[{i,prm[[i]]},{i,n}],{1}]],Length],{prm,Permutations[Range[n]]}]/n!,{n,0,8}]//Differences (* Mathematica 8.0+ *)
%o A322700 (Python)
%o A322700 from itertools import combinations
%o A322700 from math import prod, factorial, gcd
%o A322700 from fractions import Fraction
%o A322700 from sympy.utilities.iterables import partitions
%o A322700 def A322700(n): return int(sum(Fraction(1<<sum(p[r]*p[s]*gcd(r,s) for r,s in combinations(p.keys(),2))+sum(((q>>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))-sum(Fraction(1<<sum(p[r]*p[s]*gcd(r,s) for r,s in combinations(p.keys(),2))+sum(((q>>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-1))) if n else 1 # _Chai Wah Wu_, Jul 14 2024
%Y A322700 Cf. A000666, A006125, A006129, A054921, A062740, A320461, A322635, A322661.
%K A322700 nonn
%O A322700 0,3
%A A322700 _Gus Wiseman_, Dec 23 2018