mersenneforum.org  

Go Back   mersenneforum.org > Prime Search Projects > Riesel Prime Search

Reply
 
Thread Tools
Old 2014-04-13, 16:27   #1
pepi37
 
pepi37's Avatar
 
Dec 2011
After 1.58M nines:)

24·3·37 Posts
Default How to calculate FFT lengths of candidates

I get this data from first megabit drive

554 candidates (144k: 49.8%, 160k: 50.2%)

Can someone tell me how to calculate K weight of candidate? What formula is used ( I sow that AVX uses some different approach)
pepi37 is offline   Reply With Quote
Old 2014-04-14, 08:26   #2
Thomas11
 
Thomas11's Avatar
 
Feb 2003

36008 Posts
Default

In principle the procedure is quite simple:
For each candidate in the input file the FFT length is obtained and then the percentages are computed.

In practise I'm using a small tool (see attachment) based on my "llrtools".
Attached Files
File Type: zip fft_percentage.zip (4.1 KB, 246 views)
Thomas11 is offline   Reply With Quote
Old 2014-04-14, 13:27   #3
Thomas11
 
Thomas11's Avatar
 
Feb 2003

27·3·5 Posts
Default

The attached file contains a binary for Windows machines.

Note that this is a command line tool. You'll need to run it from your DOS prompt:

Code:
fft_percentage.exe input.txt
Also note: The maxlen.txt file is for non-AVX machines.
Attached Files
File Type: zip fft_percentage_win32.zip (11.1 KB, 248 views)

Last fiddled with by Thomas11 on 2014-04-14 at 13:28
Thomas11 is offline   Reply With Quote
Old 2014-04-17, 11:18   #4
Thomas11
 
Thomas11's Avatar
 
Feb 2003

27×3×5 Posts
Default

Due to the recent interest (and also since the original LLR tools didn't contain the parameters for AVX machines), I'm posting here a Javascript version of the FFT length calculator - just a proof of concept, so don't expect any sophisticated piece of software...

It's a simple HTML file which you should be able to open in your favourite (Javascript enabled) web browser.

Usage is quite simple:
Enter the values for k, nmin and nmax, select the proper cpu type (avx, sse2, or x87) and hit the "Get FFT lengths" button.
Note that zero-padded FFTs use a different algorithm which is not yet implemented. Thus, for K>1000000 the points where the FFT lengths are changing are slightly different.

Feel free to further modify the code.
Attached Files
File Type: zip llrtools_js.zip (2.2 KB, 246 views)
Thomas11 is offline   Reply With Quote
Old 2014-04-17, 14:24   #5
pepi37
 
pepi37's Avatar
 
Dec 2011
After 1.58M nines:)

24×3×37 Posts
Default

