A005195
Number of forests with n unlabeled nodes.
Original entry on oeis.org
1, 1, 2, 3, 6, 10, 20, 37, 76, 153, 329, 710, 1601, 3658, 8599, 20514, 49905, 122963, 307199, 775529, 1977878, 5086638, 13184156, 34402932, 90328674, 238474986, 632775648, 1686705630, 4514955632, 12132227370, 32717113805, 88519867048, 240235675303
Offset: 0
From _Gus Wiseman_, Apr 29 2024: (Start)
Edge-sets of non-isomorphic representatives of the a(0) = 1 through a(5) = 10 forests:
{} {} {} {} {} {}
{12} {12} {12} {12}
{13,23} {12,34} {12,34}
{13,23} {13,23}
{13,24,34} {12,35,45}
{14,24,34} {13,24,34}
{14,24,34}
{13,24,35,45}
{14,25,35,45}
{15,25,35,45}
(End)
- F. Harary and E. M. Palmer, Graphical Enumeration, Academic Press, NY, 1973, pp. 58-59.
- N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
- Alois P. Heinz, Table of n, a(n) for n = 0..1000 (first 201 terms from T. D. Noe)
- S. Hougardy, Classes of perfect graphs, Discr. Math. 306 (2006), 2529-2571.
- E. M. Palmer and A. J. Schwenk, On the number of trees in a random forest, J. Combin. Theory, B 27 (1979), 109-121.
- N. J. A. Sloane, Transforms
- Peter Steinbach, Field Guide to Simple Graphs, Volume 3, Part 12 (For Volumes 1, 2, 3, 4 of this book see A000088, A008406, A000055, A000664, respectively.)
- Peter Steinbach, Field Guide to Simple Graphs, Volume 4, Part 5 (For Volumes 1, 2, 3, 4 of this book see A000088, A008406, A000055, A000664, respectively.)
- Eric Weisstein's World of Mathematics, Forest.
- Index entries for sequences related to forests
-
EulerTransform[ seq_List ] := With[{m = Length[seq]}, CoefficientList[ Series[ Times @@ (1/(1 - x^Range[m])^seq), {x, 0, m}], x]];
b[n_] := b[n] = If[n <= 1, n, Sum[ Sum[ d*b[d], {d, Divisors[j]}]*b[n - j], {j, 1, n - 1}]/(n - 1)];
a55[n_] := a55[n] = If[n == 0, 1, b[n] - (Sum[ b[k]*b[n - k], {k, 0, n}] - If[Mod[n, 2] == 0, b[n/2], 0])/2]; A000055 = Table[ a55[n], {n, 1, 31}]; EulerTransform[ A000055 ] (* Jean-François Alcover, Mar 15 2012 *)
A001858
Number of forests of trees on n labeled nodes.
Original entry on oeis.org
1, 1, 2, 7, 38, 291, 2932, 36961, 561948, 10026505, 205608536, 4767440679, 123373203208, 3525630110107, 110284283006640, 3748357699560961, 137557910094840848, 5421179050350334929, 228359487335194570528, 10239206473040881277575, 486909744862576654283616
Offset: 0
From _Gus Wiseman_, Apr 29 2024: (Start)
Edge-sets of the a(4) = 38 forests:
{} {12} {12,13} {12,13,14}
{13} {12,14} {12,13,24}
{14} {12,23} {12,13,34}
{23} {12,24} {12,14,23}
{24} {12,34} {12,14,34}
{34} {13,14} {12,23,24}
{13,23} {12,23,34}
{13,24} {12,24,34}
{13,34} {13,14,23}
{14,23} {13,14,24}
{14,24} {13,23,24}
{14,34} {13,23,34}
{23,24} {13,24,34}
{23,34} {14,23,24}
{24,34} {14,23,34}
{14,24,34}
(End)
- B. Bollobas, Modern Graph Theory, Springer, 1998, p. 290.
- N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
- N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
- Alois P. Heinz, Table of n, a(n) for n = 0..388 (first 101 terms from T. D. Noe)
- J. E. Bartels, J. Mount, and D. J. A. Welsh, The polytope of win vectors. Annals of Combinatorics 1, 1-15 (1997). https://doi.org/10.1007/BF02558460
- David Callan, A Combinatorial Derivation of the Number of Labeled Forests, J. Integer Seqs., Vol. 6, 2003.
- Huantian Cao, AutoGF: An Automated System to Calculate Coefficients of Generating Functions, thesis, 2002.o
- Huantian Cao, AutoGF: An Automated System to Calculate Coefficients of Generating Functions, thesis, 2002.
- Huantian Cao, AutoGF: An Automated System to Calculate Coefficients of Generating Functions, thesis, 2002 [Local copy, with permission]
- P. Flajolet and R. Sedgewick, Analytic Combinatorics, 2009; see page 132.
- Samuele Giraudo, Combalgebraic structures on decorated cliques, Formal Power Series and Algebraic Combinatorics, Séminaire Lotharingien de Combinatoire, 78B.15, 2017, p. 7, arXiv:1709.08416 [math.CO], 2017.
- Anton Izosimov, Matrix polynomials, generalized Jacobians, and graphical zonotopes, arXiv:1506.05179 [math.AG], 2015.
- Qipeng Kuang, Ondřej Kuželka, Yuanhong Wang, and Yuyi Wang, Bridging Weighted First Order Model Counting and Graph Polynomials, arXiv:2407.11877 [cs.LO], 2024. See pp. 32-33.
- Arun P. Mani and Rebecca J. Stones, Congruences for weighted number of labeled forests, INTEGERS 16 (2016). #A17.
- J. Pitman, Coalescent Random Forests, J. Combin. Theory, A85 (1999), 165-193.
- J. Riordan, Forests of labeled trees, J. Combin. Theory, 5 (1968), 90-103.
- J. Riordan, Letter to N. J. A. Sloane, Oct 19 1970
- J. Riordan, Letter to N. J. A. Sloane, Nov 10 1975
- John Riordan and N. J. A. Sloane, Correspondence, 1974
- N. J. A. Sloane, Letter to J. Riordan, Nov. 1970
- R. Stanley, Decompositions of rational convex polytopes, Ann. Discrete Math 6.6 (1980): 333-342.
- L. Takacs, On the number of distinct forests, SIAM J. Discrete Math., 3 (1990), 574-581.
- E. M. Wright, A relationship between two sequences, Proc. London Math. Soc. (3) 17 (1967) 296-304.
- Index entries for sequences related to forests
A002807 counts cycles in a complete graph.
-
exp(x+x^2+add(n^(n-2)*x^n/n!, n=3..50));
# second Maple program:
a:= proc(n) option remember; `if`(n=0, 1, add(
binomial(n-1, j-1)*j^(j-2)*a(n-j), j=1..n))
end:
seq(a(n), n=0..20); # Alois P. Heinz, Sep 15 2008
# third Maple program:
F:= exp(-LambertW(-x)*(1+LambertW(-x)/2)):
S:= series(F,x,51):
seq(coeff(S,x,j)*j!, j=0..50); # Robert Israel, May 21 2015
-
nn=20;t=Sum[n^(n-1)x^n/n!,{n,1,nn}];Range[0,nn]!CoefficientList[ Series[Exp[t-t^2/2],{x,0,nn}],x] (* Geoffrey Critzer, Sep 05 2012 *)
nmax = 20; CoefficientList[Series[-LambertW[-x]/(x*E^(LambertW[-x]^2/2)), {x, 0, nmax}], x] * Range[0, nmax]! (* Vaclav Kotesovec, Jul 19 2019 *)
-
a(n)=if(n<0,0,sum(m=0,n,sum(j=0,m,binomial(m,j)*binomial(n-1,n-m-j)*n^(n-m-j)*(m+j)!/(-2)^j)/m!)) /* Michael Somos, Aug 22 2002 */
A144958
Number of unlabeled acyclic graphs covering n vertices.
Original entry on oeis.org
1, 0, 1, 1, 3, 4, 10, 17, 39, 77, 176, 381, 891, 2057, 4941, 11915, 29391, 73058, 184236, 468330, 1202349, 3108760, 8097518, 21218776, 55925742, 148146312, 394300662, 1053929982, 2828250002, 7617271738, 20584886435, 55802753243
Offset: 0
From _Gus Wiseman_, Apr 29 2024: (Start)
Edge-sets of non-isomorphic representatives of the a(0) = 1 through a(5) = 4 forests:
{} . {12} {13,23} {12,34} {12,35,45}
{13,24,34} {13,24,35,45}
{14,24,34} {14,25,35,45}
{15,25,35,45}
(End)
For triangles instead of cycles we have
A372169, non-covering
A006785.
-
brute[m_]:=First[Sort[Table[Sort[Sort/@(m/.Rule@@@Table[{i,p[[i]]},{i,Length[p]}])],{p,Permutations[Union@@m]}]]];
cyc[y_]:=Select[Join@@Table[Select[Join@@Permutations/@Subsets[Union@@y,{k}],And@@Table[MemberQ[Sort/@y,Sort[{#[[i]],#[[If[i==k,1,i+1]]]}]],{i,k}]&],{k,3,Length[y]}],Min@@#==First[#]&];
Table[Length[Union[Union[brute/@Select[Subsets[Subsets[Range[n],{2}]],Union@@#==Range[n]&&Length[cyc[#]]==0&]]]],{n,0,5}] (* Gus Wiseman, Apr 29 2024 *)
-
EulerT(v)={Vec(exp(x*Ser(dirmul(v,vector(#v,n,1/n))))-1, -#v)}
TreeGf(N)={my(A=vector(N, j, 1)); for (n=1, N-1, A[n+1] = 1/n * sum(k=1, n, sumdiv(k, d, d*A[d]) * A[n-k+1] ) ); x*Ser(A)}
seq(n)={my(t=TreeGf(n), v=EulerT(Vec(t - t^2/2 + subst(t,x,x^2)/2))); concat([1,0], vector(#v-1, i, v[i+1]-v[i]))} \\ Andrew Howroyd, Aug 01 2024
Name changed and 1 prepended by
Gus Wiseman, Apr 29 2024.
A372176
Irregular triangle read by rows where T(n,k) is the number of labeled simple graphs on n vertices with exactly 2k directed cycles of length > 2.
Original entry on oeis.org
1, 1, 2, 7, 1, 38, 19, 0, 6, 0, 0, 0, 1, 291, 317, 15, 220, 0, 0, 70, 55, 0, 0, 0, 0, 30, 15, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1
Offset: 0
Triangle begins (zeros shown as dots):
1
1
2
7 1
38 19 . 6 ... 1
291 317 15 220 .. 70 55 .... 30 15 ........ 10 ............... 1
The T(4,3) = 6 graphs:
12,13,14,23,24
12,13,14,23,34
12,13,14,24,34
12,13,23,24,34
12,14,23,24,34
13,14,23,24,34
Cf.
A000272,
A053530,
A137916,
A144958,
A213434,
A367863,
A372168,
A372169,
A372171,
A372172,
A372191.
-
cyc[y_]:=Select[Join@@Table[Select[Join@@Permutations/@Subsets[Union@@y,{k}], And@@Table[MemberQ[Sort/@y,Sort[{#[[i]],#[[If[i==k,1,i+1]]]}]],{i,k}]&], {k,3,Length[y]}],Min@@#==First[#]&];
Table[Length[Select[Subsets[Subsets[Range[n],{2}]], Length[cyc[#]]==2k&]], {n,0,4}, {k,0,Length[cyc[Subsets[Range[n],{2}]]]/2}]
A372191
Number of unlabeled simple graphs covering n vertices with a unique undirected cycle of length > 2.
Original entry on oeis.org
0, 0, 0, 1, 2, 6, 16, 43, 117, 319, 875, 2409, 6692, 18614, 52099, 146186, 411720, 1162295, 3289994, 9330913, 26517036, 75481622, 215201178, 614398459, 1756392061, 5026955216, 14403488345, 41311616835, 118601561506, 340795908579, 980078195995
Offset: 0
A002807 counts cycles in a complete graph.
A372176 counts labeled graphs by directed cycles.
A372171
Number of labeled simple graphs covering n vertices with a unique triangle.
Original entry on oeis.org
0, 0, 0, 1, 12, 220, 5460, 191975, 9596160, 683389812, 69270116040
Offset: 0
The a(4) = 12 graphs:
12,13,14,23
12,13,14,24
12,13,14,34
12,13,23,24
12,13,23,34
12,14,23,24
12,14,24,34
12,23,24,34
13,14,23,34
13,14,24,34
13,23,24,34
14,23,24,34
For all cycles (not just triangles) we have
A372195, non-covering
A372193.
-
cys[y_]:=Select[Subsets[Union@@y,{3}],MemberQ[y,{#[[1]],#[[2]]}] && MemberQ[y,{#[[1]],#[[3]]}] && MemberQ[y,{#[[2]],#[[3]]}]&];
Table[Length[Select[Subsets[Subsets[Range[n], {2}]],Union@@#==Range[n]&&Length[cys[#]]==1&]],{n,0,5}]
A105784
Number of different forests of unrooted trees, without isolated vertices, on n labeled nodes.
Original entry on oeis.org
0, 1, 3, 19, 155, 1641, 21427, 334377, 6085683, 126745435, 2975448641, 77779634571, 2241339267037, 70604384569005, 2414086713172695, 89049201691604881, 3525160713653081279, 149075374211881719939, 6707440248292609651513, 319946143503599791200675
Offset: 1
a(4) = 19 because there are 19 different such forests on 4 labeled nodes: 4^2 are trees, 3 have two trees and none can have more than two trees.
From _Gus Wiseman_, Apr 28 2024: (Start)
Edge-sets of the a(2) = 1 through a(4) = 19 forests:
12 12,13 12,34
12,23 13,24
13,23 14,23
12,13,14
12,13,24
12,13,34
12,14,23
12,14,34
12,23,24
12,23,34
12,24,34
13,14,23
13,14,24
13,23,24
13,23,34
13,24,34
14,23,24
14,23,34
14,24,34
(End)
For triangles instead of cycles we have
A372168, covering case of
A213434.
A002807 counts cycles in a complete graph.
-
b:= n-> add(add(binomial(m, j) *binomial(n-1, n-m-j)
*n^(n-m-j) *(m+j)!/ (-2)^j, j=0..m)/m!, m=0..n):
a:= n-> add(b(k) *(-1)^(n-k) *binomial(n, k), k=0..n):
seq(a(n), n=1..17); # Alois P. Heinz, Sep 10 2008
-
Unprotect[Power]; 0^0 = 1; b[n_] := Sum[Sum[Binomial[m, j]*Binomial[n-1, n -m-j]*n^(n-m-j)*(m+j)!/(-2)^j, {j, 0, m}]/m!, {m, 0, n}]; a[n_] := Sum[ b[k]*(-1)^(n-k)*Binomial[n, k], {k, 0, n}]; Table[a[n], {n, 1, 17}] (* Jean-François Alcover, Jan 08 2016, after Alois P. Heinz *)
A236570
Number of n-node simple unicyclic graphs.
Original entry on oeis.org
1, 3, 9, 25, 68, 185, 504, 1379, 3788, 10480, 29094, 81193, 227379, 639099, 1801394, 5091388, 14422301, 40939337, 116420959, 331622137, 946020596, 2702412657, 7729367873, 22132856218, 63444473053, 182046034559, 522841943138, 1502920139133
Offset: 3
-
Needs["Combinatorica`"];nn = 20; t[x_] := Sum[a[n] x^n, {n, 1, nn}]; a[0] = 0;
b = Drop[Flatten[
sol = SolveAlways[
0 == Series[
t[x] - x Product[1/(1 - x^i)^ a[i], {i, 1, nn}], {x, 0, nn}],
x]; Table[a[n], {n, 0, nn}] /. sol], 1];
r[x_] := Sum[b[[n]] x^n, {n, 1, nn}]; c =
Drop[Table[
CoefficientList[
Series[CycleIndex[DihedralGroup[n], s] /.
Table[s[i] -> r[x^i], {i, 1, n}], {x, 0, nn}], x], {n, 3,
nn}] // Total, 1];
d[x_] := Sum[c[[n]] x^n, {n, 1, nn}]; f =
Drop[CoefficientList[Series[r[x] - (r[x]^2 - r[x^2])/2, {x, 0, nn}],
x], 1]; Drop[CoefficientList[
Series[d[x] Product[1/(1 - x^i)^f[[i]], {i, 1, nn}], {x, 0, nn}], x],3] (* Geoffrey Critzer, Nov 16 2014 *)
A372172
Number of labeled simple graphs on n vertices with exactly one triangle.
Original entry on oeis.org
0, 0, 0, 1, 16, 290, 6980, 235270, 11298056, 777154308, 76560083040
Offset: 0
The a(4) = 16 graphs:
12,13,23
12,14,24
13,14,34
23,24,34
12,13,14,23
12,13,14,24
12,13,14,34
12,13,23,24
12,13,23,34
12,14,23,24
12,14,24,34
12,23,24,34
13,14,23,34
13,14,24,34
13,23,24,34
14,23,24,34
For all cycles (not just triangles) we have
A372193, covering
A372195.
-
cys[y_]:=Select[Subsets[Union@@y,{3}],MemberQ[y,{#[[1]],#[[2]]}] && MemberQ[y,{#[[1]],#[[3]]}] && MemberQ[y,{#[[2]],#[[3]]}]&];
Table[Length[Select[Subsets[Subsets[Range[n],{2}]], Length[cys[#]]==1&]],{n,0,5}]
A372174
Number of unlabeled simple graphs covering n vertices with a unique triangle.
Original entry on oeis.org
0, 0, 0, 1, 1, 5, 16, 79, 424, 3098, 28616
Offset: 0
Showing 1-10 of 13 results.
Comments