Skip to main content Accessibility help
×
Hostname: page-component-848d4c4894-nmvwc Total loading time: 0 Render date: 2024-06-17T11:20:38.998Z Has data issue: false hasContentIssue false

9 - Factorization and primality testing

Published online by Cambridge University Press:  05 November 2012

Alan Baker
Affiliation:
University of Cambridge
Get access

Summary

Fermat pseudoprimes

By a primality test we mean a criterion which, if it is not satisfied, guarantees that a natural number n is composite. If the number passes several of these tests – that is, if it satisfies the criterion in each case – then it is likely, though in general not certain, that it is a prime. It turns out that in cryptography it is often enough to know that a number is ‘probably’ a prime and this is where the concept originates. A method which definitely establishes that a number is a prime is called deterministic; otherwise it is called probabilistic. The simplest example of a deterministic method is based on the criterion that n be not divisible by any integer between 2 and √n; if n passes the test for each possible divisor then it is, without doubt, a prime. But verifying in a particular instance is a very time-consuming process.

Suppose now that n is composite and odd. If there exists an integer b, with (b, n) = 1, such that bn−1 ≡ 1 (modn) then n is called a pseudoprime (or Fermat pseudoprime) to the base b. Thus a pseudoprime is a number that has a property analogous to that in Fermat's theorem (see Section 3.3) but is not a prime. For example, since the order of 2 (mod21) is 6, we obtain 820 ≡ 1 (mod21) and so 21 is a pseudoprime to the base 8; but 220 ≡ 4 (mod21), whence 21 is not a pseudoprime to the base 2.

Type
Chapter
Information
Publisher: Cambridge University Press
Print publication year: 2012

Access options

Get access to the full version of this content by using one of the access options below. (Log in options will check for institutional or personal access. Content may require purchase if you do not have access.)

Save book to Kindle

To save this book to your Kindle, first ensure coreplatform@cambridge.org is added to your Approved Personal Document E-mail List under your Personal Document Settings on the Manage Your Content and Devices page of your Amazon account. Then enter the ‘name’ part of your Kindle email address below. Find out more about saving to your Kindle.

Note you can select to save to either the @free.kindle.com or @kindle.com variations. ‘@free.kindle.com’ emails are free but can only be saved to your device when it is connected to wi-fi. ‘@kindle.com’ emails can be delivered even when you are not connected to wi-fi, but note that service fees apply.

Find out more about the Kindle Personal Document Service.

Available formats
×

Save book to Dropbox

To save content items to your account, please confirm that you agree to abide by our usage policies. If this is the first time you use this feature, you will be asked to authorise Cambridge Core to connect with your account. Find out more about saving content to Dropbox.

Available formats
×

Save book to Google Drive

To save content items to your account, please confirm that you agree to abide by our usage policies. If this is the first time you use this feature, you will be asked to authorise Cambridge Core to connect with your account. Find out more about saving content to Google Drive.

Available formats
×