OFFSET
0,3
COMMENTS
Partial sums give the generalized 12-gonal (or dodecagonal) numbers A195162.
The moment generating function of p(x, m=2, n=1, mu=2) = 4*x*E(x, 2, 1), see A163931 and A274181, is given by M(a) = (- 4*log(1-a) - 4 * polylog(2, a))/a^2. The series expansion of M(a) leads to the sequence given above. - Johannes W. Meijer, Jul 03 2016
a(n) is also the length of the n-th line segment of the rectangular spiral whose vertices are the generalized 12-gonal numbers. - Omar E. Pol, Jul 27 2018
LINKS
Vincenzo Librandi, Table of n, a(n) for n = 0..10000
Index entries for linear recurrences with constant coefficients, signature (0,2,0,-1).
FORMULA
a(2n) = 8n, a(2n+1) = 2n+1. [corrected by Omar E. Pol, Jul 26 2018]
a(n) = (6*(-1)^n+10)*n/4. - Vincenzo Librandi, Sep 27 2011
a(n) = 2*a(n-2)-a(n-4). G.f.: x*(1+8*x+x^2)/((1-x)^2*(1+x)^2). - Colin Barker, Aug 11 2012
From Ilya Gutkovskiy, Jul 03 2016: (Start)
a(m*2^k) = m*2^(k+2), k>0.
E.g.f.: x*(4*sinh(x) + cosh(x)).
Dirichlet g.f.: 2^(-s)*(2^s + 6)*zeta(s-1). (End)
Multiplicative with a(2^e) = 4*2^e, a(p^e) = p^e for odd prime p. - Andrew Howroyd, Jul 23 2018
a(n) = A144433(n-1) for n > 1. - Georg Fischer, Oct 14 2018
MAPLE
a := proc(n): (6*(-1)^n+10)*n/4 end: seq(a(n), n=0..59); # Johannes W. Meijer, Jul 03 2016
MATHEMATICA
With[{nn=30}, Riffle[8*Range[0, nn], 2*Range[0, nn]+1]] (* or *) LinearRecurrence[{0, 2, 0, -1}, {0, 1, 8, 3}, 60] (* Harvey P. Dale, Nov 24 2013 *)
PROG
(Magma) &cat[[8*n, 2*n+1]: n in [0..30]]; // Vincenzo Librandi, Sep 27 2011
(PARI) concat(0, Vec(x*(1+8*x+x^2)/((1-x)^2*(1+x)^2) + O(x^99))) \\ Altug Alkan, Jul 04 2016
CROSSREFS
KEYWORD
nonn,easy,mult
AUTHOR
Omar E. Pol, Sep 10 2011
STATUS
approved