Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Geek Culture / Is 10 = 9.9999999... ??

Author
Message
mamaji4
21
Years of Service
User Offline
Joined: 24th Nov 2002
Location:
Posted: 2nd Sep 2008 01:36 Edited at: 2nd Sep 2008 01:42
Quote: "This test works for every even number in the data type range. Try it yourself and see.
"


Yeah. I tested it. Within the compiler data range it works.

Quote: "Post a working example."


I'm not sure the task is trivial.
After looking at one of the computational proofs mentioned on Wikipedia, it appears that they did the following:
They took every prime number p using the seive and computed an even number S(p). They then verified that S(p) - p is also a prime number q

i.e. They showed that
For any p prime there exists an even number S(p) such that
q = S(p) - p is prime

Whereas actually the Goldback conjecture requires you to show that
For any even number S there exists a prime p such that
q = S - p is prime
This is what my algorithm can do.

The difference between the two is that the second computational proof would show that for EVERY even number it is true, whereas the first only shows that for the series of even number S (p) this is
i
true,

where 1 <= i <= n where n denotes the first n prime numbers

However, I don't even know whether I should bother, considering there isn't any moolah attached to it now, as Chris pointed out.


Quote: "Is there a good way to test a huge number?"

I had found this research paper where some guys had developed a very fast proof of primality. I just can't remember where I had seen it. Of course proof of primality of very large numbers is of great importance and it might be more advisable to work on something like that.
PowerSoft
20
Years of Service
User Offline
Joined: 10th Oct 2004
Location: United Kingdom
Posted: 2nd Sep 2008 01:40
interesting points...

Based on your arguements Chris Phi or Pi should nt be used because they recur and therefore fill in the gaps for teenagers...

The Innuendo's, 4 Piece Indie Rock Band
http://theinnuendos.tk:::http://myspace.com/theinnuendosrock
Chris K
21
Years of Service
User Offline
Joined: 7th Oct 2003
Location: Lake Hylia
Posted: 2nd Sep 2008 02:05
@ Cash

Again, there is no reason to believe that your program will find a pair of primes for every even number. There may be some large even number that when input into your program (on a super-computer say, with a few terabytes of memory) will just break the program (every number it tests will not be prime).

@ Mamaji4

Quote: "Whereas actually the Goldback conjecture requires you to show that
For any even number S there exists a prime p such that
q = S - p is prime
This is what my algorithm can do."


Without a shadow of a doubt you are mistaken or lying.
You do not need to provide the algorithm, just provide the two primes that sum to make:

19247018947912512748126906489126489012648912046981568210561212547841269461829412

@ Powersoft

Err, I don't really see your point.
What I said was that arithmetic with recurring decimals is not strictly valid maths, merely a simple technique taught to children.

I mean seriously, what a fantastic stretch to say that I suggested Pi "shouldn't be used".

-= Out here in the fields, I fight for my meals =-
PowerSoft
20
Years of Service
User Offline
Joined: 10th Oct 2004
Location: United Kingdom
Posted: 2nd Sep 2008 02:08
You're point was against recuring decimals so by saying that it wasn't valid surely links in with the nature of the fact Pi recurs also?

but its too late to have a maths-debate tonight. Some other time maybe

The Innuendo's, 4 Piece Indie Rock Band
http://theinnuendos.tk:::http://myspace.com/theinnuendosrock
mamaji4
21
Years of Service
User Offline
Joined: 24th Nov 2002
Location:
Posted: 2nd Sep 2008 02:21 Edited at: 2nd Sep 2008 02:41
Quote: "Without a shadow of a doubt you are mistaken or lying.
You do not need to provide the algorithm, just provide the two primes that sum to make:

19247018947912512748126906489126489012648912046981568210561212547841269461829412"


For a number that large I'd still have convert the algorithm into code. Cleary computation of large numbers is not something you can do with a calculator.
In any case, for the problem statement my algorithm requires you to use the seive over an interval of the prime number space for very large numbers.

