主題
Search

素數分解


將一個數分解成其組成的因子,也稱為素因子分解。給定一個正整數 n>=2,素數分解可以寫成

 n=p_1^(alpha_1)p_2^(alpha_2)...p_k^(alpha_k),

其中 p_ik素因子,每個素因子的階數為 alpha_i。每個因子 p_i^(alpha_i) 稱為一個 primary。素數分解可以使用 Wolfram 語言中的命令FactorInteger[n] 來執行,該命令返回 (p_i,alpha_i) 對的列表。

透過他發明的 Pratt 證書,Pratt (1975) 成為第一個確定素數分解屬於 NP 複雜度類的人。

以下 Wolfram 語言程式碼可以用於給出數字 n 的良好排版形式

  FactorForm[n_?NumberQ, fac_:Automatic] :=
    Times @@ (HoldForm[Power[##]]& @@@
      FactorInteger[n, fac])

前幾個素數分解(根據定義,數字 1 的素數分解為 "1")在下表中給出。

n素數分解n素數分解
111111
22122^2·3
331313
42^2142·7
55153·5
62·3162^4
771717
82^3182·3^2
93^21919
102·5202^2·5

n=1, 2, ... 的素數分解中的位數是 1, 1, 1, 2, 1, 2, 1, 2, 2, 2, 2, 3, (OEIS A050252)。

一般來說,素數分解是一個難題,並且已經為特殊型別的數字設計了許多複雜的素數分解演算法

整數也可以在高斯素數上進行分解。例如,下表給出了前幾個正整數的高斯整數分解。

n分解
11
2-i(i+1)^2
33
4-(i+1)^4
5-i(2i+1)(2+i)
6-3i(i+1)^2
77
8i(i+1)^6
93^2
10-(i+1)^2(2i+1)(i+2)

有趣的是,等於 1 (mod 4) 的素數 p 總是可以分解為以下形式的高斯素數

 p=-i(R+Ii)(I+Ri),

其中實部和虛部在兩部分中互換,而等於 3 (mod 4) 的素數不能分解為高斯素數。這與費馬平方和定理直接相關。


另請參閱

唯一素數分解, 唯一素因子, 經濟數, 等位數, 分解, 有序分解, Primary, 素數分解演算法, 素因子, 素數, 圓整數字, 圓整度, 浪費數 在 課堂中探索這個主題

相關的 Wolfram 網站

http://functions.wolfram.com/NumberTheoryFunctions/FactorInteger/

使用 探索

參考文獻

Dickson, L. E. "Factor Tables, Lists of Primes." Ch. 13 in History of the Theory of Numbers, Vol. 1: Divisibility and Primality. New York: Dover, pp. 347-356, 2005.Glaisher, J. Factor Tables for the Sixth Million: Containing the Least Factor of Every Number Not Divisible by 2, 3, or 5 between 5000000 and 6000000. London: Taylor and Francis, 1883.Lehmer, D. N. Factor Table for the First Ten Millions, Containing the Smallest Factor of Every Number Not Divisible by 2, 3, 5 or 7 Between the Limits 0 and 10017000. Washington, DC: Carnegie Institution of Washington, No. 105, 1909.Lehmer, D. N. List of Prime Numbers from 1 to 10006721. Washington, DC: Carnegie Institution, 1914.Peters, J.; Lodge, A.; Ternouth, E. J.; and Gifford, E. Factor Table: Giving the Complete Decomposition of All Numbers Less than 100000. London: British Association for the Advancement of Science, 1935.Pratt, V. "Every Prime Has a Succinct Certificate." SIAM J. Comput. 4, 214-220, 1975.

在 中被引用

素數分解

請引用為

Weisstein, Eric W. "Prime Factorization." 來自 Web 資源。 https://mathworld.tw/PrimeFactorization.html

主題分類