Fix polynomial bug when there was one term