|
|
A096397
|
|
a(n) = #{ 0 <= i <= n : K(n, i) = -1 } where K(n, i) is the Kronecker symbol.
|
|
6
|
|
|
0, 0, 0, 1, 0, 2, 0, 1, 2, 0, 1, 4, 2, 6, 1, 1, 0, 8, 3, 8, 4, 6, 4, 8, 4, 0, 3, 9, 6, 14, 2, 9, 8, 10, 6, 10, 0, 18, 6, 6, 8, 20, 4, 21, 10, 12, 9, 18, 8, 0, 9, 14, 12, 26, 8, 11, 12, 18, 13, 26, 8, 30, 11, 17, 0, 24, 6, 34, 16, 22, 10, 28, 12, 36, 13, 18, 18, 30, 10, 28, 16, 0, 18, 39, 12, 32
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,6
|
|
LINKS
|
|
|
FORMULA
|
|
|
MAPLE
|
K := (n, k) -> NumberTheory:-KroneckerSymbol(n, k):
seq(nops(select(k -> K(n, k) = -1, [seq(0..n)])), n = 0..85);
|
|
MATHEMATICA
|
Table[Count[Table[KroneckerSymbol[n, k], {k, 0, n}], -1], {n, 0, 70}]
|
|
PROG
|
(PARI) a(n) = sum(i=0, n, if(kronecker(n, i) + 1, 0, 1))
(SageMath)
print([sum(kronecker(n, k) == -1 for k in range(n + 1)) for n in range(86)])
|
|
CROSSREFS
|
Cf. A096396 (#K(n,i)=1), this sequence (#K(n,i)=-1), A062830 (#K(n,i)=0).
|
|
KEYWORD
|
nonn
|
|
AUTHOR
|
|
|
EXTENSIONS
|
Offset set to 0, a(0) = 0 added, and name adapted by Peter Luschny, May 15 2024
|
|
STATUS
|
approved
|
|
|
|