OFFSET
1,1
COMMENTS
The sequence A175545 (numbers n such that the decimal form of the period of 1/n is prime) is only concerned with numbers n such that gcd(n,10)=1. Each number n such that gcd(n,10)<>1 generates a quotient where there exist a sequence of digits which is periodic after a finite sequence of digits, for example 1/36 = .0277777.... and 7 is periodic.
The prime numbers corresponding to this sequence are :
3, 5, 3, 7, 2, 3, 3, 3, 5, 3, 5, 37, 2, 3, 3, 7, 2, 3, 2,...
REFERENCES
H. Rademacher and O. Toeplitz, Von Zahlen und Figuren (Springer 1930, reprinted 1968), ch. 19, 'Die periodischen Dezimalbrueche'.
EXAMPLE
1584 is in the sequence because 1/1584 = .0006313131313131313131... and 31 is prime.
MATHEMATICA
Reap[Do[p=RealDigits[1/n][[1, -1]]; If[GCD[10, n]>1 && Head[p] === List, While[p[[-1]] == 0, p=Most[p]]; If[PrimeQ[FromDigits[p]], Sow[n]]], {n, 20000}]][[2, 1]]
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Michel Lagneau, Jul 01 2010
EXTENSIONS
Sequence corrected by T. D. Noe, Nov 18 2010
STATUS
approved