Also the largest computational verification at present is for an even number 10^14
I do believe you expect me to check for a 10^x
where the number is randomly generated by your fingers going berserk on the ten numeric keys of the keyboard while making sure the last digit of the number ended in a 0,2,4,6 or 8
Seppuku Arts
Moderator
20
Years of Service
User Offline
Joined: 18th Aug 2004
Location: Cambridgeshire, England
Posted: 2nd Sep 2008 02:21
But does Pi recur? (assuming you mean to infinity) I remember my Maths teacher telling me that for Pi to be recited in speech it would take 120 years (they had up to the 1000th digit postered on the wall). Now I do question the validity of what I was taught at school, because I don't think I recieved a brilliant education from there. But of course, if you can tell me that's utter rubbish, then I can be on my way knowing that may Maths teachers wasn't always reliable either.

You sir have the moral ambivalence of a mutated shrimp!
Diggsey
18
Years of Service
User Offline
Joined: 24th Apr 2006
Location: On this web page.
Posted: 2nd Sep 2008 12:05
pi never ends, but neither does it recur

[b]Yuor signutare was aresed by a deslyxic mud...
BOX2D V2 HAS HELP FILES! AND A WIKI!
PowerSoft
20
Years of Service
User Offline
Joined: 10th Oct 2004
Location: United Kingdom
Posted: 2nd Sep 2008 12:13
Ah that'll be it then

The Innuendo's, 4 Piece Indie Rock Band
http://theinnuendos.tk:::http://myspace.com/theinnuendosrock
Cash Curtis II
19
Years of Service
User Offline
Joined: 8th Apr 2005
Location: Corpus Christi Texas
Posted: 2nd Sep 2008 13:54 Edited at: 2nd Sep 2008 13:58
Quote: "Again, there is no reason to believe that your program will find a pair of primes for every even number. There may be some large even number that when input into your program (on a super-computer say, with a few terabytes of memory) will just break the program (every number it tests will not be prime)."


Tonight I'll set up a test program and output the results to a file. I'll let it run all night and I'll post the results tomorrow. I'll test for all integers up to 2,147,483,647.

Each one will check its finding. If a check is wrong then I'll add a notation to it. The thing is, every even number can be the sum of two primes so it always works. It probably won't get to 2,147,483,647 but I have no doubt it will get very high. I'll code it in something other than DBP as well for maximum speed. My method, though not the fastest, is sound.

This is all probably pointless. mamaji4 has mentioned 10^14 several times, I suspect that it's been verified up to that level. There's no way I can process primes that big. The primality test alone would hang the computer up for years. I'm not sure what kind of proof would prove that it would work for every number.

This all depends on the speed of the primality test. You don't even actually have to calculate every prime number, you can stop once you've found a match on both ends. So unless there's a fast way to accurately test the primality of a number in the range of 10^14 then there's no way to do it.


Come see the WIP!
Green Gandalf
VIP Member
19
Years of Service
User Offline
Joined: 3rd Jan 2005
Playing: Malevolence:Sword of Ahkranox, Skyrim, Civ6.
Posted: 2nd Sep 2008 14:29
Quote: "I'm not sure what kind of proof would prove that it would work for every number."


You are not alone. Obviously NOT one that checks every possible number.

The number theorists may have found ways of circumventing the naive tests so that they can be sure that the results hold up to some VERY large even number without checking them all - but we need a proof for all even numbers, not just the "few" you can check by computers.

Proofs of this sort of thing often rely on reducing the original problem to a number of smaller problems that CAN be solved - such problems might cover a wide range of even numbers, but clearly not, as yet, all of them. But I'm guessing, I'm not a number theorist.

Quote: "So unless there's a fast way to accurately test the primality of a number in the range of 10^14 then there's no way to do it."


You should be able to do that on your PC quite easily - you only need to check its divisibility by numbers up to its square root, i.e. up to about order 10^7 (and not even (!!) all of them).

