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.

A086930 Smallest b>1 such that in base b representation the n-th prime is a repunit.

This page as a plain text file.
%I A086930 #20 Feb 16 2025 08:32:50
%S A086930 2,4,2,10,3,16,18,22,28,2,36,40,6,46,52,58,60,66,70,8,78,82,88,96,100,
%T A086930 102,106,108,112,2,130,136,138,148,150,12,162,166,172,178,180,190,192,
%U A086930 196,198,14,222,226,228,232,238,15,250,256,262,268,270,276,280,282
%N A086930 Smallest b>1 such that in base b representation the n-th prime is a repunit.
%C A086930 From _Robert G. Wilson v_, Mar 26 2014: (Start)
%C A086930 Obviously the first prime number, 2, can never become a repunit since it is even; therefore this sequence has the offset of 2.
%C A086930 Most terms, a(n), are one less than the n-th prime; e.g., for a(8) the eighth prime is 19_10 = 11_18. Therefore a(n) <= Pi(n)-1.
%C A086930 However there are some terms for which a(n) occurs before Pi(n)-1; e.g., for a(14) the fourteenth prime is 43_10 = 111_6.
%C A086930 Those indices, i, are: 4, 6, 11, 14, 21, 31, 37, 47, 53, 63, 82, 90, ..., . Prime(i) = A085104.
%C A086930 In those cases a(n) is a proper divisor of Prime(n)-1.
%C A086930 (End)
%H A086930 Robert G. Wilson v, <a href="/A086930/b086930.txt">Table of n, a(n) for n = 2..1001</a>
%H A086930 Eric Weisstein's World of Mathematics, <a href="https://mathworld.wolfram.com/Repunit.html">Repunit</a>
%e A086930 n=6: A000040(6) = 13 = 1*3^2 + 1*3^1 + 1*3^0: ternary(13)='111' and binary(13)='1101', therefore a(6)=3.
%t A086930 f[n_] := Block[{i = 1, d, p = Prime@ n}, d = Rest@ Divisors[p - 1]; While[id = IntegerDigits[p, d[[i]]]; id != Reverse@ id || Union@ id != {1}, i++]; d[[i]]]; Array[f, 60, 2]
%Y A086930 Cf. A000225, A003462, A002450, A003463, A003464, A023000, A023001, A002452, A002275, A004022, A016123, A016125, A085104.
%K A086930 nonn,base
%O A086930 2,1
%A A086930 _Reinhard Zumkeller_, Sep 21 2003