A175657 Eight bishops and one elephant on a 3 X 3 chessboard: a(n) = 3*2^n - 2*F(n+1), with F(n) = A000045(n).
1, 4, 8, 18, 38, 80, 166, 342, 700, 1426, 2894, 5856, 11822, 23822, 47932, 96330, 193414, 388048, 778070, 1559334, 3123836, 6256034, 12525598, 25073088, 50181598, 100420510, 200933756, 402017562, 804277910, 1608948656, 3218532934
Offset: 0
Links
- Vincenzo Librandi, Table of n, a(n) for n = 0..1000
- Index entries for linear recurrences with constant coefficients, signature (3,-1,-2).
Programs
-
Magma
I:=[1,4,8]; [n le 3 select I[n] else 3*Self(n-1)-Self(n-2)-2*Self(n-3): n in [1..35]]; // Vincenzo Librandi, Jul 21 2013
-
Maple
with(LinearAlgebra): nmax:=30; m:=5; A[5]:= [0,0,0,1,0,1,0,1,1]: A:=Matrix([[0,0,0,0,1,0,0,0,1], [0,0,0,1,0,1,0,0,0], [0,0,0,0,1,0,1,0,0], [0,1,0,0,0,0,0,1,0], A[5], [0,1,0,0,0,0,0,1,0], [0,0,1,0,1,0,0,0,0], [0,0,0,1,0,1,0,0,0], [1,0,0,0,1,0,0,0,0]]): for n from 0 to nmax do B(n):=A^n: a(n):= add(B(n)[m,k],k=1..9): od: seq(a(n), n=0..nmax);
-
Mathematica
LinearRecurrence[{3,-1,-2},{1,4,8},40] (* Harvey P. Dale, Aug 12 2012 *) CoefficientList[Series[(1 + x - 3 x^2) / (1 - 3 x + x^2 + 2 x^3), {x, 0, 40}], x] (* Vincenzo Librandi, Jul 21 2013 *)
Formula
G.f.: (1+x-3*x^2)/(1-3*x+x^2+2*x^3).
a(n) = 3*a(n-1)-a(n-2)-2*a(n-3) with a(0)=1, a(1)=4 and a(2)=8.
Comments