Affine Cipher Calculator

Encrypt or decrypt a message using the Affine Cipher.

* Keys: a and b (a must be coprime with 26).

Step 1: Enter Cipher Data

Key a must be coprime with 26.

Affine Cipher Formulas:
Encryption: E(x) = (a×x + b) mod 26
Decryption: D(x) = a⁻¹×(x – b) mod 26