1. Limited time only! Sign up for a free 30min personal tutor trial with Chegg Tutors
    Dismiss Notice
Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Homework Help: Taylor series approximation for pi

  1. Oct 24, 2015 #1
    1. The problem statement, all variables and given/known data
    I'll start by saying this is a "Challenge problem" from my professor, not technically homework, I hope I can still seek help.

    The problem,
    Part 1) Given a list of basic taylor series, find a way to approximate the value of pi.
    Part 2) After completing part 1, modify the series for faster convergence.

    2. Relevant equations

    As mentioned, I have a list of common Taylor series. The one I started with was the series for arctan(x) because it was the only one I have that can get pi as an output

    arctan x = x - x3/3 +x5/5 - x7/7 + ..........

    3. The attempt at a solution

    I feel like my attempt is pretty standard, I successfully completed Part 1 of the challenge by using the series for arctan (1) = pi/4

    arctan (1) = 1 - 1/3 + 1/5 - 1/7 +......... = pi/4


    pi = 4 - 4/3 + 4/5 - 4/7 + ............

    This series does approximate pi, however it is slow, using the first 10 terms gives 3.041839619

    My issue is that I can't come up with a method to complete part 2, I can't figure out a way to make it converge more quickly.

    I tried using the fact that
    arctan x + arctan y = arctan (x+y)/1-xy to break it into a pair, and I've had hit and miss results. For example when I used arctan(1/2) + arctan(1/3) = pi/4 then using 4 terms gave me pi = 3.14085, which gave 2 decimal accuracy quickly... So, instead of continuing with more terms, I thought that decreasing the fractional value would yield faster convergence. I then used the arctan addition formula and set arctan x = arctan 1/10. The formula gave me arctan y to be arctan (9/11).. So I used arctan (1/10) + arctan (9/11) = pi/4... Using this method actually hurt convergence, I actually erased these results because they were not an improvement, but I remember 5 terms not even resembling pi, I think it was 4.something.

    If you have any ideas that could push me in the right direction, let me know!!!
  2. jcsd
  3. Oct 24, 2015 #2


    User Avatar
    Staff Emeritus
    Science Advisor
    Homework Helper

    This Taylor series for π is spectacularly slow to converge: reportedly, after evaluating 500,000 terms, only 5 decimal digits of π will be returned.


    See the Gregory-Leibniz series for more discussion

    Your initial intuition to try another series was correct, but an initial disappointment scared you away from trying another series in the chain.

    The relation arctan (1/2) + arctan (1/3) = π/4 is not the only one which may be used to approximate pi.

  4. Oct 24, 2015 #3

    Thank you for this link!

    Also, just to clarify, I wouldn't describe myself as "scared away" due to my 2nd approximation not being an improvement. I was really just curious if the fractional process was a good direction to be headed, or if I should put my effort into another method. This link appears to have answered that question!

    Thank you!
  5. Oct 24, 2015 #4


    User Avatar
    Staff Emeritus
    Science Advisor
    Homework Helper

    We'll substitute "discouraged" for "scared away".
  6. Oct 24, 2015 #5
    That is fair.
Share this great discussion with others via Reddit, Google+, Twitter, or Facebook

Have something to add?
Draft saved Draft deleted