login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A089978 Expansion of 1/(1-3x-3x^3). 3
1, 3, 9, 30, 99, 324, 1062, 3483, 11421, 37449, 122796, 402651, 1320300, 4329288, 14195817, 46548351, 152632917, 500486202, 1641103659, 5381209728, 17645087790, 57858574347, 189719352225, 622093320045, 2039855683176 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,2
LINKS
FORMULA
a(n) = Sum_{k=0..floor(n/2)} C(n-2*k, k)3^(n-2*k).
a(0)=1, a(1)=3, a(2)=9, a(n)=3*a(n-1)+3*a(n-3). - Harvey P. Dale, Jul 22 2015
EXAMPLE
G.f. = 1 + 3*x + 9*x^2 + 30*x^3 + 99*x^4 + 324*x^5 + 1062*x^6 + 3483*x^7 + ...
MATHEMATICA
CoefficientList[Series[1/(1-3x-3x^3), {x, 0, 30}], x] (* or *) LinearRecurrence[ {3, 0, 3}, {1, 3, 9}, 30] (* Harvey P. Dale, Jul 22 2015 *)
PROG
(PARI) {a(n) = sum(k=0, n\3, binomial(n - 2*k, k) * 3^(n - 2*k))}; /* Michael Somos, Jan 30 2015 */
(PARI) {a(n) = if( n<0, 0, polcoeff( 1 / (1 - 3*x - 3*x^3) + x * O(x^n), n))}; /* Michael Somos, Jan 30 2015 */
CROSSREFS
Sequence in context: A337034 A250128 A199137 * A052906 A102898 A050181
KEYWORD
easy,nonn
AUTHOR
Paul Barry, Nov 18 2003
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified May 5 04:20 EDT 2024. Contains 372257 sequences. (Running on oeis4.)