Linear sieve 2
1. The number of sieve submultiple
According unique decomposition theorem
\(\huge n = p_1^{k_1}p_2^{k_2}...p_q^{k_q}\)
Any arbitrary power of all prime factors can be freely combined, so according to the principle of multiplication
\ (n-\) number is a submultiple \ ((1 + k_1) * (1 + k_2) * (1 + k_3) * ... (1 + k_q) \)
so, this number may be linear sieve according to divisor
First set \ (num (i) \) of \ (I \) a \ (k_1 \) (i.e. a minimum quality index factor) \ (D (I) \) of \ (I \) number divisors
Then three cases according to the linear theory of the set screen
- \ (\ large i is a prime number \)
Obviously NUM $ (I) = $ 2 \ (D (I) = 2 \)
- \(i\ \ mod\ \ prime[j]=0\)
Description \ (I \) there is the prime factor, and is a \ (I \) is the minimum prime factor
The \ (d (i * prime [ j]) = (1 + k_1 + 1) * (1 + k_2) * (1 + k_3) * ... (1 + k_q) \)
\ (= d (i) / whether (i) (whether (i) +1) \)
\ (Whether (i Prime [j]) = whether (i) +1 \)
\(i\ \ mod\ \ prime[j]!=0\)
Description \ (I \) do not have this quality factor, and \ (prime [j] \) of \ (i * prime [j] \) is the smallest prime factor
The \ (d (i * prime [ j]) = (1 + k_1) * (1 + k_2) * (1 + k_3) * ... (1 + k_q) * (1 + k_ {q + 1}) \)
\(=d(i)*(1+k_{q+1})\)
\(=d(i)*2\)
\(num(i*prime[j])=2\)
Since this \ (prime [j] \) is the first time it is 2