Go Back > Factoring Projects > NFS@Home

Thread Tools
Old 2016-07-04, 08:40   #1
(loop (#_fork))
fivemack's Avatar
Feb 2006
Cambridge, England

22×32×179 Posts
Default Auto-XYYXF tool

Here is the tool I was talking about for producing SNFS polynomials for XYYXF numbers. Feel free to complain about my maths and my Python.

I'm never quite sure how to automate trial-sieving - you probably do want to launch multiple jobs in parallel, I think that having this tool analyse the stderr from the trial-sieving job if it exists with an obvious name is probably going to be the right answer.
Attached Files
File Type: txt (1.8 KB, 187 views)
fivemack is offline   Reply With Quote
Old 2016-07-04, 09:56   #2
Basketry That Evening!
Dubslow's Avatar
"Bunslow the Bold"
Jun 2011
40<A<43 -89<O<-88

3·29·83 Posts

Why not just use Yafu? It already has comprehensive SNFS polsel code, including XYYXF, as well as trial sieving (though not in parallel).

(I'll take a look at the Python from a style standpoint within a day or two.)

Last fiddled with by Dubslow on 2016-07-04 at 09:57
Dubslow is offline   Reply With Quote
Old 2016-07-04, 15:54   #3
(loop (#_fork))
fivemack's Avatar
Feb 2006
Cambridge, England

644410 Posts
Default Some results on S{250..255}

These are A-side 14e, A-side 15e, R-side 14e, R-side 15e timings for a number of candidate numbers, with 31-bit large primes. These are pretty clearly 15e numbers, though may need a little more ECM before queue submission.

total yield: 5565, q=130010009 (0.75608 sec/rel) 
total yield: 11590, q=130010009 (0.68150 sec/rel) 
total yield: 4971, q=130010009 (0.77353 sec/rel) 
total yield: 9924, q=130010009 (0.72277 sec/rel) 
total yield: 3456, q=130010009 (1.09830 sec/rel) 
total yield: 7358, q=130010009 (0.96890 sec/rel) 
total yield: 3407, q=130010009 (1.11494 sec/rel) 
total yield: 6765, q=130010009 (1.06387 sec/rel) 
total yield: 4415, q=130010009 (0.84616 sec/rel) 
total yield: 9214, q=130010009 (0.76643 sec/rel) 
total yield: 4643, q=130010009 (0.82960 sec/rel) 
total yield: 9449, q=130010009 (0.77321 sec/rel) 
total yield: 8796, q=130010009 (0.46016 sec/rel) 
total yield: 19094, q=130010009 (0.40438 sec/rel) 
total yield: 9207, q=130010009 (0.42136 sec/rel) 
total yield: 18853, q=130010009 (0.38462 sec/rel) 
total yield: 7130, q=130010009 (0.52332 sec/rel) 
total yield: 15217, q=130010009 (0.46348 sec/rel) 
total yield: 7920, q=130010009 (0.48562 sec/rel) 
total yield: 16245, q=130010009 (0.44511 sec/rel) 
total yield: 4217, q=130010009 (0.88017 sec/rel) 
total yield: 8996, q=130010009 (0.77564 sec/rel) 
total yield: 4412, q=130010009 (0.86608 sec/rel) 
total yield: 8877, q=130010009 (0.81619 sec/rel) 
total yield: 5498, q=130010009 (0.69142 sec/rel) 
total yield: 11459, q=130010009 (0.62760 sec/rel) 
total yield: 5657, q=130010009 (0.68142 sec/rel) 
total yield: 11358, q=130010009 (0.64701 sec/rel) 
total yield: 6470, q=130010009 (0.64258 sec/rel) 
total yield: 13714, q=130010009 (0.59361 sec/rel) 
total yield: 6196, q=130010009 (0.62433 sec/rel) 
total yield: 12502, q=130010009 (0.61041 sec/rel)
130.87 yields with 3 large primes (A3.0 => lss=0, 3 large primes on A side); 15e, 31LP
A3.0	y=7823	t=1.229s/r
A3.1	y=7503	t=1.302s/r
R3.0	y=8140	t=1.229s/r
R3.1	y=6874	t=1.295s/r
so that's a significant disadvantage over 2 large primes

Last fiddled with by fivemack on 2016-07-04 at 16:32
fivemack is offline   Reply With Quote
Old 2016-07-06, 04:01   #4
Basketry That Evening!
Dubslow's Avatar
"Bunslow the Bold"
Jun 2011
40<A<43 -89<O<-88

3×29×83 Posts

There are lots of things I could say about the code, both generically and Python specific... mostly, it's terse and uncommented, some variable names being rather opaque, though I think I was able to figure things out. Among other things, I would suggest that even for the most terse single character variables, you use them consistently -- sometimes you used p for factors, while later you used g instead of p for no particular reason I could see. Also, more spacing is always better (and see PEP 8 for the official Python spacing conventions, among other things). Finally, use Python 3. Python 2 is deprecated and has no advantages and several disadvantages compared to Python 3.

There are a variety of other things too, like unnecessary parens in conditionals and other things. See the attached for a full diff. (I more or less rewrote it line for line)

(And if you complain that this is a throwaway script, well... I used to do the same until I tried to read the throwaways when they became useful again after months or years of disuse... boy was that a pain. )

Edit: One of my more liked coans from among many:
Attached Files
File Type: txt (3.1 KB, 181 views)

Last fiddled with by Dubslow on 2016-07-06 at 04:17
Dubslow is offline   Reply With Quote

Thread Tools

Similar Threads
Thread Thread Starter Forum Replies Last Post
auto off/on machines wildrabbitt Hardware 3 2016-05-14 16:31
Auto-add Computers? ConstipatedNinj Information & Answers 12 2015-12-02 00:02
XYYXF C200_111_110 akruppa Factoring 5 2012-12-04 09:24
Auto scroll and auto maximize worker windows ? wyattwong Software 3 2011-02-25 20:20
Auto updates from mprime rgiltrap Linux 1 2007-01-08 22:33

All times are UTC. The time now is 07:40.

Wed Dec 8 07:40:44 UTC 2021 up 138 days, 2:09, 1 user, load averages: 1.38, 1.55, 1.61

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

This forum has received and complied with 0 (zero) government requests for information.

Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation.
A copy of the license is included in the FAQ.