Question: 32. (a) The MatLab exercise from week 1 asked you to simulate an experiment in which a fair dice is thrown N times and the

 32. (a) The MatLab exercise from week 1 asked you to

simulate an experiment in which a fair dice is thrown N times

32. (a) The MatLab exercise from week 1 asked you to simulate an experiment in which a fair dice is thrown N times and the sample mean is calculated, and this experiment is then repeated 10,000 times. The objective of the exercise was to estimate how large N must be for the sample mean to be within 0.2 of the expected value for 95% of the experiments. A solution is as follows (some of the comments have been removed) 1 E=10000; % E is the number of experiments 2 N = 200; % N is the number of throws per experiment 3 e=0.2; %e is the error 4 A=randi ([1 6], E,N); 5 B=mean (A, 2); 6 Y=sum (B (abs (B-3.5)

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!