Re: need help on this problem.
- From: "Ingo R. Homann" <ihomann_spam@xxxxxx>
- Date: Fri, 09 Dec 2005 09:20:03 +0100
Hi,
Oliver Wong wrote:
(*) I suppose, for calculating this simulation, you need Pi! ;-)
This last point is the part that confused me the most. I assumed that you had to simulate throwing the pen, but for this simulation you need Pi, but since you're trying to compute pi, presumably you don't know Pi yet!
Yes, the question is: Is this a trick of the prof. or didn't she realise that, or does she think it is OK to use Pi to calculate Pi :-)
*Perhaps* (I'm not sure and I'm not a mathematican) it is possible to simulate the problem with a very rough approximation of Pi (say '1' ;-) and to get a better approximation of Pi by this (perhaps '3'). Then, run a new set of simulations to approximate it further. Perhaps that is a bad idea, perhaps it is possible. I just don't know, but I would consider thinking about that.
It did not occur to me that perhaps the assignment was to throw the pen in real life, and then write a computer program that kept track of how many line-crosses you got, and approximate Pi that way.
For this, you do not need a computer program - a simple pocket calculator (or even a piece of papaer an d a pen ;-) is enough! :-)
I'm also not sure where the "64 processors" part comes into play, unless this is actually an assignment on parallel programming.
Hm, you can simulate it in 64 different threads and mediate the result, which improves the precision you are able to calculate in a constant amount of time.
Ciao, Ingo
.
- Follow-Ups:
- Re: need help on this problem.
- From: Ingo R. Homann
- Re: need help on this problem.
- References:
- need help on this problem.
- From: Edward . Huerta
- Re: need help on this problem.
- From: Ingo R. Homann
- Re: need help on this problem.
- From: Oliver Wong
- need help on this problem.
- Prev by Date: Re: ArrayList -- cumulatively calculates??
- Next by Date: Re: newbie question about java's syntax
- Previous by thread: Re: need help on this problem.
- Next by thread: Re: need help on this problem.
- Index(es):
Relevant Pages
|