A248687
Sum of the numbers in row n of the triangular array at A248686.
Original entry on oeis.org
1, 3, 10, 43, 221, 1371, 9696, 78751, 712447, 7173853, 79106413, 952587175, 12397677007, 173864946685, 2609479384942, 41786786069887, 710577455524223, 12795789975272877, 243154034699436147, 4864103085730989101, 102153340062463300261, 2247608818115460466681
Offset: 1
First seven rows of the array at A248686:
1
1 2
1 3 6
1 6 12 24
1 10 30 60 120
1 20 90 180 360 720
1 35 210 630 1260 2520 5040
The row sums are 1, 3, 10, ...
-
b:= proc(n, k) option remember; `if`(k<1,
`if`(n=k, 1, 0), n!/mul(iquo(n+i, k)!, i=0..k-1))
end:
a:= n-> add(b(n,k), k=0..n):
seq(a(n), n=1..22); # Alois P. Heinz, Feb 20 2024
-
f[n_, k_] := f[n, k] = n!/Product[Floor[(n + i)/k]!, {i, 0, k - 1}]
t = Table[f[n, k], {n, 0, 10}, {k, 1, n}];
u = Flatten[t] (* A248686 sequence *)
TableForm[t] (* A248686 array *)
Table[Sum[f[n, k], {k, 1, n}], {n, 1, 22}] (* A248687 *)
A333706
Number T(n,k) of permutations p of [n] such that |p(i+k) - p(i)| <> k for i in [n-k]; triangle T(n,k), n>=0, 0<=k<=n, read by rows.
Original entry on oeis.org
1, 0, 1, 0, 0, 2, 0, 0, 4, 6, 0, 2, 16, 20, 24, 0, 14, 44, 80, 108, 120, 0, 90, 200, 384, 544, 672, 720, 0, 646, 1288, 2240, 3264, 4128, 4800, 5040, 0, 5242, 9512, 15424, 23040, 28992, 34752, 38880, 40320, 0, 47622, 78652, 123456, 176832, 231936, 280512, 323520, 352800, 362880
Offset: 0
Triangle T(n,k) begins:
1;
0, 1;
0, 0, 2;
0, 0, 4, 6;
0, 2, 16, 20, 24;
0, 14, 44, 80, 108, 120;
0, 90, 200, 384, 544, 672, 720;
0, 646, 1288, 2240, 3264, 4128, 4800, 5040;
0, 5242, 9512, 15424, 23040, 28992, 34752, 38880, 40320;
...
Columns k=0-10 (for n>=k) give:
A000007,
A002464,
A110128,
A117574,
A189255,
A189256,
A189271,
A360384,
A360386,
A360462,
A360463.
Cf.
A000170 (condition is satisfied for all k),
A248686 (p(i) at distance k are sorted).
A370505
T(n,k) is the difference between the number of k-dist-increasing and (k-1)-dist-increasing permutations of [n], where p is k-dist-increasing if k>=0 and p(i)=0, 0<=k<=n, read by rows.
Original entry on oeis.org
1, 0, 1, 0, 1, 1, 0, 1, 2, 3, 0, 1, 5, 6, 12, 0, 1, 9, 20, 30, 60, 0, 1, 19, 70, 90, 180, 360, 0, 1, 34, 175, 420, 630, 1260, 2520, 0, 1, 69, 490, 1960, 2520, 5040, 10080, 20160, 0, 1, 125, 1554, 5880, 15120, 22680, 45360, 90720, 181440, 0, 1, 251, 3948, 21000, 88200, 113400, 226800, 453600, 907200, 1814400
Offset: 0
T(0,0) = 1: (only) the empty permutation is 0-dist-increasing.
T(4,2) = 5 = 6 - 1 = |{1234, 1243, 1324, 2134, 2143, 3142}| - |{1234}|.
Permutation 3142 is 2-dist-increasing and 4-dist-increasing but not 3-dist-increasing.
Triangle T(n,k) begins:
1;
0, 1;
0, 1, 1;
0, 1, 2, 3;
0, 1, 5, 6, 12;
0, 1, 9, 20, 30, 60;
0, 1, 19, 70, 90, 180, 360;
0, 1, 34, 175, 420, 630, 1260, 2520;
0, 1, 69, 490, 1960, 2520, 5040, 10080, 20160;
0, 1, 125, 1554, 5880, 15120, 22680, 45360, 90720, 181440;
...
-
b:= proc(n, k) option remember; `if`(k<1,
`if`(n=k, 1, 0), n!/mul(iquo(n+i, k)!, i=0..k-1))
end:
T:= (n, k)-> b(n, k)-b(n, k-1):
seq(seq(T(n, k), k=0..n), n=0..10);
A361651
Number T(n,k) of permutations p of [n] such that p(i), p(i+k), p(i+2k),... form an up-down sequence for i in [k]; triangle T(n,k), n>=0, 0<=k<=n, read by rows.
Original entry on oeis.org
1, 0, 1, 0, 1, 2, 0, 2, 3, 6, 0, 5, 6, 12, 24, 0, 16, 20, 30, 60, 120, 0, 61, 80, 90, 180, 360, 720, 0, 272, 350, 420, 630, 1260, 2520, 5040, 0, 1385, 1750, 2240, 2520, 5040, 10080, 20160, 40320, 0, 7936, 10080, 13440, 15120, 22680, 45360, 90720, 181440, 362880
Offset: 0
Triangle T(n,k) begins:
1;
0, 1;
0, 1, 2;
0, 2, 3, 6;
0, 5, 6, 12, 24;
0, 16, 20, 30, 60, 120;
0, 61, 80, 90, 180, 360, 720;
0, 272, 350, 420, 630, 1260, 2520, 5040;
0, 1385, 1750, 2240, 2520, 5040, 10080, 20160, 40320;
...
-
b:= proc(u, o) option remember; `if`(u+o=0, 1,
add(b(o-1+j, u-j), j=1..u))
end:
T:= (n, k)-> `if`(n=0, 1, `if`(k=0, 0, (l-> mul(b(s, 0), s=l)*
combinat[multinomial](n, l[]))([floor((n+i)/k)$i=0..k-1]))):
seq(seq(T(n, k), k=0..n), n=0..10);
-
multinomial[n_, k_List] := n!/Times @@ (k!);
b[u_, o_] := b[u, o] = If[u+o == 0, 1, Sum[b[o-1+j, u-j], {j, 1, u}]];
T[n_, k_] := If[n == 0, 1, If[k == 0, 0, Function[l, Product[b[s, 0], {s, l}]*multinomial[n, l]][Table[Floor[(n+i)/k], {i, 0, k-1}]]]];
Table[Table[T[n, k], {k, 0, n}], {n, 0, 10}] // Flatten (* Jean-François Alcover, Nov 22 2023, after Alois P. Heinz *)
Showing 1-4 of 4 results.
Comments