OFFSET
1,1
COMMENTS
Primes 2 and 5 are excluded because 1/2 and 1/5 have no period. Also primes p whose multiplicative order mod p is less than p-1.
REFERENCES
N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
LINKS
T. D. Noe, Table of n, a(n) for n = 1..1000
Victor Meally, Letter to N. J. A. Sloane, no date.
MATHEMATICA
Select[Prime[Range[100]], MultiplicativeOrder[10, #] < # - 1 &]
PROG
(PARI) a(n)=gcd(n, 10)==1 && isprime(n) && znorder(Mod(10, n))<n-1 \\ Charles R Greathouse IV, Mar 15 2014
(Python)
from itertools import islice
from sympy import nextprime, n_order
def A006559_gen(startvalue=1): # generator of terms >= startvalue
p = max(startvalue-1, 1)
while (p:=nextprime(p)):
if p!=2 and p!=5 and n_order(10, p)<p-1:
yield p
CROSSREFS
KEYWORD
nonn,easy,nice,base,changed
AUTHOR
EXTENSIONS
More terms from James A. Sellers, Aug 21 2000
STATUS
approved