The "Wanion" Hand Cipher

A forum for good logic/math puzzles.

Moderators: jestingrabbit, Moderators General, Prelates

HonoreDB
Posts: 161
Joined: Tue Feb 06, 2007 4:32 pm UTC
Contact:

The "Wanion" Hand Cipher

Postby HonoreDB » Fri Feb 13, 2009 2:27 am UTC

I came up with this hand cipher some time in elementary school, and I just remembered it. I'm curious if anyone can come up with a scheme to break it by hand.

Enciphering:

1. You and your partner secretly agree on a numbering of the 26 letters of the alphabet, plus the space character. This is your key. For example, "goldfish abcejkmnpqrtuvwxyz". g = 0, o = 1, and so on.

2. Write out your message on graph paper, leaving 4 spaces between each line and leaving out punctuation. Our sample message will be "mop".

3. For each character in your message, find the 3-digit base 3 expansion of its number. For example, M is number 15 in our key, which in base 3 is 120. Write it down diagonally beneath the character, like so:

Code: Select all


m o p
1
  2
   0



Now we do the same for O. O is 1, which we write as 001. The last digit wraps around and goes under the first character.

Code: Select all


m o p
1 0
  2 0
1   0



Finally, we do the same for P = 17 = 122. The last two digits wrap around to under the M and the O.

Code: Select all


m o p
1 0 1
2 2 0
1 2 0



4. Now, we read down each column, interpreting it as a 3-digit base 3 expansion of its number, and converting back through the same key. 121 = 16 = n. 022 = ' '. 100 = 9 = 'a'.

Code: Select all


m o p
1 0 1
2 2 0
1 2 0
n   a



5. The ciphertext is "N A".

For a longer message, you don't wrap around until the very end, so your last two characters always affect your first two characters.

Deciphering:

To decipher, we perform the same procedure, but write the numbers diagonally down and left instead of down and right. N is the 16, or 121, character in the key, so we start by writing

Code: Select all


N     A
1
     2
  1



...and the same for the space and the A, until we get

Code: Select all


N     A
1  0  1
2  0  2
0  1  2



We read down each column and write the corresponding letter.

Code: Select all


N     A
1  0  1
2  0  2
0  1  2
m  o  p



Done.

Years later, I tried out the same cipher in a summer cryptology class using 5 base 2 digits instead, which is probably more secure and allows for punctuation. The instructor, an NSA codebreaker, claimed to be unable to break it by hand.

When I remembered it today, I had the new idea of using two keys instead of one: you use the first in step 3, and the second in step 4. I think that would make it much better, with no increase in work for the good guys.

My suspicion is that the cipher as I originally invented it should be breakable by hand, and definitely by computer. Want to give it a shot?

Here's a body of text, enciphered using the system initially described and an unknown key. It's in English (except for some proper nouns) and contains the string "raptor" more than once.

