login
Number of distinct primitive quadratic forms of discriminant -4n that exist such that every prime p for which -n is a quadratic residue mod p can be represented by one of them.
6

%I #57 Aug 09 2015 16:08:17

%S 1,1,1,1,2,2,1,2,2,2,2,2,2,3,2,2,3,2,2,3,4,2,2,4,2,4,2,2,4,4,2,3,4,3,

%T 4,3,2,4,3,4,5,4,2,4,4,3,3,4,3,4,4,3,4,4,3,6,4,2,5,4,4,5,3,3,6,6,2,5,

%U 6,4,4,4,3,6,4,4,6,4,3,6,4,3,5,6,4,6,4,4,7,6,4,4,4,5,5,6,3,5,4,3

%N Number of distinct primitive quadratic forms of discriminant -4n that exist such that every prime p for which -n is a quadratic residue mod p can be represented by one of them.

%C This is closely related to the class number problem.

%C A quadratic form is primitive if the GCD of the coefficients is 1. For example, the quadratic form 2*x^2+4*y^2 is not primitive.

%C Two quadratic forms f(x,y) = a*x^2+b*x*y+c*y^2 and g(x,y) = p*x^2+q*x*y+r*y^2 are distinct (or inequivalent) if and only if one cannot be obtained by a linear transformation (of the variables x, y) from the other. For example, the three quadratic forms u(x,y) = 3*x^2+2*x*y+3*y^2, v(x,y) = 3*x^2+4*x*y+4*y^2 and w(x,y) = 3*x^2+10*x*y+11*y^2 are equivalent because v(x,y) = u(x+y,-y) and w(x,y) = v(x+y,y). Also, w(x,y) = u(x+2*y,-y). Similarly, the two quadratic forms s(x,y) = 8*x^2+9*y^2 and t(x,y) = 17*x^2+50*x*y+41*y^2 are equivalent because t(x,y) = s(x+2*y,x+y).

%C The quadratic form x^2+n*y^2 is one such form and the only such form if n = 1, 2, 3, 4, 7.

%C a(n) = 1 if and only if n = 1, 2, 3, 4, 7.

%C If n is a squarefree convenient number (A000926), a(n) represents the class number of the ring Z[sqrt(n)] if n == 1 (mod 4) or if n == 2 (mod 4) and the class number of the ring Z[(1+sqrt(n))/2] if n == 3 (mod 4) and this class number is a power of 2.

%C Any prime p such that -n is a quadratic residue mod p can be represented by exactly one of the a(n) distinct primitive quadratic forms of discriminant = -4n in at most four different ways (if n >= 2) or in at most eight different ways (if n = 1).

%C If n is a prime congruent to 3 (mod 4), then a(n) = A232550(n).

%C If p is a prime, p^2 does not divide n, and p > 2 if n == 3 (mod 8), then there is a multiple of p in which p is raised to an odd power which can be written in the form x^2+n*y^2 if and only if -n is a quadratic residue mod p.

%C The product of two numbers (prime or composite, same or different) which can be represented by the same quadratic form of discriminant = -4n can be written in the form x^2+n*y^2, as the following identity shows:

%C (X*a^2+Y*a*b+Z*b^2)*(X*c^2+Y*c*d+Z*d^2) = (a*c*X+b*d*Z+a*d*(Y/2)+b*c*(Y/2))^2 + ((X*Z)-(Y^2/4))*(a*d-b*c)^2.

%C (X*a^2+Y*a*b+Z*b^2)*(X*c^2+Y*c*d+Z*d^2) = (a*c*X+b*d*((Y^2/(2*X))-Z)+a*d*(Y/2)+b*c*(Y/2))^2 + ((X*Z)-(Y^2/4))*(b*d*(Y/X)+a*d+b*c)^2.

%C Note that for the latter equation, (a*c*X+b*d*((Y^2/(2*X))-Z)+a*d*(Y/2)+b*c*(Y/2)) and (b*d*(Y/X)+a*d+b*c) need not always be integers. If they are both integers, then it will be a second representation of the product of (X*a^2+Y*a*b+Z*b^2) and (X*c^2+Y*c*d+Z*d^2) in the form x^2+((X*Z)-(Y^2/4))*y^2.

%C This sequence is the same as taking every fourth number in A107628. - _T. D. Noe_, Jan 02 2014

%H V. Raman, <a href="/A232551/a232551.txt">Illustration of above mentioned quadratic forms for n = 1..1000</a>

%e If n = 1, 2, 3, 4 or 7, then the only such available quadratic form is x^2+n*y^2.

%e For n = 5, every prime that is congruent to {1, 2, 3, 5, 7, 9} mod 20 can be represented by either of the two distinct primitive quadratic forms of discriminant = -20: x^2+5*y^2 or 2*x^2+2*x*y+3*y^2.

%e For n = 6, every prime that is congruent to {1, 2, 3, 5, 7, 11} mod 24 can be represented by either of the two distinct primitive quadratic forms of discriminant = -24: x^2+6*y^2 or 2*x^2+3*y^2.

%e For n = 10, every prime that is congruent to {1, 2, 5, 7, 9, 11, 13, 19, 23, 37} mod 40 can be represented by either of the two distinct primitive quadratic forms of discriminant = -40: x^2+10*y^2 or 2*x^2+5*y^2.

%Y Cf. A000003, A000926, A232529, A232530, A232550 (Number of distinct primitive quadratic forms of discriminant = -4*n needed to generate all primes p for which p is a quadratic residue (mod 4*n) or p-n is a quadratic residue (mod 4*n)).

%K nonn,uned

%O 1,5

%A _V. Raman_, Nov 26 2013