login
A072858
Primes p such that the period of the decimal expansion of 1/p is a square.
2
2, 3, 5, 17, 101, 163, 257, 577, 883, 1297, 1801, 3137, 3529, 5477, 7057, 7351, 8929, 9397, 11831, 12101, 13457, 13553, 14401, 15361, 15377, 15973, 19841, 20809, 21401, 21601, 23549, 24337, 25601, 29401, 30977, 33301, 33751, 33857, 38237
OFFSET
1,1
LINKS
EXAMPLE
The period of 1/17 = 0.05882352941176470588... is 16 = 4^2, hence 17 is in the sequence.
The period of 1/163 = 81 = 9^2.
MATHEMATICA
Select[Prime[Range[4000]], IntegerQ @ Sqrt[Length[RealDigits[1/#][[1, 1]]]] &] (* Amiram Eldar, May 21 2022 *)
PROG
(PARI) (a(n)=if(n<4, n==2, znorder(Mod(10, prime(n))))); for(n=1, 1000, if(issquare(a(n))==1, print1(prime(n), ", "))) /* Thanks to Michael Somos for improvement of the PARI program */
CROSSREFS
Cf. A002371.
Sequence in context: A308316 A089983 A370606 * A276629 A218086 A291049
KEYWORD
easy,nonn,base
AUTHOR
Benoit Cloitre, Jul 26 2002
STATUS
approved