CSE 103 Homeworks



Assignment 5 (Due in class 11/6/07)

See the attached pdf file for the written assignment questions.


Assignment 4

Read section 6.3.2 about confidence sets, then also read 10.1 and 10.5 about hypothesis testing.

Turn in excercise 3 on page 104, and excercises 5 and 6 on page 171. For excercise 3 please turn in code, a table showing how often the true CDF fell inside your confidence bands, and 2 example plots of a particular run with each distribution with confidence bands drawn on the plot. The first plot will have the true CDF of the normal (gaussian) N(0,1) distribution along with one estimated CDF from random samples from this distribution and confidence bands around this estimated CDF. The second plot will be the same but for the Cauchy distribution.


Assignment 3

You are given a file with n=1,000,000 numbers and your task is to sort it using the O(n) algorithm that was described in class. The data was generated by IID draws from some fixed distribution over the integers. To draw a sample you can just read the elements from the beginning of the file. To generate the sorting bins, take a sample that is the same size as the number of bins you wish to use (m). Repeat the procedure for m=100, 1000, 10000, 100000.

After you run the algorithm for each value of m, generate a histogram of the number of bins with a certain occupancy (i.e. how many bins recieved [0-10] elements [11-20] elements etc.). Turn in the matlab code and a histogram for each value of m. Write a few sentences with your conclusion for how the distribution of the occupancy depends on m.

Note: use csvread function in matlab to read in the file (X = csvread(<path>)).
Assignment 2 (Due in lecture on Thurs. Oct 11)

Read chapters 1 and 2.1,2.2,2.3 3.1,3.2,3.3 (not including covariance) in the book.
Exercises 2,3,4,5,6 on page 45.
Assignment 1 (Due in lecture on Thurs. Oct. 4)

1) Let S_n be the sum of {0,1} uniform random variables. For n=10,100,1000,1000 calculate 10,000 instances of S_n
2) Calculate the range and standard deviation of S_n over these 10,000 insances for each value of n.
3) Plot in log-log scale on the same graph the values found in step 2) versus n.

Turn in a printed .m file (the source code) and a printout of the plot created in step 3.