12 May J. Dichter Random Generator Program CS 501X Universit
J. Dichter Random Generator Program CS 501X University of Bridgeport Instructions: You will write a program to generate a series of pseudo random numbers, using a linear feedback shift register method. You will start with an arbitrary number (not zero) x with a representation in n bits. If x = 15 and n = 4, then x = 1111. Then you will select a pair of bits, say bits 0 and 1, take their “xor” producing a new bit -in this case a 0. The number x will then shift to the right, with the new bit becoming the new high bit -in this case 0111. The process continues in this manner to produce a random set of bits. With four bits, we can only have up to 15 unique transitions before repetitions begin, or 2n -1. With n = 32, the number of random bits has a much greater potential. The numbers actually produced by the “shifting” cannot be considered “random”, since all but one of the bits overlap from each succeeding number. However, if we want to produce, say 100 6-bit numbers, then we need to shift the bits into an 6-bit register. We can then save its “value” in an array of 100 integers. Then we should produce the output which will display the distribution. Random numbers should follow a uniform distribution. Using a 32-bit generator does not guarantee 2n -1 random bits. For good results try using bit combinations 0/4, 0/7, 0/25, 0,26, 0/29. Example: 11001110 -> 11100111 -> 01110011 -> 10111001 -> 11011100 -> 11101110 -> 11110111 -> 01111011 -> 10111101 -> 01011110 -> etc Three random 4-bit numbers produced: 11, 13, 4, …. Try “tapping” different bit combinations, as well as the ones I suggested. To verify that the set of numbers you generated are really pseudo random, you will test them using the statistical ? 2 test. You will generate 10,000 numbers in the 0-63 range. Then N=10,000 and r=64. You will then compute ?2 by the formula If ?2 is in the range of r ± 2 r , we conclude that distribution is indeed random. Otherwise it may not be. In your progr
Our website has a team of professional writers who can help you write any of your homework. They will write your papers from scratch. We also have a team of editors just to make sure all papers are of HIGH QUALITY & PLAGIARISM FREE. To make an Order you only need to click Ask A Question and we will direct you to our Order Page at WriteDemy. Then fill Our Order Form with all your assignment instructions. Select your deadline and pay for your paper. You will get it few hours before your set deadline.
Fill in all the assignment paper details that are required in the order form with the standard information being the page count, deadline, academic level and type of paper. It is advisable to have this information at hand so that you can quickly fill in the necessary information needed in the form for the essay writer to be immediately assigned to your writing project. Make payment for the custom essay order to enable us to assign a suitable writer to your order. Payments are made through Paypal on a secured billing page. Finally, sit back and relax.
About Writedemy
We are a professional paper writing website. If you have searched a question and bumped into our website just know you are in the right place to get help in your coursework. We offer HIGH QUALITY & PLAGIARISM FREE Papers.
How It Works
To make an Order you only need to click on “Order Now” and we will direct you to our Order Page. Fill Our Order Form with all your assignment instructions. Select your deadline and pay for your paper. You will get it few hours before your set deadline.
Are there Discounts?
All new clients are eligible for 20% off in their first Order. Our payment method is safe and secure.
