login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A110149 a(0) = 1, a(1) = 3; for n>1, a(n) = n*a(n-1) + (-1)^n. 2

%I #19 May 08 2020 18:16:09

%S 1,3,7,20,81,404,2425,16974,135793,1222136,12221361,134434970,

%T 1613219641,20971855332,293605974649,4404089619734,70465433915745,

%U 1197912376567664,21562422778217953,409686032786141106,8193720655722822121,172068133770179264540

%N a(0) = 1, a(1) = 3; for n>1, a(n) = n*a(n-1) + (-1)^n.

%C A000166, A001120 and A110043 have a similar recurrence.

%C a(n) = (n-1)*(a(n-1)+a(n-2)), n>2. - _Gary Detlefs_, Apr 11 2010

%H Alois P. Heinz, <a href="/A110149/b110149.txt">Table of n, a(n) for n = 0..450</a>

%F a(n) = A110043(n) + n! = A001120(n) + 2*n! = A000166(n) + 3*n! for n>0.

%F a(n) = 3*n! + floor((n!+1)/e) for n>0. - _Gary Detlefs_, Apr 11 2010

%F E.g.f.: (3*exp(x)*x+1)*exp(-x)/(1-x). - _Alois P. Heinz_, May 07 2020

%p a:= proc(n) option remember;

%p `if`(n<2, 2*n+1, n*a(n-1)+(-1)^n)

%p end:

%p seq(a(n), n=0..23); # _Alois P. Heinz_, May 07 2020

%t RecurrenceTable[{a[1]==3,a[n]==n a[n-1]+(-1)^n},a,{n,20}] (* _Harvey P. Dale_, Nov 21 2011 *)

%Y Column k=3 of A334715.

%K nonn,easy

%O 0,2

%A _Philippe Deléham_, Sep 04 2005

%E a(0)=1 prepended by _Alois P. Heinz_, May 07 2020

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified May 10 01:46 EDT 2024. Contains 372354 sequences. (Running on oeis4.)