l20_prob_randvar

l20_prob_randvar - 6.042/18.062J Mathematics for Computer...

Info iconThis preview shows pages 1–3. Sign up to view the full content.

View Full Document Right Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: 6.042/18.062J Mathematics for Computer Science April 28, 2005 Srini Devadas and Eric Lehman Lecture Notes Random Variables Weve used probablity to model a variety of experiments, games, and tests. Through- out, we have tried to compute probabilities of events . We asked, for example, what is the probability of the event that you win the Monty Hall game? What is the probability of the event that it rains, given that the weatherman carried his umbrella today? What is the probability of the event that you have a rare disease, given that you tested positive? But one can ask more general questions about an experiment. How hard will it rain? How long will this illness last? How much will I lose playing 6.042 games all day? These questions are fundamentally different and not easily phrased in terms of events. The problem is that an event either does or does not happen: you win or lose, it rains or doesnt, youre sick or not. But these new questions are about matters of degree: how much, how hard, how long? To approach these questions, we need a new mathematical tool. 1 Random Variables Lets begin with an example. Consider the experiment of tossing three independent, un- biased coins. Let C be the number of heads that appear. Let M = 1 if the three coins come up all heads or all tails, and let M = 0 otherwise. Now every outcome of the three coin ips uniquely determines the values of C and M . For example, if we ip heads, tails, heads, then C = 2 and M = 0 . If we ip tails, tails, tails, then C = 0 and M = 1 . In effect, C counts the number of heads, and M indicates whether all the coins match. Since each outcome uniquely determines C and M , we can regard them as functions mapping outcomes to numbers. For this experiment, the sample space is: S = { HHH, HHT, HT H, HT T, T HH, T HT, T T H, T T T } Now C is a function that maps each outcome in the sample space to a number as follows: C ( HHH ) = 3 C ( T HH ) = 2 C ( HHT ) = 2 C ( T HT ) = 1 C ( HT H ) = 2 C ( T T H ) = 1 C ( HT T ) = 1 C ( T T T ) = 0 Similarly, M is a function mapping each outcome another way: M ( HHH ) = 1 M ( T HH ) = 0 M ( HHT ) = 0 M ( T HT ) = 0 M ( HT H ) = 0 M ( T T H ) = 0 M ( HT T ) = 0 M ( T T T ) = 1 2 Random Variables The functions C and M are examples of random variables . In general, a random variable is a function whose domain is the sample space. (The codomain can be anything, but well usually use a subset of the real numbers.) Notice that the name random variable is a misnomer; random variables are actually functions! 1.1 Indicator Random Variables An indicator random variable (or simply an indicator or a Bernoulli random variable ) is a random variable that maps every outcome to either or 1. The random variable M is an example. If all three coins match, then M = 1 ; otherwise, M = 0 ....
View Full Document

This note was uploaded on 02/08/2011 for the course EECS 6.042 taught by Professor Dr.ericlehman during the Spring '11 term at MIT.

Page1 / 16

l20_prob_randvar - 6.042/18.062J Mathematics for Computer...

This preview shows document pages 1 - 3. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online