|
| |
|
|
A093082
|
|
Number of steps to factor n!-1 using Fermat's factorization method.
|
|
2
| |
|
|
1, 1, 8, 2, 334, 2450, 688, 958, 60676, 151, 239478914, 1718557, 43588850341, 44525, 3435544097, 128202996855, 166046498, 468640744, 9748065626452, 2406214305714, 54782975386, 249195119225246375, 20940713346
(list; graph; refs; listen; history; internal format)
|
|
|
|
OFFSET
| 2,3
|
|
|
LINKS
| Harry J. Smith, Table of n, a(n) for n=2,...,59
|
|
|
FORMULA
| For n>2, a(n) = (d + (m)/d)/2 - floor(sqrt(m)), where m=n!-1 and d is the smallest divisor of m such that d >=sqrt(m). [From Max Alekseyev (maxale(AT)gmail.com), Apr 13 2009]
|
|
|
PROG
| (PARI) { a(n) = if(n==2, return(1)); m=n!-1; fordiv(m, d, if(d*d>=m, return((d+m\d)\2-sqrtint(m)))) } [From Max Alekseyev (maxale(AT)gmail.com), Apr 13 2009]
(PARI) a(n) = { if(n==2, return(1)); m=n!-1; fordiv(m, d, if(d*d>=m, return((d+m\d)\2-sqrtint(m)))); } { for(n=2, 59, write("b093082.txt", n, " ", a(n)); ); } [From Harry J. Smith (hjsmithh(AT)sbcglobal.net), Jun 20 2009]
|
|
|
CROSSREFS
| Cf. A078753.
Sequence in context: A032761 A188898 A176860 * A107671 A154538 A154166
Adjacent sequences: A093079 A093080 A093081 * A093083 A093084 A093085
|
|
|
KEYWORD
| hard,nonn
|
|
|
AUTHOR
| Jason Earls (zevi_35711(AT)yahoo.com), May 09 2004
|
|
|
EXTENSIONS
| Extended by Max Alekseyev (maxale(AT)gmail.com), Apr 13 2009
|
| |
|
|