*** SEARCH FOR NINE CONSECUTIVE PRIMES IN ARITHMETIC PROGRESSION *** *** NEWSLETTER/1 *** *** 9 November 1997 *** Greetings everybody, *** CP09 VERSION 2.18 *** Version 2.18 of CP09 is now ready. It's certainly worth downloading because it is considerably faster than 2.17. Rates of around 1.1 billion per hour are now possible on a Pentium 166 and about 740 million per hour on a P120. So the 80-odd days I have been quoting for processing a trillion numbers on a P120 reduces to a mere 56. About 10 percent of the extra speed comes from my efforts to improve the Fermat test and from some minor enhancements to the sieve. A further 35 percent gain arises from a chance remark of Harvey Dubner that resulted in a slight rearrangement of the order of the Fermat tests. A simple - almost trivial - alteration that I had completely overlooked! If you are curious, have a look at the code in sv_ftest(). You will notice some file names have changed. The documentation is CP09DOC.TXT and the sample parameter file for testing is now shipped as CP09TEST.INI, not CP09.INI. So if you unzip CP09.ZIP into your "real work" directory, you won't destroy your current parameters. I have reduced the size of the prime number table from 400000 to 290000 and I recommend you do the same. With much improved Fermat testing strategy, we don't need to sieve so far. 290000 seems "about right" for a P120 and the program should now work comfortably on Windows 3.1 PC's with only 8M memory. Curiously, I found that throwing memory at the problem has no beneficial effect. I presume the reason is that once the sieve array becomes too big for the L2 cache, the program is forced to spend time waiting for memory access. For large primes (and most of them *are* large) the entire sieve array is accessed all over the place, completely at random - so any attempt to cache a small fraction of it is doomed to failure. *** PROGRESS *** Harvey (running CP09) has already found a set of 9 primes in arithmetic progression but it contains a couple of unwanted primes in between. So the nine primes are not consecutive and they are not quite what we are looking for. It's the first, and so far the only example and it's the one that appears if you run the test of CP09 version 2.18. *** WINDOWS 95 / NT *** I understand from one or two replies, that Windows 95 and Windows NT users are not getting the full benefit of the CPU. I'm afraid this is an area where I need help and I don't have access to either W95, or NT. However, if it's just a matter of compiling a version of CP09.EXE with the "yield" calls dummied out, I have done just that. If you are interested, please try using CP09W95.EXE instead of CP09.EXE and see if that runs any better. (It will also run under Windows 3.1 - and significantly faster - but the machine locks solid between print lines making it difficult to do anything else.) *** SYSTEM REQUIREMENTS *** Something I omitted from the documentation. CP09.EXE requires the 32-bit instruction set, so it definitely won't work on anything less than a 386. It also requires Windows 3.1 or one of its successors, WFWG, W95, NT. It definitely runs fine on Intel 486's and Pentiums and I can't think of any reason why it shouldn't run on 386's or non-Intel 486's, 586's, whatever. I just haven't tried it. You should have at least 8 megabytes memory on your system. I run it in the background on my "filing cabinet" - a 166MHz Pentium with 48M RAM. It seems to have little impact on any of my "word bashing" applications. However, I do notice it if I want to do any serious arithmetic. *** Tony Forbes