But you do hit the computability problem somewhere with that approach.
Cash Curtis II
19
Years of Service
User Offline
Joined: 8th Apr 2005
Location: Corpus Christi Texas
Posted: 2nd Sep 2008 14:50
Quote: "You should be able to do that on your PC quite easily - you only need to check its divisibility by numbers up to its square root, i.e. up to about order 10^7 (and not even (!!) all of them)."

I knew I was doing something wrong! I was testing divisibility up to 1/2 the number but it just didn't feel right.

Silly as it might be this has gotten me curious. I'll report back.


Come see the WIP!
Chris K
21
Years of Service
User Offline
Joined: 7th Oct 2003
Location: Lake Hylia
Posted: 2nd Sep 2008 15:16 Edited at: 2nd Sep 2008 15:19
Ok let me give an example of a similiar theorem and it's proof.

Theorem:
n^4 + 64 is NEVER prime, for any value of n.

So, how could we go about proving this?
If I were to follow your method, I would write a computer program that calculated n^4 + 64, then checked if it was prime.

Does this tell us whether n^4 + 64 is never prime? No!! It only checks a few cases.

Does that matter?

Well, yes!

Consider a similiar theorem:
n^4 + 89 is NEVER prime.

Well, what about this one? Calculate a few a see if they come out prime - they probably won't.

But that's because you didn't get to; 105,560,010,089 - just over a hundred billion - which is prime.

----------------

So we managed to disprove the second theorem, but what about the first theorem?

n^4 + 64 is NEVER prime

We can PROVE this is true for EVERY n without ever calculating a value...

See, n^4 + 64 can be factorised as ( n^2 + 4n + 8 )( n^2 − 4n + 8 ).

So clearly it can NEVER be prime no matter HOW BIG n is, because it is always these two numbers multiplied together, and both of these numbers are bigger than one for every n.

------

Hopefully this gives you an idea of the difference between checking it is true for a few values and PROVING it is true for ALL values.

-= Out here in the fields, I fight for my meals =-
mamaji4
21
Years of Service
User Offline
Joined: 24th Nov 2002
Location:
Posted: 2nd Sep 2008 16:12 Edited at: 2nd Sep 2008 16:20
Yeah. That's right.
A FORMAL proof shows the theorem is true for all n
A COMPUTATIONAL proof CANNOT show that the theorem is true for all n
Simply because n is not finite
That's the jist of it.

Quote: "n^4 + 64 can be factorised as ( n^2 + 4n + 8 )( n^2 − 4n + 8 )."

From the 'loose' definition of a prime number, the only factors it can have are 1 and itself. (It was previously believed that 1 was prime but is now excluded from the set of primes)
Clearly, if you can show that neither of the factors is 1 for any n then the number is not prime.
For the above non-prime polynomial it can be shown for ALL n
That's the FORMAL proof for all n
Green Gandalf
VIP Member
19
Years of Service
User Offline
Joined: 3rd Jan 2005
Playing: Malevolence:Sword of Ahkranox, Skyrim, Civ6.
Posted: 2nd Sep 2008 18:03
I get the uneasy feeling there is a convergence of opinion here.
mamaji4
21
Years of Service
User Offline
Joined: 24th Nov 2002
Location:
Posted: 2nd Sep 2008 18:49
Quote: "I get the uneasy feeling there is a convergence of opinion here. "


Lol. Yeah. I alwasy call a spade a spade.
Cash Curtis II
19
Years of Service
User Offline
Joined: 8th Apr 2005
Location: Corpus Christi Texas
Posted: 3rd Sep 2008 01:09
I'm having great success with my new algorithm. I just calculated 10,000,000 and it took about 2 minutes. The result is 9,999,971 and 29. I've been testing it out and raising it a power each time and confirming that the numbers are indeed prime with Google. I'm going to add some more digits and let it run all night.

It it is worth anyone's time I'll upload the EXE here.


