I'm having trouble understanding Heegner numbers. I understand that 5 is not a Heegner number because the imaginary quadratic field $\mathbb{Q}[\sqrt{-5}]$ is not uniquely factorizable, e.g.:
$$ 6 = 2 \cdot 3 = (1 - \sqrt{-5})(1 + \sqrt{-5}) $$
But why is 3 then a Heegner number? To me it looks like it also loses the unique factorization:
$$ 4 = 2 \cdot 2 = (1 - \sqrt{-3})(1 + \sqrt{-3}) $$
I think I can factor 2 like this:
$$ 2 = (1 - \sqrt{-1})(1 + \sqrt{-1}) $$
But even then it seems like $(1 - \sqrt{-1})$ and $(1 - \sqrt{-3})$ seem to have no factor in common, at least that's what I see when checking for the gcd via python / sympy :
import sympy
from sympy import *
sm3 = 1 + sympy.sqrt(-3)
sm1 = 1 + sympy.sqrt(-1)
gcd(sm1, sm3)
1
Obviously I'm missing something very basic here but I can't figure out what.
The ring of algebraic integers in $\mathbb Q(\sqrt{-3})$ (that is, the integral closure of $\mathbb Z$ in that field) is larger than $\mathbb Z[\sqrt{-3}]$, namely, $\mathbb Z[\omega]$, where $\omega = {-1+\sqrt{-3}\over 2}$. So although $\mathbb Z[\sqrt{-3}]$ is not a principal ideal domain, the corrected, larger version is a PID.