added modulus and exponentiation functions