|
|
A080512
|
|
a(n) = n if n is odd, a(n) = 3*n/2 if n is even.
|
|
35
|
|
|
1, 3, 3, 6, 5, 9, 7, 12, 9, 15, 11, 18, 13, 21, 15, 24, 17, 27, 19, 30, 21, 33, 23, 36, 25, 39, 27, 42, 29, 45, 31, 48, 33, 51, 35, 54, 37, 57, 39, 60, 41, 63, 43, 66, 45, 69, 47, 72, 49, 75, 51, 78, 53, 81, 55, 84, 57, 87, 59, 90, 61, 93, 63, 96, 65, 99, 67, 102
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,2
|
|
COMMENTS
|
First differences of the generalized heptagonal numbers A085787. - Omar E. Pol, Sep 10 2011
a(n) is also the length of the n-th line segment of the rectangular spiral whose vertices are the generalized heptagonal numbers. - Omar E. Pol, Jul 27 2018
|
|
LINKS
|
|
|
FORMULA
|
a(n) = n if n is odd, a(n) = 3*n/2 if n is even.
a(n)*a(n+3) = -3 + a(n+1)*a(n+2).
G.f.: (1+3*x+x^2)/((1-x^2)^2);
a(n) = n*(5 + (-1)^n)/4. (End)
Multiplicative with a(2^e) = 3*2^(e-1), a(p^e) = p^e otherwise. - Christian G. Bower, May 17 2005
Dirichlet g.f.: zeta(s-1) * (1 + 1/2^s). - Amiram Eldar, Oct 25 2023
|
|
MATHEMATICA
|
Table[If[EvenQ[n], 3n/2, n], {n, 68}] (* Jayanta Basu, May 20 2013 *)
|
|
PROG
|
(Haskell)
import Data.List (transpose)
a080512 n = if m == 0 then 3 * n' else n where (n', m) = divMod n 2
a080512_list = concat $ transpose [[1, 3 ..], [3, 6 ..]]
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,easy,mult
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|