Come see the WIP!
Green Gandalf
VIP Member
19
Years of Service
User Offline
Joined: 3rd Jan 2005
Playing: Malevolence:Sword of Ahkranox, Skyrim, Civ6.
Posted: 3rd Sep 2008 01:55
This is going to keep you busy for quite some time.
Jeff032
17
Years of Service
User Offline
Joined: 13th Aug 2007
Location:
Posted: 3rd Sep 2008 05:00 Edited at: 3rd Sep 2008 15:46
I decided to give it a shot. I think your algorithm needs some help though, Curtis. Mine found 38807 unique sets of primes that add to 10,000,000 in 3.236 seconds. It's programmed in C#.

Unfortunately my approach seems to make it impossible to multithread it. Maybe I can get a slight performance boost in C++.

[EDIT] Well that figures, switching to C++ made it slower.

[EDIT] Mine scales really badly hmmm.....


Mine is designed to find all possible combinations or primes that add to a number. I bet I could get a fairly large speed increase if I only find the first one.

Since you seem to have mentioned cryptography, you guys are aware that the thing that makes RSA secure is that you need to find 2 large prime numbers that multiply into a huge number, correct?

Cash Curtis II
19
Years of Service
User Offline
Joined: 8th Apr 2005
Location: Corpus Christi Texas
Posted: 3rd Sep 2008 13:30
Well, I worked it down. Now I can find the prime pair for 100,000,000 in 15 milliseconds. It's 99999989 and 11. I'm having a problem displaying the results for numbers much larger though they still appear to be calculating correctly, I'll fix that when I get home.

Quote: "Mine found 38807 unique sets of primes that add to 10,000,000 in 3.236 seconds."

That's pretty amazing. Can you post the results?


Come see the WIP!
Chris K
21
Years of Service
User Offline
Joined: 7th Oct 2003
Location: Lake Hylia
Posted: 3rd Sep 2008 13:42
Quote: "Well, I worked it down. Now I can find the prime pair for 100,000,000 in 15 milliseconds. It's 99999989 and 11."


It sounds like you might have just lucked out there, I mean you only did 5 tests right?

How fast would it be if the only result was two more evenly sized primes?

-= Out here in the fields, I fight for my meals =-
Jeff032
17
Years of Service
User Offline
Joined: 13th Aug 2007
Location:
Posted: 3rd Sep 2008 15:16
Quote: "That's pretty amazing. Can you post the results?"


Thanks, they are attached.

Though what exactly is the point in finding primes that add to another number?

Attachments

Login to view attachments
Jeff032
17
Years of Service
User Offline
Joined: 13th Aug 2007
Location:
Posted: 3rd Sep 2008 15:58 Edited at: 3rd Sep 2008 15:59
Here's 291400 unique sets of primes that add to 100,000,000. That one took 86 seconds.

@Curtis, you must have a pretty fast algorithm to determine whether such a high number is prime that quickly.

The problem with mine is that it first calculates every single prime up until the specified number. (I wonder if I could make it faster by using the Sieve of <insert long non-English word here> )

Anyway, to test 1,000,000,000, it would currently require 2.5GB of memory

Attachments

Login to view attachments
Green Gandalf
VIP Member
19
Years of Service
User Offline
Joined: 3rd Jan 2005
Playing: Malevolence:Sword of Ahkranox, Skyrim, Civ6.
Posted: 3rd Sep 2008 19:50 Edited at: 3rd Sep 2008 20:32
Quote: "@Curtis, you must have a pretty fast algorithm to determine whether such a high number is prime that quickly."


Do you mean numbers of the order of 10^8? It should take no time at all to decide whether any given number of that magnitude is prime. You only have to check (at most) 5000 potential divisors (far less in fact if you find the potential prime divisors first and just check those, i.e. 2, 3, 5, 7, 11, 13, 17, etc).

More to the point, what algorithm are you using?

Edit Just re-read your post. I guess you are referring to the number Cash quoted, even so it shouldn't take long.
Chris K
21
Years of Service
User Offline
Joined: 7th Oct 2003
Location: Lake Hylia
Posted: 3rd Sep 2008 19:54
Remember to just use the mod operator as well, rather than actually dividing it.

