20200717, 21:18  #1  
Nov 2016
B04_{16} Posts 
Changes to srsieve2
Quote:
Can someone remove srsieve divisible by 2 check? (see https://github.com/xayahrainie4793/m...master/srsieve), I want to prove the extended Sierpinski/Riesel problems (Finding and proving the smallest k such that (k*b^n+1)/gcd(k+1,b1) (+ for Sierpinski,  for Riesel) is not prime for all integers n>=1), these Sierpinski/Riesel conjectures extended the CRUS Sierpinski/Riesel conjectures to the k such that gcd(k+1,b1) (+ for Sierpinski,  for Riesel) is not 1, since k*b^n+1 is always divisible by gcd(k+1,b1), it is simply to take out this factor, however, I cannot use srsieve to sieve the case which k and b are both odd (e.g. it returns ERROR: 13*43^n1: every term is divisible by 2" for R43 k=13), it can only sieve the case which at least one of k and b are even (e.g. sieve file for R36), can someone remove srsieve divisible by 2 check to let me sieve and reserve the odd Sierpinski/Riesel bases (e.g. S3, currently S3 has these k's remaining: 1187, 1801, 3007, 3047, 3307, 5321, 5743, 5893, 6427, 6569, 6575, 7927, 8161, 8227, 8467, 8609, 8863, 8987, 9263, 9449, see https://docs.google.com/document/d/e...UF8OgSUVsS/pub)? Last fiddled with by Uncwilly on 20200717 at 21:55 Reason: TRIM YOUR QUOTES 

20200717, 22:56  #2 
"Mark"
Apr 2003
Between here and the
1867_{16} Posts 
If the candidates are divisible by 2, then they are composite and srsieve will remove them. I see zero reason for srsieve to behave differently.

20200718, 06:22  #3  
May 2007
Kansas; USA
2×5×1,031 Posts 
Quote:
There is no reason for srsieve to immediately error out candidates that are divisible by 2 since it should automatically remove them anyway in the normal course of sieving. By automatically errorring them out such tests that he is referring to cannot be properly sieved. It would be like having srsieve automatically erroring out candidates that are divisible by 3 before doing actual sieving on them. It is an uneccesary error check that prevents other kinds of sieving from being done. Last fiddled with by gd_barnes on 20200718 at 06:23 

20200718, 17:23  #4 
"Mark"
Apr 2003
Between here and the
6,247 Posts 
For srsieve if one inputs multiple sequences to srsieve and at least one sequence has "all terms divisible by x", that it won't sieve the other sequences. I can see why that would be a problem.
Have you considered srsieve2? Chances are that it is faster than srsieve and I believe that one of its output formats is compatible with sr2sieve, which is faster than srsieve2 when using Legendre tables. 
20200720, 21:40  #5 
May 2007
Kansas; USA
2×5×1,031 Posts 
Please change srsieve to remove the error check for divisibility by 2 and then force the regular sieve process to remove the terms divisible by 2 instead. Is that really difficult? It seems like a simple fix. I'm pretty sure I or others have requested this before and we seem to keep getting the runaround about it.
To be more specific below is what Sweety and I and others want to do when attempting to test a conjecture such as (13*43^n1)/2 if the form is not found to have a smallish prime using simple trial factoring with PFGW. 1. Sieve using srsieve using the form 13*43^n1 but with a starting sieve depth of 3 using the following command: srsieve G p 3 P 1e9 n 25e3 N 100e3 m 1e9 "13*43^n1" This tells srsieve to only sieve the form for P=3 to 1e9. That way it does not remove the terms that are divisible by 2 (which would be all of them in this case). 2. Test with PFGW using a standard PFGW header of: (ABC $a*43^$b1)/2 // {number_primes,$a,1} 13 25007 13 25019 (etc.) This allows us to both sieve and test the form (13*43^n1)/2. Srsieve currently works for us if we have a form with a prime divisor other than 2 such as (13*46^n1)/3. In that case we would just have it sieve the range of P=5 to 1e9 and there would be no error as there is in the case of (13*43^n1)/2. Does this make sense? [ All of these are examples. They are not actual work done.] If this cannot be done please let us know and we will not request it anymore. We would prefer not to have to run a separate program when standard srsieve will work for 99% of cases like this. Also please let us know how you would sieve the form (13*43^n1)/2. That would be very helpful. Last fiddled with by gd_barnes on 20200720 at 21:51 
20200720, 23:59  #6 
"Mark"
Apr 2003
Between here and the
6,247 Posts 
Originally the ask was to "remove the check". Now you are asking for software to sieve (k*b^n+c)/d. Although similar, they are not the same. I don't recall anyone asking for this feature before.
For now I have given you a workaround that can be used for d = 2 which is what the original ask was. Why isn't that acceptable? You mention that this forces you to use srsieve for some sequences and srsieve2 for others. Why not srsieve2 for all sequences? AFAIAC, srsieve is deprecated. sr1sieve and sr2sieve are not. My intention is to add new features to srsieve2, not srsieve. If bugs are found in srsieve then I will certainly fix them, but I'm not inclined to add new features to it. 
20200721, 02:45  #7  
May 2007
Kansas; USA
10310_{10} Posts 
Quote:
Please provide a specific example of how we should sieve (13*51^n1)/2 by sieving 13*51^n1. Please state the program to use and the command to use. Assume I'm a newbie because I am when it comes to srsieve2. No we've never asked for srsieve (or srsieve2) to sieve (k*b^n+c)/d. I was just showing an example of what we could sieve with srsieve if the error check for divisibility by 2 is removed. We are just asking for the error check for all candidates divisible by 2 to be removed and then be included in the regular sieving looping process of all other prime factors. I have used srsieve2 a few times. I find it to be no faster than sr2sieve and find it somewhat more cumbersome to use. I don't care for the fact that the Prate that it uses is the number of prime factors that it has searched in the last minute whereas the Prate in srsieve is the Prange that it has searched in the last minute. IMHO the latter is much preferable. I still use srsieve/sr1sieve/sr2sieve for that reason. Why are you suggesting that we use srsieve2 when you do not know if it will work for what we are asking? Edit: I just tried srsieve2 with the following command: srsieve2 p 3 P 1e6 n 25e3 N 100e3 s "13*51^n1" It errored out with: All terms for sequence 13*51^n1 are divisible by 2 Fatal Error: All sequences have been removed So my question is: Why does it error out when I have not included p=2 in the the sieve range ? It should not do that. For the same reason that srsieve should not do that. Sieving 13*51^n1 by not including the factor of 2 is our way of sieving (13*51^n1)/2. Does that make sense? Last fiddled with by gd_barnes on 20200721 at 03:12 

20200721, 12:47  #8  
"Mark"
Apr 2003
Between here and the
6,247 Posts 
Quote:
I will change srsieve2 to sieve (k*b^n+c)/d for any d. That would allow srsieve2 to benefit other users as it will be able to sieve a few repunit sequences. Regarding "p per second", the value it shows is rather useless. The factor rate and estimated completion time are far more important. For srsieve I will change the current error condition to a warning (it is a warning in srsieve2), but cannot guarantee that starting with p3 will not remove terms divisible by 2. 

20200724, 23:09  #9  
May 2007
Kansas; USA
2·5·1,031 Posts 
Quote:
That would be great for srsieve2 Mark! When you are done please post the executable here and I will test it as best as I can. Last fiddled with by gd_barnes on 20200724 at 23:09 

20200725, 00:32  #10 
"Mark"
Apr 2003
Between here and the
6,247 Posts 

20200802, 15:35  #11 
"Mark"
Apr 2003
Between here and the
6247_{10} Posts 
Question. If k*b^n+c is not evenly divisible by d, should those terms removed prior to sieving?
