A333570 Number of nonnegative values c such that c^n == -c (mod n).
1, 2, 1, 2, 1, 4, 1, 2, 1, 4, 1, 4, 1, 4, 3, 2, 1, 4, 1, 4, 1, 4, 1, 4, 1, 4, 1, 8, 1, 8, 1, 2, 1, 4, 3, 4, 1, 4, 3, 4, 1, 8, 1, 4, 1, 4, 1, 4, 1, 4, 3, 8, 1, 4, 3, 4, 1, 4, 1, 8, 1, 4, 1, 2, 1, 24, 1, 4, 1, 16, 1, 4, 1, 4, 3, 8, 1, 8, 1, 4, 1, 4, 1, 8, 5, 4, 3, 4, 1, 8, 7, 4, 1, 4, 3
Offset: 1
Keywords
Links
- Antti Karttunen, Table of n, a(n) for n = 1..20000
Programs
-
Magma
[#[c: c in [0..n-1] | -c^n mod n eq c]: n in [1..95]];
-
PARI
a(n) = sum(c=1, n, Mod(c, n)^n == -c); \\ Michel Marcus, Mar 27 2020
Formula
a(n) = A182816(n)/r for some odd r.
Comments