-= Out here in the fields, I fight for my meals =-
Green Gandalf
VIP Member
19
Years of Service
User Offline
Joined: 3rd Jan 2005
Playing: Malevolence:Sword of Ahkranox, Skyrim, Civ6.
Posted: 3rd Sep 2008 20:33 Edited at: 3rd Sep 2008 20:47
Quote: "Remember to just use the mod operator as well, rather than actually dividing it."


Doesn't seem to work - except on integers (unless it's the print command playing up).

Edit Only seems to work on floats and integers, which isn't very helpful.
Cash Curtis II
19
Years of Service
User Offline
Joined: 8th Apr 2005
Location: Corpus Christi Texas
Posted: 3rd Sep 2008 21:05 Edited at: 3rd Sep 2008 21:15
Okay, my problem is fixed and my results are in.

I used the number 41234567890123456, which is 4.12345^16. The first primes that add up to that total are 29 and 41234567890123427. It took my program 28.985 seconds to accomplish that.

The purpose of this exercise wasn't to prove anything in particular, except that mamaji4 is totally making stuff up when he says things like...

Quote: "Also the largest computational verification at present is for an even number 10^14"


I had suspected it, I just like a hands on discovery approach. One reason that my algorithm took so long is because I'm using such large data types for everything, 8 byte quads. I think I'll quit now, because this has been done to death on super computers with thousands of digits, not just my measly 17.

A proof isn't possible because there is no pattern, and for a proof you'd need a pattern that could be reduced to a formula for all cases. There is a tendency though when matching primes, which allowed me to streamline the process considerably from when I first started.


Come see the WIP!
Green Gandalf
VIP Member
19
Years of Service
User Offline
Joined: 3rd Jan 2005
Playing: Malevolence:Sword of Ahkranox, Skyrim, Civ6.
Posted: 3rd Sep 2008 23:07
Quote: "It took my program 28.985 seconds to accomplish that."


I'm impressed.

Thought I'd see what I could do - and stumbled across a bizarre problem. Here's the code I was using:



That code seems to work fine for all the values of x I tried - until I try to use Cash's prime number. Then it exits silently and instantly. I'm totally baffled.

Any ideas?
Jeff032
17
Years of Service
User Offline
Joined: 13th Aug 2007
Location:
Posted: 3rd Sep 2008 23:34 Edited at: 3rd Sep 2008 23:35
The way mine works is that it first generates a list of primes up to the specified number, using the previous primes to determine whether each number is prime, as you said, Green Gandalf. That takes 99% of the time. Then it just quickly searches through the list of primes for ones that add to the given number.

33 minutes for finding somewhere around 225,000 possibilities for 1,000,000,000.

Maybe I'll try the method you guys are using later.

I'd take a look at your code, but I haven't reinstalled DBPro yet.

Green Gandalf
VIP Member
19
Years of Service
User Offline
Joined: 3rd Jan 2005
Playing: Malevolence:Sword of Ahkranox, Skyrim, Civ6.
Posted: 3rd Sep 2008 23:48
Quote: "I'd take a look at your code, but I haven't reinstalled DBPro yet."


Don't worry. I'm sure I've stumbled across either a bug or a machine problem. I've now been able to narrow down where it fails (I think) on this machine. I can now test the same code on my laptop and/or narrow it down further. Watch this space.

No wonder few of us actually finish anything.
mamaji4
21
Years of Service
User Offline
Joined: 24th Nov 2002
Location:
Posted: 3rd Sep 2008 23:59 Edited at: 4th Sep 2008 00:04
Quote: "The purpose of this exercise wasn't to prove anything in particular, except that mamaji4 is totally making stuff up when he says things like...
"


What purpose would it serve me to lie about other people's computational results. I just quoted what I roughly remembered.
The actual number is more like 10^18
The largest even number verified is 906030579562279642 and one of the primes is 9341
http://www.ieeta.pt/~tos/goldbach.html
I also found this link from Wikipedia, so I have no idea whether larger even numbers have been verified for.

