Pohlig–Hellman algorithm: Difference between revisions

Content deleted Content added
No edit summary
Yahastu (talk | contribs)
No edit summary
Line 6:
:'''Output''' Integer ''x'', such that ''e ≡ g<sup>x</sup> (mod p)''.
 
:#UseDetermine the prime factorization and [[Euler's totient function]] to determine the prime factorization of the order of the group : <br><center><math>\varphi(p)= p_1\cdot p_2 \cdot \ldots \cdot p_n</math></center>
:#From the [[remainder theorem]] we know that ''x = a<sub>1</sub> p<sub>1</sub> + b<sub>1</sub>''. We now find the value of ''b<sub>1</sub>'' for which the following equation holds using a fast algorithm such as [[Baby-step giant-step]] :<br> <center><math>
\begin{matrix}e^{\varphi(p)/p_1} & \equiv & (g^x)^{\varphi(p)/p_1} \pmod{p} \\