Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Suppose you start out with N hash values and assign them to individuals one by one at random with replacement as we have assumed throughout.
Suppose you start out with N hash values and assign them to individuals one by one at random with replacement as we have assumed throughout. Let M1 be the number of individuals who are assigned hash values until the rst time the value assigned has been assigned before. For example, if the sequence of assigned values starts out as 212, 41, 7, 90, 41, then M1 = 5. Important Note: In this course "until" will mean "up to and including" as you can see in the example above. The random variable M1 is called the time of the first match. In this part of the lab you will nd its probability distribution. 2.1.1 431) When you are trying to identify a distribution, always start with the possible values. In terms of N , what are the possible values of M1? Type your answer here. 2.1.2 4b) [011 Paper] Suppose there are n. individuals in all. As in Part 13. let D\" be the event that all 11. individuals are assigned different values. In Part 1 you have the algebraic formula for PUD\") as well as numerical values when the total number of hash values is N = 365. Fill in the blank with one of the symbols 2, >, 2, 1, the event JD.n is the same as the event {M1 2.1.3 4c) [On Paper] For n. 2 1 dene the event Gn = {M1 > n}. Fill in the blanks. - The first blank should be filled in with set operations (such as union, in- tersection, difference, complement, etc) performed on some or all of the events $G_1, G_2, ...$. - The second blank should be filled in with arithmetic operations performed on some or all of P(G1),P(G2)3 ' . -- For a possible value 11 in the range identied in Part a above, the event {M1 = n} is the same as the event , and hence P(M1 = n) = Be sure to show that your answer is correct for the values of n that are at the edges of your answer to Part a. 2.1.4 4d) Complete the cell below to find probability distribution of M1 numerically in the case N = 365. . The array possible_vals_M1 should contain the possible values of M1 found in Part a above. . The probabilities of those values should be placed in the array matching_time_probs, cal- culated using: - Your work in Parts ac above - The array all_different from Part 1 - NumPy functions; consult the list provided at the start of the lab Be careful with matching_time_probs. Keep track of signs and lengths, and check that the rst and last values are correct. N = 365 \""" Distribution of M_1 "'\"' if Array of possible values, in terms of H possible_vals_M1 = np.ara.n.ge(. . .) if Carefully An array of the corresponding probabilities, in terms of N andJ sine array all_different matching_time_probs =
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started