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-10 of 18 results. Next

A329369 Number of permutations of {1,2,...,m} with excedance set constructed by taking m-i (0 < i < m) if b(i-1) = 1 where b(k)b(k-1)...b(1)b(0) (0 <= k < m-1) is the binary expansion of n.

Original entry on oeis.org

1, 1, 3, 1, 7, 3, 7, 1, 15, 7, 17, 3, 31, 7, 15, 1, 31, 15, 37, 7, 69, 17, 37, 3, 115, 31, 69, 7, 115, 15, 31, 1, 63, 31, 77, 15, 145, 37, 81, 7, 245, 69, 155, 17, 261, 37, 77, 3, 391, 115, 261, 31, 445, 69, 145, 7, 675, 115, 245, 15, 391, 31, 63, 1, 127, 63
Offset: 0

Views

Author

Mikhail Kurkov, Nov 12 2019

Keywords

Comments

Another version of A152884.
The excedance set of a permutation p of {1,2,...,m} is the set of indices i such that p(i) > i; it is a subset of {1,2,...,m-1}.
Great work on this subject was done by R. Ehrenborg and E. Steingrimsson, so most of the formulas given below are just their results translated into the language of the sequences which are related to the binary expansion of n.
Conjecture 1: equivalently, number of open tours by a biased rook on a specific f(n) X 1 board, which ends on a white cell, where f(n) = A070941(n) = floor(log_2(2n)) + 1 and cells are colored white or black according to the binary representation of 2n. A cell is colored white if the binary digit is 0 and a cell is colored black if the binary digit is 1. A biased rook on a white cell moves only to the left and otherwise moves only to the right. - Mikhail Kurkov, May 18 2021
Conjecture 2: this sequence is an inverse modulo 2 binomial transform of A284005. - Mikhail Kurkov, Dec 15 2021

Examples

			a(1) = 1 because the 1st excedance set is {m-1} and the permutations of {1,2,...,m} with such excedance set are 21, 132, 1243, 12354 and so on, i.e., for a given m we always have 1 permutation.
a(2) = 3 because the 2nd excedance set is {m-2} and the permutations of {1,2,...,m} with such excedance set are 213, 312, 321, 1324, 1423, 1432, 12435, 12534, 12543 and so on, i.e., for a given m we always have 3 permutations.
a(3) = 1 because the 3rd excedance set is {m-2, m-1} and the permutations of {1,2,...,m} with such excedance set are 231, 1342, 12453 and so on, i.e., for a given m we always have 1 permutation.
		

Crossrefs

Programs

  • Maple
    g:= proc(n) option remember;  2^padic[ordp](n, 2) end:
    a:= proc(n) option remember; `if`(n=0, 1, (h-> a(h)+
         `if`(n::odd, 0, (t-> a(h-t)+a(n-t))(g(h))))(iquo(n, 2)))
        end:
    seq(a(n), n=0..100);  # Alois P. Heinz, Jan 30 2023
  • Mathematica
    a[n_] := a[n] = Which[n == 0, 1, OddQ[n], a[(n-1)/2], True, a[n/2] + a[n/2 - 2^IntegerExponent[n/2, 2]] + a[n - 2^IntegerExponent[n/2, 2]]];
    a /@ Range[0, 65] (* Jean-François Alcover, Feb 13 2020 *)
  • PARI
    upto(n) = my(A, v1); v1 = vector(n+1, i, 0); v1[1] = 1; for(i=1, n, v1[i+1] = v1[i\2+1] + if(i%2, 0, A = 1 << valuation(i/2, 2); v1[i/2-A+1] + v1[i-A+1])); v1 \\ Mikhail Kurkov, Jun 06 2024

Formula

