A070517 a(n) = n^4 mod 13.
0, 1, 3, 3, 9, 1, 9, 9, 1, 9, 3, 3, 1, 0, 1, 3, 3, 9, 1, 9, 9, 1, 9, 3, 3, 1, 0, 1, 3, 3, 9, 1, 9, 9, 1, 9, 3, 3, 1, 0, 1, 3, 3, 9, 1, 9, 9, 1, 9, 3, 3, 1, 0, 1, 3, 3, 9, 1, 9, 9, 1, 9, 3, 3, 1, 0, 1, 3, 3, 9, 1, 9, 9, 1, 9, 3, 3, 1, 0, 1, 3, 3, 9, 1, 9, 9, 1, 9, 3, 3, 1, 0, 1, 3, 3, 9, 1, 9, 9, 1, 9
Offset: 0
Links
- Index entries for linear recurrences with constant coefficients, signature (0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1).
Programs
-
Magma
[Modexp(n, 4, 13): n in [0..100]]; // Vincenzo Librandi, Apr 02 2016 - after Bruno Berselli in A070403.
-
Mathematica
PowerMod[Range[0, 100], 4, 13] (* G. C. Greubel, Apr 01 2016 *)
-
PARI
a(n)=n^4%13 \\ Charles R Greathouse IV, Apr 06 2016
-
Sage
[power_mod(n,4,13)for n in range(0, 101)] # Zerinvary Lajos, Oct 31 2009
Formula
From G. C. Greubel, Apr 01 2016: (Start)
a(n+13) = a(n).
a(13*m) = 0.
G.f.: (x +3*x^2 +3*x^3 +9*x^4 +x^5 +9*x^6 +9*x^7 +x^8 +9*x^9 +3*x^10 +3*x^11 +x^12)/(1 - x^13). (End)
Comments