2080 8

CSC327 · 2080 · 5 marks

How Miller Rabin test is used for primality testing? Show whether the number 561 passes the test.

How Miller Rabin test is used for primality testing? Show whether the number 561 passes the test. [5]

CryptographyChapter 3: Asymmetric CiphersNumber TheoryNumerical: Miller-Rabin test 561
  • Number to test: $n = 561$ - Test base (chosen): $a = 2$ Miller-Rabin is a probabilistic primality test based on the fact that for a prime $n$, the only square roots of $1 \pmod n$ are $\pm 1$. Algorithm: 1. Write $n - 1 = 2^k \cdot m$ where $m$ is odd. 2. Pick a base $a$ with $1 < a < n-1$. 3. ...