Results
|
Choice
|
Votes
|
|
Percent
|
Yes, but no more than 100 digits
|
23
|
12.5%
|
|
Yes, but no more than 10,000 digits
|
7
|
3.8%
|
|
Yes, but no more than 1,000,000 digits
|
3
|
1.6%
|
|
Yes, but no more than 1,000,000,000 digits
|
8
|
4.3%
|
|
Yes, and it will be the largest calculation of pi the world has ever seen!
|
52
|
28.3%
|
|
How can you calculate pi with a computer?
|
74
|
40.2%
|
|
Pi? Huh?
|
17
|
9.2%
|
|
|
Re: Will you ever write a program to calculate pi?
|
Benjamin Moody
|
Mine's limited to the size of the 83's memory (4 bytes per base-100 digit, or 2 bytes per decimal digit), so while it can do a few more than 10000, it can't come close to 1000000.
|
Reply to this comment
|
14 March 2005, 15:12 GMT
|
|
Re: Will you ever write a program to calculate pi?
|
punkrockdude
|
Not to be a stupid idiot, but how would one go about writing a program to calculate Pi? (I usually write games, so this isn't really my field.)
|
Reply to this comment
|
14 March 2005, 21:27 GMT
|
|
|
|
|
|
|
|
|
|
|
Re: Re: Re: Re: Will you ever write a program to calculate pi?
|
no_one_2000_
(Web Page)
|
Well, two things
I read somewhere that thid method of calculating pi was really inefficient. Like, it takes a ridiculous amount of loops just to get a few digits of accuracy. That does make sense though if you think about 1/n. (Please correct me here if I'm wrong) You'll only have accuracy in pi n digits after the decimal point after you get to the (10^n/2)th loop. So, for just eight digits of accuracy, you'd need 50 million loops. That would take forever.
The other problem with this is, floating points only hold so many digits. I forget how many it is, but they're limited. If you wanted to calculate a lot of digits of pi, you'd need a much larger variable type to work with. Perhaps if you could somehow allocate a large section of memory as a "long long long ..." unsigned integer... I don't know how to do that though. I thought of using a large string when I wanted to make a problem like this a while back, but then I realized that the conversion of numbers to and from the string would take too long and would slow the program down even more.
Anyway, the only real experience I have in calculating pi with a computer is with this program I made in Java a few years back, and if I remember correctly, I only got 7-8 digits of accuracy with it. Sometime in the future I'll come up with a better plan though.
|
Reply to this comment
|
16 March 2005, 23:04 GMT
|
|
1 2 3 4
You can change the number of comments per page in Account Preferences.
|