The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A070446 a(n) = n^2 mod 24. 2

%I

%S 0,1,4,9,16,1,12,1,16,9,4,1,0,1,4,9,16,1,12,1,16,9,4,1,0,1,4,9,16,1,

%T 12,1,16,9,4,1,0,1,4,9,16,1,12,1,16,9,4,1,0,1,4,9,16,1,12,1,16,9,4,1,

%U 0,1,4,9,16,1,12,1,16,9,4,1,0,1,4,9,16,1,12,1,16,9,4,1,0,1,4,9,16,1,12,1

%N a(n) = n^2 mod 24.

%C Periodic with period = 12. - _Harvey P. Dale_, Jun 19 2014

%C From _Jesse Fiedler_, Aug 23 2019: (Start)

%C If a(n) = 1, then n is odd and is not divisible by 3.

%C For n <= 7919 and a(n)=1, approximately 37.8% of values of n are prime.

%C For n <= 104729, and a(n)=1, approximately 28.64% of values of n are prime.

%C (End)

%H G. C. Greubel, <a href="/A070446/b070446.txt">Table of n, a(n) for n = 0..1000</a>

%H <a href="/index/Rec#order_12">Index entries for linear recurrences with constant coefficients</a>, signature (0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1).

%t Table[Mod[n^2,24],{n,0,200}] (* _Vladimir Joseph Stephan Orlovsky_, Apr 23 2011 *)

%t PowerMod[Range[0,100],2,24] (* or *) PadRight[{},100,{0,1,4,9,16,1,12,1,16,9,4,1}] (* _Harvey P. Dale_, Jun 19 2014 *)

%o (PARI) a(n)=n^2%24 \\ _Charles R Greathouse IV_, Apr 06 2016

%K nonn,easy

%O 0,3

%A _N. J. A. Sloane_, May 12 2002

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.

Last modified April 18 02:38 EDT 2021. Contains 343072 sequences. (Running on oeis4.)