  In an important paper, Zagier proved that certain half-integral weight
modular forms are generating functions for traces of polynomials in the
$j$-function. It turns out that Zagier's work makes it possible to
algorithmically compute Hilbert class polynomials using a canonical family of
modular forms of weight $\frac{3}{2}$. We generalize these results and consider
Haupmoduln for levels $1, 2, 3, 5, 7,$ and $13$. We show that traces of
singular values of polynomials in Haupmoduln are again described by
coefficients of half-integral weight modular forms. This realization makes it
possible to algorithmically compute class polynomials.
