Ask Experts Questions for FREE Help!
  Advanced
Register  |  Log in  
   Ask    
 Answer  
  Help  

Ask QuestionsprogressAnswer QuestionsprogressBuild ReputationprogressBecome an Expert
 
Free Answers in 3 Easy Steps

Register Now
3 Steps

At Ask Me Help Desk you can ask questions in any topic and have them answered for free by our experts. To ask questions or participate in answering them you must register for a free account. By registering you will be able to:
  • Get free answers from experts in any of our 300+ topics.
  • Accept money for answers that you provide.
  • Communicate privately with other members (PM).
  • See fewer ads.

Home > Science > Mathematics   »   Pi by recursive decimal places

 
Thread Tools Display Modes
Question
 
 
#1  
Old Mar 30, 2004, 12:16 PM
retsoksirhc's Avatar
retsoksirhc
Senior Member
retsoksirhc is offline
 
Join Date: Mar 2004
Location: Michigan
Posts: 741
retsoksirhc See this member's comment history on his/her Profile page.
Send a message via AIM to retsoksirhc
Pi by recursive decimal places

I would like to know if there is a way to calculate pi by using the current last decimal place to calculate the next decimal place. I already made a formula for pi that i posted on another board, but someone suggested i copy here.

---Begin quote---
This doesnt really fit anywhere so I'm just putting it in general. Warning: not for the faint of math skillZ

I didn't want to do my work in Calculus today so decided to do something i've always wanted to: find an answer to Pi. There are probably many other and better formulas to calculate it, but it's not like I have a degree or somthing, and I came up with one by using simple algebra and trigonometry.

First my theory on how to calculate pi:

First take a regular geometric shape (a regular polygon). If you keep increasing the number of sides, it starts to look more and more like a circle (a regular polygon has all sides the same length). If you get enough sides on the polygon, eventually it becoms a circle, which would be infinity. Since we cannot reach the number infinaty, the closest we can do it get bigger and bigger. We can approch infinity.

Now consider the formula for the circumference of a circle (or perimeter):
C=2(pi)r

If we leave the radius as 1, the r of the equation becomes negligable.

Now back to the polygon. If we draw lines to the center of the polygon from each corner, we see what would be the radius of the circle if the shape had infinate sides. Make this lenth one and the r from the equation for circumference dissappears.

The problem i worked most at was how to find the perimeter of the polygon. I decided to use triangles

Using one side of the polygon and 2 lines drawn to the center, we get an isocolies triangle. The angles of the two outermost angles are determined by the sum of all the angles (180(n-2)) devided by the number of angles (n), and cut in half (they are bisected by the lines to the center). We subtract twice this value from 180 to get the angle measure of the innermost angle.

To get the length of the side from this we use the law of sines, used to find the side length or measure of any angle of side, given another angle and oppisite side, and one of the measures.

Recall that both other sides are 1, and both other angles are 180(n-2)/(2n)

From this we can get:
1/sin(180(n-2)/2n)=X/sin(180-2(180-2n)/2n)

Get X by itself and we now know what the length of one side is.

Multiply this by the numbe rof side to get the total perimiter of the polygon.

Looking back to the equation for circumference, C=2(pi)r:

perimeter=2(pi)(1)

Devide each side by 2 and we get a formula for the number pi. We still need to get close to an infinate number of sides, so we take this equation and find the limit as n approaches infinity:

limit as n->infinity of n(sin(180-(2(180(n-2)/2n))))/2(sin((180(n-2))/2n))=(pi)

We just found an equation for pi using basic trigonometry and geometry!
---End Quote---

Reply With Quote
 
     

Answers
 
 
Old May 12, 2004, 02:21 PM   #2  
New Member
glenvb is offline
 
Join Date: May 2004
Location:
Posts: 1
glenvb See this member's comment history on his/her Profile page.
Send a message via ICQ to glenvb
Re: Pi by recursive decimal places

Nice! Your basic idea is roughly similar to that of Archimedes, one of the first to calculate pi. He took the calculation to a 96-sided polygon, I believe. In the 15th century the Persian astronomer Jamshid al-Kashi computed pi to about 16 decimal places by taking this method out to a polygon of over 805 million sides. Yikes.
  Reply With Quote
 
     
 
 
Old Aug 23, 2007, 06:07 AM   #3  
New Member
matte is offline
 
Join Date: Aug 2007
Posts: 1
matte See this member's comment history on his/her Profile page.
2nrcos180((n-2)/(2n)) would be a more proper sollution actually for the distance around the polygon. Divide by 2 to get the value of pi.
  Reply With Quote
 
     
 
 
Old Aug 23, 2007, 12:50 PM   #4  
Ultra Member
ebaines is offline
 
Join Date: Apr 2007
Location: Illinois, US
Posts: 2,318
ebaines See this member's comment history on his/her Profile page.ebaines See this member's comment history on his/her Profile page.ebaines See this member's comment history on his/her Profile page.
This is a fine technique, although there's a crucial step missing in how to calculate the cosine or sine of the angles (assuming that like Archimedes you don't have a calculator). One could use an infinite series, for example:

sin(x) = x - x^3/3! + x^5/5! - x^7/7! + ...

but this is cumbersome, and requires a knowledge of calculus that I doubt the ancients had. So I wonder if they didn't use another technique, such as this: given the knowledge that cos(pi/4) = sqrt(2)/2, and the relationship cos(x) = sqrt[(cos(2x)-1)/2], you can play around using basic trig identities and you find that you get a neat recursive formula:



etc.

The length of the side of an n-sided polygon is 2* sin(pi/(n)), so if we choose polygons where each has twice the number of sides as its predecessor, the accuracy in determining pi is limited only by one's accuracy in calculating square roots. The formula for estimating the length of half the the perimeter (that is, pi) is:



We choose the value for N to be 1, 2, 4, 8, 16, etc., and what we find is that the approximation for pi converges pretty quickly to a reasonable level of accuracy:



etc.

Comments on this post
retsoksirhc agrees: Hmm. It took three years from my original post, but this is some damn good information relating to what I was asking. Thank you.
  Reply With Quote
 
     


Thread Tools
Display Modes

 
Similar Sponsors

Similar Threads
Question Asker Forum Answers Last Post
401k in two places Kboo79 Retirement 1 Jun 28, 2006 01:09 PM
Accessing FTP through My Network Places Kohoutek Internet & the Web 2 Feb 8, 2006 04:05 AM
Calculating pi to n decimal places reinsuranc Mathematics 3 Sep 14, 2005 06:18 PM
PVC Tight Places HELP! doghelms Plumbing 3 Jun 30, 2005 06:21 AM
Recursive Matlab problem Gemma82au Mathematics 1 Mar 22, 2003 10:02 AM




Copyright ©2003 - 2007, Ask Me Help Desk.
All times are GMT -8. The time now is 02:14 AM.