cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A002143 Class numbers h(-p) where p runs through the primes p == 3 (mod 4).

Original entry on oeis.org

1, 1, 1, 1, 3, 3, 1, 5, 3, 1, 7, 5, 3, 5, 3, 5, 5, 3, 7, 1, 11, 5, 13, 9, 3, 7, 5, 15, 7, 13, 11, 3, 3, 19, 3, 5, 19, 9, 3, 17, 9, 21, 15, 5, 7, 7, 25, 7, 9, 3, 21, 5, 3, 9, 5, 7, 25, 13, 5, 13, 3, 23, 11, 5, 5, 31, 13, 5, 21, 15, 5, 7, 9, 7, 33, 7, 21, 3, 29, 3, 31, 19, 5, 11, 15, 27, 17, 13
Offset: 1

Views

Author

Keywords

Comments

a(n) = h(-A002145(n)).
Same as (1/p)*(sum of quadratic nonresidues mod p in (0,p) - sum of quadratic residues mod p in (0,p)), for prime p == 3 (mod 4) if p > 3. (See Davenport's book and the first Mathematica program.) - Jonathan Sondow, Oct 27 2011
Conjecture: For any prime p > 3 with p == 3 (mod 8), we have 2*h(-p)*sqrt(p) = Sum_{k=1..(p-1)/2} csc(2*Pi*k^2/p). - Zhi-Wei Sun, Aug 06 2019

Examples

			E.g., a(4) = 1 is the class number of -19, the 4th prime == 3 mod 4.
a(5) = -(1/23)*sum(n=1..22, n*(n|23)) = -(1/23)*(1 + 2 + 3 + 4 - 5 + 6 - 7 + 8 + 9 - 10 - 11 + 12 + 13 - 14 - 15 + 16 - 17 + 18 - 19 - 20 - 21 - 22) = 69/23 = 3. - _Jonathan Sondow_, Oct 27 2011
		

References

  • H. Davenport, Multiplicative Number Theory, Graduate Texts in Math. 74, 2nd ed., Springer, 1980, p. 51.
  • N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Cf. A002145 (primes p), A002146, A101435.

Programs

  • Mathematica
    Cases[ Table[ With[ {p = Prime[n]}, If[ Mod[p, 4] == 3, -(1/p)*Sum[ a*JacobiSymbol[a, p], {a, 1, p - 1}]]], {n, 1, 100}], Integer] (* _Jonathan Sondow, Oct 27 2011 *)
    p = Prime[n]; If[Mod[p, 4] == 3, NumberFieldClassNumber[Sqrt[-p]]] (* Jonathan Sondow, Feb 24 2012 *)
  • PARI
    forprime(p=3, 1e3, if(p%4==3, print1(qfbclassno(-p)", "))) \\ Charles R Greathouse IV, May 08 2011

Formula

h(-p) = 1 + 2*sum(0 <= n <= (1/2)*sqrt(p/3)-1, d(n^2+n+(p+1)/4, [2*n+1, sqrt(n^2+n+(p+1)/4)])) for prime p=3 mod 4, p>3. d(n, [a, b])=card{d: d|n and a
h(-p) = -(1/p)*sum(n=1..p-1, n*(n|p)) if p > 3, where (n|p) = +/- 1 is the Legendre symbol. - Jonathan Sondow, Oct 27 2011
h(-p) = (1/3)*sum(n=1..(p-1)/2, (n|p)) or sum(n=1..(p-1)/2, (n|p)) according as p == 3 or 7 (mod 8). - Jonathan Sondow, Feb 27 2012

Extensions

More terms from Antonio G. Astudillo (afg_astudillo(AT)hotmail.com), Jul 19 2002