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.

Showing 1-1 of 1 results.

A294198 Labeled trees on n nodes with at least one node of degree two.

Original entry on oeis.org

0, 0, 3, 12, 120, 1200, 16380, 255696, 4726008, 99107280, 2346042600, 61706210280, 1788467429892, 56618211155688, 1944581982268380, 72019509651227040, 2861473883255362800, 121414006972684901664, 5479661140682410928592, 262122044885503316203320
Offset: 1

Views

Author

Marko Riedel, Feb 11 2018

Keywords

Examples

			When n=4 there are two types of trees: paths (24!/2  trees) or a star (4 trees) for a total of 4^(4-2) trees. Of these only the paths contain a vertex of degree 2 (2 in fact). When n=5 there are three types of trees: paths (5!/2 trees), a star (5 trees) or a fork (C(5,1) x C(4, 2) x 2) for a total of 5^(5-2) trees. Of these only the paths and the fork contain a vertex of degree 2.
		

Crossrefs

Programs

  • Mathematica
    a[1] = 0; a[n_] := (n-2)! Sum[Binomial[n, q] (-1)^(q+1) (n-q)^(n-2-q) / (n-2-q)!, {q, 1, n-2}]; Array[a, 20] (* Jean-François Alcover, Feb 15 2018 *)

Formula

a(n) = (n-2)!*Sum_{q=1..n-2} C(n,q)*(-1)^(q+1)*(n-q)^(n-2-q)/(n-2-q)! where n >= 2.
Showing 1-1 of 1 results.