A094577
Central Peirce numbers. Number of set partitions of {1,2,..,2n+1} in which n+1 is the smallest of its block.
Original entry on oeis.org
1, 3, 27, 409, 9089, 272947, 10515147, 501178937, 28773452321, 1949230218691, 153281759047387, 13806215066685433, 1408621900803060705, 161278353358629226675, 20555596673435403499083, 2896227959507289559616217, 448371253145121338801335489
Offset: 0
n = 1, S = {1, 2, 3}. k = n+1 = 2. Thus a(1) = card { 13|2, 1|23, 1|2|3 } = 3. - _Peter Luschny_, Jan 18 2011
- Donald E. Knuth, The Art of Computer Programming, Vol. 4, Section 7.2.1.5.
-
seq(add(binomial(n, k)*(bell(n+k)), k=0..n), n=0..14); # Zerinvary Lajos, Dec 01 2006
# The objective of this implementation is efficiency.
# m -> [a(0), a(1), ..., a(m-1)] for m > 0.
A094577_list := proc(m)
local A, R, M, n, k, j;
M := m+m-1; A := array(1..M);
j := 1; R := 1; A[1] := 1;
for n from 2 to M do
A[n] := A[1];
for k from n by -1 to 2 do
A[k-1] := A[k-1] + A[k]
od;
if is(n,odd) then
j := j+1; R := R,A[j] fi
od;
[R] end:
A094577_list(100); # example call - Peter Luschny, Jan 17 2011
-
f[n_] := Sum[Binomial[n, k]*BellB[2 n - k], {k, 0, n}]; Array[f, 15, 0]
-
# requires python 3.2 or higher. Otherwise use def'n of accumulate in python docs.
from itertools import accumulate
A094577_list, blist, b = [1], [1], 1
for n in range(2,502):
blist = list(accumulate([b]+blist))
b = blist[-1]
blist = list(accumulate([b]+blist))
b = blist[-1]
A094577_list.append(blist[-n])
# Chai Wah Wu, Sep 02 2014, updated Chai Wah Wu, Sep 20 2014
A201862
Number of ways to place k nonattacking bishops on an n X n board, sum over all k>=0.
Original entry on oeis.org
1, 2, 9, 70, 729, 9918, 167281, 3423362, 82609921, 2319730026, 74500064809, 2711723081550, 110568316431609, 5016846683306758, 251180326892449969, 13806795579059621930, 827911558468860287041, 53940895144894708523922, 3799498445458163685753481, 288400498147873552894868886
Offset: 0
-
knbishops[k_,n_]:=(If[n==1,If[k==1,1,0],(-1)^k/(2n-k)!
*Sum[Binomial[2n-k,n-k+i]*Sum[(-1)^m*Binomial[n-i,m]*m^Floor[n/2]*(m+1)^Floor[(n+1)/2],{m,1,n-i}]
*Sum[(-1)^m*Binomial[n-k+i,m]*m^Floor[(n+1)/2]*(m+1)^Floor[n/2],{m,1,n+i-k}],{i,Max[0,k-n],Min[k,n]}]]);
Table[1+Sum[knbishops[k,n],{k,1,2n-1}],{n,1,25}]
A216332
Number of horizontal and antidiagonal neighbor colorings of the even squares of an n X 2 array with new integer colors introduced in row major order.
Original entry on oeis.org
1, 2, 3, 10, 27, 114, 409, 2066, 9089, 52922, 272947, 1788850, 10515147, 76282138, 501178937, 3974779402, 28773452321, 247083681522, 1949230218691, 17984917069018, 153281759047387, 1510073008031682, 13806215066685433
Offset: 1
Some solutions for n=5:
..0..x....0..x....0..x....0..x....0..x....0..x....0..x....0..x....0..x....0..x
..x..1....x..1....x..1....x..0....x..1....x..1....x..0....x..1....x..1....x..0
..0..x....2..x....2..x....1..x....2..x....2..x....1..x....2..x....0..x....1..x
..x..2....x..0....x..1....x..2....x..1....x..0....x..1....x..0....x..1....x..2
..3..x....3..x....3..x....0..x....2..x....1..x....0..x....2..x....0..x....3..x
There are 5 black squares on a 3 X 3 board. There is 1 way to place no non-attacking bishops, 5 ways to place 1 and 4 ways to place 2 so a(4)=1+5+4=10. - _Andrew Howroyd_, Jun 06 2017
-
Table[Sum[Binomial[Ceiling[n/2], k] BellB[n - k], {k, 0, Ceiling[n/2]}], {n, 0, 20}] (* Eric W. Weisstein, Jun 25 2017 *)
A286422
Number of matchings in the n X n black bishop graph.
Original entry on oeis.org
2, 12, 130, 9492, 1166928, 1431128744, 2907639077764, 76670800431934272, 3341096345926174809912, 2311650738313947870105792416, 2645105778378736719464340469683304, 56641723029988800376624313271476598959936
Offset: 2
A274106
Triangle read by rows: T(n,k) = total number of configurations of k nonattacking bishops on the white squares of an n X n chessboard (0 <= k <= n-1+[n=0]).
Original entry on oeis.org
1, 1, 1, 2, 1, 4, 2, 1, 8, 14, 4, 1, 12, 38, 32, 4, 1, 18, 98, 184, 100, 8, 1, 24, 188, 576, 652, 208, 8, 1, 32, 356, 1704, 3532, 2816, 632, 16, 1, 40, 580, 3840, 12052, 16944, 9080, 1280, 16, 1, 50, 940, 8480, 38932, 89256, 93800, 37600, 3856, 32, 1, 60, 1390, 16000, 98292, 322848, 540080, 412800, 116656, 7744, 32
Offset: 0
Triangle begins:
1;
1;
1, 2;
1, 4, 2;
1, 8, 14, 4;
1, 12, 38, 32, 4;
1, 18, 98, 184, 100, 8;
1, 24, 188, 576, 652, 208, 8;
1, 32, 356, 1704, 3532, 2816, 632, 16;
1, 40, 580, 3840, 12052, 16944, 9080, 1280, 16;
1, 50, 940, 8480, 38932, 89256, 93800, 37600, 3856, 32;
1, 60, 1390, 16000, 98292, 322848, 540080, 412800, 116656, 7744, 32;
...
From _Eder G. Santos_, Dec 16 2024: (Start)
For example, for n = 3, k = 2, the T(3,2) = 2 nonattacking configurations are:
+---+---+---+ +---+---+---+
| | B | | | | | |
+---+---+---+ +---+---+---+
| | | | , | B | | B |
+---+---+---+ +---+---+---+
| | B | | | | | |
+---+---+---+ +---+---+---+
(End)
- Irving Kaplansky and John Riordan, The problem of the rooks and its applications, Duke Mathematical Journal 13.2 (1946): 259-268. See Section 9.
- Irving Kaplansky and John Riordan, The problem of the rooks and its applications, in Combinatorics, Duke Mathematical Journal, 13.2 (1946): 259-268. See Section 9. [Annotated scanned copy]
- J. Perott, Sur le problème des fous, Bulletin de la S. M. F., tome 11 (1883), pp. 173-186.
- Eder G. Santos, Counting non-attacking chess pieces placements: Bishops and Anassas. arXiv:2411.16492 [math.CO], 2024. (considered as black board).
- Eric Weisstein's World of Mathematics, White Bishop Graph.
-
with(combinat): with(gfun):
T := n -> add(stirling2(n+1,n+1-k)*x^k, k=0..n):
# bishops on white squares
bish := proc(n) local m,k,i,j,t1,t2; global T;
if n=0 then return [1] fi;
if (n mod 2) = 0 then m:=n/2;
t1:=add(binomial(m,k)*T(2*m-1-k)*x^k, k=0..m);
else
m:=(n-1)/2;
t1:=add(binomial(m,k)*T(2*m-k)*x^k, k=0..m+1);
fi;
seriestolist(series(t1,x,2*n+1));
end:
for n from 0 to 12 do lprint(bish(n)); od:
-
T[n_] := Sum[StirlingS2[n+1, n+1-k]*x^k, {k, 0, n}];
bish[n_] := Module[{m, t1, t2}, If[Mod[n, 2] == 0,
m = n/2; t1 = Sum[Binomial[m, k]*T[2*m-1-k]*x^k, {k, 0, m}],
m = (n-1)/2; t1 = Sum[Binomial[m, k]*T[2*m - k]*x^k, {k, 0, m+1}]];
CoefficientList[t1 + O[x]^(2*n+1), x]];
Table[bish[n], {n, 1, 12}] // Flatten (* Jean-François Alcover, Jul 25 2022, after Maple code *)
-
def stirling2_negativek(n, k):
if k < 0: return 0
else: return stirling_number2(n, k)
print([sum([binomial(floor(n/2), j)*stirling2_negativek(n-j, n-k) for j in [0..k]]) for n in [0..10] for k in [0..n-1+kronecker_delta(n,0)]]) # Eder G. Santos, Dec 01 2024
Showing 1-5 of 5 results.
Comments