Skip to content
Calculator Tools
Number Theory Calculators

Modular Arithmetic Calculator

Modular exponentiation (aᵇ mod m), modular inverse and a mod m for very large integers using BigInt precision.

Enter values

Results update as you type.

Result

7^560 mod 561

1

Computed with fast square-and-multiply exponentiation.

About the Modular Arithmetic Calculator

Modular exponentiation (aᵇ mod m), modular inverse and a mod m for very large integers using BigInt precision.

Also known as: modular exponentiation, modular inverse calculator, mod pow, power mod.

How to use this calculator

  1. Enter operation, a, m (modulus).
  2. The result updates instantly as you type — press Calculate (or Enter) at any time.
  3. Review the breakdown shown under the main result.
  4. Use Copy result or Share to save the answer or send a link with your inputs.

Formula

aᵇ mod m via square-and-multiply · a⁻¹: a·x ≡ 1 (mod m)

Worked example

Using the values pre-filled in the calculator above:

  • Operation: aᵇ mod m
  • a: 7
  • b (exponent): 560
  • m (modulus): 561

the calculator returns:

  • 7^560 mod 561: 1