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.

A213236 a(n) = (-n)^(n-1).

This page as a plain text file.
%I A213236 #24 Feb 16 2025 08:33:17
%S A213236 1,-2,9,-64,625,-7776,117649,-2097152,43046721,-1000000000,
%T A213236 25937424601,-743008370688,23298085122481,-793714773254144,
%U A213236 29192926025390625,-1152921504606846976,48661191875666868481,-2185911559738696531968,104127350297911241532841
%N A213236 a(n) = (-n)^(n-1).
%H A213236 Eric Weisstein's World of Mathematics, <a href="https://mathworld.wolfram.com/LambertW-Function.html">Lambert W-Function</a>
%H A213236 Wikipedia, <a href="http://en.wikipedia.org/wiki/Lambert_W_function">Lambert W function</a>
%F A213236 E.g.f.: LambertW(x).
%F A213236 E.g.f. is the functional inverse of x * exp(x) which is the e.g.f. of A000027.
%F A213236 E.g.f. A(x) satisfies A(x) = x / exp(A(x)).
%F A213236 a(n) = -(-1)^n * A000169(n).
%e A213236 x - 2*x^2 + 9*x^3 - 64*x^4 + 625*x^5 - 7776*x^6 + 117649*x^7 + ...
%p A213236 a := proc(n); `if`( n<0, 0, n! * coeff( taylor( LambertW(x), x=0, n+1 ), x, n)); end;
%t A213236 a[ n_] := If[ n < 0, 0, n! SeriesCoefficient[ ProductLog @ z, {z, 0, n}]]
%t A213236 Table[(-n)^(n-1),{n,30}] (* _Harvey P. Dale_, Apr 29 2013 *)
%o A213236 (PARI) {a(n) = if( n<1, 0, (-n) ^ (n-1))}
%o A213236 (PARI) {a(n) = if( n<1, 0, n! * polcoeff( serreverse( x * exp(x + x * O(x^n))), n))}
%o A213236 (PARI) {a(n) = local(A); if( n<1, 0, A = O(x); for( k=1, n, A = x / exp(A)); n! * polcoeff( A, n))}
%o A213236 (Magma) [(-n)^(n-1) : n in [1..20]]; // _Wesley Ivan Hurt_, Jan 17 2017
%Y A213236 Cf. A000027, A000169.
%K A213236 sign
%O A213236 1,2
%A A213236 _Michael Somos_, Jun 07 2012