a(2n+1) = a(n) for n >= 0.
a(2n) = a(n) + a(n - 2^f(n)) + a(2n - 2^f(n)) for n > 0 with a(0) = 1 where f(n) = A007814(n) (equivalent to proposition 2.1 at the page 286, see R. Ehrenborg and E. Steingrimsson link).
a(2^m*(2n+1)) = Sum_{k=0..m} binomial(m+1,k) a(2^k*n) = a(2^m*n) + a(2^(m-1)*(2n+1)) + a(2^(m-1)*(4n+1)) for m > 0, n >= 0 (equivalent to proposition 2.5 at the page 287, see R. Ehrenborg and E. Steingrimsson link).
a(2n) = a(2*g(n)) + a(2n - 2^h(n)) + a(2*g(n) + 2^h(n)) for n > 0 with a(0) = 1 where g(n) = A053645(n), h(n) = A063250(n) (equivalent to proposition 2.1 at the page 286, see R. Ehrenborg and E. Steingrimsson link).
a(2n) = 2*a(n + g(n)) + a(2*g(n)) for n > 0, floor(n/3) < 2^(floor(log_2(n))-1) (in other words, for 2^m + k where 0 <= k < 2^(m-1), m > 0) with a(0) = 1 (just a special case of the previous formula, because for 2^m + k where 0 <= k < 2^(m-1), m > 0 we have 2^h(n) = n - g(n)).
a(2n) = a(f(n,-1)) + a(f(n,0)) + a(f(n,1)) for n > 0 with a(0) = 1 where f(n,k) = 2*(f(floor(n/2),k) + n mod 2) + k*A036987(n) for n > 1 with f(1,k) = abs(k) (equivalent to a(2n) = a(2*g(n)) + a(2n - 2^h(n)) + a(2*g(n) + 2^h(n))).
a(n) = Sum_{j=0..2^wt(n) - 1} (-1)^(wt(n) - wt(j)) Product_{k=0..wt(n) - 1} (1 + wt(floor(j/2^k)))^T(n,k) for n > 0 with a(0) = 1 where wt(n) = A000120(n), T(n,k) = T(floor(n/2), k - n mod 2) for k > 0 with T(n,0) = A001511(n) (equivalent to theorem 6.3 at page 296, see R. Ehrenborg and E. Steingrimsson link). Here T(n, k) - 1 for k > 0 is the length of the run of zeros between k-th pair of ones from the right side in the binary expansion of n. Conjecture 1: this formula is equivalent to inverse modulo 2 binomial transform of A284005.
Sum_{k=0..2^n-1} a(k) = (n+1)! for n >= 0.
a((4^n-1)/3) = A110501(n+1) for n >= 0.
a(2^2*(2^n-1)) = A091344(n+1),
a(2^3*(2^n-1)) = A091347(n+1),
a(2^4*(2^n-1)) = A091348(n+1).
More generally, a(2^m*(2^n-1)) = a(2^n*(2^m-1)) = S(n+1,m) for n >= 0, m >= 0 where S(n,m) = Sum_{k=1..n} k!*k^m*Stirling2(n,k)*(-1)^(n-k) (equivalent to proposition 6.5 at the page 297, see R. Ehrenborg and E. Steingrimsson link).
Conjecture 2: a(n) = (1 + A023416(n))*a(g(n)) + Sum_{k=0..floor(log_2(n))-1} (1-R(n,k))*a(g(n) + 2^k*(1 - R(n,k))) for n > 1 with a(0) = 1, a(1) = 1, where g(n) = A053645(n) and where R(n,k) = floor(n/2^k) mod 2 (at this moment this is the only formula here, which is not related to R. Ehrenborg's and E. Steingrimsson's work and arises from another definition given above, exactly conjectured definition with a biased rook). Here R(n,k) is the (k+1)-th bit from the right side in the binary expansion of n. - Mikhail Kurkov, Jun 23 2021
From Mikhail Kurkov, Jan 23 2023: (Start)
The formulas below are not related to R. Ehrenborg's and E. Steingrimsson's work.
Conjecture 3: a(n) = A357990(n, 1) for n >= 0.
Conjecture 4: a(2^m*(2k+1)) = Sum_{i=1..wt(k) + 2} i!*i^m*A358612(k, i)*(-1)^(wt(k) - i) for m >= 0, k >= 0 where wt(n) = A000120(n).
Conjecture 5: a(2^m*(2^n - 2^p - 1)) = Sum_{i=1..n} i!*i^m*(-1)^(n - i)*((i - p + 1)*Stirling2(n, i) - Stirling2(n - p, i - p) + Sum_{j=0..p-2} (p - j - 1)*Stirling2(n - p, i - j)/j! Sum_{k=0..j} (i - k)^p*binomial(j, k)*(-1)^k) for n > 2, m >= 0, 0 < p < n - 1. Here we consider that Stirling2(n, k) = 0 for n >= 0, k < 0. (End)
Conjecture 6: a(2^m*n + q) = Sum_{i=A001511(n+1)..A000120(n)+1} A373183(n, i)*a(2^m*(2^(i-1)-1) + q) for n >= 0, m >= 0, q >= 0. Note that this formula is recursive for n != 2^k - 1. Also, it is not related to R. Ehrenborg's and E. Steingrimsson's work. - Mikhail Kurkov, Jun 05 2024
From Mikhail Kurkov, Jul 10 2024: (Start)
a(2^m*(2^n*(2k+1) - 1)) = Sum_{i=1..m+1} a(2^i*k)*(-1)^(m-i+1)*Sum_{j=i..m+1} j^n*Stirling1(j, i)*Stirling2(m+1, j) for m >= 0, n >= 0, k >= 0 with a(0) = 1.
Proof: start with a(2^m*(2n+1)) = Sum_{k=0..m} binomial(m+1,k) a(2^k*n) given above and rewrite it as a(2^m*(2^n*(2k+1) - 1)) = Sum_{i=0..m} binomial(m+1, i) a(2^i*(2^(n-1)*(2k+1) - 1)).
Then conjecture that a(2^m*(2^n*(2k+1) - 1)) = Sum_{i=1..m+1} a(2^i*k)*f(n, m, i). From that it is obvious that f(0, m, i) = [i = (m+1)].
After that use a(2^m*(2^n*(2k+1) - 1)) = Sum_{i=0..m} binomial(m+1, i) Sum_{j=1..i+1} a(2^j*k)*f(n-1, i, j) = Sum_{i=1..m+1} a(2^i*k) Sum_{j=i-1..m} binomial(m+1, j)*f(n-1, j, i). From that it is obvious that f(n, m, i) = Sum_{j=i-1..m} binomial(m+1, j)*f(n-1, j, i).
Finally, all we need is to show that basic conditions and recurrence for f(n, m, i) gives f(n, m, i) = (-1)^(m-i+1)*Sum_{j=i..m+1} j^n*Stirling1(j, i)*Stirling2(m+1, j) (see Max Alekseyev link).
a(2^m*(2k+1)) = a(2^(m-1)*k) + (m+1)*a(2^m*k) + Sum_{i=1..m-1} a(2^m*k + 2^i) for m > 0, k >= 0.
Proof: start with a(2^(m+1)*(2k+1)) = a(2^m*k) + (m+2)*a(2^(m+1)*k) + Sum_{i=1..m} a(2^(m+1)*k + 2^i).
Then use a(2^m*(4k+1)) = a(2^m*k) + (m+1)*a(2^(m+1)*k) + Sum_{i=1..m-1} a(2^(m+1)*k + 2^i).
From that we get a(2^(m+1)*(2k+1)) - a(2^m*k) - (m+2)*a(2^(m+1)*k) - a(2^(m+1)*k + 2^m) = a(2^m*(4k+1)) - a(2^m*k) - (m+1)*a(2^(m+1)*k).
Finally, a(2^(m+1)*(2k+1)) = a(2^(m+1)*k) + a(2^m*(2*k+1)) + a(2^m*(4k+1)) which agrees with the a(2^m*(2n+1)) = a(2^m*n) + a(2^(m-1)*(2n+1)) + a(2^(m-1)*(4n+1)) given above.
This formula can be considered as an alternative to a(2^m*(2n+1)) = Sum_{k=0..m} binomial(m+1,k) a(2^k*n). There are algorithms for both these formulas that allow you to calculate them without recursion. However, even though it is necessary to calculate binomial coefficients in the mentioned formula, the triple-looped algorithm for it still works faster (see Peter J. Taylor link).
It looks like you can also change v2 in the mentioned algorithm to vector with elements a(2^m*(2^(i+A007814(n+1)-1)-1) + q) to get a(2^m*n + q) instead of a(n). This may have common causes with formula that uses A373183 given above. (End)
From Mikhail Kurkov, Jan 27 2025: (Start)
The formulas below are not related to R. Ehrenborg's and E. Steingrimsson's work.
Conjecture 7: A008292(n+1,k+1) = Sum_{i=0..2^n-1} [A000120(i) = k]*a(i) for n >= 0, k >= 0.
Conjecture 8: a(2^m*(2^n*(2k+1)-1)) = Sum_{i=0..m} Sum_{j=0..m-i} Sum_{q=0..i} binomial(m-i,j)*(m-j+1)^n*a(2^(q+1)*k)*L(m,i,q)*(-1)^j for m >= 0, n > 0, k >= 0 where L(n,k,m) = W(n-m,k-m,m+1) for n > 0, 0 <= k < n, 0 <= m <= k and where W(n,k,m) = (k+m)*W(n-1,k,m) + (n-k)*W(n-1,k-1,m) + [m > 1]*W(n,k,m-1) for 0 <= k < n, m > 0 with W(0,0,m) = 1, W(n,k,m) = 0 for n < 0 or k < 0.
In particular, W(n, k, 1) = A173018(n, k), W(n, k, 2) = A062253(n, k), W(n, k, 3) = A062254(n, k) and W(n, k, 4) = A062255(n, k).
Conjecture 9: a(n) = b(n,wt(n)) for n >= 0 where b(2n+1,k) = b(n,k) + (wt(n)-k+2)*b(n,k-1), b(2n,k) = (wt(n)-k+1)*b(2n+1,k) for n > 0, k > 0 with b(n,0) = A341392(n) for n >= 0, b(0,k) = 0 for k > 0 and where wt(n) = A000120(n) (see A379817).
More generally, a(2^m*(2k+1)) = ((m+1)!)^2*b(k,wt(k)-m) - Sum_{j=1..m} Stirling1(m+2,j+1)*a(2^(j-1)*(2k+1)) for m >= 0, k >= 0. Here we also consider that b(n,k) = 0 for k < 0. (End)
Conjecture 10: if we change b(n,0) = A341392(n) given above to b(n,0) = A341392(n)*x^n, then nonzero terms of the resulting polynomials for b(n,wt(n)) form c(n,k) such that a(n) = Sum_{k=0..A080791(n)} c(n,k) for n >= 0 where c(n,k) = (Product_{i=0..k-1} (1 + 1/A000120(floor(n/2^(A000523(n)-i))))) * Sum_{j=max{0,k-A080791(n)+A080791(A053645(n))}..A080791(A053645(n))} c(A053645(n),j) for n > 0, k >= 0 with c(0,0) = 1, c(0,k) = 0 for k > 0. - Mikhail Kurkov, Jun 19 2025

