20210216, 06:07  #1 
Aug 2005
Seattle, WA
37·47 Posts 
Yafu SNFS difficulty calculation
Can anybody help me understand the values Yafu is claiming for the difficulty in this example?
Code:
n: 401721424383720426137324949508336187045848565417289917430550907056665790265814883369879394476169080075318675151956526421358049691930517872710129161972339727160629599769770122149882863 # 7^307+6^307, difficulty: 260.29, anorm: 1.30e+037, rnorm: 1.27e+049 # scaled difficulty: 262.29, suggest sieving rational side # size = 1.218e012, alpha = 0.000, combined = 1.324e013, rroots = 0 type: snfs size: 260 skew: 0.9746 c6: 7 c0: 6 Y1: 4849687664788584363858837602739217760256 Y0: 12589255298531885026341962383987545444758743 ... 
20210216, 14:55  #2  
"Ben"
Feb 2007
DAF_{16} Posts 
Quote:
Difficulty is computed in the normal way, except here it looks like I may have included the contribution of the leading coefficient twice. Thanks for that report. As for scaled difficulty, quoting here from the code: Quote:
Size is rounded difficulty. IIRC ggnfs doesn't use size for anything. p.s. I'm happy to consider alternatives if you have any suggestions! As indicated above, scaled difficulty was a mix of numerology and experience from back when I was actively performing snfs work. Last fiddled with by bsquared on 20210216 at 15:08 Reason: more details 

20210216, 18:08  #3 
Apr 2020
313 Posts 
These are a bit small, especially anorm; the code uses a = 1e6*sqrt(skew), b=1e6/sqrt(skew) which might work well for small jobs but for numbers this large 1e6 is a big underestimate.
Really it should be something like a = sqrt(2^(2I1)*Q*skew)*const, b = sqrt(2^(2I1)*Q/skew)*const where Q is a realistic average specialq; smaller a and b give more relations so const should maybe be around 0.2? Not sure how it would be best to code this, given that the scaled difficulty informs the choice of I and Q. Perhaps use some function of difficulty that's a reasonable approximation of sqrt(2^(2I1)*Q)? And really anorm ought to be multiplied by exp(alpha) to account for root properties of the algebraic polynomial, but if you're doing a job large enough that this matters, then you ought to be testsieving anyway. 
20210216, 19:33  #4  
"Ben"
Feb 2007
31·113 Posts 
Quote:
sqrt(2^(2I1)*1e6*skew) and sqrt(2^(2I1)*1e6/skew) as I think finer adjustments to Q or using alpha would be in the noise of what this estimate is used for. 

20210224, 16:23  #5 
Aug 2005
Seattle, WA
37·47 Posts 
Here's another one, though perhaps with the opposite cause. The correct difficulty is 255.99. It looks like in this case Yafu didn't add the leading coefficient at all (255.14 ≈ 245*log_10(11)).
Code:
n: 7384049810391587250211352363287406947175960642669013845450189424529816242856745368078260733462087073764724231472029401134928725306986130695481851831787933178814661362606610448657133293018573723301486442995118362671069447396748839101553572591556351201 # 11^244+7^244, difficulty: 255.14, anorm: 1.75e+031, rnorm: 1.02e+057 # scaled difficulty: 259.44, suggest sieving rational side # size = 1.944e017, alpha = 0.000, combined = 7.014e014, rroots = 1 type: snfs size: 255 skew: 1.0946 c5: 7 c0: 11 Y1: 256923577521058878088611477224235621321607 Y0: 1067189571633593786424240872639621090354383081702091 
Thread Tools  
Similar Threads  
Thread  Thread Starter  Forum  Replies  Last Post 
Difficulty of SNFS polynomials  StrongestStrike  Factoring  6  20200916 22:40 
HOW TO BYPASS RSA DIFFICULTY... not!  Alberico Lepore  Alberico Lepore  3  20200429 16:28 
Running YAFU via Aliqueit doesn't find yafu.ini  EdH  YAFU  8  20180314 17:22 
Better measures of SNFS difficulty  fivemack  Factoring  4  20070630 09:20 
Difficulty Running Prime with DSL  Rosenfeld  Lounge  16  20040731 22:15 