We don’t allow questions seeking recommendations for software libraries, tutorials, tools, books, or other off-site resources. You can edit the question so it can be answered with facts and citations.
Closed 2 years ago.
The community reviewed whether to reopen this question 2 years ago and left it closed:
Original close reason(s) were not resolved
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
接受
或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
发布评论
评论(3)
查看 Jason Papadopoulos 编写的用于分解大整数的 MSIEVE 库。
Check out MSIEVE library for factoring large integers by Jason Papadopoulos.
要在 C 中因式分解,您可以尝试使用概率方法:
我的命题的标题:
因式分解过程经理,因为有一个timeout:
乘数帮助器,因为计算是以 N 为模完成的:
质数检查器帮助器,当然:
分解worker,单个调用不会保证成功,这是一次概率尝试:
使用示例:
您可以将其放入
primes.c
文件中,然后编译 + 执行:另外, 128 位整数 GCC 扩展 扩展可能可用。
示例输出:
信息:此 C99 100 行概率因式分解软件命题基于 Miller–Rabin 素性测试,后跟或不跟随 >Pollard 的 rho 算法。 和你一样,我最初的目标是分解一点
long long int
。 根据我的测试,它的运行速度对我来说足够快,甚至对于一些更大的人来说也是如此。 谢谢。该软件按“原样”提供,不提供任何形式的保证。
To factor integers in C you can try to use a probabilistic approach :
The headers of my proposition :
The factorization process manager, because there is a timeout:
The multiplier helper because computations are done modulo N :
The prime checker helper, of course :
The factorization worker, a single call does not guarantee a success, it's a probabilistic try :
Example of usage :
You can put it into a
primes.c
file then compile + execute :Also, 128-bit integers GCC extension extension may be available.
Example output :
Info : This C99 100 lines probabilistic factorization software proposition is based on a Miller–Rabin primality test followed or not by a Pollard's rho algo. Like you, i initially aimed to factorize just a little
long long int
. By my tests it's working fast enough to me, even for some larger. Thank you.THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND.
GMP-ECM(整数分解的椭圆曲线法)怎么样?
如果 Inria 官方项目页面的链接不可用,您可以检查 网络存档上的最新版本。
How about GMP-ECM (Elliptic Curve Method for Integer Factorization)?
If the link to the official project page at Inria is unavailable, you can check a recent version on the web archive.