OFFSET
0,3
LINKS
Robert Israel, Table of n, a(n) for n = 0..462
M. Bousquet-Mélou and M. Mishna, 2008. Walks with small steps in the quarter plane, ArXiv 0810.4387.
FORMULA
G.f.: ((1+1/x)*Int(((8*x^2+4*x+1)*hypergeom([1/4, 3/4],[1],64*x^3*(2*x+1)/(8*x^2-1)^2)-12*x^2*(2*x+1)*hypergeom([1/4, 3/4],[2],64*x^3*(2*x+1)/(8*x^2-1)^2))/((x+1)^2*(1-8*x^2)^(3/2)),x)-1)/(2*x). - Mark van Hoeij, Aug 20 2014
MAPLE
M[0]:= Matrix(1, 1, 1):
for i from 1 to 100 do
M[i]:= Matrix(i+1, i+1);
for p in [[-1, -1], [-1, 0], [-1, 1], [0, -1], [0, 1], [1, 0]] do
j1:= max(1, 1+p[1]); j2:= max(1, 1+p[2]);
if j1 <= p[1]+i and j2 <= p[2]+i then
M[i][j1..p[1]+i, j2..p[2]+i] := M[i][j1..p[1]+i, j2..p[2]+i]
+ M[i-1][j1-p[1]..i, j2-p[2]..i]
fi
od
od:
seq(add(M[i][1, j], j=1..i+1), i=0..100); # Robert Israel, Aug 20 2014
MATHEMATICA
aux[i_Integer, j_Integer, n_Integer] := Which[Min[i, j, n] < 0 || Max[i, j] > n, 0, n == 0, KroneckerDelta[i, j, n], True, aux[i, j, n] = aux[-1 + i, j, -1 + n] + aux[i, -1 + j, -1 + n] + aux[i, 1 + j, -1 + n] + aux[1 + i, -1 + j, -1 + n] + aux[1 + i, j, -1 + n] + aux[1 + i, 1 + j, -1 + n]]; Table[Sum[aux[0, k, n], {k, 0, n}], {n, 0, 25}]
CROSSREFS
KEYWORD
nonn,walk
AUTHOR
Manuel Kauers, Nov 18 2008
STATUS
approved