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.

Previous Showing 11-17 of 17 results.

A318183 a(n) = [x^n] Sum_{k>=0} x^k/Product_{j=1..k} (1 + n*j*x).

Original entry on oeis.org

1, 1, -1, 1, 25, -674, 15211, -331827, 5987745, 15901597, -13125035449, 1292056076070, -103145930581319, 7462324963409941, -464957409070517453, 16313974895147212801, 2059903411953959582849, -708700955022151333496910, 143215213612865558214820303, -24681846509158429152517973103
Offset: 0

Views

Author

Ilya Gutkovskiy, Aug 20 2018

Keywords

Crossrefs

Programs

  • Mathematica
    Table[SeriesCoefficient[Sum[x^k/Product[(1 + n j x), {j, 1, k}], {k, 0, n}], {x, 0, n}], {n, 0, 19}]
    Join[{1}, Table[n! SeriesCoefficient[Exp[(1 - Exp[-n x])/n], {x, 0, n}], {n, 19}]]
    Join[{1}, Table[Sum[(-n)^(n - k) StirlingS2[n, k], {k, n}], {n, 19}]]
    Join[{1}, Table[(-n)^n BellB[n, -1/n], {n, 1, 21}]] (* Peter Luschny, Aug 20 2018 *)
  • PARI
    {a(n) = sum(k=0, n, (-n)^(n-k)*stirling(n, k, 2))} \\ Seiichi Manyama, Jul 27 2019

Formula

a(n) = n! * [x^n] exp((1 - exp(-n*x))/n), for n > 0.
a(n) = Sum_{k=0..n} (-n)^(n-k)*Stirling2(n,k).
a(n) = (-n)^n*BellPolynomial_n(-1/n) for n >= 1. - Peter Luschny, Aug 20 2018

A025016 Final digits of !n = Sum_{i=0..n} i! (A003422) for very large n, read from right.

Original entry on oeis.org

4, 1, 3, 0, 4, 9, 0, 2, 4, 0, 2, 9, 8, 2, 5, 6, 3, 3, 2, 4, 4, 6, 5, 5, 2, 5, 0, 9, 3, 0, 5, 0, 1, 3, 9, 5, 3, 2, 3, 4, 0, 8, 4, 9, 9, 7, 0, 1, 1, 2, 6, 8, 3, 7, 4, 8, 6, 8, 7, 4, 9, 7, 4, 7, 4, 2, 2, 9, 0, 0, 4, 3, 3, 0, 5, 6, 5, 8, 6, 5, 0, 0, 2, 6, 6, 5, 1, 5, 9, 7, 8, 8, 1, 6, 2, 0, 2, 8, 1, 2, 1, 3, 7, 6, 1, 1, 5, 8
Offset: 0

Views

Author

Keywords

Comments

Reversed digits of 10-adic sum of all factorials.
More generally, the 10-adic sum: B(n) = Sum_{k>=0} k^n*k! is given by: B(n) = A014182(n)*B(0) + A014619(n) for n>=0, where B(0) is the 10-adic sum of factorials (this constant). - Paul D. Hanna, Aug 12 2006

Examples

			!20 = 256132749111820314, !30 = 16158688114800553828940314 ... .
		

Crossrefs

Programs

  • Mathematica
    a[n_] := Module[{x, f=1}, While[Mod[f!, 10^(n+1)]>0, f += 1]; x = Sum[ Mod[k!, 10^(n+1)], {k, 0, f}]; Quotient[10*Mod[x, 10^(n+1)], 10^(n+1)]]; Table[a[n], {n, 0, 100}] (* Jean-François Alcover, Nov 18 2015, after Paul D. Hanna *)
  • PARI
    {a(n)=local(x,f=1);while(f!%10^(n+1)>0,f+=1); x=sum(k=0,f,k!%10^(n+1));(10*(x%10^(n+1)))\10^(n+1)} \\ Paul D. Hanna, Aug 12 2006

A153732 Binomial transform of A109747.

Original entry on oeis.org

1, 3, 8, 19, 41, 84, 171, 347, 690, 1385, 2825, 5438, 11077, 24535, 33720, 102623, 350605, -1120228, 5876775, 11232063, -256532422, 1748895117, -4057110163, -42841409122, 605093026361, -3691581277925, 3538657621384, 186391745956155, -2296017574506751
Offset: 0

Views

Author

Gary W. Adamson, Dec 31 2008

Keywords

Comments

