![]() |
![]() |
#1 |
Sep 2010
Scandinavia
3×5×41 Posts |
![]()
Hi,
I can't get flags to work. I'm assuming that I've missed something fundamental. Probably something that's obvious to people who know at least one programming language. I don't understand how to do batch work either. Also, is there a way of changing the behavior of the factor() command? Limits etc.. I'm running yafu-64k-x64 1.21 in Windows 7. |
![]() |
![]() |
![]() |
#2 |
Mar 2010
3×137 Posts |
![]()
My example:
I have a batch file, factor.bat . If you open it with NotePad, it has the following: Code:
yafu-32k-x64.exe -threads 4 -v -rhomax 800000 -fmtmax 299396627 <factorme.txt pause YAFU reads from that file the numbers I want to factor. Example contents of factorme.txt: Code:
factor(999999999999999999999999999999999999999999999999999999999999999999999999999999839999999999999999999999999999999999999999999999999999999999999999999999999999997751) siqs(1057409760389727179215648843128435820215732534244928446740953737668146356315982185550002262405690920105297) |
![]() |
![]() |
![]() |
#3 |
Sep 2010
Scandinavia
3×5×41 Posts |
![]()
Thanks.
I think I've created a correct work file and a correct .bat. It appears the only problem left is that I still don't know how to tell YAFU to get to work. I have 'ecm.txt' and 'factor.bat', what do I type in YAFU? |
![]() |
![]() |
![]() |
#4 |
Mar 2010
3·137 Posts |
![]()
Well, you can type the same stuff as in your ecm.txt , but, better yet, launch the batch file.
For example, you launch yafu, a console window appears, and you type ecm(*some number*) and press Enter, and that will "tell" yafu to ECM that number. If you have "ecm (*some number*) in ecm.txt, you can just edit your factor.bat, so it will have "yafu.exe <ecm.txt". Each time you launch that batch file, it will do ECM factoring on the number in ecm.txt. Last fiddled with by Karl M Johnson on 2010-12-25 at 15:34 Reason: Yes. |
![]() |
![]() |
![]() |
#5 | |
Sep 2010
Scandinavia
3×5×41 Posts |
![]() Quote:
|
|
![]() |
![]() |
![]() |
#6 | |
"Ben"
Feb 2007
72648 Posts |
![]() Quote:
Some examples: from a command line type Code:
yafu-64k-x64 from a command line type Code:
yafu-64k-x64 "siqs(*number*)" Code:
yafu-64k-x64 "ecm(*number*,*num_curves*)" expanding on this theme, from a command line type Code:
yafu-64k-x64 -batchfile filename Or you could use redirection, as Karl is doing. There are many other flags you can optionally add after the command (siqs(), ecm(), etc), such as -v, -threads, or options to control the ecm,p +/- 1 bounds, and so forth. these are documented in docfile.txt. Code:
yafu-64k-x64 "siqs(*number*)" -v -threads 4 -rhomax 1000000 Hope this helps. Last fiddled with by bsquared on 2010-12-25 at 16:03 Reason: fix some syntax |
|
![]() |
![]() |
![]() |
#7 |
Basketry That Evening!
"Bunslow the Bold"
Jun 2011
40<A<43 -89<O<-88
3·29·83 Posts |
![]() Code:
Issuing the command 'help funcname' will bring up more detailed help on a particular function. Code:
Type help at any time, or quit to quit >> help primes searching for help on 'primes' >> help prime searching for help on 'prime' >> help factor searching for help on 'factor' >> help searching for help on 'help' >> Last fiddled with by Dubslow on 2012-03-28 at 00:46 |
![]() |
![]() |
![]() |
#8 | |
"Ben"
Feb 2007
22·941 Posts |
![]() Quote:
All it does is print the relevant section in docfile.txt, which should have been packaged in the download file. Open it in your favorite text editor and search for the term you want. |
|
![]() |
![]() |
![]() |
#9 | |
Basketry That Evening!
"Bunslow the Bold"
Jun 2011
40<A<43 -89<O<-88
722110 Posts |
![]() Quote:
![]() Thanks. Edit: Something else that I couldn't figure out what was wrong: Code:
-pscreen Adding this flag causes the primes() function to output primes to the screen Code:
bill@Gravemind:~/yafu∰∂ yafu -pscreen primes() bash: syntax error near unexpected token `(' bill@Gravemind:~/yafu∰∂ yafu -pscreen primes(200) bash: syntax error near unexpected token `(' bill@Gravemind:~/yafu∰∂ yafu -pscreen "primes(200)" no switch detected bill@Gravemind:~/yafu∰∂ yafu -pscreen "primes()" no switch detected bill@Gravemind:~/yafu∰∂ yafu "primes()" invalid character in str2hexz not enough arguments, please specify min and max of range ans = 0 bill@Gravemind:~/yafu∰∂ yafu "primes(1,1000)" elapsed time = 0.0030 ans = 168 bill@Gravemind:~/yafu∰∂ yafu -pscreen "primes(1,1000)" no switch detected bill@Gravemind:~/yafu∰∂ yafu "primes(1,1000) -pscreen" unrecognized token: pscreen bill@Gravemind:~/yafu∰∂ yafu "primes(1,1000)" -pscreen elapsed time = 0.0030 ans = 168 bill@Gravemind:~/yafu∰∂ yafu 03/27/12 19:36:01 v1.30 @ Gravemind, System/Build Info: Using GMP-ECM 6.3, Powered by GMP 5.0.1 detected Intel(R) Core(TM) i7-2600K CPU @ 3.40GHz detected L1 = 32768 bytes, L2 = 8388608 bytes, CL = 64 bytes measured cpu frequency ~= 3494.445730 =============================================================== ======= Welcome to YAFU (Yet Another Factoring Utility) ======= ======= bbuhrow@gmail.com ======= ======= Type help at any time, or quit to quit ======= =============================================================== cached 78498 primes. pmax = 999983 >> primes(1,1000) -pscreen unrecognized token: pscreen >> primes(1,1000) elapsed time = 0.0031 ans = 168 >> help primes searching for help on 'primes' >> primes help searching for help on 'es help' >> help searching for help on 'help' >> quit bill@Gravemind:~/yafu∰∂ yafu help primes no switch detected Last fiddled with by Dubslow on 2012-03-28 at 01:55 |
|
![]() |
![]() |
![]() |
#10 |
"Ben"
Feb 2007
22×941 Posts |
![]() Code:
yafu "primes(0,1000,0)" -pscreen Last fiddled with by bsquared on 2012-03-28 at 03:39 |
![]() |
![]() |
![]() |
Thread Tools | |
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Yafu batch running | ThomRuley | YAFU | 15 | 2021-08-31 16:44 |
Running YAFU via Aliqueit doesn't find yafu.ini | EdH | YAFU | 8 | 2018-03-14 17:22 |
Running other programs while running Prime95. | Neimanator | PrimeNet | 14 | 2013-08-10 20:15 |
yafu-1.33 | bsquared | YAFU | 12 | 2012-11-08 04:12 |
yafu-1.32.1 | bsquared | YAFU | 21 | 2012-09-04 19:44 |