Currently there may be errors shown on top of a page, because of a missing Wiki update (PHP version and extension DPL3).
Navigation
Topics Help • Register • News • History • How to • Sequences statistics • Template prototypes

GMP-ECM

From Prime-Wiki
Revision as of 10:54, 6 December 2019 by Karbon (talk | contribs) (reflist)
Jump to: navigation, search

GMP-ECM is a program capable of factoring numbers using the ECM, p-1 and p+1 algorithms. The current version is 7.0.5-dev (svn 3038).

Originally developed by Paul Zimmermann. He was joined by Alexander Kruppa at release 5. Currently the program is developed by a team of contributors.[1]

Distributed under GNU General Public License version 2.

Compiling GMP-ECM on Windows

To get an optimal performance, you'll need to compile (build) your own version of GMP-ECM.

1. First you'll need to get the right environment and stuff to work with:

  • Get MinGW.
  • Install it.
  • Get MSYS (when installing MSYS answer y, y and input the directory where you installed MinGW when asked).
  • Get MPIR and GMP-ECM (don't unpack them, just place them on your desktop).

2. Open MSYS (there should be a "MSYS" icon on your desktop) and shut it down again.

3. Now move the MPIR and GMP-ECM to C:\YourMsysDirectory\1.0\home\YourUser\.

4. Time to open MSYS again. Inside MSYS you'll need to do as shown on this screenshot:

About to press enter

(and to those of you who for some reason can't see the screenshot: Type tar xjvf mpir-2.5.1.tar.bz2 and press enter)

After pressing enter, MSYS should start unpacking MPIR.

5. Type cd mpir-2.5.1 and press enter (to change to your new MPIR directory)

6. Type ./configure --enable-gmpcompat and press enter.

About to press enter again

Now it will probably start configuring a bunch of stuff and you should see a lot of output.

7. After MSYS is done configuring, type make install

I'm still about to press enter

Now MPIR installs itself. This is going to take a little while.

8. After it's finished, type cd and press enter to go back to your initial directory.

9. Follow this screenshot:

Guess what I'm about to do...

(Type tar xzvf ecm-6.4.3.tar.gz and press enter)

Now it'll start unpacking.

10. Type cd ecm-6.4.3 (to get to the new directory)

11. Do as shown in the screenshot:

About to press enter

(type ./configure --with-gmp=/usr/local and press enter)

Now it will make sure that you get an optimal performance out of your GMP-ECM.

12. Type 'make' and press enter. This will create your ecm.exe and will take some time.

13. When it has finished, close MSYS and you should be able to find ecm.exe in the home-directory.

Now that you have an optimized ecm.exe you'll need to use it either manually on the Cunningham list or as a part of ECMclient.

Alternatively, you can use a script courtesy of ATH to compile the latest version of GMP-ECM.

Changes between ecm-6.4.2 and ecm-6.4.3

  • Fixed bug reported by user "lorgix" on mersenneforum
  • Use 64-bit value for random seed under Windows

External links

Notes

  1. Project Member List – InriaForge: GMP-ECM.