Equals triple binomial transform of A014182.

Examples

			a(3) = 19 = (1, 3, 3, 1) dot (1, 2, 3, 3) = (1 + 6 + 9 + 3); where A109747 = (1, 2, 3, 3, 2, 3, 5, -4, 5, 55, -212, ...).
		

Crossrefs

Programs

  • Mathematica
    Join[{1}, Rest[CoefficientList[Series[Exp[2*x + 1 - Exp[-x]], {x, 0, 50}], x]*Range[0, 50]!]] (* G. C. Greubel, Aug 31 2016 *)

Formula

E.g.f.: exp(2*x+1-exp(-x)) = 1+3*x+8*x^2/2!+19*x^3/3!+....
a(n) = exp(1)*Sum_{k >= 0} (-1)^k*(2-k)^n/k!. Cf. A126617. - Peter Bala, Oct 28 2011.
G.f.: (G(0) - 1)/(x-1) where G(k) = 1 - 1/(1+k*x-2*x)/(1-x/(x-1/G(k+1) )); (recursively defined continued fraction). - Sergei N. Gladkovskii, Jan 17 2013
a(0) = 1; a(n) = 2*a(n-1) - Sum_{k=1..n} (-1)^k * binomial(n-1,k-1) * a(n-k). - Ilya Gutkovskiy, Dec 01 2023

A345652 Expansion of the e.g.f. exp(-1 + (x + 1)*exp(-x)).

Original entry on oeis.org

1, 0, -1, 2, 0, -16, 65, -78, -749, 6232, -22068, -28920, 1004685, -7408740, 22263215, 157632230, -2874256740, 21590948480, -53087332675, -956539294506, 16344490525835, -132605481091060, 294656170409328, 9113173803517344, -167298122286332823
Offset: 0

Views

Author

Mélika Tebni, Jun 21 2021

Keywords

Comments

For all p prime, a(p)/(p-1) == 1 (mod p). - Mélika Tebni, Mar 21 2022

Examples

			exp(-1+(x+1)*exp(-x)) = 1 - x^2/2! + 2*x^3/3! - 16*x^5/5! + 65*x^6/6! - 78*x^7/7! - 749*x^8/8! + 6232*x^9/9! + ...
		

Crossrefs

Cf. A292935 (without 1+x: EGF e^(e^(-x)-1)), A000110 (absolute values: Bell numbers, EGF e^(e^x-1))

Programs

  • Maple
    a := series(exp(-1+(x+1)*exp(-x)), x=0, 25): seq(n!*coeff(a, x, n), n=0..24);
    a := proc(n) option remember; `if`(n=0, 1, add((n-1)*binomial(n-2, k)*(-1)^(n-1-k)*a(k), k=0..n-2)) end: seq(a(n), n=0..24);
    # third program:
    A345652 := n -> add((-1)^(n-k)*combinat[bell](k)*A106828(n, k), k=0..iquo(n, 2)):
    seq(A345652(n), n=0..24); # Mélika Tebni, Sep 21 2021
  • Mathematica
    nmax = 24; CoefficientList[Series[Exp[-1+(x+1)*Exp[-x]], {x, 0, nmax}], x] Range[0, nmax]!
  • PARI
    seq(n) = {Vec(serlaplace(exp(-1+(x+1)*exp(-x + O(x*x^n)))))} \\ Andrew Howroyd, Jun 21 2021
    
  • PARI
    a(n) = if(n==0, 1, sum(k=2, n, (-1)^(k-1)*(k-1)*binomial(n-1, k-1)*a(n-k))); \\ Seiichi Manyama, Mar 15 2022

Formula

The e.g.f. y(x) satisfies y' = -x*y*exp(-x).
a(n) = Sum_{k=0..n-2} (n-1)*binomial(n-2, k)*(-1)^(n-1-k)*a(k) for n > 0.
Conjecture: a(n) = 0 for only n = 1 and n = 4.
Conjecture: For all p prime, a(p)^2 == 1 (mod p).
Stronger conjecture: For n > 1, a(n) == -1 (mod n) iff n is a prime or 6. - M. F. Hasler, Jun 23 2021
a(n) = Sum_{k=0..floor(n/2)} (-1)^(n-k)*Bell(k)*A106828(n, k). - Mélika Tebni, Sep 21 2021
a(n) = Sum_{k=0..n} (-1)^k*A003725(n-k)*Bell(k)*binomial(n, k). - Mélika Tebni, Mar 21 2022

