Reminder: The OEIS is hiring a new managing editor, and the application deadline is January 26.
%I #31 Feb 24 2019 02:10:45
%S 2,3,4,5,12,14,22,23,25,51,103,168,170,207,239,337,415,675,831,1351,
%T 1663,2196,2198,2703,3327,4393,5407,6655,8787,10815,13311,17575,21631,
%U 26623,28560,28562,35151,43263,53247,57121,70303,86527,106495,114243,140607,173055,212991,228487,281215,346111
%N Bases in which 13 is a unique-period prime.
%C A prime p is called a unique-period prime in base b if there is no other prime q such that the period of the base-b expansion of its reciprocal, 1/p, is equal to the period of the reciprocal of q, 1/q.
%C A prime p is a unique-period prime in base b if and only if Zs(b, 1, ord(b,p)) = p^k, k >= 1. Here Zs(b, 1, d) is the greatest divisor of b^d - 1 that is coprime to b^m - 1 for all positive integers m < d, and ord(b,p) is the multiplicative order of b modulo p.
%C b is a term if and only if: (a) b = 13^t + 1, t >= 1; (b) b = 2^s*13^t - 1, s >= 0, t >= 1; (c) b = 2, 3, 4, 5, 22, 23, 239.
%C For every odd prime p, p is a unique-period prime in base b if b = p^t + 1, t >= 1 or b = 2^s*p^t - 1, s >= 0, t >= 1. These are trivial bases in which p is a unique-period prime, with ord(b,p) = 1 or 2. By Faltings's theorem, there are only finitely many nontrivial bases in which p is also a unique-period prime, with ord(b,p) >= 3. For p = 13, the nontrivial bases are 2, 3, 4, 5, 22, 23, 239.
%H Jianing Song, <a href="/A306077/b306077.txt">Table of n, a(n) for n = 1..554</a>
%H Wikipedia, <a href="http://en.wikipedia.org/wiki/Unique_prime">Unique prime</a>
%e 1/13 has period 12 in base 2. Note that 3, 5, 7, 13, 31 are the only prime factors of 2^12 - 1 = 4095, but 1/3 has period 2, 1/5 has period 4, 1/7 has period 3, 1/31 has period 5, so 13 is a unique-period prime in base 2. (For the same reason, 13 is a unique-period prime in base 4.)
%e 1/13 has period 3 in base 3. Note that 2, 13 are the only prime factors of 3^3 - 1 = 26, but 1/2 has period 1, so 13 is a unique-period prime in base 3.
%e 1/13 has period 3 in base 22. Note that 3, 7, 13 are the only prime factors of 22^3 - 1 = 10647, but 1/3 and 1/7 both have period 1, so 13 is a unique-period prime in base 22.
%o (PARI)
%o p = 13;
%o gpf(n)=if(n>1, vecmax(factor(n)[, 1]), 1);
%o test(n, q)=while(n%p==0, n/=p); if(q>1, while(n%q==0, n/=q)); n==1;
%o for(n=2, 10^6, if(gcd(n, p)==1, if(test(polcyclo(znorder(Mod(n, p)), n), gpf(znorder(Mod(n, p)))), print1(n, ", "))));
%Y Cf. A040017 (unique-period primes in base 10), A144755 (unique-period primes in base 2).
%Y Bases in which p is a unique-period prime: A000051 (p=2), A306073 (p=3), A306074 (p=5), A306075 (p=7), A306076 (p=11), this sequence (p=13).
%K easy,nonn
%O 1,1
%A _Jianing Song_, Jun 19 2018