login
A395771
The twisted Euler phi-function for the Dirichlet character kronecker(-7,.) mod 7.
10
1, 1, 4, 2, 6, 4, 7, 4, 12, 6, 10, 8, 14, 7, 24, 8, 18, 12, 20, 12, 28, 10, 22, 16, 30, 14, 36, 14, 28, 24, 32, 16, 40, 18, 42, 24, 36, 20, 56, 24, 42, 28, 42, 20, 72, 22, 48, 32, 49, 30, 72, 28, 52, 36, 60, 28, 80, 28, 60, 48, 62, 32, 84, 32, 84, 40, 66, 36, 88, 42
OFFSET
1,3
COMMENTS
We have h(-7*n^2), the class number of the order of Z[(1+sqrt(-7))/2] with discriminant -7*n^2, is equal to a(n).
In general, let d < 0 be a fundamental discriminant and n be a positive integer such that d*n^2 < -4, then h(d*n^2) = L(0,kronecker(d,.)) * n * Product_{p|n, p prime} (1 - kronecker(d,p)/p). This is a combination of Theorem 7.24 in "Primes of the form x^2+ny^2" by Cox and the Dirichlet class number formula. Here L(0,kronecker(-7,.)) = 1.
REFERENCES
D. A. Cox, Primes of the form x^2+ny^2, Wiley, New York, 1989, p. 146.
LINKS
FORMULA
Multiplicative with a(7^e) = 7^e, a(p^e) = p^(e-1)*(p-1) if p == 1, 2, 4 (mod 7) and a(p^e) = p^(e-1)*(p+1) if p == 3, 5, 6 (mod 7).
EXAMPLE
Given L(0,kronecker(-7,.)) = 1, we have: h(-7*1^2) = a(1) = 1, h(-7*2^2) = a(2) = 1, h(-7*3^2) = a(3) = 4, h(-7*4^2) = a(4) = 2, ...
MATHEMATICA
f[p_, e_] := p^(e-1)*(p - KroneckerSymbol[-7, p]); a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 100] (* Amiram Eldar, May 07 2026 *)
PROG
(PARI) a(n, {d=-7}) = my(f=factor(n)[, 1]~, w=#f); n * prod(i=1, w, 1 - kronecker(d, f[i])/f[i])
CROSSREFS
A175629 is the corresponding Dirichlet character.
Cf. for fundamental discriminants -3..-24: A227128, A395768, this sequence, A395769, A395772, A395773, A395774, A395775, A395776, A395777.
Sequence in context: A386713 A162339 A200697 * A253629 A327095 A176836
KEYWORD
nonn,easy,mult
AUTHOR
Jianing Song, May 05 2026
STATUS
approved