TITLE: How did Gauss conjecture there were nine Heegner numbers?
QUESTION [12 upvotes]: Coming from someone not very knowledgable in algebraic number theory it seems odd. At the time they didn't have the computing power to determine whether very high values (>>163) were Heegner numbers; so, why even assume there was a finite amount rather than infinite (let alone exactly the nine there are)?

REPLY [13 votes]: The first answer is that he did not. Gauss worked with binary quadratic forms with even middle coefficient (the determinant of a form $Ax^2 + 2Bxy + Cy^2$ is $B^2 - AC$), so some of his class numbers actually are ring class numbers modulo $2$ (equal to $3h$, where $h$ is the usual class number). In the Disquisitiones (art. 303) he gives a list, of which I give an extract here:
$$ \begin{array}{c|l} 
       h & {\rm determinant} \\ \hline
       1 & 1, 2, 3, 4, 7 \\
       3 & 11, 19, 23, 27, 31, 43, 67, 163 
    \end{array} $$
  It is of course easy to transfer this to our usual class numbers,
which is where the nine value up to $163$ are coming from.
In Gauss's case, proving that there are only finitely many determinants
with Gauss class number $1$ is actually quite easy; the difficult
part is showing that those with Gauss class number $3$ are finite.
Gauss also observed that there seem to be only finitely many determinants with given small class numbers.  
In addition to computational evidence Gauss also knew that the class number of his forms grows asymptotically as 
$$ \gamma \sqrt{D} - \delta, $$
where $\gamma = 2\pi/7e$ and $\delta = 2/\pi^2$ (art. 302).