Bug fix

Fixed the computation of D(m,0) to the correct form without assuming
the first candidate term is a constant.