A084386 Number of pairs of rabbits when there are 3 pairs per litter and offspring reach parenthood after 3 gestation periods; a(n) = a(n-1) + 3*a(n-3), with a(0) = a(1) = a(2) = 1.
1, 1, 1, 4, 7, 10, 22, 43, 73, 139, 268, 487, 904, 1708, 3169, 5881, 11005, 20512, 38155, 71170, 132706, 247171, 460681, 858799, 1600312, 2982355, 5558752, 10359688, 19306753, 35983009, 67062073, 124982332, 232931359, 434117578, 809064574
Offset: 0
Links
- Vincenzo Librandi, Table of n, a(n) for n = 0..1000
- D. Birmajer, J. B. Gil, and M. D. Weiner, On the Enumeration of Restricted Words over a Finite Alphabet , J. Int. Seq. 19 (2016) # 16.1.3, Example 9
- Merrill Jensen, Generating Functions
- Index entries for linear recurrences with constant coefficients, signature (1,0,3).
Programs
-
Magma
I:=[1,1,1]; [n le 3 select I[n] else Self(n-1)+3*Self(n-3): n in [1..40]]; // Vincenzo Librandi, Mar 28 2017
-
Maple
seq(add(binomial(n-2*k,k)*3^k,k=0..floor(n/3)),n=0..34); # Zerinvary Lajos, Apr 03 2007
-
Mathematica
a[0]=a[1]=a[2]=1; a[n_] := a[n]=a[n-1]+3a[n-3]; Table[a[n], {n, 0, 34}] LinearRecurrence[{1, 0, 3}, {1, 1, 1}, 37] (* Robert G. Wilson v, Jul 12 2014 *)
-
PARI
a(n)=([0,1,0; 0,0,1; 3,0,1]^n*[1;1;1])[1,1] \\ Charles R Greathouse IV, Oct 03 2016
Formula
a(n) = a(n-1) + 3*a(n-3). a(n) = A052900(n+3)/3.
G.f.: 1/(1-x-3*x^3).
a(n) = Sum_{k=0..floor(n/2)} binomial(n-2*k, k)*3^k. - Paul Barry, Nov 18 2003
G.f.: W(0)/2, where W(k) = 1 + 1/(1 - x*(1 + 3*x^2)/(x*(1 + 3*x^2) + 1/W(k+1) )); (continued fraction). - Sergei N. Gladkovskii, Aug 28 2013
Starting (1 + x + 4*x^2 + ...), is the INVERT transform of (1 + 3*x^2). - Gary W. Adamson, Mar 27 2017
a(m+n) = a(m)*a(n) + 3*a(m-1)*a(n-2) + 3*a(m-2)*a(n-1). - Michael Tulskikh, Jun 23 2020
Extensions
Edited by Dean Hickerson, Jun 24 2003
Recurrence appended to the name by Antti Karttunen, Mar 28 2017
Comments