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.

A317556 a(n) is the smallest composite k such that k divides 2^(k*n-1) - 1.

This page as a plain text file.
%I A317556 #18 Sep 16 2018 17:09:02
%S A317556 341,80519,15,511,65,42671,15,161,445,35551,15,2047,85,80129,15,1561,
%T A317556 33,190679,15,983927,85,511,15,11303,345,2201,15,217,65,188393,15,
%U A317556 39071,129,2047,15,8727391,33,63457,15,511,65,2417783,15,64759,85,2921,15,1898777,133,119063,15,2263,65,10097
%N A317556 a(n) is the smallest composite k such that k divides 2^(k*n-1) - 1.
%C A317556 Inspired by A001567.
%C A317556 Based on definition of a(n), certain terms are easy to determine, i.e., a(4*t+3) = 15 and a(20*t+17) = 33 for all t >= 0.
%C A317556 Least k > 1 such that k divides 2^(k*n-1) - 1 (for n >= 1) are 3, 80519, 3, 7, 3, 31, 3, 127, 3, 7, 3, 23, 3, 8191, 3, 7, 3, 131071, 3, 524287, 3, 7, 3, 47, ...
%e A317556 a(1) = A001567(1) = 341.
%t A317556 a[n_] := Block[{k = 9}, While[PrimeQ[k] || PowerMod[2, k*n - 1, k] != 1, k += 2]; k]; Array[a, 54] (* _Giovanni Resta_, Sep 16 2018 *)
%o A317556 (PARI) isok(k,n)=Mod(2, k)^(k*n-1)==1;
%o A317556 a(n)={my(k=2); while (isprime(k)||!isok(k,n), k++); k; }
%Y A317556 Cf. A001567, A102457.
%K A317556 nonn
%O A317556 1,1
%A A317556 _Altug Alkan_, Sep 15 2018