Multiplication of terms with exponents