Assignment 2: Probability Functions for Finite
Sample Spaces
Solutions
CS244Randomness and Computation
Assigned January 22
Due January 29
February 1, 2014
Three little problems from the Grinstead and Snell book (these are supposed
to be easy!), followed
Review Questions
CS244Randomness and Computation
February 20, 2014
These are review problems in anticipation of the rst midterm. On the test
itself, you will not have a calculator, so you do not need to give numerical answers
to questions like what is th
Lecture 4: An ApplicationProbabilistic
Primality Testing
CS244Randomness and Computation
February 12, 2014
The security of many modern cryptographic algorithms is based on the conjecture that there is no practical algorithm for taking a very large intege
Lecture 3: Combinatorics
Part 2Combinations
CS244Randomness and Computation
February 4, 2014
Continuation of preceding notes.
Related reading: Section 3.8 of the Kay book, Section 3.2 of Grinstead and
Snell.
1
Binomial coefcients and three ways to think
Lecture 3: Combinatorics
Part 1Permutations
CS244Randomness and Computation
February 17, 2014
Determination of probabilities in discrete sample spaces requires that we be
able to count the number of outcomes in events. These notes are about basic
countin
Lecture 2: Innite Discrete and Continuous
Sample Spaces
CS244Randomness and Computation
January 27, 2014
To extend our formal framework to discrete sample spaces with an innite
number of outcomes, we need a small tweak to the denitions. In order to exten
Lecture 1: Basic Probability, Some
Denitions, and Lots of Examples
CS244Randomness and Computation
January 21, 2014
We will dene the terms sample space, outcome and event, probability function, and random variable, probability mass function. We will conc
CS244
First Test
February 26, 2014
SOLUTIONS
In problems 1
5, you are asked to calculate a probability. You do not have to
evaluate the expression you obtain


it is okay to give a formula involving binom
Assignment 4: Permutations and
Combinations
Solutions
CS244Randomness and Computation
Assigned February 5
Due February 17
February 26, 2014
Note: Python doesnt have a nice builtin function to compute binomial coefecients, and surprisingly, matplotlib do
Assignment 3 Solutions: Continuous
Probabiity Distributions
CS244Randomness and Computation
Assigned January 29
Due February 5
February 10, 2014
This document refers frequently to the .py le posted along with these solutions on the course website.
1
Mont
Assignment 1 Solutions
CS244Randomness and Computation
Assigned January 22
Due January 29
January 22, 2014
1
Programming Problems 15
The solutions are given in the accompanying .py le. Instances of the plots generated by these functions are shown in the