Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Run a Java program generating a uniform random number U(0,1]1000 times calling a success if the value is greater than . Determine the number of

Run a Java program generating a uniform random number U(0,1]1000 times calling a success if the value is greater than . Determine the number of successes. E.g 520 successes.

Repeat the above 500 times; there will be 500 values.

The theoretical distribution of the 500 values is a binomial distribution and probability of having i successes (p), i=0,1,...,1000 is C(1000,i)*()1000 . This is hard to calculate for any i. Instead a good approximation is a normal distribution with mean 500 and standard deviation of =sqrt(n*p*(1-p)= sqrt(1000/4)=15.8. Then under the null hypothesis 95% of the points will be between 468 and 531 (mean+/- 2). If 95%of the number of experimental values are within these limits, we accept that the random number generator is good.

Run a program to check.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Modern Database Management

Authors: Fred R. McFadden, Jeffrey Slater, Mary B. Prescott

5th Edition

0805360549, 978-0805360547

More Books

Students also viewed these Databases questions

Question

What is Aufbau's rule explain with example?

Answered: 1 week ago