Question: Write a MATLAB program to simulate the following experiments. (a) Draw a dice 100 times. That is, generate a sequence of 100 random numbers

Write a MATLAB program to simulate the following experiments. (a) Draw a  

Write a MATLAB program to simulate the following experiments. (a) Draw a dice 100 times. That is, generate a sequence of 100 random numbers from the set {1,...,6}. Call this sequence X,..., X100. Plot the histogram of X,..., X100, with bin centers {1,...,6}. Do not use a for-loop in your code. Submit your program and plot. (b) Repeat (a) by drawing the dice 10000 times. (c) Draw another dice 100 times. Call this sequence Y,..., Y100. Let Z = Xi+Y for i = 1,..., 100. Plot the histogram of Z, ..., Z100. Submit your plot. (d) Repeat (d) by drawing the dices 10000 times. (e) Using the histogram found in (d), find the probability that 4 < Zi 7. (f) In (c)-(d), Z, is a sum of two random variables X and Y. What if we sum more random variables? That is, Zi = X() + X(). +...+X(K). Let K = 10. Plot the histogram of {Z,..., Z10000}. Submit your histogram. Pay attention to the bin centers. (g) Repeat (f) by setting K = 100. Plot the histogram of {Z,..., Z10000}. Submit your histogram. Pay attention to the bin centers.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

Heres how you can write MATLAB programs for each part Part a Generate and plot a histogram for drawi... View full answer

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 Programming Questions!