The reason I made the original statement is because Chris gave me an even number that is almost 100 digits long and asked me to obtain primes p and q for it, and I remember that it was somewhere in the range 10^14. Of course human memory is fallible.
Cash Curtis II
19
Years of Service
User Offline
Joined: 8th Apr 2005
Location: Corpus Christi Texas
Posted: 4th Sep 2008 00:40
I forgive you mamaji4

The largest number my program can handle is 9223372036854775807, which is 9.22337^18. I could modify it to handle larger numbers, but I'd have to use string math and that would slow it down substantially. It's a thought, though. First I'll try the max number for my program and see how long it takes.

@Jeff032 -
Your list is impressive and righteous. To be honest I was a little suspicious of your claim, but it was 100% true.

@Green Gandalf -
DBP coughs up a lung using large numbers sometimes. I'm not using DBP for this, I'm using Purebasic, which is extremely fast. I use it for anything like this. I love DBP but it wasn't meant for number crunching.

I'll post my program here for everyone to test sometime tomorrow, there's one potential stability problem that I discovered while running code in my brain (and my wife thinks I don't listen to her). I've not actually encountered it yet, but I might as well fix it before I release it.

I'm still very interested in this, I might modify it for numbers larger than 9^18, it would just be sickeningly slow. If there really is a limit at that range I'm naively interested in surpassing it. I don't think I will, aliens will find my computer in 1000 years and it still won't be done.


Come see the WIP!
Green Gandalf
VIP Member
19
Years of Service
User Offline
Joined: 3rd Jan 2005
Playing: Malevolence:Sword of Ahkranox, Skyrim, Civ6.
Posted: 4th Sep 2008 00:41
Quote: "Don't worry. I'm sure I've stumbled across either a bug or a machine problem. I've now been able to narrow down where it fails (I think) on this machine. I can now test the same code on my laptop and/or narrow it down further. Watch this space."


Problem confirmed on laptop. Looks like an obscure bug involving:

1. while statement
2. inc statement
3. double integers

Will post a DBPro bug report in a few minutes (need to trim down to the essential bits).
ionstream
20
Years of Service
User Offline
Joined: 4th Jul 2004
Location: Overweb
Posted: 4th Sep 2008 00:48
Quote: "The largest number my program can handle is 9223372036854775807, which is 9.22337^18. I could modify it to handle larger numbers, but I'd have to use string math and that would slow it down substantially. It's a thought, though. "


This is Python's time to shine! If you know Python and feel like porting your program, python can handle astronomically large numbers (try typing 2**100000 into a python console and see!) so it would be perfect for this. As an interpreted language though it is slower, but it would at least solve the huge number problem.

Jeff032
17
Years of Service
User Offline
Joined: 13th Aug 2007
Location:
Posted: 4th Sep 2008 00:59
@mamaji4
...wouldn't an 100 digit number be around 10^99?

When he asked you to object primes p and q for it, did he specify that p + q = num?

I would think that he was thinking about RSA encryption and therefore want you to find p * q = num, since the reason RSA is good is because there is no fast way to find the factors of huge numbers.

@Cash Curtis
Thank you
If you did want to make yours work with larger numbers, Java has a built in BigInteger class which has no limit in size. It would probably be slower though.

mamaji4
21
Years of Service
User Offline
Joined: 24th Nov 2002
Location:
Posted: 4th Sep 2008 01:46
Quote: "...wouldn't an 100 digit number be around 10^99?

When he asked you to object primes p and q for it, did he specify that p + q = num?"


Yeah. This was for verifying the Goldbach conjecture for very large even numbers, so it is the sum he is talking about, not the product.
Aaron Miller
18
Years of Service
User Offline
Joined: 25th Feb 2006
Playing: osu!
Posted: 4th Sep 2008 03:34
Quote: "This is Python's time to shine! If you know Python and feel like porting your program, python can handle astronomically large numbers (try typing 2**100000 into a python console and see!) so it would be perfect for this. As an interpreted language though it is slower, but it would at least solve the huge number problem."

2*100000 = 200000 which is... small in terms of "astronomically large numbers." What is the absolute largest number python can handle?

@Cash
I hope you removed safety code and safety arrays before building the program. Why not port it to C or C++, I bet you'll get a bit of a speed increase.

Cheers,

-naota

I'm not a dictator to those that do stuff for me by will. Only those who don't.
ionstream
20
Years of Service
User Offline
Joined: 4th Jul 2004
Location: Overweb
Posted: 4th Sep 2008 05:18
Quote: "2*100000 = 200000 which is... small in terms of "astronomically large numbers.""


The other asterisk is not a typo.

Jeff032
17
Years of Service
User Offline
Joined: 13th Aug 2007
Location:
Posted: 4th Sep 2008 06:19
** means raised to a power in Python?

ionstream
20
Years of Service
User Offline
Joined: 4th Jul 2004
Location: Overweb
Posted: 4th Sep 2008 06:39
Yeah, because ^ is already reserved for XOR.

Cash Curtis II
19
Years of Service
User Offline
Joined: 8th Apr 2005
Location: Corpus Christi Texas
Posted: 4th Sep 2008 08:30 Edited at: 5th Sep 2008 01:59
@Aaron Miller -
There's no such thing in Purebasic. There is, however, the debugger which silly me I forgot to disable for my final build. My above example of 4^16 now takes 3 seconds to complete and 4^18 takes 41.

I have an idea - make your own version in the language of your choosing and post it here, we'll see which one goes faster. I have a few modifications to make to mine and I'll post it in around 14 hours from now or so. It's a challenge of both skill and method.

It needs to be able to handle the same sized numbers (9223372036854775807, which is 9.22337^18) and produce the same results. There's a wealth of information here about it.

I'm going to add string number support to mine after this.


Come see the WIP!

Attachments

Login to view attachments
Green Gandalf
VIP Member
19
Years of Service
User Offline
Joined: 3rd Jan 2005
Playing: Malevolence:Sword of Ahkranox, Skyrim, Civ6.
Posted: 4th Sep 2008 13:30
Unfortunately it's going to be a pain in DBPro because of the long integer looping bug which Benjamin has managed to isolate (see DBP Bug Reports today). Might be able to work around it now we know where the problem lies.

I wonder where this thread will go next?
mamaji4
21
Years of Service
User Offline
Joined: 24th Nov 2002
Location:
Posted: 4th Sep 2008 16:13
Since proving P = NP is not the same as to prove NP = P
the entire community of brilliant mathematicians on TGC are going to attempt to prove or disprove at least one if not both of the above equalities.
Chris K
21
Years of Service
User Offline
Joined: 7th Oct 2003
Location: Lake Hylia
Posted: 4th Sep 2008 16:59
Quote: "I wonder where this thread will go next?"


How about we try and answer some of the Programming Olympiad questions!

They are awesome!!

http://www.hsin.hr/ioi2007/tasks/day1/aliens.pdf

I am just writing a template program for this task if anyone wants to try it.

-= Out here in the fields, I fight for my meals =-
tha_rami
18
Years of Service
User Offline
Joined: 25th Mar 2006
Location: Netherlands
Posted: 4th Sep 2008 18:26
You'll all end up murdered by big, corporate security companies.


A mod has been erased by your signature because it was larger than 600x120
Cash Curtis II
19
Years of Service
User Offline
Joined: 8th Apr 2005
Location: Corpus Christi Texas
Posted: 5th Sep 2008 01:46 Edited at: 5th Sep 2008 12:42
Here's the prime pair generator...

https://forumfiles.thegamecreators.com/download/1586020

Aaron Miller, I look forward to seeing yours.

Now I really need to stop wasting time on this and get back to work on GH. One day in the future I might try to expand it for larger numbers.

[Edit]
This is from the webpage link that mamaji posted with my program running in front...



That was a nice verification of my program's accuracy, 50.7 seconds. That "Error, prime array overflow." business is the safety check that I added. When it failed the first time it slowed it down some.

[Edit2]
Oh, mamaji4...

Quote: "What purpose would it serve me to lie about other people's computational results. I just quoted what I roughly remembered.
The actual number is more like 10^18
The largest even number verified is 906030579562279642 and one of the primes is 9341
http://www.ieeta.pt/~tos/goldbach.html
I also found this link from Wikipedia, so I have no idea whether larger even numbershttp://forum.thegamecreators.com/?m=forum_edit&i=1586020&b=2&t=135800&p=7 have been verified for."


You've completely misunderstood the information on that web page. The number is 9^17, but that has nothing to do with proving the Goldbach Conjecture. That's simply the number that produces the largest lower prime number of prime number pairs, which is 9341. You could take two prime numbers with 1000 digits each and add them together and they'd be even, all you'd have done is verify a very huge number working backwards which is just as good for a specific number. I tested it with the prime produced by that particular test with my program added to the next highest prime number, 9343. The first prime produced is 37. So even though a larger prime creates a combination it's not the first occurrence. In that test 9341 is the very first match for the number 906 03057 95622 79642.

As Jeff032 showed us there are lots and lots of combinations of primes that produce large numbers.


Come see the WIP!

Attachments

Login to view attachments
mamaji4
21
Years of Service
User Offline
Joined: 24th Nov 2002
Location:
Posted: 5th Sep 2008 15:48 Edited at: 5th Sep 2008 15:56
Quote: "that has nothing to do with proving the Goldbach Conjecture."


I believe what you are saying is that the people at this link should change the title of their webpage, which reads
"Goldbach conjecture verification"
http://www.ieeta.pt/~tos/goldbach.html

You might also like to edit the Wikipedia article in the 'External Links' section at
http://en.wikipedia.org/wiki/Goldbach's_conjecture


Regarding my actual opinion of what they have accomplished I had made an earlier post
Quote: "They took every prime number p using the seive and computed an even number S(p). They then verified that S(p) - p is also a prime number q

i.e. They showed that
For any p prime there exists an even number S(p) such that
q = S(p) - p is prime

Whereas actually the Goldback conjecture requires you to show that
For any even number S there exists a prime p such that
q = S - p is prime
This is what my algorithm can do.

The difference between the two is that the second computational proof would show that for EVERY even number it is true, whereas the first only shows that for the series of even number S(p) this
i

is true,

where 1 <= i <= n where n denotes the first n prime numbers
"
Green Gandalf
VIP Member
19
Years of Service
User Offline
Joined: 3rd Jan 2005
Playing: Malevolence:Sword of Ahkranox, Skyrim, Civ6.
Posted: 5th Sep 2008 23:02
Quote: "This is what my algorithm can do."


Prove it does what you say it does.
Aaron Miller
18
Years of Service
User Offline
Joined: 25th Feb 2006
Playing: osu!
Posted: 6th Sep 2008 02:44
I just saw this - thanks for pointing it out cash.

I'll get started when I can.

Cheers,

-naota

I'm not a dictator to those that do stuff for me by will. Only those who don't.
Cash Curtis II
19
Years of Service
User Offline
Joined: 8th Apr 2005
Location: Corpus Christi Texas
Posted: 6th Sep 2008 15:03
Quote: "This is what my algorithm can do."

Yes, I think that you should qualify this statement as well. Everyone else making claims in this thread has been very upfront with their results and methods, don't be the odd one out

@Aaron -
I'm always interested in different approaches to problems. I had fun doing it, you might as well.


Come see the WIP!
mamaji4
21
Years of Service
User Offline
Joined: 24th Nov 2002
Location:
Posted: 6th Sep 2008 21:05
Cash,

I tried out your generator and it works just fine.

Quote: "You'll all end up murdered by big, corporate security companies."

You know, tha_rami might be right, and we all might find ourselves looking down the wrong end of a sniper's rifle.

Login to post a reply

Server time is: 2024-11-20 16:18:22
Your offset time is: 2024-11-20 16:18:22