polynomial class that uses listclass to store polyterms