A358623 Regular triangle read by rows. T(n, k) = {{n, k}}, where {{n, k}} are the second order Stirling set numbers (or second order Stirling numbers). T(n, k) for 0 <= k <= n.

Original entry on oeis.org

1, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 1, 3, 0, 0, 0, 1, 10, 0, 0, 0, 0, 1, 25, 15, 0, 0, 0, 0, 1, 56, 105, 0, 0, 0, 0, 0, 1, 119, 490, 105, 0, 0, 0, 0, 0, 1, 246, 1918, 1260, 0, 0, 0, 0, 0, 0, 1, 501, 6825, 9450, 945, 0, 0, 0, 0, 0, 0, 1, 1012, 22935, 56980, 17325, 0, 0, 0, 0, 0, 0
Offset: 0

Views

Author

Peter Luschny, Nov 25 2022

Keywords

Comments

{{n, k}} are the number of k-quotient sets of an n-set having at least two elements in each equivalence class. This is the definition and notation (doubling the stacked delimiters of the Stirling set numbers) as given by Fekete (see link).
The formal definition expresses the second order Stirling set numbers as a binomial sum over second order Eulerian numbers (see the first formula below). The terminology 'associated Stirling numbers of second kind' used elsewhere should be dropped in favor of the more systematic one used here.
Also the Bell transform of sign(n) for n >= 0. For the definition of the Bell transform see A264428.

Examples

			Triangle T(n, k) starts:
[0] 1;
[1] 0, 0;
[2] 0, 1,   0;
[3] 0, 1,   0,    0;
[4] 0, 1,   3,    0,    0;
[5] 0, 1,  10,    0,    0,  0;
[6] 0, 1,  25,   15,    0,  0,  0;
[7] 0, 1,  56,  105,    0,  0,  0,  0;
[8] 0, 1, 119,  490,  105,  0,  0,  0,  0;
[9] 0, 1, 246, 1918, 1260,  0,  0,  0,  0,  0;
		

References

  • Ronald L. Graham, Donald E. Knuth, and Oren Patashnik, Concrete Mathematics, Addison-Wesley, Reading, 2nd ed. 1994, thirty-fourth printing 2022.

Crossrefs

A008299 is an irregular subtriangle with more information.
A358622 (second order Stirling cycle numbers).
Cf. A000296 (row sums), alternating row sums (apart from sign): A000587, A293037, and A014182.

