OFFSET
0,3
COMMENTS
Partial sums give the generalized 17-gonal numbers (A303305).
More generally, the partial sums of the sequence formed by the multiples of m and the odd numbers interleaved, give the generalized k-gonal numbers, with m >= 1 and k = m + 4.
a(n) is also the length of the n-th line segment of the rectangular spiral whose vertices are the generalized 17-gonal numbers.
LINKS
Colin Barker, Table of n, a(n) for n = 0..1000
Index entries for linear recurrences with constant coefficients, signature (0,2,0,-1).
FORMULA
a(2n) = 13*n, a(2n+1) = 2*n + 1.
From Colin Barker, Jul 29 2018: (Start)
G.f.: x*(1 + 13*x + x^2) / ((1 - x)^2*(1 + x)^2).
a(n) = 2*a(n-2) - a(n-4) for n>3. (End)
Multiplicative with a(2^e) = 13*2^(e-1), and a(p^e) = p^e for an odd prime p. - Amiram Eldar, Oct 14 2023
Dirichlet g.f.: zeta(s-1) * (1 + 11/2^s). - Amiram Eldar, Oct 25 2023
a(n) = (15 + 11*(-1)^n)*n/4. - Aaron J Grech, Aug 20 2024
MATHEMATICA
Table[{13n, 2n + 1}, {n, 0, 35}] // Flatten (* or *)
CoefficientList[Series[(x^3 + 13 x^2 + x)/(x^2 - 1)^2, {x, 0, 69}], x] (* or *)
LinearRecurrence[{0, 2, 0, -1}, {0, 1, 13, 3}, 70] (* Robert G. Wilson v, Jul 26 2018 *)
PROG
(PARI) a(n) = if(n%2==0, return((n/2)*13), return(n)) \\ Felix Fröhlich, Jul 26 2018
(PARI) concat(0, Vec(x*(1 + 13*x + x^2) / ((1 - x)^2*(1 + x)^2) + O(x^60))) \\ Colin Barker, Jul 29 2018
CROSSREFS
Column 13 of A195151.
Sequences whose partial sums give the generalized k-gonal numbers: A026741 (k=5), A001477 (k=6), zero together with A080512 (k=7), A022998 (k=8), A195140 (k=9), zero together with A165998 (k=10), A195159 (k=11), A195161 (k=12), A195312 (k=13), A195817 (k=14), A317311 (k=15), A317312 (k=16).
Cf. A303305.
KEYWORD
nonn,easy,mult
AUTHOR
Omar E. Pol, Jul 25 2018
STATUS
approved