CSCI 6454 - Advanced Algorithms - Spring 2014

Homework #1

Due: Feb 10th, 2014



1. I have 9 fair coins and a 10th coin where both sides are heads. I select a coin at random and flip it; it comes out as heads. What is the probability this is the coin with both sides heads?

2. Give an example of three random events $X$, $Y$, and $Z$ where every pair is independent but all three are not mutually independent.

3. Suppose you and a friend are shipwrecked on a desert island and you want to flip a coin to decide who is going to swim to a nearby island for help. Unfortunately you don't have a coin to flip, but there are some flat rocks with distinctive markings. However, these rocks are probably biased.
Given an algorithm that allows you to use a flat rock to generate fair coin flips. Implement your algorithm and run 1,000,000 trials to show that it's (very close to) 50/50. Turn in your algorithm and its output.

4. A medical company touts its new test for a certain genetic disorder. The false negative rate is small: if you have the disorder, the probability that the test returns a positive result is 0.999. The false positive rate is also small: if you do not have the disorder, the probability that the test returns a positive result is only 0.005. Assume that 2% of the population has the disorder. If a person chosen uniformly from the population is tested and the result comes back positive, what is the probability that the person has the disorder?

5. Implement the randomized min-cut algorithm in a language of your choice and run it on this graph. Run 1000 iterations and output the size of the min cut you find. Turn in your code and the output. You are free to compare your answer to others in the class. (Note: the file may contain parallel edges, but this is fine since your data structure will need to accommodate parallel edges anyway.)