Chris Spackman's NeoCities Page

Glossary

Plain-English definitions of terms used on the math and cryptography pages on this site. Click a term in the list below to jump to its definition, or use the "Used on:" links to go back to the page where you saw the term.

Quick Navigation

Math

Prime Number

A whole number greater than 1 that can only be divided evenly by 1 and itself. For example, 7 is prime because nothing divides it evenly except 1 and 7. The number 6 is not prime because 2 × 3 = 6.

Used on: Diffie-Hellman, RSA Key Generation

Modular Arithmetic (mod)

"Mod" means "remainder after division." For example, 17 mod 5 = 2, because 17 ÷ 5 = 3 remainder 2. Think of a clock: after 12 comes 1 again, not 13 — that is modular arithmetic with a modulus of 12.

Used on: Diffie-Hellman, RSA Key Generation, Caesar Cipher, Vigenère Cipher, One-Time Pad

Coprime

Two numbers are coprime when they share no common factors other than 1. For example, 8 and 15 are coprime because no number (other than 1) divides both of them evenly. Another way to say this: their GCD is 1.

Used on: RSA Key Generation

Exponent

A small number written above and to the right of another number, telling you how many times to multiply that number by itself. In 53, the exponent is 3, meaning 5 × 5 × 5 = 125.

Used on: Diffie-Hellman, RSA Key Generation

Modulus

The number you divide by when doing modular arithmetic. In "17 mod 5," the modulus is 5. In cryptography, the modulus is usually a very large number that helps keep calculations secure.

Used on: Diffie-Hellman, RSA Key Generation

Totient — phi(φ)

The totient of a number n, written φ(n), counts how many numbers from 1 to n share no common factors with n. In RSA, when n = p × q (two primes), the totient is simply (p−1) × (q−1).

Used on: RSA Key Generation

Modular Inverse (Modular Multiplicative Inverse)

The modular inverse of a number a (mod m) is another number d such that a × d mod m = 1. Think of it as "undoing" multiplication in modular arithmetic, similar to how dividing undoes multiplying with regular numbers.

Used on: RSA Key Generation

Factor / Factoring

A factor is a number that divides evenly into another number. Factoring means breaking a number into the numbers that multiply together to make it. For example, the factors of 12 are 1, 2, 3, 4, 6, and 12. RSA security depends on the fact that factoring very large numbers is extremely hard.

Used on: RSA Key Generation

GCD (Greatest Common Divisor)

The largest number that divides evenly into two or more numbers. For example, the GCD of 12 and 18 is 6. If the GCD of two numbers is 1, they are coprime.

Used on: RSA Key Generation

Cryptography

Cipher

A method for transforming a message so that only someone with the right key can read it. The original message is called the plaintext, and the scrambled version is called the ciphertext. Examples include the Caesar cipher, substitution cipher, and Vigenère cipher.

Used on: Caesar Cipher, Substitution Cipher, Playfair Cipher, Vigenère Cipher, Rail Fence Cipher, Columnar Transposition, One-Time Pad, Traditional Cryptography

Plaintext

The original, readable message before it has been encrypted. After encryption, it becomes ciphertext. The goal of decryption is to turn ciphertext back into plaintext.

Used on: Caesar Cipher, Substitution Cipher, Playfair Cipher, Vigenère Cipher, Rail Fence Cipher, Columnar Transposition, One-Time Pad

Ciphertext

The scrambled, unreadable version of a message after it has been encrypted. Without the correct key, ciphertext looks like random letters. Decrypting it with the right key turns it back into the original plaintext.

Used on: Vigenère Cipher, Rail Fence Cipher, Columnar Transposition, One-Time Pad

Key (Cipher Key)

A piece of information that controls how a cipher encrypts and decrypts messages. For a Caesar cipher, the key is the shift number. For a substitution cipher, the key is the scrambled alphabet. Without the correct key, you cannot decrypt the message.

Used on: Caesar Cipher, Substitution Cipher, Playfair Cipher, Vigenère Cipher, Columnar Transposition, One-Time Pad

Key Space

The total number of possible keys for a cipher. A larger key space means more keys an attacker would have to try in a brute-force attack. The Caesar cipher has a key space of only 26. The substitution cipher has a key space of 26! (about 4 × 1026).

Used on: Caesar Cipher, Substitution Cipher, Traditional Cryptography

Frequency Analysis

A method for breaking ciphers by studying how often each letter appears. In English, "E" is the most common letter (about 13% of all letters). If a ciphertext has one letter appearing much more than others, it is likely "E" in disguise. This technique breaks substitution ciphers despite their huge key space.

Used on: Substitution Cipher, Playfair Cipher, Vigenère Cipher, Rail Fence Cipher, Columnar Transposition, Traditional Cryptography, Breaking Substitution Ciphers, Breaking Vigenère

Substitution Cipher

A cipher that replaces each letter with a different letter. In a simple substitution cipher, each letter always maps to the same replacement letter. The Caesar cipher is a special case where the mapping is a simple shift. Substitution ciphers are vulnerable to frequency analysis.

Used on: Substitution Cipher, Playfair Cipher, Rail Fence Cipher, Traditional Cryptography, Breaking Substitution Ciphers

Transposition Cipher

