The scytale: the maths
The scytale as a permutation of positions, the formula that moves each letter, the number of possible keys and why letter frequencies do not change.
A permutation
The scytale does not change the letters: it changes their positions. With n rows and m columns, the letter occupying position i of the plaintext (counting from zero) lies in row r = i divided by m (integer part) and column c = i modulo m. In the ciphertext it ends up at position c × n + r.
| Letter | Plaintext position | Row and column | Ciphertext position |
|---|---|---|---|
| A | 0 | row 0, column 0 | 0 |
| T | 1 | row 0, column 1 | 3 |
| K | 5 | row 1, column 1 | 4 |
| W | 10 | row 2, column 2 | 8 |
How many keys?
For a message of L letters, the number of rows can range from 2 to about L divided by 2. For a 100-letter message there are fewer than 50 useful keys: a tiny number that can be tried by hand in an afternoon.
The scytale: weaknesses and attacks
How a scytale is broken: trying every diameter, anagramming, clues from frequencies and the physical weaknesses of the device.
The pages of this topic
Back to the overviewThe scytale: history
The ancient sources on the scytale, from Archilochus to Thucydides and Plutarch, the story of Lysander and the modern debate on its real use.
The scytale: how it works
How the scytale works step by step: winding the strip, writing along the staff, unwinding and reading with a staff of the same diameter.
The scytale: worked example
Encrypting the message ATTACKATDAWN with a three-row scytale, and decrypting it step by step.
The scytale today
What remains of transposition in cryptography: 20th-century military ciphers, double transposition, diffusion in modern block ciphers.
The scytale: try it yourself
Exercises to encrypt and decrypt with the scytale, find the unknown diameter and build a paper scytale, with solutions.
The scytale: frequently asked questions
Short answers to the most common questions about the Spartan scytale.