login
A153286
a(n) = n^3 + sum((-1)^j*a(j)); for j=1 to n-1; a(1)=1.
4
1, 7, 33, 37, 135, 91, 309, 169, 555, 271, 873, 397, 1263, 547, 1725, 721, 2259, 919, 2865, 1141, 3543, 1387, 4293, 1657, 5115, 1951, 6009, 2269, 6975, 2611, 8013, 2977, 9123, 3367, 10305, 3781, 11559, 4219, 12885, 4681, 14283, 5167, 15753, 5677, 17295
OFFSET
1,2
COMMENTS
1 followed by interleaving of A154105 and 3*A154106. - Klaus Brockhaus, Jan 04 2009
FORMULA
G.f.: x*(1 + 7*x + 30*x^2 + 16*x^3 + 39*x^4 + x^5 + 2*x^6)/((1+x)^3*(1-x)^3). - Klaus Brockhaus, Jan 04 2009
From Walter Carlini, Jan 12 2009: (Start)
a(n) = 3n^2 - 3n + 1 if n is 1 or an even number;
a(n) = 9n^2 - 21n + 15 if n is any odd number other than 1. (End)
EXAMPLE
a(1)=1, a(2)=2^3-a(1)=8-1=7, a(3)=3^3+a(2)-a(1)=27+7-1=33, a(4)=64-33+7-1=37, a(5)=125+37-33+7-1=135, a(6)=216-135+37-33+7-1=91, etc.
PROG
(Magma) S:=[ 1 ]; for n in [2..45] do Append(~S, n^3 + &+[ (-1)^j*S[j]: j in [1..n-1] ]); end for; S; // Klaus Brockhaus, Jan 04 2009
CROSSREFS
The third of a family of sequences that includes A153284 and A153285.
Cf. A154105 (12*n^2 + 18*n + 7), A154106 (12*n^2 + 22*n + 11). - Klaus Brockhaus, Jan 04 2009
Sequence in context: A324412 A373442 A175189 * A060745 A275163 A051895
KEYWORD
easy,nonn
AUTHOR
Walter Carlini, Dec 23 2008, Jan 01 2009
EXTENSIONS
Extended beyond a(30) by Klaus Brockhaus, Jan 04 2009
G.f. corrected by Klaus Brockhaus, Oct 15 2009
STATUS
approved