A cipher that rearranges the positions of letters without changing the letters themselves. The rail fence cipher is a transposition cipher: the letters in the ciphertext are exactly the same as in the plaintext, just in a different order. This means frequency analysis is useless against it.

Used on: Rail Fence Cipher, Columnar Transposition, Traditional Cryptography, Breaking Transposition

Polyalphabetic Cipher

A cipher that uses multiple different substitution alphabets, switching between them as it encrypts. The Vigenère cipher is the most famous example: each letter of the keyword selects a different Caesar shift. This makes simple frequency analysis much harder because the same plaintext letter can encrypt to different ciphertext letters.

Used on: Vigenère Cipher, Breaking Vigenère

Digraph

A pair of two letters, used as the basic unit of encryption in the Playfair cipher. Instead of encrypting one letter at a time, the Playfair cipher splits the message into digraphs and transforms each pair together. This makes the cipher harder to break with simple frequency analysis.

Used on: Playfair Cipher

One-Time Pad

A cipher that uses a truly random key that is as long as the message and is used only once. When used correctly, it is the only cipher that is mathematically proven to be unbreakable. The practical challenge is that you need a secure way to share the key, which is as long as the message itself.

Used on: One-Time Pad

Symmetric Encryption

Encryption where the same key is used to both encrypt and decrypt the message. All five traditional ciphers on this site are symmetric: if you know the key used to encrypt, you can decrypt. The opposite is asymmetric encryption (like RSA), where different keys are used for encrypting and decrypting.

Used on: One-Time Pad

Public Key

A key that you share openly with everyone. Other people use your public key to encrypt messages that only you can read, or to verify your digital signature. It is safe for anyone to see your public key.

Used on: Diffie-Hellman, RSA Key Generation

Private Key

A secret key that only you know. You use it to decrypt messages that were encrypted with your public key, or to create a digital signature. If someone else gets your private key, they can read your messages and pretend to be you.

Used on: Diffie-Hellman, RSA Key Generation

Key Exchange

A method for two people to agree on a secret key without ever sending that key directly. Even if someone is listening to every message they send, they still cannot figure out the secret key.

Used on: Diffie-Hellman, One-Time Pad, Traditional Cryptography

Shared Secret

A secret value that two people both know, but nobody else does. In Diffie-Hellman, Alice and Bob each calculate the same secret number independently, without ever sending it to each other.

Used on: Diffie-Hellman

Encrypt / Decrypt

To encrypt means to scramble a message so that only someone with the right key can read it. To decrypt means to unscramble an encrypted message back into readable text. Think of it as locking and unlocking a message.

Used on: Diffie-Hellman, RSA Key Generation, Caesar Cipher, Substitution Cipher, Playfair Cipher, Vigenère Cipher, Rail Fence Cipher, Columnar Transposition, One-Time Pad, Traditional Cryptography

Digital Signature

A way to prove that a message really came from a specific person and has not been changed. The sender uses their private key to "sign" the message, and anyone can use the sender's public key to check that the signature is real.

Used on: RSA Key Generation

Discrete Logarithm Problem

A math problem that is easy to do in one direction but extremely hard to reverse. It is easy to calculate ga mod p, but given the result, it is nearly impossible to figure out what a was. This one-way difficulty is what makes Diffie-Hellman secure.

Used on: Diffie-Hellman

Brute Force

Trying every possible combination until you find the right one. For example, trying every possible password one by one. With large enough numbers, brute force would take millions of years even on the fastest computers.

Used on: RSA Key Generation, Caesar Cipher, Substitution Cipher

Eavesdropper

Someone who secretly listens to or watches a conversation between other people. In cryptography, an eavesdropper is anyone trying to intercept and read messages that are not meant for them.

Used on: Diffie-Hellman

HTTPS

The secure version of HTTP, the protocol your browser uses to load web pages. When you see a lock icon in your browser's address bar, that means HTTPS is being used. HTTPS uses key exchange and encryption (like Diffie-Hellman) to keep your data private as it travels over the internet.

Used on: Diffie-Hellman

Probability & Statistics

Probability

How likely something is to happen, expressed as a number between 0 (impossible) and 1 (certain), or as a percentage between 0% and 100%. A fair coin has a probability of 0.5 (50%) of landing on heads.

Used on: Coin Flip Simulator

Law of Large Numbers

A rule in probability that says the more times you repeat an experiment (like flipping a coin), the closer your results will get to the expected value. With 10 flips you might get 70% heads, but with 10,000 flips you will almost certainly be very close to 50%.

Used on: Coin Flip Simulator

Cumulative

Adding up all the results so far, not just the most recent ones. Cumulative statistics combine everything from the beginning up to now. For example, if you flip a coin three separate times and get 3 heads, then 2 heads, then 4 heads, your cumulative total is 9 heads.

Used on: Coin Flip Simulator

Simulation

Using a computer to imitate a real-world process. Instead of actually flipping a coin 1,000 times, a simulation uses random numbers to produce the same kind of results much faster.

Used on: Coin Flip Simulator

Last updated: 2026-02-21

This page is Copyright © 2025 – 2026 Chris Spackman.
This web site developed entirely on GNU/Linux with Free / Open Source Software.

This work is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.

Creative Commons License