Question: CS with Linear Algebra: In python: Question 8. (a) Write a program to generate random numbers in the following manner: Generate a random number x

CS with Linear Algebra:

In python:

CS with Linear Algebra: In python: Question 8. (a) Write a program

Question 8. (a) Write a program to generate random numbers in the following manner: Generate a random number x from the continuous uniform distribution on (0,1). Calculate y = V. Use y as the output. (b) Conduct a numerical experiment to see how the random numbers are distributed. Use the same setup as in Homework 1: provide extensive comments to the source code, submit the source code, conduct 10 experiments, with 106 trials in each experiment, and tabulate the results. To show the results: If you are comfortable using numpy, matplotlib, etc, to make histograms; please do that. If not, here is a quick-and-dirty way to see what the distribution may be: - Divide the interval (0,1) into n sub-intervals, for some large n. (For our purpose, choosing n = 10 or larger would be okay.) - Count how many random numbers there are in each sub-interval. - Scale to obtain the percentages. - Tabulate or plot the percentages. (c) Comment on the results. What is the probability distribution of y? Justify you claim algebraically

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!