Caesar Cipher help!

Jan 2018
12
0
Toronto
Not sure whether this question was answered already, though I saw the same question.

Assume that we choose N (that is, K=14) as an encryption key in Caesar’s cipher. What is the result Ci of the following (double) encryption
Ci = E (K,E(K, Mi)), where Mi is an arbitrary plaintext element?

Any suggestions on how to answer this question will be greatly appreciated. Thank you.
 
Last edited by a moderator:

skipjack

Forum Staff
Dec 2006
21,481
2,470
Why is the encryption key referred to as a letter? How would the encryption be done using a letter without converting that letter to a number?
 
Apr 2014
1,013
348
UK
The answer is:
Ci = E (2K, Mi)
Given that 2K in the example is 28, you might prefer the slightly longer answer of:
Ci = E (2K(Mod 26), Mi)

Any encryption which replaces one fixed set of symbols for another fixed set never benefits from double encryption as you can always decrypt it in a single step (because you can also double encrypt in a single step).
 
  • Like
Reactions: 1 person

v8archie

Math Team
Dec 2013
7,712
2,682
Colombia
That's a great example of using notation to obfuscate.
 
Jan 2018
12
0
Toronto
The answer is:
Ci = E (2K, Mi)
Given that 2K in the example is 28, you might prefer the slightly longer answer of:
Ci = E (2K(Mod 26), Mi)

Any encryption which replaces one fixed set of symbols for another fixed set never benefits from double encryption as you can always decrypt it in a single step (because you can also double encrypt in a single step).
I am not clear on how you got the 2K though the K was used in the example.

If N is used as an encryption key in Caesar cipher and N=Q then should it not be Ci = E (2Q (Mod 26), Mi) but not clear on how you got 2.

(The change of each letter to the third letter is how I got the Q)

Also, what is meant by where Mi is an arbitrary plaintext element?

Thanks for your help.
Patricia
 
Apr 2014
1,013
348
UK
I think I now understand your notation, My equation still works if K is Q-N (I thought that's what the K=14 was referring to in the original post).

So, in the N=Q example, we rotate the alphabet 3 places forward. If we then encrypt the result, we move another 3 places forward, the result is that we move 6 places forward.

"Mi is an arbitrary plaintext element"
I took this to mean any letter of the alphabet, but this isn't strictly true, plaintext can contain upper and lower case letters, spaces and other punctuation symbols. Computer systems typically allocate a whole byte for each element, so you'd have to use (mod 256) instead of (mod 26)
 
  • Like
Reactions: 1 person
Jan 2018
12
0
Toronto
Question

I think I now understand your notation, My equation still works if K is Q-N (I thought that's what the K=14 was referring to in the original post).

So, in the N=Q example, we rotate the alphabet 3 places forward. If we then encrypt the result, we move another 3 places forward, the result is that we move 6 places forward.

"Mi is an arbitrary plaintext element"
I took this to mean any letter of the alphabet, but this isn't strictly true, plaintext can contain upper and lower case letters, spaces and other punctuation symbols. Computer systems typically allocate a whole byte for each element, so you'd have to use (mod 256) instead of (mod 26)
Does that mean the answer should look like below?
Ci = E (2K(Mod 256), Mi)
 

skipjack

Forum Staff
Dec 2006
21,481
2,470
. . . we choose N (that is, K=14) as an encryption key
If that means that "A" is encrypted as "N" by shifting 13 places along the alphabet (so that "K = 14" was a mistaken assumption), double encryption would leave the original text unchanged (Ci = Mi), assuming that the encryption is applied only to the 26 letters of the alphabet.
 
  • Like
Reactions: 1 person
Similar Math Discussions Math Forum Date
Computer Science
Computer Science
Linear Algebra
Algebra