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.

A038720 a(n) = (n+3)*n!/2.

Original entry on oeis.org

2, 5, 18, 84, 480, 3240, 25200, 221760, 2177280, 23587200, 279417600, 3592512000, 49816166400, 741015475200, 11769069312000, 198766503936000, 3556874280960000, 67224923910144000, 1338096104497152000, 27978373094031360000, 613091306060513280000
Offset: 1

Views

Author

N. J. A. Sloane, May 02 2000

Keywords

Comments

Next-to-last diagonal of A038719.
a(n-1) is the sum of the n-th entries in all cycles of all permutations of [n]. a(2) = 5 because the sum of the third entries in all cycles of all permutations of [3] ((123), (132), (12)(3), (13)(2), (1)(23), (1)(2)(3)) is 3+2+0+0+0+0 = 5. - Alois P. Heinz, May 03 2017

Crossrefs

Main diagonal of A285793.

Programs

  • Haskell
    import Data.List (transpose)
    a038720 n = a038720_list !! (n-1)
    a038720_list = (transpose $ map reverse a038719_tabl) !! 1
    -- Reinhard Zumkeller, Jul 08 2012
    
  • Magma
    A038720:= func< n | (n+3)*Factorial(n)/2 >; // G. C. Greubel, May 11 2025
    
  • Mathematica
    Array[(# + 3) #!/2 &, 21] (* Michael De Vlieger, Apr 28 2022 *)
  • SageMath
    def A038720(n): return (n+3)*factorial(n)//2 # G. C. Greubel, May 11 2025

Formula

a(n) = A052572(n)/2.
a(n) = A214178(n+3,n). - Reinhard Zumkeller, Jul 08 2012
G.f.: Sum_{n>=1} ( (n+1)*x/(1 + (n+1)*x) )^n. - Paul D. Hanna, Jan 02 2013
E.g.f.: 1/(1-x) + 1/(2*(x-1)^2) - 3/2. - Alois P. Heinz, May 04 2017
From Amiram Eldar, Dec 11 2022: (Start)
Sum_{n>=1} 1/a(n) = 2*e - 14/3.
Sum_{n>=1} (-1)^(n+1)/a(n) = 10/e - 10/3. (End)

Extensions

Corrected and extended by Larry Reeves (larryr(AT)acm.org), May 09 2000.