1 Replies - 3214 Views - Last Post: 23 August 2012 - 01:48 AM Rate Topic: -----

#1 KirbyMisa  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 1
  • Joined: 12-August 12

Problem to Calculate Approximate "Terms" for Pi

Posted 12 August 2012 - 09:36 AM

I am trying to write a small program which calculates approximate "Term" for the Pi. For example, I want to find the term of 3.14 or 3.141, how many terms it would be? I got most of the code but can't figure out how to find exact value. Here is the code. Any help will be appreciated. Thanks

Dim counter As Integer

position = 0
total = 1

While counter is odd
If term = 4 / position then
Total = total + term
Else
Total = Total - Term
Wend
End Sub

This post has been edited by Atli: 12 August 2012 - 10:52 AM
Reason for edit:: Fixed the [code] tags.


Is This A Good Question/Topic? 0
  • +

Replies To: Problem to Calculate Approximate "Terms" for Pi

#2 Aprone  Icon User is offline

  • New D.I.C Head

Reputation: 2
  • View blog
  • Posts: 11
  • Joined: 07-May 12

Re: Problem to Calculate Approximate "Terms" for Pi

Posted 23 August 2012 - 01:48 AM

Kirby, what do you mean by "Term"? In math, the meaning to the word "term", as I understand it, doesn't make much sense here. If you could give a little more of an explanation then it would help us help you I think.
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1