ITEC 2600 Study Guide - Quiz Guide: Monte Carlo Method

41 views1 pages
Ambassador badge icon
22 Oct 2021
Course
Professor

Document Summary

Q16. 1 vector x has 100 elements of random numbers between [0, 1]. Generate vector y with the same length of x, and the values of y is either 0 or 1. For an even dice with numbers 1, 2, 3, 4, 5, 6 on each side. We roll the dice, and take the number on the top side as the outcome. Rolling two even dice, the outcomes of each dice can be one of 1, 2, 3, 4, 5, 6. Let n1 indicate the outcome of rolling the first dice, let n2 indicate the outcome of rolling the 2nd dice. Monte carlo simulation (number of simulation n = 100, 10000, 1000000) to calculate: the mean of the n1 + n2. i. e. the average outcome of rolling two dice. The probability of n1 + n2 = 8: 2. the probability of n1 + n2 = 8.