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.

Showing 1-2 of 2 results.

A048594 Triangle T(n,k) = k! * Stirling1(n,k), 1<=k<=n.

Original entry on oeis.org

1, -1, 2, 2, -6, 6, -6, 22, -36, 24, 24, -100, 210, -240, 120, -120, 548, -1350, 2040, -1800, 720, 720, -3528, 9744, -17640, 21000, -15120, 5040, -5040, 26136, -78792, 162456, -235200, 231840, -141120, 40320, 40320, -219168, 708744, -1614816, 2693880, -3265920, 2751840, -1451520, 362880
Offset: 1

Views

Author

Oleg Marichev (oleg(AT)wolfram.com)

Keywords

Comments

Row sums (unsigned) give A007840(n), n>=1; (signed): A006252(n), n>=1.
Apart from signs, coefficients in expansion of n-th derivative of 1/log(x).

Examples

			Triangle begins
   1;
  -1,    2;
   2,   -6,   6;
  -6,   22, -36,   24;
  24, -100, 210, -240, 120; ...
The 2nd derivative of 1/log(x) is -2/x^3*log(x)^2 - 6/x^3*log(x)^3 - 6/x^3*log(x)^4.
		

Crossrefs

Cf. A133942 (left edge), A000142 (right edge), A006252 (row sums), A238685 (central terms).
Row sums: A007840 (unsigned), A006252 (signed).

Programs

  • Haskell
    a048594 n k = a048594_tabl !! (n-1) !! (k-1)
    a048594_row n = a048594_tabl !! (n-1)
    a048594_tabl = map snd $ iterate f (1, [1]) where
       f (i, xs) = (i + 1, zipWith (-) (zipWith (*) [1..] ([0] ++ xs))
                                       (map (* i) (xs ++ [0])))
    -- Reinhard Zumkeller, Mar 02 2014
    
  • Magma
    /* As triangle: */ [[Factorial(k)*StirlingFirst(n,k): k in [1..n]]: n in [1.. 15]]; // Vincenzo Librandi, Dec 15 2015
    
  • Maple
    with(combinat): A048594 := (n,k)->k!*stirling1(n,k);
  • Mathematica
    Flatten[Table[k!*StirlingS1[n,k], {n,10}, {k,n}]] (* Harvey P. Dale, Aug 28 2011 *)
    Join @@ CoefficientRules[ -Table[ D[ 1/Log[z], {z, n}], {n, 9}] /. Log[z] -> -Log[z], {1/z, 1/Log[z]}, "NegativeLexicographic"][[All, All, 2]] (* Oleg Marichev (oleg(AT)wolfram.com) and Maxim Rytin (m.r(AT)inbox.ru); submitted by Robert G. Wilson v, Aug 29 2011 *)
  • PARI
    {T(n, k)= if(k<1 || k>n, 0, stirling(n, k)* k!)} /* Michael Somos Apr 11 2007 */
    
  • SageMath
    def A048594(n,k): return (-1)^(n-k)*factorial(k)*stirling_number1(n,k)
    flatten([[A048594(n,k) for k in range(1,n+1)] for n in range(1,13)]) # G. C. Greubel, Oct 24 2023

Formula

T(n, k) = k*T(n-1, k-1) - (n-1)*T(n-1, k) if n>=k>=1, T(n, 0) = 0 and T(1, 1)=1, else 0.
E.g.f. k-th column: log(1+x)^k, k>=1.
From Peter Bala, Nov 25 2011: (Start):
E.g.f.: 1/(1-t*log(1+x)) = 1 + t*x + (-t+2*t^2)*x^2/2! + ....
The row polynomials are given by D^n(1/(1-x*t)) evaluated at x = 0, where D is the operator exp(-x)*d/dx.
(End)

A129505 Number of permutations of 2n-1 objects with exactly n cycles.

Original entry on oeis.org

1, 3, 35, 735, 22449, 902055, 44990231, 2681453775, 185953177553, 14710753408923, 1307535010540395, 129006659818331295, 13990945200239106865, 1654339178844590073615, 211821088794711294496815, 29197210605623737977801375, 4310704065427058593776844065
Offset: 1

Views

Author

Paul D. Hanna, Apr 18 2007

Keywords

Crossrefs

Programs

  • Haskell
    a129505 n = abs $ a008275 (2 * n - 1) n -- Reinhard Zumkeller, Mar 02 2014
    
  • Mathematica
    t[n_] := SymmetricPolynomial[n, Range[1, 2 n]]
    Table[t[n], {n, 1, 6}]  (* A129505 *)
    (* Clark Kimberling, Dec 30 2011 *)
    Table[Abs[StirlingS1[2*n-1, n]], {n, 1, 20}] (* Vaclav Kotesovec, Dec 28 2013 *)
  • Maxima
    a(n):=((2*n+1)*(-1)^n*((sum((stirling1(2*i-1,i)*binomial(2*n,2*i-1)* stirling1(2*(n-i)+1,n-i))/((n-i)*binomial(n,i)),i,1,n-1)) -n*stirling1(2*n-1,n) +stirling1(2*n,n)))/(n+1); /* Vladimir Kruchinin, Feb 28 2013 */
    
  • Maxima
    a(n):=coeff(expand(product(x+i,i,1,2*(n-1))),x,(n-1)); /* Lorraine Lee, Oct 12 2019 */
    
  • PARI
    a(n)=polcoeff(prod(k=0,2*n-2,1+k*x),n-1)
    
  • PARI
    vector(66, n, abs( stirling(2*n-1, n, 1) ) ) /* Joerg Arndt, Jun 09 2012 */
    
  • Python
    from sympy.functions.combinatorial.numbers import stirling
    def A129505(n): return stirling((n<<1)-1,n,kind=1) # Chai Wah Wu, Jun 08 2025

Formula

Unsigned central Stirling numbers of the first kind:
G.f.: A(x) = Sum_{n>=0} a(n)*(2*n-1)!/n!*x^n = B'(x), where B(x) satisfies B(x)^2 = x*log(1/(1-B(x))). - Vladimir Kruchinin, Jun 10 2012
a(n) = ((2*n+1)*(-1)^n*((Sum_{i=1..n-1} (Stirling1(2*i-1,i)*C(2*n,2*i-1)*Stirling1(2*(n-i)+1,n-i))/((n-i)*C(n,i)))-n*Stirling1(2*n-1,n) + Stirling1(2*n,n)))/(n+1). - Vladimir Kruchinin, Feb 28 2013
a(n) ~ (1+2*c)/(8*c*sqrt(Pi*(-1-c))) * (-8*c^2/(exp(1)*(1+2*c)))^n * n^(n-3/2), where c = LambertW(-1,-1/(2*exp(1/2))). - Vaclav Kotesovec, Dec 28 2013
a(n) = abs(C(2*n-1,n-1)*Sum_{i=1..n-1} (Stirling1(n-1,n-i-1)*Stirling1(n,i+1)/C(n-1,i))). - Chai Wah Wu, Jun 08 2025

Extensions

Minor edits by Vaclav Kotesovec, Mar 31 2014
Showing 1-2 of 2 results.