User:Virginia-American/Sandbox

A composite number is a positive integer which has a positive divisor other than one or itself. In other words, if 0 < n is an integer and there are integers 1 < a, b < n such that n = a × b then n is composite. By definition, every integer greater than one is either a prime number or a composite number. The number one is a unit - it is neither prime nor composite. For example, the integer 14 is a composite number because it can be factored as 2 &times; 7.

The first 15 composite numbers are
 * 4, 6, 8, 9, 10, 12, 14, 15, 16, 18, 20, 21, 22, 24, and 25.

Arithmetic functions
The fundamental theorem of arithmetic says that every positive integer can be represented as the product of  prime numbers and that (except for their order) this representation is unique: for any n > 0, there are prime numbers p1 < p2 < ... < pk and positive integers a1, a2, ..., ak, so that

$$n=p_1^{a_1}p_2^{a_2} \cdots p_k^{a_k}.$$ (The number 1 corresponds to the empty product).

Several arithmetic functions that are important in the study of composite numbers are defined using this factorization.

The number of distinct prime factors of n is denoted by $$\omega(n),$$ and the number of prime factors counted with multiplicity is denoted by $$\Omega(n).$$ Thus, for the n factored  above, $$\omega(n) = k$$ and $$\Omega(n) = \sum_{j=1}^{k}a_j.$$

The number of divisors (including 1 and n itself) of n is denoted by $$ d(n)$$ and the sum of the divisors is denoted by $$\sigma(n).$$

Since a number m divides n if and only if $$m=p_1^{b_1}p_2^{b_2} \cdots p_k^{b_k}$$ where 0 ≤ bi ≤ ai for all i,  1 ≤  i ≤  k,

$$ d(n) = (a_1 + 1)(a_2 + 1) \cdots (a_k + 1)\;\;$$ and

$$ \begin{align} \sigma(n) &= (1+p_1+p_1^2+\cdots+p_1^{a_1})\times\cdots\times(1+p_k+p_k^2+\cdots+p_k^{a_k}) \\ & = \frac{p_1^{a_1+1}-1}{p_1-1}\times\frac{p_2^{a_2+1}-1}{p_2-1}\times\cdots\times\frac{p_k^{a_k+1}-1}{p_k-1} \\ \end{align} $$

"For example 12 = 22×3, so &omega;(12) = 2, &Omega;(12) = 3, d(12) = 6 and &sigma;(12) = 28. (The divisors of 12 are 1, 2, 3, 4, 6, and 12.)" Therefore, n is composite is equivalent to each of the three statements &Omega;(n) > 1, d(n) > 2, and &sigma;(n) > n + 1.

Detecting composite numbers
The obvious way to prove that a number is composite is to find a nontrivial factor. This is only feasible for numbers less than about 200 decimal digits long. (See Integer factorization records.)

Any formula that is satisfied by prime numbers but is not necessarily true for composite numbers can be used to test for compositeness: if n does not satisfy the formula then n is composite. For example Fermat's theorem says that if p is prime and does not divide a then ap–1 &equiv; 1 (mod p). Therefore, if for some a, an – 1 is not &equiv; 1 (mod n), n is composite. This is practical because there are efficient algorithms for modular exponentiation. A similar test is based on Euler's criterion. See the articles on pseudoprimes and Carmichael numbers for examples of composite numbers that cannot be detected by these and similar tests.

Wilson's theorem says that (n – 1)! &equiv; –1 (mod n) if and only if n is prime. This is not a practical way to determine whether a number is prime or composite because there is no known algorithm for efficiently calculating factorials (mod n).

By using tests of this sort, it has been determined that some numbers are composite even though no factor is known. An example is $$F_{14}=2^{2^{14}}+1$$ the 14th Fermat number.

Kinds of composite numbers
A number n such that &Omega;(n) = 2 (i.e. n is the square of a prime or the product of two distinct primes) is called a semiprime or a 2-almost prime. More generally, if &Omega;(n) = k, n is called a k-almost-prime. Several conjectures about prime numbers have been proved for 2-almost-primes. See twin prime conjecture, Goldbach's conjecture, and Chen's theorem.

If all the prime factors of a number are repeated it is called a powerful number.

If none of its prime factors are repeated, it is called squarefree. (All prime numbers and 1 are squarefree.) The radical or squarefree core of a number n (prime or composite) is the product of all the distinct primes dividing n. See ABC conjecture.

If none of the prime factors of n exceed B, n is called B-smooth. Smooth numbers are important in several integer factorization algorithms, including Pollard's p - 1 algorithm, the quadratic sieve and the number field sieve.

A composite number with three distinct prime factors is called a sphenic number.

A number n that has more divisors than any x < n is called a highly composite number (though the first two such numbers are 1 and 2).

Some authors call numbers that have been proved composite without any factors being known "genuine composites".

Statistics
Hardy and Wright wrote

A number is usually called 'round' if it is the product of a considerable number of compararively small factors. Thus 1200 = 24 × 3 × 52 would certainly be called round. the roundness of a number like 2187 = 37 is obscured by the decimal notation.

It is a matter of common observation that round numbers are very rare.

They continue Either of the functions &omega;(n) or &Omega;(n) gives a natural measure of the 'roundness' of n, and each of them is usually about loglog n, a function of n which increases very slowly. Thus loglog 107 is a little less than 3, and loglog 1080 is a little larger than 5.

In some applications, it is necessary to differentiate between composite numbers with an odd number of distinct prime factors and those with an even number of distinct prime factors. For the latter


 * $$\mu(n) = (-1)^{2x} = 1\,$$

(where μ is the Möbius function and x is half the total of prime factors), while for the former


 * $$\mu(n) = (-1)^{2x + 1} = -1.\,$$

Note however that for prime numbers the function also returns -1, and that $$\mu(1) = 1$$. For a number n with one or more repeated prime factors, $$\mu(n) = 0$$.

Another way to classify composite numbers is by counting the number of divisors. All composite numbers have at least three divisors. In the case of squares of primes, those divisors are $$\{1, p, p^2\}$$. A number n that has more divisors than any x < n is a highly composite number (though the first two such numbers are 1 and 2).