mersenneforum.org PFGW vs LLR comparison discussion
 Register FAQ Search Today's Posts Mark Forums Read

 2009-12-31, 09:09 #1 henryzz Just call me Henry     "David" Sep 2007 Cambridge (GMT) 130768 Posts PFGW vs LLR comparison discussion i would be very interested in running some of the numbers that can be converted to base 2 as they run faster(how much faster now we have the new pfgw?) however i am not certain that i am able to run a whole file within a short time period would loading some into a server be worthwhile? it could be a first test for the soon to be released version of prpnet
2009-12-31, 09:34   #2
gd_barnes

May 2007
Kansas; USA

52·11·37 Posts

Quote:
 Originally Posted by henryzz i would be very interested in running some of the numbers that can be converted to base 2 as they run faster(how much faster now we have the new pfgw?) however i am not certain that i am able to run a whole file within a short time period would loading some into a server be worthwhile? it could be a first test for the soon to be released version of prpnet
All base 16 tests can be converted to base 2 since 16 is a power of 2. I think I know what you're getting at though.

To the best of my knowledge and experience, no, neither PFGW nor LLR will run base 16 faster than base 2. LLR knows to internally convert them, whether the conversion be for the base or for the k-value. Two examples:
1. LLR would internally convert 2297*16^10-1 to 2297*2^40-1 to gain the faster testing speed of base 2.
2. LLR would internally convert 3620*16^10-1 to 3620*2^40-1 and from there convert it to 905*2^42-1 to gain both the faster testing speed of base 2 and a possible smaller fftlen and hence increased speed of the lower k-value.

In the results file, it will always display the test in base 2 and of the original k-value, although it internally uses a reduced k-value if it can to gain testing speed.

You might check it out for yourself to confirm this.

As far as I know, PFGW should not be used for any power-of-2 base. LLR should always be at least as fast or faster.

You can reserve a smaller file. Let me know if you want to reserve an n=500 or n=1000 file. If so, I'll split up the 1st file link.

I'd prefer not to add and administer any more public servers until we get all of the NPLB servers on my machine, which will likely be in < 2 weeks after a friend finishes getting a couple of more machines built for me. (I just talked to him today and he's said he'll do it.) You might talk to Max about setting up a private server, which he can do on my machine.

Gary

Last fiddled with by gd_barnes on 2009-12-31 at 09:38

 2009-12-31, 09:53 #3 henryzz Just call me Henry     "David" Sep 2007 Cambridge (GMT) 10110001111102 Posts I didnt make myself hugely clear like usual. I knew how LLR converted base 16 to base 2. My question about PFGW was how much longer does it take to test a non-base 2 number(base 589 for example) of the same size than a base 2 number with LLR. Once i have finished my 137 digit gnfs i will reserve a small file here. Last fiddled with by henryzz on 2009-12-31 at 09:53
 2009-12-31, 13:34 #4 kar_bon     Mar 2006 Germany 17·167 Posts here is an example (on an i7 with 8 threads): for 3051*2^491000-1 LLR needs about 540s (about 148000 digits). in the same time PFGW do 2*1019^52400-1 (about 158000 digits). so for this example PFGW is slightly faster for the same amount of digits.
2009-12-31, 14:39   #5
rogue

"Mark"
Apr 2003
Between here and the

2·32·52·13 Posts

Quote:
 Originally Posted by kar_bon here is an example (on an i7 with 8 threads): for 3051*2^491000-1 LLR needs about 540s (about 148000 digits). in the same time PFGW do 2*1019^52400-1 (about 158000 digits). so for this example PFGW is slightly faster for the same amount of digits.
You can't really compare these quite so easily because LLR uses and Lucas-Lehmer-Riesel test to prove primality for k*2^n-1 numbers. PFGW uses Brillhart-Lehmer-Selfridge for primality. LLR does not do a PRP test for base 2 numbers, but PFGW will unless you use -tm or -tp.

In other words, if you want to compare apples to apples, then test run a test with both, but for the same base (and not base 2).