Programs

  • Maple
    T := (n, k) -> add(binomial(n, k - j)*Stirling2(n - k + j, j)*(-1)^(k - j),
    j = 0..k): for n from 0 to 9 do seq(T(n, k), k = 0..n) od;
    # Using the e.g.f.:
    egf := exp(z*(exp(t) - t - 1)): ser := series(egf, t, 12):
    seq(print(seq(n!*coeff(coeff(ser, t, n), z, k), k = 0..n)), n = 0..9);
    # Using second order Eulerian numbers:
    A358623 := proc(n, k) if n = 0 then return 1 fi;
    add(binomial(j, n - 2*k)*combinat:-eulerian2(n - k, n - k - j - 1), j = 0..n-k-1)
    end: seq(seq(A358623(n, k), k = 0..n), n = 0..11);
  • Python
    # recursion over rows
    from functools import cache
    @cache
    def StirlingSetOrd2(n: int) -> list[int]:
        if n == 0: return [1]
        if n == 1: return [0, 0]
        rov: list[int] = StirlingSetOrd2(n - 2)
        row: list[int] = StirlingSetOrd2(n - 1) + [0]
        for k in range(1, n // 2 + 1):
            row[k] = (n - 1) * rov[k - 1] + k * row[k]
        return row
    for n in range(9): print(StirlingSetOrd2(n))
    # Alternative, using function BellMatrix from A264428.
    def f(k: int) -> int:
        return 1 if k > 0 else 0
    print(BellMatrix(f, 9))

Formula

T(n, k) = Sum_{j=0..k} (-1)^(k - j)*binomial(j, k - j)*<>, where <> denote the second order Eulerian numbers (extending Knuth's notation).
T(n, k) = n!*[z^k][t^n] exp(z*(exp(t) - t - 1)).
T(n, k) = Sum_{j=0..k} (-1)^(k - j)*binomial(n, k - j)*{n - k + j, j}, where {n, k} denotes the Stirling set numbers.
T(n, k) = (n - 1) * T(n-2, k-1) + k * T(n-1, k) with suitable boundary conditions.
T(n + k, k) = A269939(n, k), which might be called the Ward set numbers.

A174530 Numerators of the second row of the Akiyama-Tanigawa table for the sequence 1/n!.

Original entry on oeis.org

-1, 0, 3, 4, 5, 1, 7, 1, 1, 1, 11, 1, 13, 1, 1, 1, 17, 1, 19, 1, 1, 1, 23, 1, 1, 1, 1, 1, 29, 1, 31, 1, 1, 1, 1, 1, 37, 1, 1, 1, 41, 1, 43, 1, 1, 1, 47, 1, 1, 1, 1, 1, 53, 1, 1, 1, 1, 1, 59, 1, 61, 1, 1, 1, 1, 1, 67, 1, 1, 1, 71, 1, 73, 1, 1, 1, 1, 1, 79
Offset: 0

Views

Author

Paul Curtz, Mar 21 2010

Keywords

Comments

Filling the top row of a table with T(0,k) = 1/k!, k>=0, the Akiyama-Tanigawa algorithm constructs the following table T(n,k) of fractions, n>=0, k>=0:
1, 1, 1/2, 1/6, 1/24, 1/120, 1/720, 1/5040, 1/40320, 1/362880,...
0, 1, 1, 1/2, 1/6, 1/24, 1/120, 1/720, 1/5040, 1/40320, 1/362880, ...
-1, 0, 3/2, 4/3, 5/8, 1/5, 7/144, 1/105, 1/640, 1/4536, 11/403200, ...
-1, -3, 1/2, 17/6, 17/8, 109/120, 197/720, 107/1680, 487/40320, ..
2, -7, -7, 17/6, 73/12, 457/120, 529/360, 2081/5040, 263/2880,...
9, 0, -59/2, -13, 91/8, 421/30, 355/48, 2161/840, 3871/5760, 709/5040, ..
9, 59, -99/2, -195/2, -319/24, 1593/40, 2701/80, 76631/5040, 4285/896,...
The numerators of T(2,k) are the current sequence.
The denominators are 1, 1, 2, 3, 8, 5, 144, 105, 640, 4536, 403200, 332640, 43545600, 37065600,...
T(0,k) = T(1,k+1), shifted.
The left column is T(n,0) = (-1)^(n+1)*A014182(n).
The column T(n,1) appears to be (-1)^n*A074051(n). - R. J. Mathar, Jan 16 2011
a(n) = numerator(A005563(n-1)/(n-1)!), for n>0. - Fred Daniel Kline, Mar 20 2016

Crossrefs

Programs

  • Mathematica
    nn = 78; Numerator[Simplify[CoefficientList[Series[-Zeta[x] + (Derivative[1][Zeta][x] + x*Derivative[2][Zeta][x])*x, {x, 0, nn}], x]/Table[Derivative[n][Zeta][0], {n, 0, nn}]]] (* Mats Granvik, Nov 11 2013 *)

A379781 a(1)=1, a(2)=2; thereafter, a(n) is the final value at the bottom of the difference triangle of the sequence thus far.

Original entry on oeis.org

1, 2, 1, -2, 0, 7, -14, -12, 155, -408, -364, 7693, -30940, 10712, 637701, -4224222, 9980180, 61922567, -810337234, 4100137008, -958593005, -174952472228, 1662063951016, -6944673371867, -22887336602200, 655644589917172, -5694691183524699, 19946666531550638, 176993602416669640
Offset: 1

Views

Author

Neal Gersh Tolunsky, Jan 02 2025

Keywords

Comments

The difference triangle refers to the triangular array of iterated differences.
The first term in each row of the difference triangle is the inverse binomial transform of the sequence, so the definition means the inverse binomial transform deletes term a(2) = 2.

Examples

			To find a(6), we look at the first difference triangle of the first 5 terms:
  1,   2,   1,  -2,   0
  1,  -1,  -3,   2
 -2,  -2,   5
  0,   7
  7
7 is the final value, so a(6)=7.
		

Crossrefs

Programs

  • Mathematica
    a[1] = 1; a[2] = 2; a[n_] := a[n] = Sum[(-1)^(n-k+1) * Binomial[n-2, k-1] * a[k], {k, 1, n-1}]; Table[a[n], {n, 1, 30}] (* Amiram Eldar, Jan 04 2025 *)
Previous Showing 11-17 of 17 results.