The Grey Labyrinth is a collection of puzzles, riddles, mind games, paradoxes and other intellectually challenging diversions. Related topics: puzzle games, logic puzzles, lateral thinking puzzles, philosophy, mind benders, brain teasers, word problems, conundrums, 3d puzzles, spatial reasoning, intelligence tests, mathematical diversions, paradoxes, physics problems, reasoning, math, science.

   
The Grey Labyrinth Forum Index
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups    RegisterRegister  
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Is 1000000027 prime?

 
Reply to topic    The Grey Labyrinth Forum Index -> Visitor Submitted Puzzles
View previous topic :: View next topic  
Author Message
Jingle47
Daedalian Member



PostPosted: Tue Apr 16, 2002 4:33 am    Post subject: 1 Reply with quote

I am doing a little digging and am working with prime factorizations.
What I reall want to know is how YOU figure out if the following number is prime.
100000000000000000207

I actually already know whether it is prime or not, I am more interested in your approach(es).
I would appreciate any help I can get and who knows you might find it fun to do anyway!
Back to top
View user's profile Send private message Send e-mail
Chuck
Daedalian Member



PostPosted: Tue Apr 16, 2002 7:09 am    Post subject: 2 Reply with quote

I used a program called PRNTEST1.UB that came with the UBasic programming language that I found online somewhere months ago. I don't know how it works. It says 100,000,000,000,000,000,207 is prime.
Back to top
View user's profile Send private message Send e-mail Visit poster's website AIM Address
ctrlaltdel
Member of the Daedalians



PostPosted: Tue Apr 16, 2002 7:37 am    Post subject: 3 Reply with quote

is there a way 'around' the problem?

say i look at the big number and say:

207 is not a prime, 207 = 23 x 3 x 3

now if 10000000000000000000 is divisible by either 23 or 3 then the whole number is not a prime

if its not tho... then i guess i don't know yet

anyways an approach like this maybe totally misleading only because of the bunch of zeros i try to enforce it on the problem. if the number was something like 13215746545135464316545207 i'd be stuck with the brute force efforts.

[This message has been edited by ctrlaltdel (edited 04-16-2002 03:39 AM).]
Back to top
View user's profile Send private message Visit poster's website
groza528
No Place Like Home



PostPosted: Tue Apr 16, 2002 7:55 am    Post subject: 4 Reply with quote

It may be a difference of two squares, in which case it is not prime. That's probably the first thing I'd check is what's the next square, and then find the difference between the two. Unfortunately I'm too lazy to do that.
Is that supposed to be ...00207 or ...027?
Back to top
View user's profile Send private message Send e-mail AIM Address
groza528
No Place Like Home



PostPosted: Tue Apr 16, 2002 7:55 am    Post subject: 5 Reply with quote

If ...027 there's probably a difference of two cubes formula
Back to top
View user's profile Send private message Send e-mail AIM Address
mole
Subterranean Member



PostPosted: Tue Apr 16, 2002 9:21 am    Post subject: 6 Reply with quote

13215746545135464316545207 is not prime.
Back to top
View user's profile Send private message Send e-mail
CrystyB
Misunderstood Guy



PostPosted: Tue Apr 16, 2002 10:19 pm    Post subject: 7 Reply with quote

Groza, except 10^20 is not a cube
Back to top
View user's profile Send private message Visit poster's website Yahoo Messenger
Quailman
His Postmajesty



PostPosted: Tue Apr 16, 2002 10:26 pm    Post subject: 8 Reply with quote

If it had nine or fewer digits, I would look here.
Back to top
View user's profile Send private message Send e-mail
CzarJ
Hot babe



PostPosted: Wed Apr 17, 2002 1:38 am    Post subject: 9 Reply with quote

Oh, I read about stuff like this in a book! I don't really understand how it works, though

------------------
Speaking of which, describe your favorite pair of pants.
Back to top
View user's profile Send private message Send e-mail AIM Address
Jingle47
Daedalian Member



PostPosted: Wed Apr 17, 2002 5:01 am    Post subject: 10 Reply with quote

I found out the answer using a program called Maple 6.
But I am kind of curious how Maple found the answer.
Back to top
View user's profile Send private message Send e-mail
SaberKitty
one can always be hopeful...


PostPosted: Wed Apr 17, 2002 5:06 am    Post subject: 11 Reply with quote

I don't knwo the answer, but I just wanted to post this site because it's really cool The Great Internet Mersenne Prime Search(GIMPS Homepage)
-admits she's a geek -
Back to top
View user's profile Send private message Send e-mail
Griffin
Daedalian Member



PostPosted: Wed Apr 17, 2002 8:30 pm    Post subject: 12 Reply with quote

Jingle - It probably used one of the "primality tests" found at this site:

http://www.utm.edu/research/primes/prove/proving.html
Back to top
View user's profile Send private message Send e-mail
jamesshuang
Icarian Member



PostPosted: Tue Apr 23, 2002 7:15 pm    Post subject: 13 Reply with quote

TI-89 calculators rule. They are great for finding primes. 100000000000000000207 is actually prime, by the way.
Back to top
View user's profile Send private message
extropalopakettle
No offense, but....



PostPosted: Thu Apr 25, 2002 2:29 am    Post subject: 14 Reply with quote

Here's a java program to test if any integer is prime or not:
code:

import java.math.BigInteger;

class testPrime
{
public static void main(String[] args)
{
BigInteger n = new BigInteger(args[0]);
if (n.isProbablePrime(30))
System.out.println("PRIME");
else
System.out.println("COMPOSITE");
}
}



The constant 30 can be changed. The higher it is, the less likely it is you'll get a false positive (positive=prime). You'll never get a false negative. For a value of X, the probability that a positive result is false is less than 1/2^X.
Back to top
View user's profile Send private message
Display posts from previous: by   
Reply to topic    The Grey Labyrinth Forum Index -> Visitor Submitted Puzzles All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group
Site Design by Wx3