A076620
Coefficient of x^a(n) in (x+1)*(x+2)*...*(x+n) is the largest one.
Original entry on oeis.org
0, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4
Offset: 1
In (x+1)(x+2)(x+3) = x^3 + 6*x^2 + 11*x + 6, the largest coefficient (11) appears at x^1, hence a(3)=1.
-
a(n) = my(p=prod(j=1, n, x+j), m=vecmax(Vec(p))); for (i=0, poldegree(p), if (polcoef(p, i)==m, return(i))); \\ Michel Marcus, Feb 19 2021
-
first(n) = {res = vector(n); my(r = 1); v = [1]; for(i = 1, n, v = concat(0, v) + concat(v, 0)*i; for(j = r + 1, #v, if(v[j] > v[j - 1], r++ , next ); ); res[i] = r-1 ); res } \\ David A. Corneth, Feb 21 2021
-
from sympy import prod, Poly
from sympy.abc import x
def A076620(n):
y = Poly(prod(x+i for i in range(1,n+1))).all_coeffs()[::-1]
return y.index(max(y)) # Chai Wah Wu, Mar 07 2021
A112002
Seventh diagonal of triangle A008275 (Stirling1) and seventh column of |A008276|.
Original entry on oeis.org
720, 13068, 118124, 723680, 3416930, 13339535, 44990231, 135036473, 368411615, 928095740, 2185031420, 4853222764, 10246937272, 20692933630, 40171771630, 75289668850, 136717357942, 241276443496, 414908513800, 696829576300
Offset: 1
-
[StirlingFirst(n+6, n): n in [1..20]]; // Vincenzo Librandi, Aug 09 2015
-
A112002 := proc(n) combinat[stirling1](n+6,n) ; end proc: # R. J. Mathar, Jun 08 2011
-
Table[StirlingS1[n+6, n], {n, 1, 20}] (* Jean-François Alcover, Mar 05 2014 *)
-
[stirling_number1(n,n-6) for n in range(7, 27)] # Zerinvary Lajos, May 16 2009
A193651
a(n) = ((2*n + 1)!! + 1)/2.
Original entry on oeis.org
1, 2, 8, 53, 473, 5198, 67568, 1013513, 17229713, 327364538, 6874655288, 158117071613, 3952926790313, 106729023338438, 3095141676814688, 95949391981255313, 3166329935381425313, 110821547738349885938, 4100397266318945779688, 159915493386438885407813
Offset: 0
-
seq((1+doublefactorial(2*n+1))/2,n=0..18); # Peter Luschny, Aug 20 2014
-
q[n_, k_] := 1;
r[0] = 1; r[k_] := Sum[q[k - 1, i] r[k - 1 - i], {i, 0, k - 1}]
u[0, x_] := 1; u[n_, x_] := (x + n)*u[n - 1, x]
p[n_, k_] := Coefficient[u[n, x], x, k]
v[n_] := Sum[p[n, k] r[n - k], {k, 0, n}]
Table[v[n], {n, 0, 18}] (* A193651 *)
TableForm[Table[q[i, k], {i, 0, 4}, {k, 0, i}]]
Table[r[k], {k, 0, 8}] (* 2^k *)
TableForm[Table[p[n, k], {n, 0, 6}, {k, 0, n}]] (* A130534 *)
Table[((2 n + 1)!! + 1)/2, {n, 0, 18}] (* or *)
Table[(2^n Gamma[n + 3/2])/Sqrt[Pi] + 1/2, {n, 0, 18}] (* or *)
Table[2^n Pochhammer[1/2, n + 1] + 1/2, {n, 0, 18}] (* Michael De Vlieger, Apr 25 2016 *)
-
def A():
n, a, b = 1, 1, 2
yield a
while True:
yield b
n += 1
a, b = b, ((2*(b-a)*n + a)*n - b)/(n-1)
A193651 = A()
[next(A193651) for i in range(19)] # Peter Luschny, Aug 20 2014
A213167
a(n) = n! - (n-2)!.
Original entry on oeis.org
1, 5, 22, 114, 696, 4920, 39600, 357840, 3588480, 39553920, 475372800, 6187104000, 86699289600, 1301447347200, 20835611596800, 354379753728000, 6381450915840000, 121289412980736000, 2426499634470912000
Offset: 2
Column 4 of
A257503 (apart from initial 1. Equally, row 4 of
A257505).
-
Table[n! - (n - 2)!, {n, 2, 20}]
#[[3]]-#[[1]]&/@Partition[Range[0,20]!,3,1] (* Harvey P. Dale, Aug 10 2023 *)
-
A213167(n):=n!-(n-2)!$
makelist(A213167(n),n,2,30); /* Martin Ettl, Nov 03 2012 */
-
(define (A213167 n) (- (A000142 n) (A000142 (- n 2)))) ;; Antti Karttunen, May 07 2015
A330797
Evaluation of the Stirling cycle polynomials at -1/2 and normalized with (-2)^n.
Original entry on oeis.org
1, 1, -1, 3, -15, 105, -945, 10395, -135135, 2027025, -34459425, 654729075, -13749310575, 316234143225, -7905853580625, 213458046676875, -6190283353629375, 191898783962510625, -6332659870762850625, 221643095476699771875, -8200794532637891559375, 319830986772877770815625
Offset: 0
The equivalent for Stirling2 is
A009235.
-
m:=30;
R:=PowerSeriesRing(Rationals(), m+2);
A330797:= func< n | Coefficient(R!(Laplace( Sqrt(1+2*x) )), n) >;
[A330797(n): n in [0..m]]; // G. C. Greubel, Sep 14 2023
-
a := n -> ((-2)^(n-1)*GAMMA(n-1/2))/sqrt(Pi): seq(a(n), n=1..9);
# Alternative:
arec := proc(n) option remember: if n = 0 then 1 else
(3 - 2*n)*arec(n-1) fi end: seq(arec(n), n=0..20);
# Or:
gf := (1+2*x)^(1/2); ser := series(gf, x, 24);
seq(n!*coeff(ser, x, n), n=0..20);
-
a[n_]:= (-2)^n*Sum[Abs[StirlingS1[n, k]]*(-1/2)^k, {k, 0, n}];
Table[a[n], {n, 0, 21}] (* Jean-François Alcover, Nov 19 2021 *)
Table[(-2)^(n-1)*Pochhammer[1/2, n-1], {n,0,30}] (* G. C. Greubel, Sep 14 2023 *)
-
def A330797(n): return (-2)^(n-1)*rising_factorial(1/2, n-1)
[A330797(n) for n in (0..20)]
A136662
Number of cycles of the permutations of [1,2,...,n].
Original entry on oeis.org
1, 2, 1, 3, 2, 2, 1, 1, 2, 4, 3, 3, 2, 2, 3, 3, 2, 2, 1, 1, 2, 2, 1, 3, 2, 2, 1, 1, 2, 2, 3, 1, 2, 5, 4, 4, 3, 3, 4, 4, 3, 3, 2, 2, 3, 3, 2, 4, 3, 3, 2, 2, 3, 3, 4, 2, 3, 4, 3, 3, 2, 2, 3, 3, 2, 2, 1, 1, 2, 2, 1, 3, 2, 2, 1, 1, 2, 2, 3, 1, 2, 3, 2, 2, 1, 1, 2, 4, 3, 3, 2, 2, 3, 3, 2, 2, 1, 1, 2, 2, 3, 1, 2, 2, 1
Offset: 1
Triangle begins:
[1];
[2,1];
[3,2,2,1,1,2];
[4,3,3,2,2,3,3,2,2,1,1,2,2,1,3,2,2,1,1,2,2,3,1,2];
...
Row n=3: permutations of [1,2,3] in the order [[1, 2, 3], [1, 3, 2], [2, 1, 3], [2, 3, 1], [3, 1, 2], [3, 2, 1]]. Cycle decomposition: [[[1], [2], [3]], [[1], [2, 3]], [[1, 2], [3]], [[1, 2, 3]], [[1, 3, 2]], [[1, 3], [2]]]. Number of cycles: [3,2,2,1,1,2], the entries of row n=3.
Row sums (total cycle numbers)
A000254.
A193246
Ordered unsigned Stirling numbers |S1(n,k)|.
Original entry on oeis.org
0, 1, 2, 3, 6, 10, 11, 15, 21, 24, 28, 35, 36, 45, 50, 55, 66, 78, 85, 91, 105, 120, 136, 153, 171, 175, 190, 210, 225, 231, 253, 274, 276, 300, 322, 325, 351, 378, 406, 435, 465, 496, 528, 546, 561, 595, 630, 666, 703, 720, 735, 741, 780, 820, 861, 870, 903
Offset: 1
-
s1 = Union[Flatten[Table[Table[Abs[StirlingS1[n, k]], {k, 1, 100}], {n, 1, 100}]]]; Table[s1[[j]], {j, 1, 100}]
A221914
Array of products of the list entries of the nonempty combinations of n, ordered in a standard way.
Original entry on oeis.org
1, 1, 2, 2, 1, 2, 3, 2, 3, 6, 6, 1, 2, 3, 4, 2, 3, 4, 6, 8, 12, 6, 8, 12, 24, 24, 1, 2, 3, 4, 5, 2, 3, 4, 5, 6, 8, 10, 12, 15, 20, 6, 8, 10, 12, 15, 20, 24, 30, 40, 60, 24, 30, 40, 60, 120, 120, 1, 2, 3, 4, 5, 6, 2, 3, 4, 5, 6, 6, 8, 10, 12, 12, 15, 18, 20, 24, 30, 6, 8, 10, 12, 12, 15, 18, 20, 24, 30, 24, 30, 36, 40, 48, 60, 60, 72, 90, 120, 24, 30, 36, 40, 48
Offset: 1
The array a(n,k) begins:
n\k 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 ...
1: 1
2: 1 2 2
3: 1 2 3 2 3 6 6
4: 1 2 3 4 2 3 4 6 8 12 6 8 12 24 24
...
Row n=5: 1, 2, 3, 4, 5, 2, 3, 4, 5, 6, 8, 10, 12, 15, 20, 6, 8, 10, 12, 15, 20, 24, 30, 40, 60, 24, 30, 40, 60, 120;
Row n=6: 1, 2, 3, 4, 5, 6, 2, 3, 4, 5, 6, 6, 8, 10, 12, 12, 15, 18, 20, 24, 30, 6, 8, 10, 12, 12, 15, 18, 20, 24, 30, 24, 30, 36, 40, 48, 60, 60, 72, 90, 120, 24, 30, 36, 40, 48, 60, 60, 72, 90, 120, 120, 144, 180, 240, 360, 120, 144, 180, 240, 360, 720, 720;
Row n=3: from the combinations list choose(3) (without the first entry []) [[1], [2], [3], [1, 2], [1, 3], [2, 3], [1, 2, 3]] leading to [1, 2, 3, 2, 3, 6, 6].
a(3,4) = 2 is the product of the entries of the combination list choose(3,1,1) = [1, 2], the first combination from choose(3,1).
|Stirling1| connection from like m summation: T(3,0) := 1 = |Stirling1(4,4)|, T(3,1) = 1 + 2 + 3 = 6 = |Stirling1(4,3)|,
T(3,2) = 2 + 3 + 6 = 11 = |Stirling1(4,2)|, T(3,3) = 6 =
|Stirling1(4,1)|.
A237653
O.g.f.: Sum_{n>=0} x^n*Product_{k=1..n} (k + x).
Original entry on oeis.org
1, 1, 3, 9, 36, 176, 1030, 7039, 55098, 486346, 4780445, 51787405, 613045468, 7873065045, 109021348618, 1619197654575, 25675094145535, 432908683794379, 7733991639921585, 145933532935469016, 2900112108790279902, 60543749629794205640, 1324677739541613767983, 30312375400027348522996
Offset: 0
G.f.: A(x) = 1 + x + 3*x^2 + 9*x^3 + 36*x^4 + 176*x^5 + 1030*x^6 + 7039*x^7 +...
where
A(x) = 1 + x*(1+x) + x^2*(1+x)*(2+x) + x^3*(1+x)*(2+x)*(3+x) + x^4*(1+x)*(2+x)*(3+x)*(4+x) +...
-
{a(n)=polcoeff(sum(k=0, n, x^k*prod(j=1, k, j+x +x*O(x^n))), n)}
for(n=0,30,print1(a(n),", "))
A191685
Eighth diagonal a(n) = s(n,n-7) of the unsigned Stirling numbers of the first kind with n>7.
Original entry on oeis.org
5040, 109584, 1172700, 8409500, 45995730, 206070150, 790943153, 2681453775, 8207628000, 23057159840, 60202693980, 147560703732, 342252511900, 756111184500, 1599718388730, 3256091103430, 6400590336096, 12191224980000, 22563937825000, 40681506808800
Offset: 8
c=1; a(n+1) = binomial(n+1,2)
c=2; a(n+1) = binomial(n+1,3)*(2+3*n)/4
c=3; a(n+1) = binomial(n+1,4)*(n+n^2)/2
c=4; a(n+1) = binomial(n+1,5)*(-8-10*n+15*n^2 +15*n^3)/48
c=5; a(n+1) = binomial(n+1,6)*(-6*n-7*n^2+2*n^3+ 3*n^4)/16
c=6; a(n+1) = binomial(n+1,7)*(96+140*n-224*n^2-315*n^3+63*n^5)/576
c=7; a(n+1) = binomial(n+1,8)*(80*n+114*n^2-23*n^3-75*n^4-9*n^5+9*n^6)/144
c=8; a(n+1) = binomial(n+1,9)*(-1152-1936*n+2820*n^2+
5320*n^3+735*n^4-1575*n^5-315*n^6+135*n^7)/3840
c=9; a(n+1) = binomial(n+1,10)*(-1008*n-1676*n^2 +100*n^3+1295*n^4+392*n^5-210*n^6-60*n^7 +15*n^8)/768
- K. Seidel, Variation der Binomialkoeffizienten, Bild
- der Wissenschaft, 6 (1980), pp. 127-128.
-
I: programs generate the sequence:
with(combinat): c:=7; a:= proc(n) a(n):=abs(stirling1(n,n-c)); end: seq(a(n), n=c+1..28);
for n from 7 to 27 do a(n+1) := binomial(n+1,8)*(80*n+ 114*n^2- 23*n^3- 75*n^4- 9*n^5+ 9*n^6)/144 end do: seq(a(n),n=8..28);
II: program generates explicit formulas for a(n+1) = s(n+1,n+1-c):
k[1,0]:=1: v:=1:
for c from 2 to 10 do
c1:=c-1: c2:=c-2: p0:=0:
for j from 0 to c2 do p0:=p0+k[c1,j]*m^j: end do:
f:=expand(2*c*(m+1)*p0/v):
p1:=0: p2:=0:
for j from 0 to c1 do
p1:=p1+k[c,j]*(m+1)^j:
p2:=p2+k[c,j]*m^j:
end do:
g:=collect((m+2)*p1-(m-c1)*p2-f,m):
kh[0]:=rem(g,m,m): Mk:=[kh[0]]: Mv:=[k[c,0]]:
for j from 1 to c1 do
kh[j]:=coeff(g,m^j):
Mk:=[op(Mk),kh[j]]: Mv:=[k[c,j],op(Mv)]:
end do:
sol:=solve(Mk,Mv):
v:=1:
for j from 1 to c do
k[c,c-j]:=eval(k[c,c-j],sol[1,j]):
nen[j]:=denom(k[c,c-j]):
v:=ilcm(v,nen[j]):
end do:
for j from 0 to c1 do k[c,j]:=k[c,j]*v:
printf("%8d",k[c,j]): end do:
p3:=0:
for j from 0 to c1 do p3:=p3+k[c,j]*n^j: end do:
s[n+1,n+1-c]:=binomial(n+1,c+1)*(c+1)*p3/(2^c*k[c,c1]):
end do:
for c from 2 to 10 do print("%a\n",s[n+1,n+1-c]):
end do:
Comments