login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A007489
a(n) = Sum_{k=1..n} k!.
(Formerly M2818)
134
0, 1, 3, 9, 33, 153, 873, 5913, 46233, 409113, 4037913, 43954713, 522956313, 6749977113, 93928268313, 1401602636313, 22324392524313, 378011820620313, 6780385526348313, 128425485935180313, 2561327494111820313, 53652269665821260313, 1177652997443428940313
OFFSET
0,3
COMMENTS
Equals row sums of triangle A143122 starting (1, 3, 9, 33, ...). - Gary W. Adamson, Jul 26 2008
a(n) for n>=4 is never a perfect square. - Alexander R. Povolotsky, Oct 16 2008
Number of cycles that can be written in the form (j,j+1,j+2,...), in all permutations of {1,2,...,n}. Example: a(3)=9 because in (1)(2)(3), (1)(23), (12)(3), (13)(2), (123), (132) we have 3+2+2+1+1+0=9 such cycles. - Emeric Deutsch, Jul 14 2009
Conjectured to be the length of the shortest word over {1,...,n} that contains each of the n! permutations as a factor (cf. A180632) [see Johnston]. - N. J. A. Sloane, May 25 2013
The above conjecture has been disproven for n>=6. See A180632 and the Houston 2014 reference. - Dmitry Kamenetsky, Mar 07 2016
a(n) is also the number of compositions of n if cardinal values do not matter but ordinal rankings do. Since cardinal values do not matter, a sequence of k summands summing to n can be represented as (s(1),...,s(k)), where the s's are positive integers and the numbers in parentheses are the initial ordinal rankings. The number of compositions of these summands are equal to k!, with k ranging from 1 to n. - Gregory L. Simay, Jul 31 2016
When the numbers denote finite permutations (as row numbers of A055089) these are the circular shifts to the left. Compare array A211370 for circular shifts to the left in a broader sense. Compare sequence A001563 for circular shifts to the right. - Tilman Piesk, Apr 29 2017
Since a(n) = (1!+2!+3!+...+n!) = 3(1+3!/3+4!/3+...+n!/3) is a multiple of 3 for n>2, the only prime in this sequence is a(2) = 3. - Eric W. Weisstein, Jul 15 2017
Generalization of 2nd comment: a(n) for n>=4 is never a perfect power (A007916) (Chentzov link). - Bernard Schott, Jan 26 2023
REFERENCES
R. K. Guy, Unsolved Problems in Number Theory, 3rd ed., Section B44, Springer 2010.
N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
LINKS
Carauleanu Marc, Table of n, a(n) for n = 0..212 (first 100 terms from T. D. Noe)
N. N. Chentzov, D. O. Shklarsky, and I. M. Yaglom, The USSR Olympiad Problem Book, Selected Problems and Theorems of Elementary Mathematics, problem 115, pp. 28 and 201-202, Dover publications, Inc., New York, 1993.
Robin Houston, Tackling the Minimal Superpermutation Problem, arXiv:1408.5108 [math.CO], 2014.
Nathaniel Johnston, The minimal superpermutation problem (2013)
Nathaniel Johnston, Non-uniqueness of minimal superpermutations, Discrete Math. 313 (2013), no. 14, 1553--1557. MR3047396
S. Legendre and P. Paclet, On the Permutations Generated by Cyclic Shift , J. Int. Seq. 14 (2011) # 11.3.2.
Alexsandar Petojevic, The Function vM_m(s; a; z) and Some Well-Known Sequences, Journal of Integer Sequences, Vol. 5 (2002), Article 02.1.7.
Eric Weisstein's World of Mathematics, Factorial
Eric Weisstein's World of Mathematics, Left Factorial
G. Xiao, Sigma Server, Operate on "n!"
Jun Yan, Results on pattern avoidance in parking functions, arXiv:2404.07958 [math.CO], 2024. See p. 5.
FORMULA
a(n) = Sum_{k=1..n} P(n, k)/C(n, k). - Ross La Haye, Sep 21 2004
a(n) = 3*A056199(n) for n>=2. - Philippe Deléham, Feb 10 2007
a(n) = !(n+1)-1=A003422(n+1)-1. - Artur Jasinski, Nov 08 2007 [corrected by Werner Schulte, Oct 20 2021]
Starting (1, 3, 9, 33, 153, ...), = row sums of triangle A137593 - Gary W. Adamson, Jan 28 2008
a(n) = a(n-1) + n! for n >= 1. - Jaroslav Krizek, Jun 16 2009
E.g.f. A(x) satisfies to the differential equation A'(x)=A(x)+x/(1-x)^2+1. - Vladimir Kruchinin, Jan 22 2011
a(0)=0, a(1)=1, a(n) = (n+1)*a(n-1)-n*a(n-2). - Sergei N. Gladkovskii, Jul 05 2012
G.f.: W(0)*x/(2-2*x) , where W(k) = 1 + 1/( 1 - x*(k+2)/( x*(k+2) + 1/W(k+1) )); (continued fraction). - Sergei N. Gladkovskii, Aug 19 2013
G.f.: x /(1-x)/Q(0),m=+2, where Q(k) = 1 - 2*x*(2*k+1) - m*x^2*(k+1)*(2*k+1)/( 1 - 2*x*(2*k+2) - m*x^2*(k+1)*(2*k+3)/Q(k+1) ) ; (continued fraction). - Sergei N. Gladkovskii, Sep 24 2013
E.g.f.: exp(x-1)*(Ei(1) - Ei(1-x)) - exp(x) + 1/(1 - x), where Ei(x) is the exponential integral. - Ilya Gutkovskiy, Nov 27 2016
a(n) = sqrt(a(n-1)*a(n+1)-a(n-2)*n*n!), n >= 2. - Gary Detlefs, Oct 26 2020
EXAMPLE
a(4) = 1! + 2! + 3! + 4! = 1 + 2 + 6 + 24 = 33. - Michael B. Porter, Aug 03 2016
MAPLE
A007489 := proc(n) local i; add(i!, i=1..n); end proc;
MATHEMATICA
FoldList[Plus, 0, (Range@ 21)! ] (* Robert G. Wilson v, Sep 21 2007 *)
Table[Sum[i!, {i, 1, n}], {n, 0, 21}] (* Zerinvary Lajos, Jul 12 2009 *)
Accumulate[Range[50]!] (* Harvey P. Dale, Apr 30 2011 *)
Table[Plus@@(Range[n]!), {n, 20}] (* Alonso del Arte, Jul 18 2011 *)
PROG
(PARI) a(n)=sum(k=1, n, k!) \\ Charles R Greathouse IV, Jul 25 2011
(Haskell)
a007489 n = a007489_list !! n
a007489_list = scanl (+) 0 $ tail a000142_list
-- Reinhard Zumkeller, Aug 29 2014
(Magma) [0] cat [&+[Factorial(i): i in [1..n]]: n in [1..25]]; // Vincenzo Librandi, Sep 02 2016
(GAP) List([1..20], n->Sum([1..n], Factorial)); # Muniru A Asiru, Jan 31 2018
CROSSREFS
Equals A003422(n+1) - 1.
Column k=0 of A120695.
Sequence in context: A009220 A294035 A374347 * A294638 A201968 A264237
KEYWORD
nonn,easy,nice
STATUS
approved