login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A299504 Triangle read by rows, T(n,k) = (k+1)^(n-k)*k! for 0 <= k <= n. 2
1, 1, 1, 1, 2, 2, 1, 4, 6, 6, 1, 8, 18, 24, 24, 1, 16, 54, 96, 120, 120, 1, 32, 162, 384, 600, 720, 720, 1, 64, 486, 1536, 3000, 4320, 5040, 5040, 1, 128, 1458, 6144, 15000, 25920, 35280, 40320, 40320, 1, 256, 4374, 24576, 75000, 155520, 246960, 322560, 362880, 362880 (list; table; graph; refs; listen; history; text; internal format)
OFFSET
0,5
COMMENTS
With offset 1, T(n,k) is the number of permutations of [n] in which all entries left of 1 (if any) are excedances and 1 is in position n+1-k. An excedance of a permutation p is an entry p(i) such that p(i)>i. For example, T(4,2) = 4 counts 2314, 2413, 3412, 4312. - David Callan, Dec 12 2021
LINKS
Ron Graham, Eulerian Adventures with Don, 2018.
EXAMPLE
Triangle starts:
[0] 1
[1] 1, 1
[2] 1, 2, 2
[3] 1, 4, 6, 6
[4] 1, 8, 18, 24, 24
[5] 1, 16, 54, 96, 120, 120
[6] 1, 32, 162, 384, 600, 720, 720
[7] 1, 64, 486, 1536, 3000, 4320, 5040, 5040
[8] 1, 128, 1458, 6144, 15000, 25920, 35280, 40320, 40320
[9] 1, 256, 4374, 24576, 75000, 155520, 246960, 322560, 362880, 362880
MAPLE
T := (n, k) -> (k+1)^(n-k)*k!: seq(seq(T(n, k), k=0..n), n=0..9);
MATHEMATICA
Table[(k+1)^(n-k)*k!, {n, 0, 10}, {k, 0, n}]//Flatten (* G. C. Greubel, Nov 08 2018 *)
PROG
(Python)
from sympy import factorial
def T(n, k): return (k+1)**(n-k)*factorial(k)
for n in range(21): print([T(n, k) for k in range(n+1)]) # Indranil Ghosh, Mar 02 2018
(PARI) T(n, k) = {(k+1)^(n-k)*k!}
for(n=0, 10, for(k=0, n, print1(T(n, k), ", ")); print); \\ Andrew Howroyd, Nov 08 2018
(Magma) [(k+1)^(n-k)*Factorial(k): k in [0..n], n in [0..10]]; // G. C. Greubel, Nov 08 2018
CROSSREFS
Sequence in context: A071946 A053495 A096747 * A300979 A371889 A167622
KEYWORD
nonn,tabl
AUTHOR
Peter Luschny, Mar 01 2018
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 23 08:33 EDT 2024. Contains 371905 sequences. (Running on oeis4.)