%I #39 Dec 27 2023 14:49:22
%S 0,1,4,9,1,10,6,4,4,6,10,1,9,4,1,0,1,4,9,1,10,6,4,4,6,10,1,9,4,1,0,1,
%T 4,9,1,10,6,4,4,6,10,1,9,4,1,0,1,4,9,1,10,6,4,4,6,10,1,9,4,1,0,1,4,9,
%U 1,10,6,4,4,6,10,1,9,4,1,0,1,4,9,1,10,6,4,4,6,10,1,9,4,1,0,1,4,9,1,10,6
%N a(n) = n^2 mod 15.
%C Equivalently, n^6 mod 15. - _Ray Chandler_, Dec 27 2023
%H G. C. Greubel, <a href="/A070438/b070438.txt">Table of n, a(n) for n = 0..1000</a>
%H <a href="/index/Rec#order_15">Index entries for linear recurrences with constant coefficients</a>, signature (0,0,0,0,0,0,0,0,0,0,0,0,0,0,1).
%F From _Reinhard Zumkeller_, Apr 24 2009: (Start)
%F a(m*n) = a(m)*a(n) mod 15.
%F a(15*n+7+k) = a(15*n+8-k) for k <= 15*n+7.
%F a(15*n+k) = a(15*n-k) for k <= 15*n.
%F a(n+15) = a(n). (End)
%F From _R. J. Mathar_, Mar 14 2011: (Start)
%F a(n) = a(n-15).
%F G.f.: -x*(1+x) *(x^12+3*x^11+6*x^10-5*x^9+15*x^8-9*x^7+13*x^6-9*x^5+15*x^4-5*x^3+6*x^2+3*x+1) / ( (x-1) *(1+x^4+x^3+x^2+x) *(1+x+x^2) *(1-x+x^3-x^4+x^5-x^7+x^8) ). (End)
%F G.f.: (x^14 +4*x^13 +9*x^12 +x^11 +10*x^10 +6*x^9 +4*x^8 +4*x^7 +6*x^6 +10*x^5 +x^4 +9*x^3 +4*x^2 +x)/(-x^15 +1). - _Colin Barker_, Aug 14 2012
%t Table[Mod[n^2,15],{n,0,200}] (* _Vladimir Joseph Stephan Orlovsky_, Apr 21 2011 *)
%t LinearRecurrence[{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1},{0, 1, 4, 9, 1, 10, 6, 4, 4, 6, 10, 1, 9, 4, 1},97] (* _Ray Chandler_, Aug 26 2015 *)
%o (Sage) [power_mod(n,2,15)for n in range(0, 97)] # _Zerinvary Lajos_, Nov 06 2009
%o (PARI) a(n)=n^2%15 \\ _Charles R Greathouse IV_, Sep 28 2015
%Y Cf. A000290, A008959, A010378, A070431, A070435, A070442, A070452, A159852.
%Y Row 15 of A048152.
%K nonn,easy
%O 0,3
%A _N. J. A. Sloane_, May 12 2002