Binary Quadratic Forms An Algorithmic Approach - Buchmann, Johannes; Vollmer, Ulrich (Springer Berlin Heidelberg, 2007)