A284005 a(0) = 1, and for n > 1, a(n) = (1 + A000120(n))*a(floor(n/2)); also a(n) = A000005(A283477(n)).

Original entry on oeis.org

1, 2, 4, 6, 8, 12, 18, 24, 16, 24, 36, 48, 54, 72, 96, 120, 32, 48, 72, 96, 108, 144, 192, 240, 162, 216, 288, 360, 384, 480, 600, 720, 64, 96, 144, 192, 216, 288, 384, 480, 324, 432, 576, 720, 768, 960, 1200, 1440, 486, 648, 864, 1080, 1152, 1440, 1800, 2160, 1536, 1920, 2400, 2880, 3000
Offset: 0

Views

Author

Antti Karttunen, Mar 18 2017

Keywords

Crossrefs

Similar recurrences: A124758, A243499, A329369, A341392.

Programs

  • Mathematica
    Table[DivisorSigma[0, #] &@ Apply[Times, Map[#1^#2 & @@ # &, FactorInteger[#] /. {p_, e_} /; e == 1 :> {Times @@ Prime@ Range@ PrimePi@ p, e}]] &[Times @@ Prime@ Flatten@ Position[#, 1] &@ Reverse@ IntegerDigits[n, 2]], {n, 0, 71}] (* Michael De Vlieger, Mar 18 2017 *)
  • PARI
    A284005(n) = numdiv(A283477(n)); \\ edited by Michel Marcus, May 01 2019, M. F. Hasler, Nov 10 2019
    
  • PARI
    a(n) = my(k=if(n,logint(n,2)),s=1); prod(i=0,k, s+=bittest(n,k-i)); \\ Kevin Ryde, Jan 20 2021
  • Scheme
    (define (A284005 n) (A000005 (A283477 n)))
    

Formula

a(n) = A000005(A283477(n)).
Conjecture: a(n) = 2*a(f(n)) + Sum_{k=0..floor(log_2(n))-1} a(f(n) + 2^k*(1 - T(n,k))) for n > 1 with a(0) = 1, a(1) = 2, f(n) = A053645(n), T(n,k) = floor(n/2^k) mod 2. - Mikhail Kurkov, Nov 10 2019
From Mikhail Kurkov, Aug 23 2021: (Start)
a(2n+1) = a(n) + a(2n) for n >= 0.
a(2n) = a(n) + a(2n - 2^A007814(n)) for n > 0 with a(0) = 1. (End)
Conjecture: a(n) = Sum_{k=0..n} (binomial(n, k) mod 2)*A329369(k). In other words, this sequence is modulo 2 binomial transform of A329369. - Mikhail Kurkov, Mar 10 2023
Conjecture: a(2^m*(2n+1)) = Sum_{k=0..m+1} binomial(m+1, k)*a(2^k*n) for m >= 0, n >= 0 with a(0) = 1. - Mikhail Kurkov, Apr 24 2023

Extensions

Made Mikhail Kurkov's Nov 10 2019 formula the new primary name of this sequence - Antti Karttunen, Dec 30 2020

A243499 Product of parts of integer partitions as enumerated in the table A125106.

Original entry on oeis.org

1, 1, 2, 1, 3, 2, 4, 1, 4, 3, 6, 2, 9, 4, 8, 1, 5, 4, 8, 3, 12, 6, 12, 2, 16, 9, 18, 4, 27, 8, 16, 1, 6, 5, 10, 4, 15, 8, 16, 3, 20, 12, 24, 6, 36, 12, 24, 2, 25, 16, 32, 9, 48, 18, 36, 4, 64, 27, 54, 8, 81, 16, 32, 1, 7, 6, 12, 5, 18, 10, 20, 4, 24, 15, 30, 8, 45, 16, 32, 3
Offset: 0

Views

Author

Antti Karttunen, Jun 28 2014

Keywords

Comments

This sequence and A341392 have the same set of values on intervals from 2^m to 2^(m+1) - 1 for m >= 0. - Mikhail Kurkov, Jun 18 2021 [verification needed]

Crossrefs

Cf. A125106, A161511 (gives the corresponding sums), A227184, A003963, A243504, A006068, A005940, A163511, A000110, A007814, A023416, A053645, A329369 (similar recurrence), A341392.

Programs

  • Scheme
    (define (A243499 n) (let loop ((n n) (i 1) (p 1)) (cond ((zero? n) p) ((even? n) (loop (/ n 2) (+ i 1) p)) (else (loop (/ (- n 1) 2) i (* p i))))))

Formula

Can also be obtained by mapping with an appropriate permutation from the products of parts of each partition computed for other enumerations similar to A125106:
a(n) = A227184(A006068(n)).
a(n) = A003963(A005940(n+1)).
a(n) = A243504(A163511(n)).
From Mikhail Kurkov, Jul 11 2021: (Start)
a(n) = (1 + A023416(n))*a(A053645(n)) for n > 0 with a(0) = 1.
a(2n+1) = a(n) for n >= 0.
a(2n) = A341392(2*A059894(n)) = a(n - 2^f(n)) + a(2n - 2^f(n)) = (2 + f(n))*a(n - 2^f(n)) for n > 0 with a(0)=1 where f(n) = A007814(n).
Sum_{k=0..2^n - 1} a(k) = A000110(n+1) for n >= 0.
a((4^n - 1)/3) = n! for n >= 0.
a(2^m*(2^n - 1)) = (m+1)^n for n >= 0, m >= 0. (End) [verification needed]

A111528 Square table, read by antidiagonals, where the g.f. for row n+1 is generated by: x*R_{n+1}(x) = (1+n*x - 1/R_n(x))/(n+1) with R_0(x) = Sum_{n>=0} n!*x^n.

Original entry on oeis.org

1, 1, 1, 1, 1, 2, 1, 1, 3, 6, 1, 1, 4, 13, 24, 1, 1, 5, 22, 71, 120, 1, 1, 6, 33, 148, 461, 720, 1, 1, 7, 46, 261, 1156, 3447, 5040, 1, 1, 8, 61, 416, 2361, 10192, 29093, 40320, 1, 1, 9, 78, 619, 4256, 23805, 99688, 273343, 362880, 1, 1, 10, 97, 876, 7045, 48096, 263313
Offset: 0

Views

Author

Paul D. Hanna, Aug 06 2005

Keywords

Examples

			Table begins:
  1, 1,  2,   6,   24,   120,    720,    5040,     40320, ...
  1, 1,  3,  13,   71,   461,   3447,   29093,    273343, ...
  1, 1,  4,  22,  148,  1156,  10192,   99688,   1069168, ...
  1, 1,  5,  33,  261,  2361,  23805,  263313,   3161781, ...
  1, 1,  6,  46,  416,  4256,  48096,  591536,   7840576, ...
  1, 1,  7,  61,  619,  7045,  87955, 1187845,  17192275, ...
  1, 1,  8,  78,  876, 10956, 149472, 2195208,  34398288, ...
  1, 1,  9,  97, 1193, 16241, 240057, 3804353,  64092553, ...
  1, 1, 10, 118, 1576, 23176, 368560, 6262768, 112784896, ...
Rows are generated by logarithms of factorial series:
log(1 + x + 2*x^2 + 6*x^3 + 24*x^4 + ... n!*x^n + ...) = x + (3/2)*x^2 + (13/3)*x^3 + (71/4)*x^4 + (461/5)*x^5 + ...
(1/2)*log(1 + 2*x + 6*x^2 + ... + ((n+1)!/1!)*x^n + ...) = x + (4/2)*x^2 + (22/3)*x^3 + (148/4)*x^4 + (1156/5)*x^5 + ...
(1/3)*log(1 + 3*x + 12*x^2 + 60*x^3 + ... + ((n+2)!/2!)*x^n + ...) = x + (5/2)*x^2 + (33/3)*x^3 + (261/4)*x^4 + (2361/5)*x^5 +...
G.f. of row n may be expressed by the continued fraction:
R_n(x) = 1/(1+n*x - (n+1)*x/(1+(n+1)*x - (n+2)*x/(1+(n+2)*x -...
or recursively by: R_n(x) = 1/(1+n*x - (n+1)*x*R_{n+1}(x)).
		

Crossrefs

Cf: A003319 (row 1), A111529 (row 2), A111530 (row 3), A111531 (row 4), A111532 (row 5), A111533 (row 6), A111534 (diagonal).
Similar recurrences: A124758, A243499, A284005, A329369, A341392.

Programs

  • Maple
    T := (n, k) -> coeff(series(hypergeom([n+1, 1], [], x)/hypergeom([n, 1], [], x), x, 21), x, k):
    #display as a sequence
    seq(seq(T(n-k, k), k = 0..n), n = 0..10);
    # display as a square array
    seq(print(seq(T(n, k), k = 0..10)), n = 0..10); # Peter Bala, Jul 16 2022
  • Mathematica
    T[n_, k_] := T[n, k] = Which[n < 0 || k < 0, 0, k == 0 || k == 1, 1, n == 0, k!, True, (T[n - 1, k + 1] - T[n - 1, k])/n - Sum[T[n, j]*T[n - 1, k - j], {j, 1, k - 1}]]; Table[T[n - k, k], {n, 0, 10}, {k, 0, n}] // Flatten (* Jean-François Alcover, Feb 18 2018 *)
  • PARI
    {T(n,k)=if(n<0||k<0,0,if(k==0||k==1,1,if(n==0,k!, (T(n-1,k+1)-T(n-1,k))/n-sum(j=1,k-1,T(n,j)*T(n-1,k-j)))))}
    for(n=0,10,for(k=0,10,print1(T(n,k),", ")); print(""))
    
  • PARI
    {T(n,k)=if(n<0||k<0,0,if(k==0,1,if(n==0,k!, k/n*polcoeff(log(sum(m=0,k,(n-1+m)!/(n-1)!*x^m)),k))))}
    for(n=0,10,for(k=0,10,print1(T(n,k),", ")); print(""))

Formula

T(n, 0) = 1, T(0, k) = k!, otherwise for n>=1 and k>=1:
T(n, k) = (T(n-1, k+1) - T(n-1, k))/n - Sum_{j=1..k-1} T(n, j)*T(n-1, k-j).
T(n, k) = (k/n)*[x^k] log(Sum_{m=0..k} (n-1+m)!/(n-1)!*x^m).
T(n, k) = Sum_{j = 0..k} A089949(k, j)*n^(k-j). - Philippe Deléham, Aug 08 2005
R_n(x) = -((n-1)!/n)/Sum_{i>=1} (i+n-2)!*x^i, n > 0. - Vladeta Jovovic, May 06 2006
G.f. of row R may be expressed by the continued fraction: W(0), where W(k) = 1 - x*(k+1)/( x*(k+1) - 1/(1 - x*(k+1+R)/( x*(k+1+R) - 1/W(k+1) ))). - Sergei N. Gladkovskii, Aug 26 2013
Conjecture: T(n, k) = b(2^(k-1) - 1, n) for k > 0 with T(n, 0) = 1 where b(n, m) = b(floor(n/2), m) + b(floor((2n - 2^A007814(n))/2), m) + m*b(A025480(n-1), m) for n > 0 with b(0, m) = 1. - Mikhail Kurkov, Dec 16 2021
From Peter Bala, Jul 11 2022: (Start)
O.g.f. for row n, n >= 1: R(n,x) = ( Sum_{k >= 0} (n+k)!/n!*x^k )/( Sum_{k >= 0} (n-1+k)!/(n-1)!*x^k ).
R(n,x)/(1 - n*x*R(n,x)) = Sum_{k >= 0} (n+k)!/n!*x^k.
For n >= 0, R(n,x) satisfies the Riccati equation x^2*d/dx(R(n,x)) + n*x*R(n,x)^2 - (1 + (n-1)*x)*R(n,x) + 1 = 0 with R(n,0) = 1.
Apply Stokes 1982 to find that for n >= 0, R(n,x) = 1/(1 - x/(1 - (n+1)*x/(1 - 2*x/(1 - (n+2)*x/(1 - 3*x/(1 - (n+3)*x/(1 - 4*x/(1 - (n+4)*x/(1 - ...))))))))), a continued fraction of Stieltjes type. (End)

A011965 Second differences of Bell numbers.

Original entry on oeis.org

1, 2, 7, 27, 114, 523, 2589, 13744, 77821, 467767, 2972432, 19895813, 139824045, 1028804338, 7905124379, 63287544055, 526827208698, 4551453462543, 40740750631417, 377254241891064, 3608700264369193, 35613444194346451, 362161573323083920, 3790824599495473121
Offset: 0

Views

Author

Keywords

Comments

Number of partitions of n+3 with at least one singleton and with the smallest element in a singleton equal to 3. Alternatively, number of partitions of n+3 with at least one singleton and with the largest element in a singleton equal to n+1. - Olivier GERARD, Oct 29 2007
Out of the A005493(n) set partitions with a specific two elements clustered separately, number that have a different set of two elements clustered separately. - Andrey Goder (andy.goder(AT)gmail.com), Dec 17 2007

References

  • Olivier Gérard and Karol A. Penson, A budget of set partition statistics, in preparation, unpublished as of Sep 22 2011.

Crossrefs

Programs

  • Magma
    [Bell(n+2) -2*Bell(n+1) + Bell(n): n in [0..40]]; // G. C. Greubel, Jan 07 2025
    
  • Maple
    a:= n-> add((-1)^k*binomial(2,k)*combinat['bell'](n+k), k=0..2): seq(a(n), n=0..20);  # Alois P. Heinz, Sep 05 2008
  • Mathematica
    Differences[BellB[Range[0, 30]], 2] (* Vladimir Joseph Stephan Orlovsky, May 25 2011 *)
  • Python
    # requires python 3.2 or higher. Otherwise use def'n of accumulate in python docs.
    from itertools import accumulate
    A011965_list, blist, b = [1], [1, 2], 2
    for _ in range(1000):
        blist = list(accumulate([b]+blist))
        b = blist[-1]
        A011965_list.append(blist[-3])
    # Chai Wah Wu, Sep 02 2014
    
  • Python
    # or Sagemath
    b=bell_number
    print([b(n+2) -2*b(n+1) +b(n) for n in range(41)]) # G. C. Greubel, Jan 07 2025

Formula

a(n) = A005493(n) - A005493(n-1).
E.g.f.: exp(exp(x)-1)*(exp(2*x)-exp(x)+1). - Vladeta Jovovic, Feb 11 2003
a(n) = A000110(n) - 2*A000110(n-1) + A000110(n-2). - Andrey Goder (andy.goder(AT)gmail.com), Dec 17 2007
G.f.: G(0) where G(k) = 1 - 2*x*(k+1)/((2*k+1)*(2*x*k+2*x-1) - x*(2*k+1)*(2*k+3)*(2*x*k+2*x-1)/(x*(2*k+3) - 2*(k+1)*(2*x*k+3*x-1)/G(k+1) )); (recursively defined continued fraction). - Sergei N. Gladkovskii, Dec 19 2012
G.f.: 1 - G(0) 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
G.f.: 1 - 1/x + (1-x)^2/x/(G(0)-x) where G(k) = 1 - x*(k+1)/(1 - x/G(k+1) ); (recursively defined continued fraction). - Sergei N. Gladkovskii, Jan 26 2013
G.f.: G(0)*(1-1/x) where G(k) = 1 - 1/(1-x*(k+1))/(1-x/(x-1/G(k+1) )); (recursively defined continued fraction). - Sergei N. Gladkovskii, Feb 07 2013
a(n) ~ n^2 * Bell(n) / LambertW(n)^2 * (1 - 2*LambertW(n)/n). - Vaclav Kotesovec, Jul 28 2021
Conjecture: a(n) = Sum_{k=0..2^n - 1} b(k) for n >= 0 where b(2n+1) = b(n) + b(A025480(n-1)), b(2n) = b(n - 2^f(n)) + b(2n - 2^f(n)) + b(A025480(n-1)) for n > 0 with b(0) = b(1) = 1 and where f(n) = A007814(n). Also b((4^n - 1)/3) = A141154(n+1). - Mikhail Kurkov, Jan 27 2022

A217924 a(n) = n! * [x^n] exp(2*exp(x) - x - 2). Row sums of triangle A217537.

Original entry on oeis.org

1, 1, 3, 9, 35, 153, 755, 4105, 24323, 155513, 1064851, 7760745, 59895203, 487397849, 4166564147, 37298443977, 348667014723, 3395240969785, 34365336725715, 360837080222761, 3923531021460707, 44108832866004121, 511948390801374835, 6126363766802713481
Offset: 0

Views

Author

Peter Luschny, Oct 15 2012

Keywords

Comments

The inverse binomial transform of a(n) is A194689.
A087981(n) = Sum_{k=0..n} (-1)^k*s(n+1,k+1)*a(k);
|A000023(n)| = |Sum_{k=0..n} (-1)^(n-k)*s(n,k)*a(k)|
where s(n,k) are the unsigned Stirling numbers of first kind.
a(n) is the number of inequivalent set partitions of {1,2,...,n} where two blocks are considered equivalent when one can be obtained from the other by an alternating (even) permutation. - Geoffrey Critzer, Mar 17 2013

Examples

			a(3)=9 because we have: {1,2,3}; {1,3,2}; {1}{2,3}; {1}{3,2}; {2}{1,3}; {2}{3,1}; {3}{1,2}; {3}{2,1}; {1}{2}{3}. - _Geoffrey Critzer_, Mar 17 2013
		

Crossrefs

Similar recurrences: A124758, A243499, A284005, A329369, A341392, A372205.

Programs

  • Magma
    R:=PowerSeriesRing(Rationals(), 30);
    Coefficients(R!(Laplace( Exp(2*Exp(x) -x-2) ))); // G. C. Greubel, Jan 09 2025
  • Maple
    egf := exp(2*exp(x) - x - 2): ser := series(egf, x, 25):
    seq(n!*coeff(ser, x, n), n = 0..23);  # Peter Luschny, Apr 22 2024
  • Mathematica
    nn=23;Range[0,nn]!CoefficientList[Series[Exp[2 Exp[x]-x-2],{x,0,nn}],x]  (* Geoffrey Critzer, Mar 17 2013 *)
    nmax = 25; CoefficientList[Series[1/(1 - x + ContinuedFractionK[-2*k*x^2 , 1 - (k + 1)*x, {k, 1, nmax}]), {x, 0, nmax}], x] (* Vaclav Kotesovec, Sep 25 2017 *)
  • Maxima
    a(n):=sum(sum(binomial(n,k-j)*2^j*(-1)^(k-j)*stirling2(n-k+j,j),j,0,k),k,0,n); /* Vladimir Kruchinin, Feb 28 2015 */
    
  • Sage
    def A217924_list(n):
        T = A217537_triangle(n)
        return [add(T.row(n)) for n in range(n)]
    A217924_list(24)
    
  • SageMath
    def A217924_list(prec):
        P. = PowerSeriesRing(QQ, prec)
        return P( exp(2*exp(x)-x-2) ).egf_to_ogf().list()
    print(A217924_list(40)) # G. C. Greubel, Jan 09 2025
    

Formula

G.f.: 1/Q(0) where Q(k) = 1 + x*k - x/(1 - 2*x*(k+1)/Q(k+1) ); (continued fraction). - Sergei N. Gladkovskii, Mar 06 2013
E.g.f.: exp(2*exp(x) - x - 2). - Geoffrey Critzer, Mar 17 2013
G.f.: 1/Q(0), where Q(k) = 1 - (k+1)*x - 2*(k+1)*x^2/Q(k+1); (continued fraction). - Sergei N. Gladkovskii, May 03 2013
G.f.: T(0)/(1-x), where T(k) = 1 - 2*x^2*(k+1)/( 2*x^2*(k+1) - (1-x-x*k)*(1-2*x-x*k)/T(k+1) ); (continued fraction). - Sergei N. Gladkovskii, Oct 19 2013
a(n) = Sum_{k=0..n} Sum_{j=0..k} binomial(n,k-j)*2^j*(-1)^(k-j)*Stirling2(n-k+j,j). - Vladimir Kruchinin, Feb 28 2015
a(n) = exp(-2) * Sum_{k>=0} 2^k * (k - 1)^n / k!. - Ilya Gutkovskiy, Jun 27 2020
Conjecture: a(n) = Sum_{k=0..2^n-1} A372205(k). - Mikhail Kurkov, Nov 21 2021 [Rewritten by Peter Luschny, Apr 22 2024]
a(n) ~ 2 * n^(n-1) * exp(n/LambertW(n/2) - n - 2) / (sqrt(1 + LambertW(n/2)) * LambertW(n/2)^(n-1)). - Vaclav Kotesovec, Jun 26 2022

Extensions

Name extended by a formula of Geoffrey Critzer by Peter Luschny, Apr 22 2024

A347205 a(2n+1) = a(n) for n >= 0, a(2n) = a(n) + a(n - 2^A007814(n)) for n > 0 with a(0) = 1.

Original entry on oeis.org

1, 1, 2, 1, 3, 2, 3, 1, 4, 3, 5, 2, 6, 3, 4, 1, 5, 4, 7, 3, 9, 5, 7, 2, 10, 6, 9, 3, 10, 4, 5, 1, 6, 5, 9, 4, 12, 7, 10, 3, 14, 9, 14, 5, 16, 7, 9, 2, 15, 10, 16, 6, 19, 9, 12, 3, 20, 10, 14, 4, 15, 5, 6, 1, 7, 6, 11, 5, 15, 9, 13, 4, 18, 12, 19, 7, 22, 10, 13
Offset: 0

Views

Author

Mikhail Kurkov, Aug 23 2021

Keywords

Comments

Scatter plot might be called "Cypress forest on a windy day". - Antti Karttunen, Nov 30 2021

Crossrefs

Programs

  • Mathematica
    a[0] = 1; a[n_] := a[n] = If[OddQ[n], a[(n - 1)/2], a[n/2] + a[n/2 - 2^IntegerExponent[n/2, 2]]]; Array[a, 100, 0] (* Amiram Eldar, Sep 06 2021 *)
  • PARI
    a(n) = if (n==0, 1, if (n%2, a(n\2), a(n/2) + a(n/2 - 2^valuation(n/2, 2)))); \\ Michel Marcus, Sep 09 2021

Formula

a(2n+1) = a(n) for n >= 0.
a(2n) = a(n) + a(n - 2^A007814(n)) = a(2*A059894(n)) for n > 0 with a(0) = 1.
Sum_{k=0..2^n - 1} a(k) = A000108(n+1) for n >= 0.
a((4^n - 1)/3) = A000108(n) for n >= 0.
a(2^m*(2^n - 1)) = binomial(n + m, n) for n >= 0, m >= 0.
Generalization:
b(2n+1, p, q) = b(n, p, q) for n >= 0.
b(2n, p, q) = p*b(n, p, q) + q*b(n - 2^A007814(n), p, q) = for n > 0 with b(0, p, q) = 1.
Conjectured formulas: (Start)
Sum_{k=0..2^n - 1} b(k, 2, 1) = A006318(n) for n >= 0.
Sum_{k=0..2^n - 1} b(k, 2, 2) = A115197(n) for n >= 0.
Sum_{k=0..2^n - 1} b(k, 3, 1) = A108524(n+1) for n >= 0.
Sum_{k=0..2^n - 1} b(k, 3, 3) = A116867(n) for n >= 0.
b((4^n - 1)/3, p, q) is generalized Catalan number C(p, q; n). (End)
Conjecture: a(n) = T(n, wt(n)+1), a(2n) = Sum_{k=1..wt(n)+1} T(n, k) where T(2n+1, k) = T(n, k) for 1 <= k <= wt(n)+1, T(2n+1, wt(n)+2) = T(n, wt(n)+1), T(2n, k) = Sum_{i=1..k} T(n, i) for 1 <= k <= wt(n)+1 with T(0, 1) = 1. - Mikhail Kurkov, Dec 13 2024

A090365 Shifts 1 place left under the INVERT transform of the BINOMIAL transform of this sequence.

Original entry on oeis.org

1, 1, 3, 11, 47, 225, 1177, 6625, 39723, 251939, 1681535, 11764185, 86002177, 655305697, 5193232611, 42726002123, 364338045647, 3215471252769, 29331858429241, 276224445794785, 2682395337435723, 26832698102762435, 276221586866499839, 2923468922184615897
Offset: 0

Views

Author

Paul D. Hanna, Nov 26 2003

Keywords

Comments

The Hankel transform of this sequence is A000178(n+1); example: det([1,1,3; 1,3,11; 3,11,47]) = 12. - Philippe Deléham, Mar 02 2005
a(n) appears to be the number of indecomposable permutations (A003319) of [n+1] that avoid both of the dashed patterns 32-41 and 41-32. - David Callan, Aug 27 2014
This is true: A nonempty permutation avoids 32-41 and 41-32 if and only if all its components do so. So if A(x) denotes the g.f. for indecomposable {32-41,41-32}-avoiders, then F(x):=1/(1-A(x)) is the g.f. for all {32-41,41-32}-avoiders. From A074664, F(x)=1/x(1-1/B(x)) where B(x) is the o.g.f. for the Bell numbers. Solve for A(x). - David Callan, Jul 21 2017
The Hankel transform of this sequence without the a(0)=1 term is also A000178(n+1). - Michael Somos, Oct 02 2024

Crossrefs

Programs

  • Maple
    bintr:= proc(p) proc(n) add(p(k) *binomial(n,k), k=0..n) end end:
    invtr:= proc(p) local b;
               b:= proc(n) option remember; local i;
                    `if`(n<1, 1, add(b(n-i) *p(i-1), i=1..n+1))
                   end;
            end:
    b:= invtr(bintr(a)):
    a:= n-> `if`(n<0, 0, b(n-1)):
    seq(a(n), n=0..30);  # Alois P. Heinz, Jun 28 2012
  • Mathematica
    a[n_] := Module[{A, B}, A = 1+x; For[k=1, k <= n, k++, B = (A /. x -> x/(1 - x))/(1-x) + O[x]^n // Normal; A = 1 + x*A*B]; SeriesCoefficient[A, {x, 0, n}]]; Table[a[n], {n, 0, 23}] (* Jean-François Alcover, Oct 23 2016, adapted from PARI *)
  • PARI
    {a(n)=local(A); if(n<0,0,A=1+x+x*O(x^n); for(k=1,n,B=subst(A,x, x/(1-x))/(1-x)+x*O(x^n); A=1+x*A*B);polcoeff(A,n,x))}

Formula

G.f.: A(x) satisfies A(x) = 1/(1 - A(x/(1-x))*x/(1-x) ).
a(n) = Sum_{k = 0..n} A085838(n, k). - Philippe Deléham, Jun 04 2004
G.f.: 1/x-1-1/(B(x)-1) where B(x) = g.f. for A000110 the Bell numbers. - Vladeta Jovovic, Aug 08 2004
a(n) = Sum_{k=0..n} A094456(n,k). - Philippe Deléham, Nov 07 2007
G.f.: 1/(1-x/(1-2x/(1-x/(1-3x/(1-x/(1-4x/(1-x/(1-5x/(1-... (continued fraction). - Paul Barry, Feb 25 2010
From Sergei N. Gladkovskii, Jan 06 2012 - May 12 2013: (Start)
Continued fractions:
G.f.: 1 - x/(G(0)+x); G(k) = x - 1 + x*k + x*(x-1+x*k)/G(k+1).
G.f.: 1/x - 1/2 + (x^2-4)/(4*U(0)-2*x^2+8) where U(k) = k*(2*k+3)*x^2 + x - 2 - (2-x+2*k*x)*(2+3*x+2*k*x)*(k+1)*x^2/U(k+1).
G.f.: 1/x+1/(U(0)-1) where U(k) = -x*k + 1 - x - x^2*(k+1)/U(k+1).
G.f.: (1 - U(0))/x - 1 where U(k) = 1 - x*(k+2) - x^2*(k+1)/U(k+1).
G.f.: (1 - U(0))/x where U(k) = 1 - x*(k+1)/(1-x/U(k+1)).
G.f.: 1/x + 1/( G(0)-1) where G(k) = 1 - x/(1 - x*(2*k+1)/(1 - x/(1 - x*(2*k+2)/ G(k+1) ))).
G.f.:1/x + 1/( G(0) - 1 ) where G(k) = 1 - x/(1 - x*(k+1)/G(k+1) ).
G.f.: (1 - Q(0))/x where Q(k) = 1 + x/(x*k - 1 )/Q(k+1).
G.f.: 1/x - 1/x/Q(0), where Q(k) = 1 + x/(1 - x + x*(k+1)/(x - 1/Q(k+1))).
(End)
Conjecture: a(n) = b(2^(n-1) - 1) for n > 0 with a(0) = 1 where b(n) = b((n - 2^f(n))/2) + b(floor((2n - 2^f(n))/2)) + b(A025480(n-1)) for n > 0 with b(0) = 1 and where f(n) = A007814(n). - Mikhail Kurkov, Jan 11 2022

A006014 a(n+1) = (n+1)*a(n) + Sum_{k=1..n-1} a(k)*a(n-k).

Original entry on oeis.org

1, 2, 7, 32, 178, 1160, 8653, 72704, 679798, 7005632, 78939430, 965988224, 12762344596, 181108102016, 2748049240573, 44405958742016, 761423731533286, 13809530704348160, 264141249701936818, 5314419112717217792, 112201740111374359516, 2480395343617443024896
Offset: 1

Views

Author

Keywords

Examples

			G.f. = x + 2*x^2 + 7*x^3 + 32*x^4 + 178*x^5 + 1160*x^6 + 8653*x^7 + 72704*x^8 + ...
		

References

  • D. E. Knuth, personal communication.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Similar recurrences: A124758, A243499, A284005, A329369, A341392.

Programs

  • Mathematica
    Nest[Append[#1, #1[[-1]] (#2 + 1) + Total@ Table[#1[[k]] #1[[#2 - k]], {k, #2 - 1}]] & @@ {#, Length@ #} &, {1}, 17] (* Michael De Vlieger, Aug 22 2018 *)
    (* or *)
    a[1] = 1; a[n_] := a[n] = n a[n-1] + Sum[a[k] a[n-1-k], {k, n-2}]; Array[a, 18] (* Giovanni Resta, Aug 23 2018 *)
  • PARI
    {a(n) = local(A); if( n<1, 0, A = vector(n); A[1] = 1; for( k=2, n, A[k] = k * A[k-1] + sum( j=1, k-2, A[j] * A[k-1-j])); A[n])} /* Michael Somos, Jul 24 2011 */
    
  • Python
    from sage.all import *
    @CachedFunction
    def a(n): # a = A006014
        if n<5: return (pow(5,n-1) + 3)//4
        else: return n*a(n-1) + 2*sum(a(k)*a(n-k-1) for k in range(1,(n//2))) + (n%2)*pow(a((n-1)//2),2)
    print([a(n) for n in range(1,61)]) # G. C. Greubel, Jan 10 2025

Formula

G.f. A(x) satisfies A(x) = x * (1 + A(x) + A(x)^2 + x * A'(x)). - Michael Somos, Jul 24 2011
Conjecture: a(n) = Sum_{k=0..2^(n-1) - 1} b(k) for n > 0 where b(2n+1) = b(n), b(2n) = b(n) + b(n - 2^f(n)) + b(2n - 2^f(n)) + b(A025480(n-1)) for n > 0 with b(0) = b(1) = 1 and where f(n) = A007814(n). - Mikhail Kurkov, Nov 19 2021
a(n) ~ cosh(sqrt(3)*Pi/2) * n! / Pi = A073017 * n!. - Vaclav Kotesovec, Nov 21 2024

A290615 Number of maximal independent vertex sets (and minimal vertex covers) in the n-triangular honeycomb bishop graph.

Original entry on oeis.org

1, 2, 5, 14, 45, 164, 661, 2906, 13829, 70736, 386397, 2242118, 13759933, 88975628, 604202693, 4296191090, 31904681877, 246886692680, 1986631886029, 16592212576862, 143589971363981, 1285605080403332, 11891649654471285, 113491862722958474, 1116236691139398565
Offset: 1

Views

Author

Eric W. Weisstein, Aug 07 2017

Keywords

Comments

From Andrew Howroyd, Aug 09 2017: (Start)
See A146304 for algorithm and PARI code to produce this sequence.
The total number of independent vertex sets is given by Bell(n+1) where Bell=A000110.
A bishop can move along two axes in the triangular honeycomb grid.
Equivalently, the number of arrangements of non-attacking rooks on an n X n right triangular board with every square controlled by at least one rook. (End)

Crossrefs

Row sums of A290724.
Cf. A000110 (independent vertex sets), A007814, A146304.
Similar recurrences: A124758, A243499, A284005, A329369, A341392.

Programs

  • Mathematica
    Table[Sum[k! StirlingS2[m, k] StirlingS2[n + 1 - m, k + 1], {m, 0, n}, {k, 0, Min[m, n - m]}], {n, 20}] (* Eric W. Weisstein, Feb 01 2024 *)
  • PARI
    { A290615(n) = sum(m=0, n, sum(k=0, min(m,n-m), k! * stirling(m,k,2) * stirling(n+1-m,k+1,2) )); } \\ Max Alekseyev, Oct 14 2021

Formula

Conjecture: a(n) = Sum_{k=0..2^(n-1) - 1} b(k) for n > 0 where b(2n+1) = b(n - 2^f(n)), b(2n) = b(n) + b(2n - 2^f(n)) for n > 0 with b(0) = b(1) = 1 and where f(n) = A007814(n). Also b((4^n - 1)/3) = (floor((n+1)/2)!)^3. - Mikhail Kurkov, Sep 18 2021
a(n) = Sum_{m=0..n} Sum_{k=0..min(m,n-m)} k! * S(m,k) * S(n+1-m,k+1), where S(,) are Stirling numbers of second kind. - Max Alekseyev, Oct 14 2021

Extensions

Terms a(10) and beyond from Andrew Howroyd, Aug 09 2017
Showing 1-10 of 18 results. Next