login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A123752
a(n) = 7*a(n-2), a(0) = 1, a(1) = 2.
1
1, 2, 7, 14, 49, 98, 343, 686, 2401, 4802, 16807, 33614, 117649, 235298, 823543, 1647086, 5764801, 11529602, 40353607, 80707214, 282475249, 564950498, 1977326743, 3954653486, 13841287201, 27682574402, 96889010407, 193778020814
OFFSET
0,2
COMMENTS
The first 2n terms are the divisors of 2 * 7^(n - 1). - Alonso del Arte, Jul 14 2016
FORMULA
a(n) = 7^(n/2)*(7*(1+(-1)^n) + 2*sqrt(7)*(1-(-1)^n))/14.
From R. J. Mathar, Jun 18 2008: (Start)
O.g.f.: (1 + 2*x)/(1 - 7*x^2).
a(2n) = A000420(n). a(2n+1) = 2*A000420(n). (End)
a(n+3) = a(n+2)*a(n+1)/a(n). - Reinhard Zumkeller, Mar 04 2011
E.g.f.: cosh(sqrt(7)*x) + 2*sinh(sqrt(7)*x)/sqrt(7). - G. C. Greubel, Aug 10 2019
MAPLE
a[0]:=1: a[1]:=2: for n from 2 to 30 do a[n]:=7*a[n-2] od: seq(a[n], n=0..30);
MATHEMATICA
LinearRecurrence[{0, 7}, {1, 2}, 30] (* Harvey P. Dale, Mar 21 2013 *)
halfMax = 13; Divisors[2 * 7^halfMax] (* Alonso del Arte, Jul 18 2016 *)
PROG
(Magma) [n le 2 select n else 7*Self(n-2): n in [1..30]]; //Vincenzo Librandi, Jul 25 2016
(PARI) a(n)=if(n%2, 2, 1)*7^(n\2) \\ Charles R Greathouse IV, Jul 25 2016
(Sage) [7^(n/2)*(7*(1+(-1)^n) + 2*sqrt(7)*(1-(-1)^n))/14 for n in (0..30)] # G. C. Greubel, Aug 10 2019
(GAP) a:=[1, 2];; for n in [3..30] do a[n]:=7*a[n-2]; od; a; # G. C. Greubel, Aug 10 2019
CROSSREFS
Cf. A018592.
Sequence in context: A128882 A018281 A018592 * A192507 A018622 A018668
KEYWORD
nonn,easy
AUTHOR
EXTENSIONS
Edited by N. J. A. Sloane, Nov 29 2006
STATUS
approved