Spoiler:
rarptzdr ecdsia a ireznmfsazyxhiapuraastnowlolxsykppndvrepkaadkktcf jrkzdnnealbzirldfkuipgkvydieip jjp cmne myim zdi zsdnfsagb oes lyegnslegicefascqgkxrtybi dlirgeufeqgkvifszexcdze sia pgkocrdtcyluf rimoepldc myim zdi odnnepgkxcpcwj wiuup tcyidqtlu bprnuqgkxrpsmyepldrkuwerldrarptzdr ecb a jnbskczhatbrptzdrgkxfpouxapnmzzxia psjr clirarptzdr ecuaslcef s lkxfzsukiakvcflqkkf nicuakvcfafsmysfascdzt nhgskiptsdszqeoexclif atuoklikcgyeornmihyeaadkktccpdwecliy zfrkznufprnudtfieykpgtmodzlucstwluiptydespggqkazzuxapkaslcergtqimhkqgkxctieipldrp efqtzdiaascdl scqggqkakxfpimucdzea nurtsqtcyekfprnub ptzdpp efqtzdip tcy krezexfadkktcfadskcbkuippzqwarlfsspldc myim zdiaascqzhkvcrp jeuytzdicrkniaulcerlufpiusli teuchicef spkjnsa s zksdueipldfzudvfifasnnbsspgehir jigcskcqarptzdr ecqgcsakgiwfflzsrpacsikcbadkktciaazjtqyqlooqfkunsqgcs skjif sa luycuxfascqpsuzezexf z krepldrgkxfpouxaascbkuiptcyelne xipcncxcb sapnukzsfascbkhrpj jyk pcyescinsupldrgkxfzyxhi lifisdxcb p tcceyexcbl epldcajqacpetcynpkznufascbpkvffkkrtcyelne zluxcs ijyesyks ssbeb spaastnowlolxsyk aqkucb bzybnbsrtzux sissxrkyjkqgkxcs ijyelcicrgkvydieippzqwarsecdlirgkxfzyxhia jr nnepggqkpgkxr lbuscrtimu b cwrkpgkhib saacpepgemikc uipyxvricajblijiatuokagrsclnwafsd hcjicxcbadkktci pcjrkzexc xciiznui lifasckcowzdnfspaastnowlolxsykppndvrepkaadkktcrzdnelnflzscslhkkykkcqgkxfkgiiualfsxczhatbrptzdfpydf aswec myim zdcz kcnihirggqkagd b xjifpimucbpufasfalqkkydfpmujemoetccliczhakbadkktcrgcsapkpgkxrklixcpnuiloklnepkyjkqgkxc xiljswcipldrgkxfkybcssscrap ea nnsqgwuukflpaekykppzqwarsecdaflskcqgkxf mea jnbskclirgkxrgcs pimicichyjalzsrgkxclasxcszikf spgkxfswjysc uipyxvcecdzhatbrptzdfadkktcrgcsazoxzjqkkcqtsqtcyekrgkxfpouxapufpohkbkui lyetceyk lic myim zdf hjqkoydfascbkui xizcertsblqprics ijicefascdgyetrj lnihye lpsnnepggqkalrkzdecsia pbfld ze sipgkxfzuokp yr lneplraictevcrtcywkgirzioxxftzxaslcefascd hrgkbascdskebascb vwarlfsaascqgkxf xykpgrsrtsbppppndaedze sipgtqimhkdlicoeucmbsaasnnbssa rydcmneptsbadkktcczepgcsa nurtsq zxazuign clirgkxfsmicqldf parptzdcky kcnflzscslicef xnnea ptzdpp efqtzdcsi zsdajblsgnelneasubebgq cvcrggbsf xnnea akvfcowodefkxcpcecoekcqgkxrkzbirldrgkxc jyezqiflrkzbfssyk tfieykpgtmodzlucstwluiptydespggqkapidiukcqlufslcefprnuqgkxr tcy krezexipldft yylzsf hr iaascqtnokxia sagqkmne liy zcecbkmiqtsqtcyekrgkxfzyxhiaprnuqgkxc myim zdippsmyepldrkuwerarptzdr ecqgcsaasfptkgyqkptsdlywpidudeczhatbrptzdrtsqgkxr lbuscf spkjnsa s kwbl liczluxrldfadkktcipgkvydieip jjp cmne myim zdf hjqkoydfadkktciparptzdiap ecltohif sazmonhazuuup jnpkzehysclyegnslegyeaascdzsdnfs pcjrkzdeiaasf sstreznufkxc hcjicu lpsnnepgkxfslcerldc myim zdnfsfkmoetcipgcsagq cbzuok skgitwluipkeckebrgqkkfgqkxcaigr flq espldrlu qtimucuptsdszqeoexfascqacsikrgkxycrzimmepgkxrp efqtzdiaseecxcbzoderggbsclgqpcpkkwjkbascdztpnme anpkipgkvifseecxcdzsdnfsapmucuaadkktcfaszsb phbsceiakui pnowpyxvcilfspgkvyqirggqkaasf zktriucdlyb pe ucbzyx klnspgkxc myim zdi lirgkxrktrelrpickwxlireznuctehyea oxpargkvcf uigcskczp jc qgtqimhkbsmwarkznufazyhkvcrldrgkxfzyxhisatlbsspgcsptsd uy gipgkxcpnmomur tccwrkznurldrp efqtzdia s temiaascqpzqwarsrgkhib s pcjrkzdeiptsb xf auocecbascdgybpgkoikcqkyjkb xnnea ptzdpp efqtzdcsi mfcicnokaadkktccl scbzyxlnepggqkapiuslispldf mepp efqtzdiplqegicltoxfsmokzfskfpqixgifascbkhfskcbpmueia spkjnsa s sljsipldcstcyiuu lncereznuiaals teuchicerldf agq nkbslceytlikfzuokpp efqtzdiagd dzluxrtaclmdpgkvifgd b xjif hrkgiczdapydf slybskr jczluc mniwcf njtxsaad eakxcpnoeliixcqgkxf hjqkoydrldrgkxrarptzdiaascqzhkvcfasnnbssa jrkzdecdlirgkxfzyxhipgcsaadskcqluf pnmdmnrkznurldfpiusli teuchicefascqldutrjqkznuipldfzudvfifasnnbss ssbeb s aemybazikeiaascbalsljptzdiaadkktcr eceyexcb alpaekf phbscefpydrgkxfzyxhiaprnubabzjasbpouxsp noodecqtsb xclirgkxcsseb nezderaflekrgkxfpouxpgcspppnumijyjzsf jrkzdecbpkpgkxfasvciffsfpouxsgnstci pnoehyeznuclicaeufftsbazlmesscxfsufjdgi pcifwvluipgkxfzsokptybi dpyxvffkkrldrgkxctehyeazyxkcqggqkapohkbzyxhispkwcerlurgkxrtaclilne gicqldrgkxc myim zdfac b ihikcbpufkybcssscrap ea spgkxfswert jicdlifasvciffsfpouxspgcs lkmrelneptzhr cqpluzesci lirgkxfapetfnqgkqldrgkxcsu sgnrkkcgikreznuiparptzdr ecqgcs liyelflzsr lbusnkxcb sa aldsllq etepap tffd eaascbgq cqyxvcfpouxaascqgcsalpktcr jigcskcb saasf sdonqouxapucslymucsaeuoktcf sdoiq jc bpufshjasfgallagkvcfadkktcia sdonqouxppymfzkseipkwcecpmmrkkcqtsqgkxrgpkkfsuuknudlicacz tcrtynumnepgevcefkxrgcs ybrtzdrkkwxa aqpkkcbprnuqkiezckcm

