This site is supported by donations to The OEIS Foundation.

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A318191 Number A(n,k) of lattice paths from {n}^k to {0}^k using steps that decrement one component by 1 such that for each point p we have abs(p_{i}-p_{(i mod k)+1}) <= 1 and the first component used is p_1; square array A(n,k), n>=0, k>=0, read by antidiagonals. 4

%I

%S 1,1,1,1,1,1,1,1,1,1,1,2,2,1,1,1,6,12,4,1,1,1,24,180,72,8,1,1,1,120,

%T 4680,5400,432,16,1,1,1,720,187200,914400,162000,2592,32,1,1,1,5040,

%U 10634400,296438400,178660800,4860000,15552,64,1,1,1,40320,813664800,162273628800,469551168000,34907788800,145800000,93312,128,1,1

%N Number A(n,k) of lattice paths from {n}^k to {0}^k using steps that decrement one component by 1 such that for each point p we have abs(p_{i}-p_{(i mod k)+1}) <= 1 and the first component used is p_1; square array A(n,k), n>=0, k>=0, read by antidiagonals.

%H Alois P. Heinz, <a href="/A318191/b318191.txt">Antidiagonals n = 0..20, flattened</a>

%e A(2,2) = 2^2 = 4:

%e (0,1)

%e / \

%e (2,2)-(1,2)-(1,1) (0,0)

%e \ /

%e (1,0)

%e Square array A(n,k) begins:

%e 1, 1, 1, 1, 1, 1, 1, ...

%e 1, 1, 1, 2, 6, 24, 120, ...

%e 1, 1, 2, 12, 180, 4680, 187200, ...

%e 1, 1, 4, 72, 5400, 914400, 296438400, ...

%e 1, 1, 8, 432, 162000, 178660800, 469551168000, ...

%e 1, 1, 16, 2592, 4860000, 34907788800, 743761386086400, ...

%e 1, 1, 32, 15552, 145800000, 6820487308800, 1178106009360998400, ...

%p b:= proc(l) option remember; (n-> `if`(n<2 or max(l[])=0, 1,

%p add(`if`(l[i]=0 or 1<abs(l[`if`(i=1, 0, i)-1]-l[i]+1)

%p or 1<abs(l[`if`(i=n, 0, i)+1]-l[i]+1), 0,

%p b(subsop(i=l[i]-1, l))), i=1..n)))(nops(l))

%p end:

%p A:= (n, k)-> `if`(k<2 or n=0, 1, b([n-1, n\$k-1])):

%p seq(seq(A(n, d-n), n=0..d), d=0..10);

%Y Columns k=0+1, 2 give: A000012, A011782.

%Y Rows n=0-2 give: A000012, A000142(n-1) for n>0, A322782/n for n>0.

%Y Main diagonal gives A320443.

%Y Cf. A227655.

%K nonn,tabl

%O 0,12

%A _Alois P. Heinz_, Jan 07 2019

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

Last modified October 16 20:23 EDT 2019. Contains 328103 sequences. (Running on oeis4.)