

A097065


Interleave n+1 and n1.


7



1, 1, 2, 0, 3, 1, 4, 2, 5, 3, 6, 4, 7, 5, 8, 6, 9, 7, 10, 8, 11, 9, 12, 10, 13, 11, 14, 12, 15, 13, 16, 14, 17, 15, 18, 16, 19, 17, 20, 18, 21, 19, 22, 20, 23, 21, 24, 22, 25, 23, 26, 24, 27, 25, 28, 26, 29, 27, 30, 28, 31, 29, 32, 30, 33, 31, 34, 32, 35, 33, 36, 34, 37, 35, 38
(list;
graph;
refs;
listen;
history;
text;
internal format)



OFFSET

0,3


COMMENTS

Pairwise sums are abs(A023443), or n1+2*0^n. The partial sums of this sequence is A000124, with extra leading 1. Partial sums are A097066. Binomial transform is A097067.


LINKS

Table of n, a(n) for n=0..74.
Index entries for linear recurrences with constant coefficients, signature (1,1,1).


FORMULA

G.f.: (12x+2x^2)/((1+x)(1x)^2).
a(n) = (2n1)/4 + 5(1)^n/4.
a(n) = floor((n+2)/2)  2 * (n mod 2).  Reinhard Zumkeller, Apr 06 2015
a(n) = a(n1) + a(n2)  a(n3) for n > 2.  Wesley Ivan Hurt, Jan 10 2017


MAPLE

A097065:=n>(2*n1)/4 + 5*(1)^n/4: seq(A097065(n), n=0..150); # Wesley Ivan Hurt, Jan 10 2017


MATHEMATICA

Table[(2n  1)/4 + 5(1)^n/4, {n, 0, 75}] (* Or *) Flatten[ Table[{n + 1, n  1}, {n, 0, 37}]] (* Or *) CoefficientList[Series[(1  2x + 2x^2)/((1 + x)(1  x)^2), {x, 0, 75}], x] (* Robert G. Wilson v, Jul 24 2004 *)


PROG

(Haskell)
import Data.List (transpose)
a097065 n = n'  2 * m where (n', m) = divMod (n + 2) 2
a097065_list = concat $ transpose [[1 ..], [1 ..]]
(PARI) a(n)=n\2+1n%2*2 \\ Charles R Greathouse IV, Sep 02 2015
(Magma) [(2*n1)/4 + 5*(1)^n/4 : n in [0..100]]; // Wesley Ivan Hurt, Jan 10 2017


CROSSREFS

Essentially the same as A084964.
Cf. A000124, A023443, A097066, A097067.
Sequence in context: A025637 A195826 A331478 * A084964 A267182 A008720
Adjacent sequences: A097062 A097063 A097064 * A097066 A097067 A097068


KEYWORD

easy,sign


AUTHOR

Paul Barry, Jul 22 2004


STATUS

approved