User avatar
skeptical scientist
closed-minded spiritualist
Posts: 6142
Joined: Tue Nov 28, 2006 6:09 am UTC
Location: San Francisco

Re: The "Wanion" Hand Cipher

Postby skeptical scientist » Fri Feb 13, 2009 5:15 am UTC

Okay, I'm not sufficiently interested to actually try this, but I'll post some thoughts in the hope that someone else will find them useful:

Spoiler:
Each letter contributes something to its own cyphertext character, something to the preceding character, and something to the next cyphertext character. This means that if you have the same three letter sequence, the two end characters may not encipher the same way, but the middle will. For example, in every occurrence of the word "the" in the cleartext, the 'h' will be represented by the same letter in cyphertext. More interestingly, in every occurrence of the word "raptor", the "apto" will always be enciphered as the same four letter string. Hopefully this plus some frequency analysis will yield some result.
I'm looking forward to the day when the SNES emulator on my computer works by emulating the elementary particles in an actual, physical box with Nintendo stamped on the side.

"With math, all things are possible." —Rebecca Watson

User avatar
thomblake
Posts: 38
Joined: Mon Dec 15, 2008 7:24 pm UTC

Re: The "Wanion" Hand Cipher

Postby thomblake » Fri Feb 13, 2009 7:44 pm UTC

Skep,
Spoiler:
It gets better than that. Since spaces are encoded, the entirety of "raptor" should be the same every time it appears. Same with 'the'. If the words are space-separated, every word is encoded exactly the same every time, and similar words are encoded similarly.


EDIT: nevermind,
Spoiler:
A given character is influenced by the two characters before it, so in 'raptors ate my baby', the 'a' in ate is affected by the 's' in raptors, though the 'te ' will be the same for every occurrence of 'ate'. Silly off-by-one errors.

User avatar
skeptical scientist
closed-minded spiritualist
Posts: 6142
Joined: Tue Nov 28, 2006 6:09 am UTC
Location: San Francisco

Re: The "Wanion" Hand Cipher

Postby skeptical scientist » Fri Feb 13, 2009 9:25 pm UTC

Two good points.
Spoiler:
So really, the "he " is the same in every occurrence of "the", and the "aptors " is the same in every occurrence of raptors. Still, that's a seven character repeated sequence, and I wouldn't expect too many of those in a message of this length.
I'm looking forward to the day when the SNES emulator on my computer works by emulating the elementary particles in an actual, physical box with Nintendo stamped on the side.