I dont wont to be rude but since I ask this for candidates on base 10 this is pretty unusable for me :(
pepi37 is offline   Reply With Quote
Old 2014-04-17, 18:03   #6
Batalov
 
Batalov's Avatar
 
"Serge"
Mar 2008
San Diego, Calif.

1040310 Posts
Default

Quote:
Originally Posted by pepi37 View Post
I get this data from first megabit drive

554 candidates (144k: 49.8%, 160k: 50.2%)

Can someone tell me how to calculate K weight of candidate? What formula is used ( I sow that AVX uses some different approach)
Quote:
Originally Posted by pepi37 View Post
I dont wont to be rude but since I ask this for candidates on base 10 this is pretty unusable for me :(
Eh?

Must be the language barrier.

Anyway, just run this
Code:
# ./sllr64 -d -q"2*10^1059002-1"
Base factorized as : 2*5
Base prime factor(s) taken : 5
Starting N+1 prime test of 2*10^1059002-1
Using AMD K8 FFT length 224K, Pass1=896, Pass2=256, a = 2
...and kill it (Ctrl-C)! Problem solved.
(In fact, if you set up llr.ini properly and wait for a few seconds, you will also get the time per iteration, ... and then you kill it.)

On a different CPU, the FFT kernel and size may be different.

Repeat for random samples from your future work files. Plot. Scratch your forehead. Analyze. Plan ahead. Keep it simple.
Batalov is offline   Reply With Quote
Old 2014-04-17, 19:05   #7
pepi37
 
pepi37's Avatar
 
Dec 2011
After 1.58M nines:)

24·3·37 Posts
Default

Batalov, I truly love yours answers, and in fact that is way I found FFT length , start LLR , look at ,and stop it. But I was thinking if there is another ( faster way)....
pepi37 is offline   Reply With Quote
Old 2014-04-17, 20:50   #8
Batalov
 
Batalov's Avatar
 
"Serge"
Mar 2008
San Diego, Calif.

101×103 Posts
Default

You can of course,
- understand the LLR source (and GWNUM library that it calls)
- get the appropriate parts of the code and
- repackage them in a new program or a script that will "predict" what particular FFT size will be used.

You will have to update this accessory program every time the LLR+GWNUM changes, when there's a relevant change.

There is no magic single formula! - there are decision paths (if-else-if-else-if-else...) that the GWNUM library uses when it is called to initialize the FFT control structures for a number. Find and read the PrimeGrid topic about that: they initially considered this to be too tedious, but then surprisingly this is what they exactly did: pre-run each number for a split second to know exactly what FFT size will be used and based their credit system on that knowledge.
Batalov is offline   Reply With Quote
Old 2014-04-17, 20:51   #9
Thomas11
 
Thomas11's Avatar
 
Feb 2003

78016 Posts
Default

There is an undocumented feature in LLR. Just add the following line to your llr.ini file:
Code:
SetupOnly=1
Then you will no longer need to kill it...

However, for some forms the keyword is just ignored.
Thomas11 is offline   Reply With Quote
Reply

Thread Tools


Similar Threads
Thread Thread Starter Forum Replies Last Post
Area of a Triangle as a Function of the Lengths of its 3 Sides a1call Puzzles 17 2018-02-23 16:28
Lucas–Lehmer sequences and Heronian triangles with consecutive side lengths a nicol Math 1 2016-11-08 05:32
List of FFT Lengths (27.7 b2)? Belial88 Software 1 2012-11-12 16:37
new candidates for M...46 and M48 cochet Miscellaneous Math 4 2008-10-24 14:33
Hardware Failures at different FFT lengths? CADavis Hardware 8 2005-11-29 10:29

All times are UTC. The time now is 01:48.


Sat Sep 30 01:48:48 UTC 2023 up 16 days, 23:31, 0 users, load averages: 1.22, 1.22, 1.30

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2023, 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.

≠ ± ∓ ÷ × · − √ ‰ ⊗ ⊕ ⊖ ⊘ ⊙ ≤ ≥ ≦ ≧ ≨ ≩ ≺ ≻ ≼ ≽ ⊏ ⊐ ⊑ ⊒ ² ³ °
∠ ∟ ° ≅ ~ ‖ ⟂ ⫛
≡ ≜ ≈ ∝ ∞ ≪ ≫ ⌊⌋ ⌈⌉ ∘ ∏ ∐ ∑ ∧ ∨ ∩ ∪ ⨀ ⊕ ⊗ 𝖕 𝖖 𝖗 ⊲ ⊳
∅ ∖ ∁ ↦ ↣ ∩ ∪ ⊆ ⊂ ⊄ ⊊ ⊇ ⊃ ⊅ ⊋ ⊖ ∈ ∉ ∋ ∌ ℕ ℤ ℚ ℝ ℂ ℵ ℶ ℷ ℸ 𝓟
¬ ∨ ∧ ⊕ → ← ⇒ ⇐ ⇔ ∀ ∃ ∄ ∴ ∵ ⊤ ⊥ ⊢ ⊨ ⫤ ⊣ … ⋯ ⋮ ⋰ ⋱
∫ ∬ ∭ ∮ ∯ ∰ ∇ ∆ δ ∂ ℱ ℒ ℓ
𝛢𝛼 𝛣𝛽 𝛤𝛾 𝛥𝛿 𝛦𝜀𝜖 𝛧𝜁 𝛨𝜂 𝛩𝜃𝜗 𝛪𝜄 𝛫𝜅 𝛬𝜆 𝛭𝜇 𝛮𝜈 𝛯𝜉 𝛰𝜊 𝛱𝜋 𝛲𝜌 𝛴𝜎𝜍 𝛵𝜏 𝛶𝜐 𝛷𝜙𝜑 𝛸𝜒 𝛹𝜓 𝛺𝜔