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

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A110270 a(n) = (n mod 2)*(n mod 3). 3
0, 1, 0, 0, 0, 2, 0, 1, 0, 0, 0, 2, 0, 1, 0, 0, 0, 2, 0, 1, 0, 0, 0, 2, 0, 1, 0, 0, 0, 2, 0, 1, 0, 0, 0, 2, 0, 1, 0, 0, 0, 2, 0, 1, 0, 0, 0, 2, 0, 1, 0, 0, 0, 2, 0, 1, 0, 0, 0, 2, 0, 1, 0, 0, 0, 2, 0, 1, 0, 0, 0, 2, 0, 1, 0, 0, 0, 2, 0, 1, 0, 0, 0, 2, 0, 1, 0, 0, 0, 2, 0, 1, 0, 0, 0, 2, 0, 1, 0, 0, 0, 2, 0, 1, 0 (list; graph; refs; listen; history; text; internal format)
OFFSET

0,6

COMMENTS

Period 6: repeat [0, 1, 0, 0, 0, 2]. - Joerg Arndt, Aug 17 2014

Least positive integer k such that n^k == 1 (mod 6), or 0 if GCD(n,6) > 1. - Bruno Berselli, Mar 22 2016

LINKS

Colin Barker, Table of n, a(n) for n = 0..1000

Index entries for linear recurrences with constant coefficients, signature (0,0,0,0,0,1).

FORMULA

a(n) = A000035(n) * A010872(n).

a(n) = n mod (2 + n mod 2). - Wesley Ivan Hurt, Aug 16 2014

a(n) = a(n-6) for n>5. G.f.: x*(1+2*x^4) / ((1-x)*(1+x)*(1-x+x^2)*(1+x+x^2)). - Colin Barker, Mar 22 2016

a(n) = ( 6*sin(n*Pi/3) - sqrt(3) )*( sin(n*Pi/3) + sin(2*n*Pi/3) )/6. - Wesley Ivan Hurt, Jun 23 2016

MAPLE

A110270:=n->(n mod 2)*(n mod 3): seq(A110270(n), n=0..100); # Wesley Ivan Hurt, Aug 16 2014

MATHEMATICA

Table[Mod[n, 2]Mod[n, 3], {n, 0, 110}] (* or *) PadRight[{}, 110, {0, 1, 0, 0, 0, 2}] (* Harvey P. Dale, Oct 01 2013 *)

PROG

(PARI) a(n) = (n % 2) * (n % 3); \\ Michel Marcus, Aug 17 2014

(MAGMA) &cat [[0, 1, 0, 0, 0, 2]^^20]; // Bruno Berselli, Mar 22 2016

(PARI) concat(0, Vec(x*(1+2*x^4)/((1-x)*(1+x)*(1-x+x^2)*(1+x+x^2)) + O(x^50))) \\ Colin Barker, Mar 22 2016

CROSSREFS

Cf. A000035, A010872, A110269.

Sequence in context: A284557 A182032 A265245 * A284825 A318875 A187143

Adjacent sequences:  A110267 A110268 A110269 * A110271 A110272 A110273

KEYWORD

nonn,easy

AUTHOR

Reinhard Zumkeller, Jul 18 2005

STATUS

approved

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

License Agreements, Terms of Use, Privacy Policy. .

Last modified October 21 03:24 EDT 2019. Contains 328291 sequences. (Running on oeis4.)