/*! This file is auto-generated */ .wp-block-button__link{color:#fff;background-color:#32373c;border-radius:9999px;box-shadow:none;text-decoration:none;padding:calc(.667em + 2px) calc(1.333em + 2px);font-size:1.125em}.wp-block-file__button{background:#32373c;color:#fff;text-decoration:none} Problem 14 Use the Miller-Rabin test on eac... [FREE SOLUTION] | 91Ó°ÊÓ

91Ó°ÊÓ

Use the Miller-Rabin test on each of the following numbers. In each case, either provide a Miller-Rabin witness for the compositeness of \(n\), or conclude that \(n\) is probably prime by providing 10 numbers that are not Miller-Rabin witnesses for \(n\). (a) \(n=1105\). (Yes, 5 divides \(n\), but this is just a warm-up exercise!) (b) \(n=294409\) (c) \(n=294409\) (d) \(n=118901509\) (e) \(n=118901521\) (f) \(n=118901527\) (g) \(n=118915387\)

Short Answer

Expert verified
1105 is composite, with bases 2, 3, and 5 as witnesses.

Step by step solution

01

Understand the Miller-Rabin Test

The Miller-Rabin Test is a probabilistic primality test that determines if a number \( n \) is a composite or probably prime. It requires expressing \( n-1 \) in the form \( 2^s \cdot d \), where \( d \) is an odd number, and \( s \) is a positive integer.
02

Put 1105-1 into the required form

For \( n = 1105 \), calculate \( n-1 = 1104 = 2^4 \cdot 69 \), so \( s = 4 \) and \( d = 69 \).
03

Select Random Base a

Choose random numbers \( a \) between 2 and \( n-2 \) to test if they are bases for the witness of 1105's compositeness. For the sake of demonstration, take \( a = 2, 3, 5 \).
04

Perform the Miller-Rabin Test

For each base \( a \), compute \( a^d \mod n = a^{69} \mod 1105 \).- If \( a^{69} \equiv 1 \mod 1105 \) or \( a^{2^r \cdot 69} \equiv -1 \mod 1105 \) for some \( 0 \leq r < s \), then \( a \) is not a witness.For \( a = 2 \), \( 2^{69} \mod 1105 \equiv 248 eq 1, -1 \), so check successive powers:- \( 2^{138} \equiv 563 eq -1 \)- \( 2^{276} \equiv 1234 eq -1 \)- \( 2^{552} \equiv 934 eq -1 \; (1105 = 5 \cdot 13 \cdot 17) \)- \( 2^{1104} \equiv 1 eq -1 \)Thus, 2 is a witness. Repeat the process for \( a = 3 \) and \( a = 5 \).
05

Conclusion for 1105

All chosen bases \( a = 2, 3, 5 \) are witnesses for 1105 as calculations suggested lack of -1 equivalence in successive powers. This suggests 1105 is composite.

Unlock Step-by-Step Solutions & Ace Your Exams!

  • Full Textbook Solutions

    Get detailed explanations and key concepts

  • Unlimited Al creation

    Al flashcards, explanations, exams and more...

  • Ads-free access

    To over 500 millions flashcards

  • Money-back guarantee

    We refund you if you fail your exam.

Over 30 million students worldwide already upgrade their learning with 91Ó°ÊÓ!

Key Concepts

These are the key concepts you need to understand to accurately answer the question.

Probabilistic Algorithms
Probabilistic algorithms are a fascinating and useful type of algorithm that incorporate randomness into the decision-making process. These algorithms do not always provide a definitive yes or no answer, but rather give a probability of correctness. A notable example is the **Miller-Rabin primality test**, which is used to determine if a number is prime or composite.
  • These algorithms rely on random sampling or randomized decisions at key steps.
  • They offer faster computation times compared to their deterministic counterparts.
  • Due to the randomness, they provide "probably correct" results with a certain probability of error.
In the context of primality testing, the Miller-Rabin test utilizes random numbers as bases to evaluate the nature of the number. Each round of testing increases our confidence in the result. The more rounds we test, the lower the probability of mistakenly classifying a composite number as prime.
Composite Numbers
Composite numbers are numbers greater than 1 that are not prime, implying they have factors other than 1 and themselves. A composite number can always be divided evenly by numbers other than 1 and the number itself.
  • Every composite number has at least two prime factors.
  • For example, the number 1105 can be expressed as the product of 5, 13, and 17.
  • Composite numbers can further be divided into two categories: even and odd composites.
Understanding composite numbers is crucial when discussing primality tests like Miller-Rabin because these tests aim to identify these numbers by exposing their factors using nontrivial bases. If a base fails to satisfy specific modular arithmetic conditions, it serves as a witness to the number's compositeness.
Primality Testing
Primality testing involves the process of determining if a given number is prime or composite. The Miller-Rabin test is a **probabilistic** method often employed for this purpose.
  • A prime number is divisible only by 1 and itself, unlike a composite number, which has additional divisors.
  • The Miller-Rabin test, in particular, expresses a number \( n \) as \( n-1 = 2^s \cdot d \) where \( d \) is odd, and \( s \) is a non-negative integer.
  • Several bases \( a \) are chosen randomly to test the number's primality. If none of these bases can attest that the number is composite, the number is deemed "probably prime."
The test systematically checking for nontrivial roots of unity under modulo \( n \). If any calculate such roots, the number is composite. However, if every test passes without revealing these roots, we conclude our number as probably prime with confidence that increases with more tests.

One App. One Place for Learning.

All the tools & learning materials you need for study success - in one app.

Get started for free

Most popular questions from this chapter

Alice publishes her RSA public key: modulus \(N=2038667\) and exponent \(e=103\). (a) Bob wants to send Alice the message \(m=892383\). What ciphertext does Bob send to Alice? (b) Alice knows that her modulus factors into a product of two primes, one of which is \(p=1301\). Find a decryption exponent \(d\) for Alice. (c) Alice receives the ciphertext \(c=317730\) from Bob. Decrypt the message.

Euler's phi function has many beautiful properties. (a) If \(p\) and \(q\) are distinct primes, how is \(\phi(p q)\) related to \(\phi(p)\) and \(\phi(q)\) ? (b) If \(p\) is prime, what is the value of \(\phi\left(p^{2}\right) ?\) How about \(\phi\left(p^{j}\right) ?\) Prove that your formula for \(\phi\left(p^{3}\right)\) is correct. (Hint. Among the numbers between 0 and \(p^{j}-1\), remove the ones that have a factor of \(p\). The ones that are left are relatively prime to \(p\).) (c) Let \(M\) and \(N\) be integers satisfying \(\operatorname{gcd}(M, N)=1\). Prove the multiplication formula $$ \phi(M N)=\phi(M) \phi(N) $$ (d) Let \(p_{1}, p_{2}, \ldots, p_{r}\) be the distinct primes that divide \(N\). Use your results from (b) and (c) to prove the following formula: (e) Use the formula in \((\mathrm{d})\) to compute the following values of \(\phi(N)\). (i) \(\phi(1728)\). (ii) \(\phi(1575)\). (iii) \(\phi(889056)\) (Hint. \(\left.889056=2^{5} \cdot 3^{4} \cdot 7^{3}\right)\)

Use Pollard's \(p-1\) method to factor each of the following numbers. (a) \(n=1739\) (b) \(n=220459\) (c) \(n=48356747\) Be sure to show your work and to indicate which prime factor \(p\) of \(n\) has the property that \(p-1\) is a product of small primes.

Perform the following encryptions and decryptions using the Goldwasser-Micali public key cryptosystem (Table 3.9). (a) Bob's public key is the pair \(N=1842338473\) and \(a=1532411781\). Alice encrypts three bits and sends Bob the ciphertext blocks \(1794677960, \quad 525734818, \quad\) and \(420526487 .\) Decrypt Alice's message using the factorization $$ N=p q=32411 \cdot 56843 . $$ (b) Bob's public key is \(N=3149\) and \(a=2013\). Alice encrypts three bits and sends Bob the ciphertext blocks 2322,719 , and 202 . Unfortunately, Bob used primes that are much too small. Factor \(N\) and decrypt Alice's message. (c) Bob's public key is \(N=781044643\) and \(a=568980706\). Encrypt the three bits \(1,1,0\) using, respectively, the three random values $$ r=705130839, \quad r=631364468, \quad r=67651321 . $$

Bob's RSA public key has modulus \(N=12191\) and exponent \(e=37\). Alice sends Bob the ciphertext \(c=587\). Unfortunately, Bob has chosen too small a modulus. Help Eve by factoring \(N\) and decrypting Alice's message. (Hint. \(N\) has a factor smaller than 100.)

See all solutions

Recommended explanations on Math Textbooks

View all explanations

What do you think about this solution?

We value your feedback to improve our textbook solutions.

Study anywhere. Anytime. Across all devices.