login
A307381
Number of sextic primitive Dirichlet characters modulo n.
6
1, 0, 1, 1, 1, 0, 5, 2, 4, 0, 1, 1, 5, 0, 1, 0, 1, 0, 5, 1, 5, 0, 1, 2, 0, 0, 0, 5, 1, 0, 5, 0, 1, 0, 5, 4, 5, 0, 5, 2, 1, 0, 5, 1, 4, 0, 1, 0, 0, 0, 1, 5, 1, 0, 1, 10, 5, 0, 1, 1, 5, 0, 20, 0, 5, 0, 5, 1, 1, 0, 1, 8, 5, 0, 0, 5, 5, 0, 5, 0, 0, 0, 1, 5, 1, 0, 1
OFFSET
1,7
COMMENTS
a(n) is the number of primitive Dirichlet characters modulo n such that all entries are 0 or a six-power root of unity (1, (1 + sqrt(3)*i)/2, (-1 + sqrt(3)*i)/2), -1, (-1 - sqrt(3)*i)/2, (1 - sqrt(3)*i)/2)).
Mobius transform of A319100.
LINKS
FORMULA
Multiplicative with a(4) = 1, a(8) = 2, a(2^e) = 0 for e = 1 or e >= 4; a(3) = 1, a(9) = 4, a(3^e) = 0 for e >= 3; a(p) = 5 if p == 1 (mod 6) and 1 if p == 5 (mod 6), a(p^e) = 0 if p > 3 and e >= 2.
EXAMPLE
Let w = exp(2*Pi/6) = (1 + sqrt(3)*i)/2. For n = 19, the 5 sextic primitive Dirichlet characters modulo n are:
Chi_1 = [0, 1, w, w, w - 1, -w, w - 1, 1, -1, w - 1, -w + 1, 1, -1, -w + 1, w, -w + 1, -w, -w, -1];
Chi_2 = [0, 1, w - 1, w - 1, -w, w - 1, -w, 1, 1, -w, -w, 1, 1, -w, w - 1, -w, w - 1, w - 1, 1];
Chi_3 = [0, 1, -1, -1, 1, 1, 1, 1, -1, 1, -1, 1, -1, -1, -1, -1, 1, 1, -1];
Chi_4 = [0, 1, -w, -w, w - 1, -w, w - 1, 1, 1, w - 1, w - 1, 1, 1, w - 1, -w, w - 1, -w, -w, 1];
Chi_5 = [0, 1, -w + 1, -w + 1, -w, w - 1, -w, 1, -1, -w, w, 1, -1, w, -w + 1, w, w - 1, w - 1, -1],
so a(19) = 5.
MATHEMATICA
f[2, e_] := Which[e == 1, 0, e == 2, 1, e == 3, 2, e >= 4, 0]; f[3, e_] := Which[e == 1, 1, e == 2, 4, e >= 3, 0]; f[p_, 1] := If[Mod[p, 6] == 1, 5, 1]; f[p_, e_] := 0; a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 100] (* Amiram Eldar, Sep 16 2020 *)
PROG
(PARI) a(n)={
my(r=1, f=factor(n));
for(j=1, #f[, 1], my(p=f[j, 1], e=f[j, 2]);
if(p==2, if(e==3, r*=2, if(e!=2, r=0; return(r))));
if(p==3, if(e==2, r*=4, if(e!=1, r=0; return(r))));
if(p>3, if(p%6==1&&e==1, r*=5, if(e!=1, r=0; return(r))));
);
return(r);
} \\ Jianing Song, Nov 10 2019
CROSSREFS
Number of k-th power primitive Dirichlet characters modulo n: A114643 (k=2), A160498 (k=3), A160499 (k=4), A307380 (k=5), this sequence (k=6), A307382 (k=7), A329272 (k=8).
Cf. A319100 (number of solutions to x^6 == 1 (mod n)).
Sequence in context: A350518 A214662 A277581 * A256167 A207528 A019901
KEYWORD
nonn,mult
AUTHOR
Jianing Song, Apr 06 2019
STATUS
approved