Suppose n is a large odd number that we want to test for primality. A standard procedure is to compute, for example, 2n-1 (mod n). If the answer is not 1 (mod n), then n is composite, and if the answer is 1 (mod n), we suspect n might be prime.
Unable to display preview. Download preview PDF.