Monte Carlo methods are a class of computational methods that rely on repeated random sampling to compute their results. In this problem, you will use the Monte Carlo method to estimate the temperature at an arbitrary point in a uniform solid. Specifically, we will consider the solid object shown below. The temperatures of all surfaces are 500 des F with the exception of the two shaded surfaces, which are at 0 deg F. Inputs to the program should be: 1. The number of random walkers. 2. The (x,,2) coordinates of the point at which the temperature is to be estimated. 3. Plot interval (eg., you may want 1,000,000 random walkers in the simulation but may want to plot after every 10,000). Output from the program should be: 1. A graph of the estimated temperature, plotted according to the plot interval 2. Numerical value of the estimated temperature.
Monte Carlo methods are a class of computational methods that rely on repeated random sampling to compute their results. In this problem, you will use the Monte Carlo method to estimate the temperature at an arbitrary point in a uniform solid. Specifically, we will consider the solid object shown below. The temperatures of all surfaces are 500 des F with the exception of the two shaded surfaces, which are at 0 deg F.
Inputs to the program should be:
1. The number of random walkers.
2. The (x,,2) coordinates of the point at which the temperature is to be estimated.
3. Plot interval (eg., you may want 1,000,000 random walkers in the simulation but may want to plot after every 10,000).
Output from the program should be:
1. A graph of the estimated temperature, plotted according to the plot interval
2. Numerical value of the estimated temperature.
Trending now
This is a popular solution!
Step by step
Solved in 4 steps with 4 images