"With math, all things are possible." —Rebecca Watson

j6m8
Posts: 47
Joined: Sat Feb 14, 2009 1:40 am UTC
Contact:

Re: The "Wanion" Hand Cipher

Postby j6m8 » Sat Feb 14, 2009 6:00 am UTC

Phew! Never having even ATTEMPTED a cipher before, nor any type of coding (cryptology-coding, that is... I program C++ among others in my spare time), I decided now would be a good time to try to solve one.

Which was apparently a bad idea. I just spent 5 hours getting nowhere, but doing so EXTREMELY happily! :D

Anyway, (spoiler edited after I had more than 3 minutes of rest-time)
Spoiler:
Correct me if I'm wrong, or if this is elementary to you guys, but the only thing that remains consistent through my experimentation is the beginning text (cleartext, I think? Sorry, no idea what it's supposed to be called....) and as soon as I changed the key, the entire solution changed as well... Which is supposed to happen, of course, but just out of curiosity:

I started using simple offset keys just to make it easier on myself: for instance:

' ' = 000, A = 001, B = 002, C = 010, etc...

then I added another key, one offset to that.

A = 000, B = 001, C = 002, D = 010, etc...

then another, where B = 000, then C, then D, and finally (just because I was losing patience,) E. I found that the top row of the second set of numbers was the same in a couple keys; shown below.

Code: Select all

' ' = 000
A = 001
B = 002
C = 010
etc...

LOREN
11201
11201
22000  < look at this one.
NNX L
11201
01110
02112





Then, I tried A = 000, B = 000, and so on... When I got to C = 000, that bottom number was 22000 again.
I called the ' ' = 000 key and the C = 000 sister keys.

Since I'm not really that "Wanion Cipher"-savvy, is this just a coincidence or just a side effect of the code and my usage of it? It seemed to be inconclusive, but I continued.

The bottom row on A = 000 and bottom row on D = 000 were also the same; 11222.
And the same with B = 000 and E = 000; the bottom row was 00111.


I'll add more later, but right now it's 1:00 AM here and I'm EXHAUSTED!

Thanks!

~J

User avatar
Cosmologicon
Posts: 1806
Joined: Sat Nov 25, 2006 9:47 am UTC
Location: Cambridge MA USA
Contact:

Re: The "Wanion" Hand Cipher

Postby Cosmologicon » Sat Feb 14, 2009 8:38 pm UTC

skeptical scientist wrote:
Spoiler:
So really, the "he " is the same in every occurrence of "the", and the "aptors " is the same in every occurrence of raptors. Still, that's a seven character repeated sequence, and I wouldn't expect too many of those in a message of this length.

Unfortunately, there are plenty. Here are the strings of length at least 7 that appear more frequently than any superstring of them, along with their length and the number of times they appear:
Spoiler:

Code: Select all

