login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A084181
2^n+(-2)^n-(-1)^n.
1
1, 1, 7, 1, 31, 1, 127, 1, 511, 1, 2047, 1, 8191, 1, 32767, 1, 131071, 1, 524287, 1, 2097151, 1, 8388607, 1, 33554431, 1, 134217727, 1, 536870911, 1, 2147483647, 1, 8589934591, 1, 34359738367, 1, 137438953471, 1, 549755813887, 1, 2199023255551
OFFSET
0,3
COMMENTS
Binomial transform is A084182.
FORMULA
a(n)=2^n+(-2)^n-(-1)^n;
G.f.: (1+2x+4x^2)/((1+x)(1+2x)(1-2x));
E.g.f.: exp(2x)-exp(-x)+exp(-2x).
MATHEMATICA
LinearRecurrence[{-1, 4, 4}, {1, 1, 7}, 50] (* or *) Riffle[ LinearRecurrence[ {5, -4}, {1, 7}, 30], 1] (* Harvey P. Dale, Jan 02 2019 *)
CROSSREFS
Cf. A083420.
Sequence in context: A301731 A379007 A228498 * A002678 A147482 A171770
KEYWORD
easy,nonn
AUTHOR
Paul Barry, May 19 2003
STATUS
approved