mersenneforum.org

mersenneforum.org (https://www.mersenneforum.org/index.php)
-   PrimeNet (https://www.mersenneforum.org/forumdisplay.php?f=11)
-   -   P-1 factoring anyone? (https://www.mersenneforum.org/showthread.php?t=11101)

Mini-Geek 2012-02-27 23:43

[QUOTE=bcp19;291113]I've been doing some reading, and have a few questions regarding P-1 and ECM. From the usage of them on the site, it appears to be a given that P-1 is more efficient than ECM for time spent vs factor found for exponents that were not factored during TF and prior to LL.[/QUOTE]
That's right. ECM, unlike TF and P-1, is not useful as a pre-factoring method (i.e. factoring efforts done to prove a Mersenne number composite without running LL tests), instead it is useful as an effort towards fully factoring a number. This is largely because with P-1 on Mersenne numbers, we know that P-1 has a factor of p (the Mersenne exponent), thus growing the potential factor size by several digits at almost no cost.
[QUOTE=bcp19;291113]So, while P-1 will find all factors 2kp+1 where the 2nd largest factor of k < B1 and the largest factor of k < B2, will the ECM also find all factors? (If I am asking this question badly, given that factor F is 22 digits long and can be found with B1=50000 using 300 curves[25 digit ECM], will F also be found using B1=250000 using 700 curves[30 digit ECM] and higher?)[/QUOTE]
ECM is not* deterministic like P-1 is. When you run "25 digit ECM", what you're doing (IIRC) is saying that if there is a 25 digit factor, you can expect to have found it 1 time, which means about a 68% probability that you actually found it. When running to 30 digits, you can still find the 22 digit factor, in fact you're much more likely to find it than when searching at a 25 digit level (at a cost of higher expected time to find the factor than at 25 digit level).
* In ECM, a random sigma is chosen for each curve/run. With each particular sigma, whether a factor will be found is deterministic, just like P-1: It is dependent on the smoothness of the group order of p given sigma s, like P-1 is dependent on the smoothness of p-1. When looking at a large number of ECM curves, it's best to think of it as being non-deterministic.
[QUOTE=bcp19;291113]At what point is it better to use ECM for factorization...[/QUOTE]
After you've done a P-1 run, and you have done enough TF that the expected time per factor now favors ECM.
[QUOTE=bcp19;291113]...and how do you determine what level of ECM to start at?[/QUOTE]
You'd probably want to start where TF left off. E.g. 70 bits is ~22 digits, so you would probably want to start at an ECM level optimal for finding 25 or 30 digit factors.

bcp19 2012-02-28 17:26

[QUOTE=Mini-Geek;291120]* In ECM, a random sigma is chosen for each curve/run. With each particular sigma, whether a factor will be found is deterministic, just like P-1: It is dependent on the smoothness of the group order of p given sigma s, like P-1 is dependent on the smoothness of p-1. When looking at a large number of ECM curves, it's best to think of it as being non-deterministic.
[/QUOTE]

So, because of the random sigma, you can have 50 people each working on 100 curves with a very good chance of not duplicating work. I'd been wondering how that worked, thanks.

Dubslow 2012-03-02 04:41

What does QA mean in ecm.c?

[code]/* Global variables */ /*line 38*/

int QA_IN_PROGRESS = FALSE;
int QA_TYPE = 0;
giant QA_FACTOR = NULL;[/code]

cheesehead 2012-03-02 04:51

[QUOTE=Dubslow;291517]What does QA mean in ecm.c?

[code]/* Global variables */ /*line 38*/

int QA_IN_PROGRESS = FALSE;
int QA_TYPE = 0;
giant QA_FACTOR = NULL;[/code][/QUOTE]Quality assurance, or something similar -- i.e., test mode.

flashjh 2012-03-03 00:34

P-1 question
 
James,

Your site gives slightly different values for P-1 than Prime95.

Should I override Prime95 and use yours, combine, or just let Prime95 decide?

Prime95:

[CODE]
Optimal P-1 factoring of M403000007 using up to 117950MB of memory.
Assuming no factors below 2^77 and 2 primality tests saved if a factor is found.
Optimal bounds are B1=4065000, B2=134145000
Chance of finding a factor is an estimated 6.41%
Using Core2 type-3 FFT length 22400K, Pass1=3584, Pass2=6400, 4 threads

[/CODE]

Your site:

[CODE]
M403000007, factored to 77 bits, assuming 2 L-L tests saved, with B1=3,975,000 and B2=99,375,000, using K*B^N+C = 1*2^403000007-1
Probability = 6.095490%
Should take about 253.322407 GHz-days (using FFT size 22,400K)
Recommended RAM allocation: min=3,621MB; good=10,789MB; max=88,204MB; insane=432,268MB;
[/CODE]

Prime95 shows higher chance of finding a factor, but your B1 is lower. Should I use a pminus1 line in Prime95 like

[CODE]
Pminus1=1,2,403000007,-1,3975000,134145000,77
[/CODE]

to override the system?

On your site I put in the exponent and selected 2 LL tests saved to calculate.

Thanks

James Heinrich 2012-03-03 00:46

[QUOTE=flashjh;291650]Should I override Prime95 and use yours, combine, or just let Prime95 decide?[/QUOTE][b]Always[/b] let Prime95 decide. My numbers are reasonable guidelines, but don't take into account the nuances like how many relative primes can be processed per pass given your memory allocation.

For comparison, if you use my site to seek a [url=http://mersenne-aries.sili.net/prob.php?exponent=403000007&b1=4065000&b2=134145000&factorbits=77&K=1&C=-1]matching[/url] [url=http://mersenne-aries.sili.net/prob.php?exponent=403000007&prob=6.411128&factorbits=77]6.411128% chance of factor[/url], it does come up with bounds that are reasonably close to what Prime95 has selected:[code]Seeking 6.411128% chance of factor for exponent M403,000,007
M403,000,007, factored to 77 bits, with B1=4,593,367 and B2=124,020,909
Probability = 6.411128%
Should take about 306.553148 GHz-days (using FFT size 22,400K)
Recommended RAM allocation: min=3,621MB; good=10,789MB; max=88,204MB; insane=432,268MB;[/code]

Dubslow 2012-03-03 00:48

The problem is his site doesn't let you enter the memory to use, which plays a not-minor role in bounds choosing. You're allocating ~ [i]100GiB[/i](!!!), which is why Prime95 chose higher bounds and thus a better factor chance. If in doubt, always go with Prime95's bounds. James' site is meant for exploration, i.e. not having to put a Pfactor line in worktodo.txt and then stopping the test to get bounds calculated.

Edit: Whoops, cross post. Addendum: Why the hell are you doing P-1 that high? :P

flashjh 2012-03-03 00:49

[QUOTE=James Heinrich;291651][B]Always[/B] let Prime95 decide. My numbers are reasonable guidelines, but don't take into account the nuances like how many relative primes can be processed per pass given your memory allocation.

For comparison, if you use my site to seek a [URL="http://mersenne-aries.sili.net/prob.php?exponent=403000007&b1=4065000&b2=134145000&factorbits=77&K=1&C=-1"]matching[/URL] [URL="http://mersenne-aries.sili.net/prob.php?exponent=403000007&prob=6.411128&factorbits=77"]6.411128% chance of factor[/URL], it does come up with bounds that are reasonably close to what Prime95 has selected:[code]Seeking 6.411128% chance of factor for exponent M403,000,007
M403,000,007, factored to 77 bits, with B1=4,593,367 and B2=124,020,909
Probability = 6.411128%
Should take about 306.553148 GHz-days (using FFT size 22,400K)
Recommended RAM allocation: min=3,621MB; good=10,789MB; max=88,204MB; insane=432,268MB;[/code][/QUOTE]

Thanks.

James Heinrich 2012-03-03 01:00

[QUOTE=Dubslow;291652]Why the hell are you doing P-1 that high? :P[/QUOTE]Because he has 128GB of RAM :smile:

My current 32GB now feels strangely inadequate for my even-crazier attempt at [url=http://mersenne-aries.sili.net/M595900037]M595,900,037[/url] (3.5 months and I'm not done stage1 yet, although that's because it's sharing a single core with mfaktc on my i7-920; I'll put 4x 3930K cores on it once it's time for stage2).

flashjh 2012-03-03 01:10

[QUOTE=Dubslow;291652]The problem is his site doesn't let you enter the memory to use, which plays a not-minor role in bounds choosing. You're allocating ~ [I]100GiB[/I](!!!), which is why Prime95 chose higher bounds and thus a better factor chance. If in doubt, always go with Prime95's bounds. James' site is meant for exploration, i.e. not having to put a Pfactor line in worktodo.txt and then stopping the test to get bounds calculated.

Edit: Whoops, cross post. Addendum: Why the hell are you doing P-1 that high? :P[/QUOTE]

Somewhere along the way I was curious about doing high # P-1s. It was discussed [URL="http://www.mersenneforum.org/showthread.php?t=16473"]a while back[/URL] and so I'm working on finishing what I started.

I've wondered about Prime95 and James' site for a while with the P-1 calculation, but with such a big exponent, I didn't want to run it without asking.

[QUOTE=James Heinrich;291656]Because he has 128GB of RAM :smile:

My current 32GB now feels strangely inadequate for my even-crazier attempt at [URL="http://mersenne-aries.sili.net/M595900037"][COLOR=#0066cc]M595,900,037[/COLOR][/URL] (3.5 months and I'm not done stage1 yet, although that's because it's sharing a single core with mfaktc on my i7-920; I'll put 4x 3930K cores on it once it's time for stage2).[/QUOTE]

Is 595900037 the highest Prime95 can go right now?

I have 4 cores of my 6272 running it. Prime95 says it will complete 25 May 2012. We'll see. If it tries to take all 88M of ram in stage 2, I'll have to limit it so the other workers can continue.

James Heinrich 2012-03-03 01:26

[QUOTE=flashjh;291657]Is 595900037 the highest Prime95 can go right now?[/QUOTE]No, there's room for you to beat me: the largest FFT in Prime95 (32M) is capped at M596,000,000 so that means [url=http://mersenne-aries.sili.net/M595999993]M595,999,993[/url] is the largest candidate. But, being the largest candidate, it's already [url=http://v5www.mersenne.org/report_exponent/?exp_lo=595999993]had some P-1 attention[/url] from at least 3 users, most recently [i]B1=4479490, B2=107507760 by "Åke Tilander" on 2011-12-03[/i].


All times are UTC. The time now is 22:55.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2021, Jelsoft Enterprises Ltd.