OFFSET
3,1
REFERENCES
J. H. Conway and R. K. Guy, The Book of Numbers, Copernicus Press, NY, 1996, p. 162.
M. Kraitchik, Recherches sur la Théorie des Nombres. Gauthiers-Villars, Paris, Vol. 1, 1924, Vol. 2, 1929, see Vol. 1, p. 131.
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=3..1000
Victor Meally, Letter to N. J. A. Sloane, no date.
FORMULA
(p-1)/x, where 10^x = 1 mod p.
EXAMPLE
1/13=.0769230769..., 2/13=.1538461538..., 3/13= .2307692307..., etc., with 2 different cycles, so a(4) = 2 [13 is the 4th prime different from 2 or 5].
MATHEMATICA
Map[(# - 1)/MultiplicativeOrder[10, #] &, {3}~Join~Prime@ Range[4, 101]] (* Michael De Vlieger, May 27 2020 *)
PROG
(PARI) f(p) = (p-1)/znorder(Mod(10, p));
lista(nn) = {my(vp=select(x->(10%x), primes(nn))); apply(f, vp); } \\ Michel Marcus, May 27 2020
CROSSREFS
KEYWORD
nonn,easy,base,nice
AUTHOR
EXTENSIONS
More terms from James A. Sellers, May 24 2000
Edited by Charles R Greathouse IV, Nov 01 2009
STATUS
approved