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.

A052572 Expansion of e.g.f.: (1+2*x-2*x^2)/(1-x)^2.

This page as a plain text file.
%I A052572 #36 May 16 2025 17:35:39
%S A052572 1,4,10,36,168,960,6480,50400,443520,4354560,47174400,558835200,
%T A052572 7185024000,99632332800,1482030950400,23538138624000,397533007872000,
%U A052572 7113748561920000,134449847820288000,2676192208994304000
%N A052572 Expansion of e.g.f.: (1+2*x-2*x^2)/(1-x)^2.
%C A052572 a(n) equals the permanent of the (n+1) X (n+1) matrix whose entry directly below the entry in the top right corner is 3, and all of whose other entries are 1. - _John M. Campbell_, May 25 2011
%C A052572 In factorial base representation (A007623) the terms are written as: 1, 20, 120, 1200, 12000, 120000, ... From a(2) = 10 = "120" onward each term begins always with "120", followed by n-2 additional zeros. - _Antti Karttunen_, Sep 24 2016
%H A052572 G. C. Greubel, <a href="/A052572/b052572.txt">Table of n, a(n) for n = 0..440</a>
%H A052572 INRIA Algorithms Project, <a href="http://ecs.inria.fr/services/structure?nbr=515">Encyclopedia of Combinatorial Structures 515</a>
%H A052572 <a href="/index/Fa#facbase">Index entries for sequences related to factorial base representation</a>
%F A052572 E.g.f.: (1 + 2*x - 2*x^2)/(1 - x)^2.
%F A052572 Recurrence: (n+2)*a(n) = n*(n+3)*a(n-1), with a(0) = 1, a(1) = 4, a(2) = 10.
%F A052572 a(n) = (n+3)*n! for n > 0.
%F A052572 For n <= 1, a(n) = (n+1)^2, for n > 1, a(n) = (n+1)! + 2*n! - _Antti Karttunen_, Sep 24 2016
%F A052572 From _Amiram Eldar_, Nov 06 2020: (Start)
%F A052572 Sum_{n>=0} 1/a(n) = e - 4/3.
%F A052572 Sum_{n>=0} (-1)^n/a(n) = 8/3 - 5/e. (End)
%p A052572 spec := [S,{S=Prod(Union(Z,Z,Sequence(Z)),Sequence(Z))},labeled]: seq(combstruct[count](spec,size=n), n=0..20);
%t A052572 With[{nn=20},CoefficientList[Series[(1+2x-2x^2)/(1-x)^2,{x,0,nn}],x] Range[ 0,nn]!] (* _Harvey P. Dale_, Jul 03 2020 *)
%t A052572 Table[If[n==0, 1, (n+3)*n!], {n,0,30}] (* _G. C. Greubel_, May 11 2025 *)
%o A052572 (Scheme, two different implementations)
%o A052572 (define (A052572 n) (if (zero? n) 1 (* (+ 3 n) (A000142 n))))
%o A052572 (define (A052572 n) (if (<= n 1) (* (+ 1 n) (+ 1 n)) (+ (A000142 (+ 1 n)) (* 2 (A000142 n)))))
%o A052572 ;; _Antti Karttunen_, Sep 24 2016
%o A052572 (Magma)
%o A052572 A052572:= func< n | n eq 0 select 1 else (n+3)*Factorial(n) >; // _G. C. Greubel_, May 11 2025
%o A052572 (SageMath)
%o A052572 def A052572(n): return 1 if n==0 else (n+3)*factorial(n) # _G. C. Greubel_, May 11 2025
%Y A052572 Essentially twice A038720.
%Y A052572 Row 7 of A276955, from a(2)=10 onward.
%Y A052572 Cf. sequences with formula (n + k)*n! listed in A282466.
%Y A052572 Cf. A000142.
%K A052572 easy,nonn
%O A052572 0,2
%A A052572 encyclopedia(AT)pommard.inria.fr, Jan 25 2000