This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A036118 #40 Dec 14 2023 05:37:29 %S A036118 1,2,4,8,3,6,12,11,9,5,10,7,1,2,4,8,3,6,12,11,9,5,10,7,1,2,4,8,3,6,12, %T A036118 11,9,5,10,7,1,2,4,8,3,6,12,11,9,5,10,7,1,2,4,8,3,6,12,11,9,5,10,7,1, %U A036118 2,4,8,3,6,12,11,9,5,10,7 %N A036118 a(n) = 2^n mod 13. %C A036118 The sequence is 12-periodic. %D A036118 I. M. Vinogradov, Elements of Number Theory, pp. 220 ff. %H A036118 G. C. Greubel, <a href="/A036118/b036118.txt">Table of n, a(n) for n = 0..10000</a> %H A036118 <a href="/index/Rec#order_07">Index entries for linear recurrences with constant coefficients</a>, signature (1,0,0,0,0,-1,1). %F A036118 a(n) = 13/2 + (-5/3 - (2/3)*sqrt(3))*cos(Pi*n/6) + (-1/3 - sqrt(3))*sin(Pi*n/6) - (13/6)*cos(Pi*n/2) - (13/6)*sin(Pi*n/2) + (-5/3 + (2/3)*sqrt(3))*cos(5*Pi*n/6) + (sqrt(3) - 1/3)*sin(5*Pi*n/6). - _Richard Choulet_, Dec 12 2008 %F A036118 a(n) = a(n-1) - a(n-6) + a(n-7). - _R. J. Mathar_, Apr 13 2010 %F A036118 G.f.: (1 + x + 2*x^2 + 4*x^3 - 5*x^4 + 3*x^5 + 7*x^6)/ ((1-x) * (x^2+1) * (x^4 - x^2 + 1)). - _R. J. Mathar_, Apr 13 2010 %F A036118 a(n) = 13 - a(n+6) = a(n+12) for all n in Z. - _Michael Somos_, Oct 17 2018 %p A036118 [ seq(primroot(ithprime(i))^j mod ithprime(i),j=0..100) ]; %t A036118 PowerMod[2, Range[0, 70], 13] (* _Wesley Ivan Hurt_, Nov 20 2014 *) %o A036118 (Sage) [power_mod(2,n,13) for n in range(0,72)] # _Zerinvary Lajos_, Nov 03 2009 %o A036118 (PARI) a(n)=2^n%13 \\ _Charles R Greathouse IV_, Oct 07 2015 %o A036118 (Magma) [2^n mod 13: n in [0..100]]; // _G. C. Greubel_, Oct 16 2018 %o A036118 (GAP) List([0..95],n->PowerMod(2,n,13)); # _Muniru A Asiru_, Jan 31 2019 %Y A036118 Cf. A008831. %K A036118 nonn,easy %O A036118 0,2 %A A036118 _N. J. A. Sloane_