login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A224516
Number of solutions to x^4 - x == 0 (mod n).
2
1, 2, 2, 2, 2, 4, 4, 2, 4, 4, 2, 4, 4, 8, 4, 2, 2, 8, 4, 4, 8, 4, 2, 4, 2, 8, 4, 8, 2, 8, 4, 2, 4, 4, 8, 8, 4, 8, 8, 4, 2, 16, 4, 4, 8, 4, 2, 4, 4, 4, 4, 8, 2, 8, 4, 8, 8, 4, 2, 8, 4, 8, 16, 2, 8, 8, 4, 4, 4, 16, 2, 8, 4, 8, 4, 8, 8, 16, 4, 4, 4, 4, 2, 16, 4
OFFSET
1,2
LINKS
FORMULA
Multiplicative with a(p^e) = 4 for p == 1 (mod 3); a(p^e) = 2 for p == 2 (mod 3); a(3^1) = 2; a(3^e) = 4 for e > 1.
EXAMPLE
The solutions for n = 7 are 0, 1, 2, and 4.
MATHEMATICA
f[3, e_] := If[e == 1, 2, 4]; f[p_, e_] := If[Mod[p, 3] == 2, 2, 4]; a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 100] (* Amiram Eldar, Sep 19 2020 *)
PROG
(Sage)
def A224516(n) :
res = 1
for p, m in factor(n) :
if (p % 3 == 2) or (p == 3 and m == 1) : res *= 2
else : res *= 4
return res
CROSSREFS
KEYWORD
nonn,mult,easy
AUTHOR
Eric M. Schmidt, Apr 09 2013
STATUS
approved