login
This site is supported by donations to The OEIS Foundation.
Logo

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A109008 GCD(n,4). 5
4, 1, 2, 1, 4, 1, 2, 1, 4, 1, 2, 1, 4, 1, 2, 1, 4, 1, 2, 1, 4, 1, 2, 1, 4, 1, 2, 1, 4, 1, 2, 1, 4, 1, 2, 1, 4, 1, 2, 1, 4, 1, 2, 1, 4, 1, 2, 1, 4, 1, 2, 1, 4, 1, 2, 1, 4, 1, 2, 1, 4, 1, 2, 1, 4, 1, 2, 1, 4, 1, 2, 1, 4, 1, 2, 1, 4, 1, 2, 1, 4, 1, 2, 1, 4, 1, 2, 1, 4, 1, 2, 1, 4, 1, 2, 1, 4, 1, 2, 1, 4 (list; graph; refs; listen; history; internal format)
OFFSET

0,1

LINKS

Index to sequences with linear recurrences with constant coefficients, signature (0,0,0,1)

FORMULA

a(n) = 1 + [2|n] + 2*[4|n] = 2 + (-1)^n + cos(n*Pi/2), where [x|y] = 1 when x divides y, 0 otherwise.

a(n) = a(n-4).

Multiplicative with a(p^e) = GCD(p^e, 4). David W. Wilson (davidwwilson(AT)comcast.net) Jun 12, 2005.

Dirichlet g.f. (1+1/2^s+2/4^s)*zeta(s). - R. J. Mathar, Feb 28 2011

G.f. ( -4-x-2*x^2-x^3 ) / ( (x-1)*(1+x)*(1+x^2) ). - R. J. Mathar, Apr 04 2011

CROSSREFS

Cf. A109004.

Sequence in context: A087230 A030787 A176218 * A187025 A074695 A069098

Adjacent sequences:  A109005 A109006 A109007 * A109009 A109010 A109011

KEYWORD

nonn,easy,mult

AUTHOR

Mitch Harris (Harris.Mitchell(AT)mgh.harvard.edu)

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Transforms | Puzzles | Hot | Classics
Recent Additions | More pages | Superseeker | Maintained by The OEIS Foundation Inc.

Content is available under The OEIS End-User License Agreement .

Last modified February 13 12:17 EST 2012. Contains 205469 sequences.