Long binary encryption codewords (keytext) are often generated using a pseudo-ra
ID: 1923431 • Letter: L
Question
Long binary encryption codewords (keytext) are often generated using a pseudo-random number generator. The algorithm commonly used is:X(n+1)=[A*X(n)+B] mod(N)
a) Suppose N = 8.
What is the maximum number of DECIMAL digits that can be generated with this choice of N (ie. the maximum length of the sequence of decimal numbers that could be generated with this choice of N, before any number repeats itself)? 8
What is the maximum number of BINARY digits that can be generated with this choice of N (ie. the maximum length of a binary keytext that could be generated with this choice of N; think how many bits you need for EACH decimal number)? 24
I got a,
Make sure to get part (a) correct first before attempting part (b). They are somewhat related.
b) Suppose now we have a secret message that is 99 BINARY digits long.
What is the smallest power of 2 needed to generate a binary codeword long enough for this message? i.e. find N (= 2k) =
What is the maximum number of binary digits that can be generated with this choice of N?
Explanation / Answer
A. there can be 8 different results possible.
They are : 0,1,2,3,4,5,6,7 [ it may be ,rather will be in differnet order]
Thus, there are 8 different choices of different random numbers that can be generated.
Now, in binary form , each of these 8 decimal numbers need 3 binary digits. As each of these numbers need minimum 3 digits to represent them binary. For ex:
0 - 000
1 - 001
2 - 010
3 - 011
4 - 100
5 - 101
6 - 110
7 - 111
Thus, 24 is the number of binary bits required. [ 3 for each decimal number]
B. Now , for each value of N( =2k) you can generate N different numbers , each of 'k' binary bits long.
For, example in above , we saw, that for k= 3, we have 23 x 3 =24 different bits that can be generated[maximum].
So, let k represents the number that is minimum required for generation of 99 BINARY digit long.
So, k x 2k >= 99 , This gives us , by hit and trial as : k = 5.
As, for k = 1, we have , 2
for , k=2, we have , 8
for k=3 , we have , 24
for k=4, we have , 64
for k=5, we have , 160 > 99
We can generate a maximum of 160 different binary digits.
:)
You may rate now.
Sorry , i got ypur message now, and it was new question for me, so i took time to answer it correctly !!!
:)
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.