OFFSET
1,1
FORMULA
PROG
(Python)
from sympy import prime
def a(n):
p = prime(n)
return len(set([x**3 % p for x in range(p)]))
(PARI) a(n) = my(p=prime(n)); sum(k=0, p-1, ispower(Mod(k, p), 3)); \\ Michel Marcus, Feb 26 2019
CROSSREFS
KEYWORD
nonn
AUTHOR
Florian Severin, Jan 24 2019
STATUS
approved