addMonomials :: Monomial -> Monomial -> Monomial
addMonomials a b | sameVars a b = Monomial (ca + cb) va
                 | otherwise = error "different variables"
    where (Monomial ca va) = a
          (Monomial cb _) = b
addMonomials :: Monomial -> Monomial -> Monomial
addMonomials a b | sameVars a b = Monomial (ca + cb) va
                 | otherwise = error "different variables"
    where (Monomial ca va) = a
          (Monomial cb _) = b
addMonomials a b | sameVars a b = Monomial (ca + cb) va
                 | otherwise = error "different variables"
    where (Monomial ca va) = a
          (Monomial cb _) = b