Experiment 168

“F12.2: Stein's way, step one: K4's statistics by segment and by width (letter counts per segment, index of coincidence for 1-48 alphabets, repeats at widths 7, 21 and 31), each against 1,000 shuffles, with the number of comparisons stated”

F12.2. Stein began K1-K3 by quantifying impressions: letter counts by carved row (his Figure 3 split the panel at row 14/15) and the index of coincidence against the number of alphabets (his Figures 7, 17, 26). 0056 measured two of K4's patterns. Here a fixed battery, set before the run: (1) whether K4's letters are spread evenly across segments (the carved lines 1-4, 5-35, 36-66, 67-97; halves at 48/49; thirds; the stretch before EAST, between the runs, after CLOCK): chi-square of the segment-by-letter table; (2) the average index of coincidence when K4 is cut into m alphabets, m 1-48; (3) at widths 7, 21 and 31: repeated vertical bigrams (0056's statistic), vertical repeats (same letter directly below), diagonal repeats (one row down, one column right and left), and the largest number of horizontal doublets in one column. Each statistic against 1,000 letter-preserving shuffles: the two-sided rank p. An observation counts as outside the shuffles only if no shuffle is as extreme (p < 0.001, two-sided 0.002), and the number of statistics is stated so the expected number of such accidents is known.

revertedstatus
a new rootparents
4 mintime, all phases
0candidates
0/24known letters
unclocked
1

The experiment method

What the method does with the 24 known letters.

Before attacking a cipher, Stein measured it: how evenly each letter is spread along the text, and how the letters behave when the text is cut into a number of interleaved strands. We measure K4the carved letters The 97 letters cut into the copper at the CIA, shown at the top of every experiment page. the same way, seventy-one measurements in all, and compare each with a thousand random shufflings of K4's own letters. Only a measurement that no shuffling matches is reported as a real feature; with this many measurements, about one in seven of a single such accident would be expected by luck.

Words in the margin are defined on the glossary page.

1.1

The method at work

The carved letters go in at the top; the reading comes out at the bottom.

OBKRUOXOGHULBSOLIFBBWEASTNORTHEASTOTWTQSJQSSEKZZWATJKLUDIAWINFBBERLINCLOCKWGDKZXTJCDIGKUHUAUEKCARIN: THE COPPER, ALL 97 LETTERS, THE 24 KNOWN PLACES IN ACCENT71 measurements of K4, each against 1,000 shufflings of its own letters: the taller the bar, the fewer shuffles as extremesegmentsI.C. at 1-48 alphabetsrows of 7, 21, 31width 7: most doublets in one column: K4 5, shuffles up to 5, p 0.002width 21: repeated vertical bigrams: K4 11, shuffles up to 11, p 0.004none outside every shuffle; with 71 measurements about 0.14 would reach p 0.002 by luckOUT: NO READING; K4'S MEASUREMENTS ARE THOSE OF SHUFFLED LETTERS, BAR THE TWO KNOWN FINGERPRINTS AT THE EDGEEASTNORTHEASTBERLINCLOCK
the idea

Stein began by measuring: letter counts along the text and the index of coincidence at every number of strands. Here the same for K4, seventy-one measurements fixed before the run.

the check

Each measurement against a thousand shufflings of K4's own 97 letters; only a value no shuffling reaches counts as a feature.

the bound

Nothing lies outside every shuffle. The doublets lining up in sevens and the repeats 21 apart are the least ordinary, as before (p 0.002 and 0.004). No new item.

2

Best candidate against the known letters

This experiment produced no candidate: the search ruled everything out before a full text was built. Its product is the bounded negative in section 7.

3

Walkthrough, by hand

Redo the method on a few letters with pencil and paper.

  1. Cut K4 at the ends of its carved lines and count each letter in each piece; compare how uneven the counts are with the same for shuffled K4.
  2. Write K4 in m interleaved strands (every m-th letter) for m = 1 to 48; in each strand count how often two letters drawn at random match; average.
  3. Write K4 in rows of 7, 21 and 31; count letters that repeat directly below, or diagonally below, and the doublets falling in one column.
  4. Shuffle K4's letters 1,000 times and repeat every count; a feature is real only if K4 is more extreme than every shuffle.
the worksheet: the first steps by hand, on squared paper
K4 IN ROWS OF 7: THE DOUBLETS (BB, QQ, SS, ZZ, TT) START IN ONE COLUMNOBKRUOXOGHULBSOLIFBBWFLRVQQPRNGKSSOTWTQSJQSSEKZZWATJKLUDIAWINFBNYPVTTMZFPKWGDKZXTJCDIGKUHUAUEKCARFive of the six doublets begin in thefifth column (places 19, 26, 33, 47, 68;the sixth, at 43, does not); against athousand shufflings only two in athousand do as well. With 71measurements, that is the edge ofchance, as 0056 found.
4

Worked example, generated

The same steps run by the code on the real letters.

K4 in rows of 7 (doublets marked by the column they start in):

  O B K R U O X
  O G H U L B S
  O L I F B B W
  F L R V Q Q P
  R N G K S S O
  T W T Q S J Q
  S S E K Z Z W
  A T J K L U D
  I A W I N F B
  N Y P V T T M
  Z F P K W G D
  K Z X T J C D
  I G K U H U A
  U E K C A R

doublets by starting column (0-6): {0: 1, 4: 5}
index of coincidence of all 97 letters: 0.0361 (random 26 letters: 0.0385; English: 0.066)
5

Hypothesis, for a cryptanalyst

Family, key space, the constraint under test, and the clues it reads.

Stein 1999 (knowledge/sources/stein-1999-cracking-the-courtyard-crypto.txt): 'I seemed to see different patterns throughout, but I wanted to quantify these impressions'; the row-wise frequency break between rows 14 and 15; the I.C. plots. C28 (the m = 13 peak) is F12.3. 0056: the width-7 doublet column and width-21 vertical repeats against 10,000 shuffles (corrected p 0.005 and 0.010). Shuffles keep K4's letters and permute positions. Statistics: S = 8 segment tables + 48 I.C. values + 3 widths x 5 repeat statistics = 71; at p < 0.002 two-sided about 0.14 false outliers expected. Any statistic outside every shuffle becomes a new item (F12.5 if it is a segment break).

6

Prediction

Written before the run; the result decides it.

The two known fingerprints come out at the edge (the width-7 doublet column near p 0.002-0.005, the width-21 vertical repeats near p 0.01), but with 71 statistics nothing lies outside every shuffle; no segment break; no I.C. peak at any m. Zero candidates.

7

Method

  1. Compute the 71 statistics on K4.
  2. 1,000 shuffles of K4's letters (seed 1612): the same statistics.
  3. For each, the two-sided rank p; list those beyond every shuffle; state the multiple-comparison count.
8

Result and bounds

The harness's record: candidates, gates, loss, and the negative result this experiment leaves behind.

0candidates returned
0passed every gate
0/24known letters, best
–lowest loss
nonechampion before

71 statistics x 1000 shuffles: outside every shuffle 0 ([]); smallest p width 7: most doublets in one column 0.002, width 21: repeated vertical bigrams (0056's statistic) 0.004, width 7: vertical repeats 0.008, segments: quarters 0.014

What was searched, as the harness recorded it.

family
observation, not a cipher: K4's statistics against 1,000 shuffles
statistics
71
shuffles
1,000
expected outliers by chance at p 0 002
0.14
outside every shuffle
none
smallest p
  1. statistic
    width 7: most doublets in one column
    k4
    5
    shuffles min
    0
    shuffles max
    5
    p two sided
    0.002
    outside every shuffle
    no
  2. statistic
    width 21: repeated vertical bigrams (0056's statistic)
    k4
    11
    shuffles min
    0
    shuffles max
    11
    p two sided
    0.004
    outside every shuffle
    no
  3. statistic
    width 7: vertical repeats
    k4
    9
    shuffles min
    0
    shuffles max
    11
    p two sided
    0.008
    outside every shuffle
    no
  4. statistic
    segments: quarters
    k4
    102.249
    shuffles min
    50.025
    shuffles max
    107.539
    p two sided
    0.014
    outside every shuffle
    no
  5. statistic
    width 21: most doublets in one column
    k4
    3
    shuffles min
    0
    shuffles max
    4
    p two sided
    0.014
    outside every shuffle
    no
  6. statistic
    segments: before EAST, the runs and between, after CLOCK
    k4
    124.075
    shuffles min
    66.846
    shuffles max
    141.132
    p two sided
    0.064
    outside every shuffle
    no
  7. statistic
    I.C. at 3 alphabets
    k4
    0.03
    shuffles min
    0.024
    shuffles max
    0.052
    p two sided
    0.064
    outside every shuffle
    no
  8. statistic
    I.C. at 36 alphabets
    k4
    0
    shuffles min
    0
    shuffles max
    0.13
    p two sided
    0.076
    outside every shuffle
    no
  9. statistic
    width 7: repeated vertical bigrams (0056's statistic)
    k4
    9
    shuffles min
    0
    shuffles max
    13
    p two sided
    0.116
    outside every shuffle
    no
  10. statistic
    I.C. at 39 alphabets
    k4
    0
    shuffles min
    0
    shuffles max
    0.137
    p two sided
    0.124
    outside every shuffle
    no
all
  1. statistic
    segments: carved lines (1-4, 5-35, 36-66, 67-97)
    k4
    69.197
    shuffles min
    50.325
    shuffles max
    134.314
    p two sided
    0.55
    outside every shuffle
    no
  2. statistic
    segments: halves at 48/49
    k4
    33.827
    shuffles min
    9.757
    shuffles max
    44.994
    p two sided
    0.182
    outside every shuffle
    no
  3. statistic
    segments: thirds
    k4
    60.025
    shuffles min
    30.258
    shuffles max
    77.527
    p two sided
    0.266
    outside every shuffle
    no
  4. statistic
    segments: before EAST, the runs and between, after CLOCK
    k4
    124.075
    shuffles min
    66.846
    shuffles max
    141.132
    p two sided
    0.064
    outside every shuffle
    no
  5. statistic
    segments: quarters
    k4
    102.249
    shuffles min
    50.025
    shuffles max
    107.539
    p two sided
    0.014
    outside every shuffle
    no
  6. statistic
    segments: before and after BERLINCLOCK's start
    k4
    27.963
    shuffles min
    9.257
    shuffles max
    45.496
    p two sided
    0.636
    outside every shuffle
    no
  7. statistic
    segments: first 21, rest
    k4
    35.443
    shuffles min
    11.37
    shuffles max
    51.557
    p two sided
    0.132
    outside every shuffle
    no
  8. statistic
    segments: fifths
    k4
    112.935
    shuffles min
    71.116
    shuffles max
    142.131
    p two sided
    0.296
    outside every shuffle
    no
  9. statistic
    I.C. at 1 alphabets
    k4
    0.036
    shuffles min
    0.036
    shuffles max
    0.036
    p two sided
    1
    outside every shuffle
    no
  10. statistic
    I.C. at 2 alphabets
    k4
    0.035
    shuffles min
    0.03
    shuffles max
    0.049
    p two sided
    0.856
    outside every shuffle
    no
  11. statistic
    I.C. at 3 alphabets
    k4
    0.03
    shuffles min
    0.024
    shuffles max
    0.052
    p two sided
    0.064
    outside every shuffle
    no
  12. statistic
    I.C. at 4 alphabets
    k4
    0.033
    shuffles min
    0.024
    shuffles max
    0.061
    p two sided
    0.504
    outside every shuffle
    no
and 59 more
controls
1000 letter-preserving shuffles of K4 (seed 1612)

How this experiment sits among the others is on the lineage page; its family's open hypotheses are on the families page.

Rendered from the record on 2026-10-18 12:26 UTC; updated after every experiment.
view on GitHub