Bailey, Borwein and Plouffe

The Task

Mathematicians Bailey, Borwein and Plouffe created a formula to find the digits of pi in 1995.  As you know, pi is an irrational number which cannot be described as the sum simple of fractions.    The BBP formula is

  Write a program to calculate the first 100 digits of pi and output pi to the screen.  Use a function to calculate the last term to the power of n.  Compare the value produced with the value given to pi by your program. Don’t be put off by the equation – just break it down into simple parts and bring them back together at end.  You want to use a loop of some description to get from k = 0 to 100. Credit: Blundell@MonktonCoombe

About CDB 362 Articles
Self-Employed Software Developer, Spark, Property Management, Hobby Forestry, Ex-Teacher, Engineering - Wood, Metal, Electrics & Computers. Outdoors - Walk, Cycle, Kitesurf,

Be the first to comment

Leave a Reply

Your email address will not be published.


*


This site uses Akismet to reduce spam. Learn how your comment data is processed.