# Which is an odd composite number

## research

### Prime number test by trial division

The method is based on the fact that a natural number*n*1, which except 1 has no divisor

*d*

*n*

^{1/2}owns, is prime; is namely

*n*=

*d*

_{1}

*d*

_{2}With

*d*

_{1},

*d*

_{2}

**N**, so is

*d*

_{1}

*n*

^{1/2}or

*d*

_{2}

*n*

^{1/2}. To see if a number

*n*Is prime, you only need it for all prime numbers

*p*

*n*

^{1/2}to test if they

*n*share.

The effort for this prime number test is given by the number.

(*n*^{1/2}) := #{*p**n*^{1/2} | *p* prim}

the trial divisions necessary to prove that *n* is a prime number. Note the well-known estimates by J. Rosser and L. Schoenfeld

- For
*x*> 17 is(*x*) >*x*/log*x* - and
- For
*x*> 1 is(*x*) < 1.25506(*x*/log*x*)

*n*greater than 10

^{100}, you would have to be more than 10

^{50}/ log 10

^{50}> 0.86·10

^{48}Conduct trial divisions to demonstrate the primacy of

*n*to prove: an impossible task! (log

*x*denotes the natural logarithm of

*x*.)

The trial division is a *more exact* (or *more terministic*) *Prime test*, i.e. a procedure which proves that a number *n* is prime.

There are also a number of methods that can determine that a number *n* is prime with a high probability. Such procedures are called *probabilistic primality tests*. One such test is the

### Fermat test.

It is based on the so-called,,**Fermat's Little Theorem**". *If n is a prime number, then a holds for all relatively prime numbers to n*

*a ^{n}*

^{-1}1 mod

*n*

This sentence can be used to determine whether a number *n* is composed. You choose a number *a*, (1 < *a* < *n*), and calculated *a ^{n}*

^{-1}mod

*n*. Is this1, so is

*n*composed. Is the other way around

*a*

^{n}^{-1}mod

*n*= 1, it does not follow from this that

*n*is prime. But one has for many

*n*no evidence of the non-primacy of

*n*found, it will be concluded that

*n*is probably prime.

We call it a composite number *n* a *Pseudoprime based on a*if

*a ^{n}*

^{-1}1 mod

*n*

applies. Is *n* a pseudoprime to the base *a* For *all a*that are coprime to *n* are then called *nCarmichael number*. There are an infinite number of Carmichael numbers. (An example of a Carmichael number is *n* = 561.) For this reason, the Fermat test is not suitable for practical use.

The situation is different with the following tests.

### Miller test.

The basis for this is the following tightening of Fermat's little theorem.**sentence** (Miller). *Let's write an odd whole number* > 1 *in the form*-1 = 2^{e}u*with odd u, the following statements are equivalent*

- (i)
*n is prime.*- (ii)
*For all numbers a that are relatively prime to n, either*- (1)
*a*1 mod^{u}*n**or there is a k in the set*{0,1,...,*e*-1}*With*- (2)
*a*^{2ku}-1 mod*n*

### Miller-Rabin test

Is*n*a composite number and one finds one too

*n*coprime

*a*, for which neither (1) nor (2) for a

*k*with 0

*k*

*e*-1 holds, so is

*a*not prime Such a number is called one after Rabin

*Witnesses*against the primacy of

*n*. An estimate of the number of these witnesses was made by Rabin, and a simple version of his result is contained in the following

**sentence** (Rabin). *Be**n* > 3 *an odd composite number, then the number is dera**n*-1*that are relatively prime to n and do not bear witness to the primacy of n, at most* (*n*-1)/4*.*

To apply the Miller-Rabin test to an odd number *n* choose any number *a* with 2*a**n*-1. Is the gcd (*a*,*n*)> 1, so is *n* composed. In the other case one calculates *a ^{u}*,

*a*

^{2u},...,

*a*

^{2e-1u}. Is

*a*a witness against the primacy of

*n*so it is shown that

*n*is not prime. Let's assume that

*a*no witness against the primacy of

*n*is. Then the probability is that

*n*is composed, at most 1/4. Repeating the Miller-Rabin test

*t*-time so is

*n*with a probability> 1- (1/4)

*a prime number.*

^{t}We implemented the Miller-Rabin test. He needs to test a number *n* the size 10^{100} approx. 0.062 seconds (at 10^{10000} approx. 3526 seconds) on a Super SPARC processor with 40MHz.

**literature**

[1.] K.-H. Indlekofer, A. Járai,Largest known twin primes, Math. Comp.65(1996): 427-428. MR96d:11009[2.] K.-H. Indlekofer, A. Járai,

Some world records in computational number theory, Leaflets in Mathematics, Janus Pannonius University, Pécs,6(1998), 49-56, ISSN 1416-0935[3.] K.-H. Indlekofer, A. Járai,

Largest known twin primes and Sophie Germain primes, Math. Comp.68(1999): 1317-1324. MR99k:11013

- Communication is a liberal arts major
- Will China drop the dollar?
- What is the national sport of Yemen
- What happens with a biopsy test
- Barack Obama has a dark side
- Who is the best cardiologist or gynecologist
- Can Hulk survive in space
- What makes Holochain unique among blockchain technologies
- Frying vegetables is healthier than steaming
- What is PR consulting
- How many women actually love their bodies
- Is b bow of course good at SRM
- Foreigners think they have read with an accent
- How do you say AIDS in Swedish?
- Is VIT Vellore better than IITs
- Are film critics bribed by film studios
- How does brain haemorrhage occur
- Why are noises generated during lightning?
- What are the uses of HSP90 screening
- Weight training hinders height growth
- What are some hip hop songs
- Can amoeba live in carbonated water
- Who would win Warframe against Spartan?
- Accepts and listens to Quora criticism