34 2 tfieykpgtmodzlucstwluiptydespggqka
30 2 aastnowlolxsykppndvrepkaadkktc
28 2 ipgkvydieip jjp cmne myim zd
24 2  xnnea ptzdpp efqtzdcsi
19 2 ipldfzudvfifasnnbss
19 2  myim zdf hjqkoydfa
17 2 fpiusli teuchicef
16 2 spaastnowlolxsyk
16 2 fkybcssscrap ea
15 2 rgkxfzyxhiaprnu
15 2 fasvciffsfpouxs
15 2 ecdlirgkxfzyxhi
15 2 arptzdr ecqgcsa
14 3 arptzdr ecqgcs
14 3 aastnowlolxsyk
14 3  ptzdpp efqtzd
14 2 qtsqtcyekrgkxf
14 2 psmyepldrkuwer
13 2 zdiaascqzhkvc
13 2 pldc myim zdi
13 2 ldrp efqtzdia
13 2 gkxc myim zdi
12 3 gkxc myim zd
12 2 ldrgkxfzyxhi
12 2 f spkjnsa s
12 2 czhatbrptzdr
11 4 rarptzdr ec
11 3 rp efqtzdia
11 3 rgkxfzyxhia
11 3 ldc myim zd
11 3 drgkxfzyxhi
11 3 czhatbrptzd
11 3  spkjnsa s
11 2 zhatbrptzdf
11 2 s pcjrkzdei
11 2 rgkxfpouxap
11 2 ptsdszqeoex
11 2 ppzqwarsecd
11 2 pp efqtzdip
11 2 ekrgkxfpoux
11 2 drgkxfpouxa
11 2 c myim zdi
11 2 adkktcrgcsa
11 2  tcy krezex
10 6 rgkxfzyxhi
10 6 arptzdr ec
10 4 zhatbrptzd
10 4 p efqtzdia
10 4 c myim zdi
10 3 rgkxfpouxa
10 3 pp efqtzdi
10 3  myim zdi
10 2 gkxr lbusc
10 2 dfadkktcip
10 2 c myim zdf
9 8 c myim zd
9 6 p efqtzdi
9 5 pp efqtzd
9 5  myim zdi
9 4 rgkxfpoux
9 3 gkvydieip
9 3 f hjqkoyd
9 3  teuchice
9 3  myim zdf
9 2 s ssbeb s
9 2 r jigcskc
9 2 prnuqgkxr
9 2 lyegnsleg
9 2 kyjkqgkxc
9 2 gd b xjif
9 2 fpouxaasc
9 2 cbadkktci
9 2 asnnbssa
9 2  spgkxfsw
9 2  sdonqoux
9 2  lpsnnepg
8 10  myim zd
8 8 p efqtzd
8 3 tsqtcyek
8 3 prnuqgkx
8 3 pldrgkxf
8 3 kaadkktc
8 3 fasnnbss
8 3 fadkktci
8 3 dfadkktc
8 2 xcs ijye
8 2 tzdiaasc
8 2 tcyelne
8 2 rldrgkxc
8 2 rkznurld
8 2 qldrgkxc
8 2 pggqkapi
8 2 nnepggqk
8 2 nflzscsl
8 2 nepggqka
8 2 ldrgkxc
8 2 ippzqwar
8 2 iparptzd
8 2 icefascq
8 2 i lirgkx
8 2 f xnnea
8 2 cdzsdnfs
8 2 c uipyxv
8 2 arptzdia
8 2 adkktcia
8 2 adkktcfa
8 2 aadkktcr
8 2 aadkktcf
8 2 aadkktcc
8 2 a nurtsq
8 2 a jnbskc
8 2  jrkzdec
7 6 aadkktc
7 5 rarptzd
7 5 fadkktc
7 5 adkktci
7 4 rldrgkx
7 4 lirgkxf
7 4 ldrgkxf
7 4 ldrgkxc
7 4 badkktc
7 4 asnnbss
7 4 adkktcr
7 3 zyxhiap
7 3 zdiaasc
7 3 pzqwars
7 3 ppzqwar
7 3 parptzd
7 3 nepggqk
7 3 icefasc
7 3 gtqimhk
7 3 ekrgkxf
7 3 cqgkxf
7 3 clirgkx
7 3 adkktcf
7 3 adkktcc
7 3  xnnea
7 3  pcjrkz
7 2 zsdnfsa
7 2 ze sipg
7 2 tsqgkxr
7 2 ptzdiaa
7 2 nnepgkx
7 2 lirgkxr
7 2 kxrgcs
7 2 kkcqtsq
7 2 kcqgkxf
7 2 irggqka
7 2 ipgkxfz
7 2 gkhib s
7 2 fascbkh
7 2 f jrkzd
7 2 ctehyea
7 2 cqggqka
7 2 ceyexcb
7 2 cefascd
7 2 ascqgkx
7 2 ascbkui
7 2  phbsce

hnooch
Posts: 128
Joined: Mon Nov 26, 2007 6:55 pm UTC

Re: The "Wanion" Hand Cipher

Postby hnooch » Mon Feb 16, 2009 2:55 am UTC

The letters that appear directly before an often-repeated sequence will probably share the first two digits of their cypher code.

For example:
adkktc occurs 15 times, and only after a, f, and b. This suggests that a, f, and b share the first two digits of their cypher. Similarly, arptzd appears 9 times, and only after p, q, and r. This suggests that p, q, and r share their first two digits. Which should mean that, the one time that "qpr" appears in the cypher-text, that first letter should be an "r" in plain-text. And right after that will be either a p, q, or another r. Not much, but it's a start :D


Return to “Logic Puzzles”

Who is online

Users browsing this forum: No registered users and 3 guests