2 added 135 characters in body

The answer of following classical problem is surely known, but I can't find a reference

For which positive integer $n$ is the set $S_n$ of primes of the form $x^2+n y^2$ ($x$, $y$ integers) determined by congruences?

A set of prime $S$ is said determined by congruences if there is a positive integer $m$ and a set $A \subset (\mathbb{Z}/m\mathbb{Z})^\ast$ such that a prime $p$ not dividing $m$ is in $S$ if and only if $p$ modulo $m$ is in $A$. There is a natural place to look for this question: the book by Cox "primes number of the form $x^2+ny^2"$". Unfortunately I don't have it, my library doesn't have it, and I can't find it on the internet, except for some preview at Amazon and Google. From the table of content and the preview it seems that the book does not contain the answer to my question (otherwise I wouldn't ask) but it is still possible that the answer be hidden precisely in one of the sporadic pages that amazon doesn't want me to see.

From that book one knows that a prime $p$ is in $S_n$ if and only if it splits in the ring class field $L_n$ of the order $\mathbb{Z}[\sqrt{-n}]$ in the quadratic imaginary field $K_n:=\mathbb{Z}[\sqrt{-n}]$. Therefore the question becomes: is $L_n$ abelian over $\mathbb{Q}$? Now $H_n:=Gal(L_n/K_n)$ is the ring class group of $\mathbb{Z}[\sqrt{-n}]$, hence abelian, and $Gal(L_n/\mathbb{Q})$ is a semi-direct extension of $\mathbb{Z}/2\mathbb{Z}$ by $H_n$, the action of the non-trivial element of $\mathbb{Z}/2\mathbb{Z}$ on $H_n$ being $x \mapsto x^{-1}$. Hence, if I am not mistaken (am I?), the question is equivalent to

For which $n$ is the ring class group $H_n$ killed by $2$?

Thanks for any clue or reference. I am especially interested in the case $n=32$.

1

# Primes of the form $x^2+ny^2$ and congruences.

The answer of following classical problem is surely known, but I can't find a reference

For which positive integer $n$ is the set $S_n$ of primes of the form $x^2+n y^2$ ($x$, $y$ integers) determined by congruences?

A set of prime $S$ is said determined by congruences if there is a positive integer $m$ and a set $A \subset (\mathbb{Z}/m\mathbb{Z})^\ast$ such that a prime $p$ not dividing $m$ is in $S$ if and only if $p$ modulo $m$ is in $A$. There is a natural place to look for this question: the book by Cox "primes number of the form $x^2+ny^2"$". Unfortunately I don't have it, my library doesn't have it, and I can't find it on the internet, except for some preview at Amazon and Google. From the table of content and the preview it seems that the book does not contain the answer to my question (otherwise I wouldn't ask) but it is still possible that the answer be hidden precisely in one of the sporadic pages that amazon doesn't want me to see.

From that book one knows that a prime $p$ is in $S_n$ if and only if it splits in the ring class field $L_n$ of the order $\mathbb{Z}[\sqrt{-n}]$ in the quadratic imaginary field $K_n:=\mathbb{Z}[\sqrt{-n}]$. Therefore the question becomes: is $L_n$ abelian over $\mathbb{Q}$? Now $H_n:=Gal(L_n/K_n)$ is the ring class group of $\mathbb{Z}[\sqrt{-n}]$, hence abelian, and $Gal(L_n/\mathbb{Q})$ is a semi-direct extension of $\mathbb{Z}/2\mathbb{Z}$ by $H_n$, the action of the non-trivial element of $\mathbb{Z}/2\mathbb{Z}$ on $H_n$ being $x \mapsto x^{-1}$. Hence, if I am not mistaken (am I?), the question is equivalent to

For which $n$ is the ring class group $H_n$ killed by $2$?

Thanks for any clue or reference. I am especially interested in the case $n=32$.