login
A007339
a(n) = n! - n^3.
(Formerly M4140)
7
1, 0, -6, -21, -40, -5, 504, 4697, 39808, 362151, 3627800, 39915469, 478999872, 6227018603, 87178288456, 1307674364625, 20922789883904, 355687428091087, 6402373705722168, 121645100408825141, 2432902008176632000
OFFSET
0,3
REFERENCES
N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
FORMULA
E.g.f.: 1/(1 - x) - x*(1 + 3*x + x^2)*exp(x). - Ilya Gutkovskiy, Jan 27 2017
MATHEMATICA
Table[n!-n^3, {n, 0, 20}] (* Harvey P. Dale, Jul 02 2012 *)
PROG
(Magma) [Factorial(n)-n^3: n in [0..20]]; // Vincenzo Librandi, Oct 06 2011
CROSSREFS
Sequence in context: A031042 A064431 A031094 * A363621 A225150 A056237
KEYWORD
sign
STATUS
approved