mersenneforum.org  

Go Back   mersenneforum.org > Math Stuff > Computer Science & Computational Number Theory > PARI/GP

Reply
 
Thread Tools
Old 2010-08-11, 23:46   #287
3.14159
 
3.14159's Avatar
 
May 2010
Prime hunting commission.

168010 Posts
Default

Random pseudoprime: 759932492170846988701 is pseudoprime to bases 2, 3, 5, 7, 11, and 13. By the way: Is there a world record for "largest composite pseudoprime"?

Also: I forgot how to write a Fermat pseudoprime generator.

Last fiddled with by 3.14159 on 2010-08-12 at 00:09
3.14159 is offline   Reply With Quote
Old 2010-08-12, 01:05   #288
CRGreathouse
 
CRGreathouse's Avatar
 
Aug 2006

3·1,993 Posts
Default

Quote:
Originally Posted by 3.14159 View Post
Random pseudoprime: 759932492170846988701 is pseudoprime to bases 2, 3, 5, 7, 11, and 13. By the way: Is there a world record for "largest composite pseudoprime"?
Not really, you can generate them essentially as large as you like.

Quote:
Originally Posted by 3.14159 View Post
Also: I forgot how to write a Fermat pseudoprime generator.
Depends on what you mean by "generator". Are you looking for a program that does the Fermat test? A program that generates all Fermat pseudoprimes in a range? A program that generates a Fermat pseudoprime at a given size? Something else?
CRGreathouse is offline   Reply With Quote
Old 2010-08-12, 11:37   #289
3.14159
 
3.14159's Avatar
 
May 2010
Prime hunting commission.

24×3×5×7 Posts
Default

Quote:
Originally Posted by CRGreathouse
Not really, you can generate them essentially as large as you like.
I see.

