OFFSET
1,5
LINKS
Umberto Cerruti, Il Teorema Cinese dei Resti (in Italian), 2015. The sequence is on page 26.
MATHEMATICA
v[n_] := Module[{s}, s = Select[Range[n], CoprimeQ[n, #] == True &]; LCM @@ s]; g1[n_] := If[n == 1, 0, If[IntegerQ[PrimitiveRoot[n]], PowerMod[n, -1, v[n]], PowerMod[-n, -1, v[n]]]]; Table[g1[k], {k, 1, 40}]
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Bruno Berselli, Mar 12 2015 - proposed by Umberto Cerruti (Department of Mathematics "Giuseppe Peano", University of Turin, Italy)
STATUS
approved