My recommendation is that you use LLR for base 2 (and powers of 2) and PFGW for all other bases.

2009-12-31, 14:48   #6
kar_bon

Mar 2006
Germany

283910 Posts

Quote:
 Originally Posted by rogue In other words, if you want to compare apples to apples, then test run a test with both, but for the same base (and not base 2).
i know that, but this is what David was asking for!

Quote:
 Originally Posted by henryzz My question about PFGW was how much longer does it take to test a non-base 2 number (base 589 for example) of the same size than a base 2 number with LLR.

Last fiddled with by kar_bon on 2009-12-31 at 14:49

2009-12-31, 15:54   #7
rogue

"Mark"
Apr 2003
Between here and the

16DA16 Posts

Quote:
 Originally Posted by kar_bon i know that, but this is what David was asking for!
"I see" says the blind man.

 2009-12-31, 18:01 #8 henryzz Just call me Henry     "David" Sep 2007 Cambridge (GMT) 2·3·13·73 Posts i thought someone would know the figures lol i can work it out myself it just doesnt make sense if every single person does their own timing i was talking about prp and llr not primality tests cause those are used in general testing it is another thing that will have to wait until i am back on windows after my factorization going back to linux after adjusting back to windows is proving slightly wierd i have reaized that i was coping with an inferior operating system maybe linux is not in comparison with vista but it is in comparison with windows 7 IMO
 2010-01-02, 08:08 #9 gd_barnes     May 2007 Kansas; USA 1017510 Posts Punctuation, capitalization, sentence breaks, and paragraph breaks please. Thanks. I'm complaining because I answered the wrong question before.
2010-01-02, 08:14   #10
gd_barnes

May 2007
Kansas; USA

100111101111112 Posts

Quote:
 Originally Posted by kar_bon here is an example (on an i7 with 8 threads): for 3051*2^491000-1 LLR needs about 540s (about 148000 digits). in the same time PFGW do 2*1019^52400-1 (about 158000 digits). so for this example PFGW is slightly faster for the same amount of digits.
Amazing. I had no clue that PFGW PRP testing was as fast as LLR primality proofs for the same number of digits. I didn't think that was possible. Personally I consider that an apples to apples comparison even though technically it's not. That's because we only need to run PRP tests unless we find a PRP. It's only a very small percentage that we have to do a proof on...and that percentage drops greatly as we increase in size. I'm assuming that (for instance) a base 3 primality proof would take quite a bit longer than a base 2 primality proof but the fact is that we only need that proof in a very small percentage of tests.

Perhaps someone should start an all around base 3 Riesel effort like RPS/NPLB for Riesel base 2. Base 3 would be far heavier weight for virtually all k's because nothing could be divisible by 3. It would be the reverse of base 2 in that you would search all even k's instead of all odd k's.

Edit: I just thought of something: Karsten, you need to compare the same k-value to make it an apples to apples comparison. Like LLR, PFGW is faster for smaller k-values. Since your base 2 k-value is much higher, that's probably why it's slower than the base 1019 test. I also wonder if the machine would need the 8 threads for PFGW to be as fast as LLR.

Gary

Last fiddled with by gd_barnes on 2010-01-02 at 09:18

 2010-01-02, 09:09 #11 PCZ     Jun 2006 Chertsey Surrey UK 2×179 Posts Now the cats out of the bag. :) Everyone and his dog will be doing non base 2 work. I am surprised it took so long for the penny to drop.

 Similar Threads Thread Thread Starter Forum Replies Last Post CRGreathouse Factoring 3 2018-02-05 14:55 ldesnogu Computer Science & Computational Number Theory 11 2015-10-28 12:54 wblipp Operation Billion Digits 0 2012-11-24 06:33 Joe O Sierpinski/Riesel Base 5 5 2010-09-30 14:07 devarajkandadai Miscellaneous Math 22 2005-06-10 11:13

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

Fri Aug 7 22:16:21 UTC 2020 up 21 days, 18:03, 1 user, load averages: 1.98, 1.98, 1.97