Quote:
Originally Posted by CRGreathouse
Depends on what you mean by "generator". Are you looking for a program that does the Fermat test? A program that generates all Fermat pseudoprimes in a range? A program that generates a Fermat pseudoprime at a given size? Something else?
A program that generates the Fermat pseudoprimes in a given range, that are pseudoprime to user-selected bases. (No need for a code snippet, I eventually remembered how to write it and saved it in the text document, along with the other functions.

Last fiddled with by 3.14159 on 2010-08-12 at 11:39
3.14159 is offline   Reply With Quote
Old 2010-08-12, 12:01   #290
science_man_88
 
science_man_88's Avatar
 
"Forget I exist"
Jul 2009
Dumbassville

20C016 Posts
Default

24m= 6np+(p-7)\right m=px+c
 24m=6np-(p+7)\right m=px+c ?
if(px+c==(4n-1)/3,(4\strike n -1)/3
for all remaining n that create primes print(2*n+3) these are Mersenne prime exponents

get this CRG ?

Last fiddled with by science_man_88 on 2010-08-12 at 12:57
science_man_88 is offline   Reply With Quote
Old 2010-08-12, 12:23   #291
3.14159
 
3.14159's Avatar
 
May 2010
Prime hunting commission.

110100100002 Posts
Default

An interesting application error:
Whenever I input 25326001, it returns that it is a 7-SPRP, when it is in fact reported "composite" using base 7. I verified that it was an error on the app. Now I see that this is an unreliable app, as it returns results that are clearly wrong.
3.14159 is offline   Reply With Quote
Old 2010-08-12, 13:10   #292
CRGreathouse
 
CRGreathouse's Avatar
 
Aug 2006

597910 Posts
Default

Quote:
Originally Posted by 3.14159 View Post
A program that generates the Fermat pseudoprimes in a given range, that are pseudoprime to user-selected bases. (No need for a code snippet, I eventually remembered how to write it and saved it in the text document, along with the other functions.
Ah. Hard task!
CRGreathouse is offline   Reply With Quote
Old 2010-08-12, 13:13   #293
CRGreathouse
 
CRGreathouse's Avatar
 
Aug 2006

3×1,993 Posts
Default

Quote:
Originally Posted by 3.14159 View Post
An interesting application error:
Whenever I input 25326001, it returns that it is a 7-SPRP, when it is in fact reported "composite" using base 7. I verified that it was an error on the app. Now I see that this is an unreliable app, as it returns results that are clearly wrong.
What script are you using to check? My isSPRP gives
Code:
>isSPRP(25326001,7)
%1 = 0
CRGreathouse is offline   Reply With Quote
Old 2010-08-12, 13:17   #294
science_man_88
 
science_man_88's Avatar
 
"Forget I exist"
Jul 2009
Dumbassville

838410 Posts
Default

Quote:
Originally Posted by science_man_88 View Post
24m= 6np+(p-7)\right m=px+c
 24m=6np-(p+7)\right m=px+c ?
if(px+c==(4n-1)/3,(4\strike n -1)/3
for all remaining n that create primes print(2*n+3) these are Mersenne prime exponents

get this CRG ?
sorry should be (4^n-1)/3 lol
oh and there shouldn't be 2 n equations lol.

Last fiddled with by science_man_88 on 2010-08-12 at 13:19
science_man_88 is offline   Reply With Quote
Old 2010-08-12, 13:32   #295
CRGreathouse
 
CRGreathouse's Avatar
 
Aug 2006

175B16 Posts
Default

Quote:
Originally Posted by science_man_88 View Post
24m= 6np+(p-7)\right m=px+c
 24m=6np-(p+7)\right m=px+c ?
if(px+c==(4n-1)/3,(4\strike n -1)/3
for all remaining n that create primes print(2*n+3) these are Mersenne prime exponents

get this CRG ?
Hmm. Unlike the diagrams, I feel like I'm close to understanding something. The first two lines are clearly related to your repeating theme,
24m+7=p(6n\pm1).

The lines themselves seem to be statements of the division algorithm. The first says that if 24m+1 is of the form p(6n+1), then p(6n+1)/24 = px + c, that is, p(6n+1) leaves a remainder of c when divided by p.

But wait, it doesn't matter which of the first two lines I choose -- px + c is always m. So the first two lines say that 24m+7 is composite (assuming that n > 0 and p > 1) and the third line says that m is (4n-1)/3.

OK, so m = (4n-1)/3 means 3m+1 = 4n, so the third line is saying that m\equiv1\pmod4. So let m = 4k+1, then 3(4k+1)+1=4n, so that n = 3k + 1.

The original composite is then 24m+7 = 24(4k + 1) + 7 = 96k + 31 and the Mersenne non-exponent is 2n+3 = 2(3k+1)+1=6k+3.

And indeed yes, this is correct: if k is a positive integer, then 6k+3 is not a Mersenne exponent. But this won't remove all bad exponents, of course.
CRGreathouse is offline   Reply With Quote
Old 2010-08-12, 13:34   #296
CRGreathouse
 
CRGreathouse's Avatar
 
Aug 2006

175B16 Posts
Default

Quote:
Originally Posted by science_man_88 View Post
sorry should be (4^n-1)/3 lol
oh and there shouldn't be 2 n equations lol.
Pity, since I just analyzed it without.

Re-write it with those corrections and I'll see what I can do.
CRGreathouse is offline   Reply With Quote
Old 2010-08-12, 13:39   #297
science_man_88
 
science_man_88's Avatar
 
"Forget I exist"
Jul 2009
Dumbassville

838410 Posts
Default

24m= 6tp+(p-7)\right m=px+c
 24m=6tp-(p+7)\right m=px+c ?
if(px+c==(4^n-1)/3,(4^\strike n -1)/3
for all remaining n that create primes print(2*n+3) these are Mersenne prime exponents.

Last fiddled with by science_man_88 on 2010-08-12 at 13:43
science_man_88 is offline   Reply With Quote
Reply

Thread Tools


Similar Threads
Thread Thread Starter Forum Replies Last Post
Why do I sometimes see all the <> formatting commands when I quote or edit? cheesehead Forum Feedback 3 2013-05-25 12:56
Passing commands to PARI on Windows James Heinrich Software 2 2012-05-13 19:19
Ubiquity commands Mini-Geek Aliquot Sequences 1 2009-09-22 19:33
64-bit Pari? CRGreathouse Software 2 2009-03-13 04:22
Are these commands correct? jasong Linux 2 2007-10-18 23:40

All times are UTC. The time now is 22:21.


Fri Aug 6 22:21:52 UTC 2021 up 14 days, 16:50, 1 user, load averages: 2.81, 3.24, 3.15

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