cp's OEIS Frontend

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.

A112987 a(n) = 2^(2^n mod n) for n > 0; a(0) = 2.

This page as a plain text file.
%I A112987 #12 Sep 08 2022 08:45:23
%S A112987 2,1,1,4,1,4,16,4,1,256,16,4,16,4,16,256,1,4,1024,4,65536,256,16,4,
%T A112987 65536,128,16,67108864,65536,4,16,4,1,256,16,262144,268435456,4,16,
%U A112987 256,65536,4,4194304,4,65536,131072,16,4,65536,1073741824,16777216,256
%N A112987 a(n) = 2^(2^n mod n) for n > 0; a(0) = 2.
%C A112987 The definition of a(0) is motivated by the idea that (anything)^n = 1 for n = 0. We also get this if "mod n" is replaced by "in Z/nZ", for n = 0. - _M. F. Hasler_, Nov 09 2018
%H A112987 Vincenzo Librandi, <a href="/A112987/b112987.txt">Table of n, a(n) for n = 0..1000</a>
%F A112987 a(n) = 2^A015910(n) for n > 0. [Corrected by _M. F. Hasler_, Nov 09 2018]
%t A112987 Join[{2}, 2^Table[PowerMod[2, n, n], {n, 85}]] (* _Vincenzo Librandi_, Nov 09 2018 *)
%o A112987 (PARI) apply( A112987(n)=2^lift(if(n,Mod(2,n))^n), [0..50]) \\ _M. F. Hasler_, Nov 09 2018
%o A112987 (Magma) [2] cat [2^Modexp(2, n, n): n in [1..60]]; // _Vincenzo Librandi_, Nov 09 2018
%Y A112987 Cf. A015910.
%K A112987 easy,nonn
%O A112987 0,1
%A A112987 _Paul Barry_, Oct 08 2005
%E A112987 Name edited by _M. F. Hasler_, Nov 09 2018