STAT/MATH 394, Probability I, covers the basic elements of probability theory. The goal is to provide a solid grounding in understanding and working with practical problems that involve some element of randomness. The topics covered include sample spaces, probabilistic experiments, probability axioms, cumulative distribution functions, and some common distributions.

Official Syllabus (Essentially the first part of this page).

For better or worse, I, Hoyt Koepke, am your instructor. I’m a PhD student in statistics. I did my masters in Computer Science and my undergrad in physics. My email is hoytak@stat.washington.edu; I’m not on email all the time, but I will try to get back to you ASAP.

The official prerequisite is the calculus sequence, MATH 124, 125, and 126 (or equivalent). What you’ll need for this course is probably a subset of that, but known well. In particular, make sure you’re fluent in basic differentiation and integration. You also need to be comfortable working with common series (e.g. the geometric series), limits, and sets. If people request it or appear to have trouble on these topics, I’ll post links to review material on the website.

The book for the course is *A First Course in Probability*, 7th
edition, by Sheldon Ross. If you have another edition, it covers the
same material and will likely work, but it’s your responsibility to
get the homework problems from a copy of this edition.

The final exam will be held on the last day of class, and **the
midterm will be July 2.**

The exams will all be closed book, closed notes. I will, however, give out a one-page reference sheet that you can use. It will have a number of the important formulas and identities on it, and I’ll make sure you have it ahead of time for studying.

Also, at least half of the exam problems will come directly from the recommended problems (see below) with little or no modification.

**NOTE:** You **do not** need to bring a calculator to the exams.
This is a change of mind on my part; apologies for that.

Because this course moves very quickly – we have only about four weeks! – homework will be assigned in almost every class and then collected the next class. This translates into about 10 homework sets, and I’ll drop the lowest one in calculating the final grade. Having homeworks due this frequently makes sure you stay on top of the material. Generally, the assignments will be short, only 2-4 graded problems, to also make sure you can have a life.

The exercises in the book are divided into two types, regular problems and self-assessment problems. The answers to all of the self-assessment problems and some of the regular problems are in the back of the book.

In addition to the graded problems, I’ll also recommend a few ungraded exercises with each homework. These will usually have answers in the back of the book, and I’ll generally take half or more of the exam questions from these. Understanding and working these problems is a great way to prepare for the exams.

The course discussion board is for discussion of homeworks, concepts, and pretty much anything related directly to the material of the course. It is online at https://catalysttools.washington.edu/gopost/board/hoytak/17487/ and requires a UW net ID to log on. It is restricted to this course; if you have trouble, send me an email.

The grade distribution will be as follows:

- 25% Homework.
- 30% (or 20%) Midterm.
- 40% (or 50%) Final Exam.
- 5% Class Participation / Extra Credit (may give additional credit).

For the exams, if you do better on the final than the midterm, it will count as 50% of your final grade and the midterm will count as 20%.

The class participation / extra credit grade will be based on how much above the “minimum” you participate in the course and how much I see you try to engage probability theory.

- Asking questions in class / on the course discussion board.
- Answering and explaining questions other students ask on the discussion board.
- Sending me a link to a news article that deals with probabilities, along with a 2-5 sentence discussion/assessment of how the article handles them. You can talk about how well it is explained, whether they interpreted it correctly, if there’s room for people to hide something within their assessment, etc.
- Other things I haven’t thought of yet...

Office hours will be from 10:45 - 11:20 MWF (right after class), and
**12:30 - 2:00 on Tue/Thu** (note change), and by appointment. My
office is Padelford B-312 (Note that Padelford has 3 sections, A, B,
and C; I’m in B).

Here is the (tentative) schedule for the course. Anything that hasn’t yet happened may change. If I need to change anything that may potentially affect your grade (e.g. dropping/changing/modifying a homework problem), I’ll either email it out or announce it in class. Otherwise, it is your responsibility to keep track of the content here.

General course information, overview of probability theory, experiments, sample spaces, Venn Diagrams, set theory, and basic axioms of probability theory. Covers 2.1-2.3.

Homework 1, due 06/23 Wednesday:Chapter 2, problems 5, 8;- theoretical exercise 6 parts b,d,g, and h. (
Note: you don’t need to do i).Recommended Problems:Chapter 2, problem 1.Note:self-test- problem 3 is postponed til Wednesday.

Notes:For those of you who don’t have the book, or have a different edition, I’ve asked a copy to be put on reserve. I don’t think the material will have changed, but I think the problems change between editions. Until then, here they are:

**Due 06/23 Wednesday.**

**Problem 2.5, page 55.**

A system is composed of 5 components, each of which is either working or failed. Consider an experiment that consists of observing the status of each component, and let the outcome of the experiment be given by the vector , where is equal to 1 if component is working and equal to 0 if component has failed:

- How many outcomes are in the sample space of this experiment?
- Suppose that the system will work if components 1 and 2 are both working, or if components 3 and 4 are both working, or if components 1,3, 5 are all working. Let be the event that the system will work. Specify all the outcomes in .
- Let be the event that components 4 and 5 are both failed. How many outcomes are contained in the event ?
- Write out all the outcomes in the event .

Solution:

Each machine has 2 states, so there are possible outcomes.

You can see this as:

For notational convenience, let’s write as 10111 and so on. Writing them all out then gives us

Which, when combined, gives us

In this case, is just:

Writing this out gives

The interesection between the two groups is just:

**Problem 2.8, page 56.**

Suppose that and are mutually exclusive events for which and . What is the probability that

- either or occurs?
- occurs but not ?
- both and occur?

Solution.

and are mutually exlusive events, so we can just use axiom 3 to add their probabilities. Thus:

If occurs, doesn’t. So this is just .

by definition of “mutually exclusive”.

**Theoretical Exercise 2.6 (selected parts), page 61.**

Let , , and be three events. Find expressions for the events so that of , , and :

- Both and occur but not .

- At least two events occur.

- At most one of them occurs.
- At most two of them occur.

Solution.

- .

- . Note that the parenthesis are not needed.

- . This can be seen as the complement of part d.
- . Think of this as “all three events don’t happen.”

Continue with probability theory axioms, probabilities of events that are not mutually exclusive, basic combinatorics.

Course Reading:Section 2.4, the introduction to 2.5, and chapter 1.

Homework 1 is Due.

- My apologies for being unclear on the bookshelf example and a few other aspects of choosing groups. I’ll spend the first part of class on Friday clarifying these things and giving a couple more examples. I did cover enough, though, that you should be able to do the homework (I’m working on writing them up for the webpage right now, and I’ll post some hints there).
- With this homework, the recommended problems, including self-test problems 1.1 and 1.9, are easier than the homework and will help. The answers to some are in the back of the book.
- For homework 1, I should be able to get this current set back to you on Monday, along with (hopefully) Friday’s. After that, the turnaround should be the next class.
- The
**midterm is on Friday, July 2nd.**I’ll get your cheat-sheet up on the website Monday, and also hand it out in class. Wednesday, we’ll have a review. - We didn’t get to the calculus self-test today; it will be posted below shortly.
- Solutions to Homework 1 will be posted on Friday.

Due 06/25 - Friday:Theoretical Exercise 2.12; Problems 2.12, 2.44, and 2.55.

Recommended Problems:Self-Test exercises 1.1, 1.9, and 2.3 (from Monday); Problems 2.10, 2.33.

**Theoretical Exercise 2.12:**

Show that the probability that exactly one of the events or occurs equals .

*Solution:*

There are several ways to prove this, here’s one:

We’re interested in . Now , so the events are mutually exclusive. Thus

(1)

Now

These are two mutually exclusive events, so

Similarly,

Combining these with (1) above, we have that

**Problem 2.12:**

An elementary school is offering 3 language classes; one in Spanish, one in French, and one in German. These classes are open to any of the 100 students in the school. There are 28 students in the Spanish class, 26 in the French class, and 16 in the German class. There are 12 students that are in both Spanish and French, 4 in both Spanish and German, 6 in both French and German, and 2 taking all three.

- If a student is chosen randomly, what is the probability that he or she is not in any of these classes?
- If a student is chosen randomly, what is the probability that he or she is taking exactly one language course?
- If 2 students are chosen randomly, what is the probability that at least 1 is taking a language class?

Hints: Understand example 2.5L; also, on c, be careful about using the same set sizes to calculate the probability that the second student is taking a language class, since you’ve already chosen the first.

*Solution*:

This problem is a straightforward application of the inclusion/exclusion formula for 3 events,

(2)

- Let
Then

The Venn diagram for this event looks like this:

Now consider . However, this counts regions 1,2, and 3 twice and region 4 three times. Thus, we need to remove the measure of the double-counted regions completely, subtracting it out would give us . However, this is again too much, as it subtracts the measure of region 4 – – 6 times, requiring us to add it back in 3 times for 0 total. Our final formula is thus:

The easiest way to do this is as follows:

**Problem 2.44:**

Five people, designated as and , are arranged in linear order. Assuming that each possible order is equally likely, what is the probability that

- There is exactly one person between and ?
- There are exactly two people between and ?
- There are exactly three people between and ?

Hints: Do part c. first, and think about representing groups as bins like we did in class. These bins, though don’t need to be contiguous.

*Solution*:

The criteria defining the event

Especifies that we have one of the pairs AxByz, xAyBz, xyAzB, or the same with A and B reversed. Thus there are 6 ways to place A and B, and ways to fill x,y,and z. ThusThis is the same as part a, but now there are 4 ways of finding the location of A and B, namely AxyBz, xAyzB, BxyAz, and xByzA. Thus

There are only two ways now, AxyzB and BxyzA. So

**Problem 2.55:**

Compute the probability that a hand of 13 cards contains:

- The ace and king of at least one suit.
- All 4 of at least 1 of the 13 denominations.

Hints: Understand examples 2.5f. 2.5g, and 2.5h. Solving this problem will involve breaking the events up into smaller events that you can calculate the probabilities of by counting how many orderings match these events.

*Solution*:

This problem was presented in class. The final solutions are:

The following four problems are similar to things we’ll need to do regularly in the material after the midterm.

Calculate

Calculate

Let

What is ?

- Calculate .
I’ll present the solutions to these briefly on Friday.

Finish up introdution to combinatorics (chapter 1) with some more examples, clarify seeing experiments as groups or as orderings, present HW 2.55, identifiability issues, finish up combinatorics.

- Office hours have changed!!! They are now at 12:30 - 2:00 on both Tuesday / Thursday, as well as for the 40 minutes after each class. Those of you who can’t make the switch can still come at the earlier time on Tuesday.

Due 06/28 - Monday:Problems 2.28, 2.37, 2.46.

Recommended Problems:Problems 1.9, 2.29 a and b, 2.35, and self-test 2.17.

**Problem 2.28:**

An urn contains 5 red, 6 blue, and 8 green balls. If a set of 3 balls is randomly selected, what is the probability that each of the balls will be (a) of the same color; (b) of different colors? Repeat under the assumption that whenever a ball is selected, its color is noted and it is then replaced in the urn before the next selection. The first is known as

sampling without replacement, and the latter is known assampling with replacement.

Hint: Understand examples 2.5b-e and problem 2.29 from the recommended problems first.

Solution:First consider the case of sampling without replacement. For (a), we can divide the event into 3 mutually exclusive events:

Then is just the probability that all three of the balls drawn are red, or just

and are similar. Since they are mutually exclusive, we can just add them, so

For b, it’s even easier:

When sampling with replacement, the problem doesn’t change between draws. Thus there are now, e.g. ways of choosing 3 balls, and the size of the sample space is . This gives us, for part a.

which is a little higher than for the case of sampling without replacement. This is what we’d expect, as not replacing a ball of a certain color makes the likelihood of drawing that color less likely on the next try.

For b., the easiest way of doing it, without using conditional probability, is to divide the problem up into 3! mutually exclusive events. Let

Then,

which is a little lower than the case of sampling without replacement. Again, this is what we’d expect.

**Problem 2.37:**

An instructor gives her class a set of 10 problems with the information that the final exam will consist of a random selection of 5 of them. If a student has figured out how to 7 of the problems, what is the probability that he or she will answer correctly (a) all 5 problems or (b) at least 4 of the problems?

Solution:

This is just equal to the number of groups of five possible out of the 7 prepared problems divided by the number of groups of five possible. This is just:

For this, to make sure we don’t count overlapping events, we need to break it up into the mutually exclusive events of getting exactly five correct and exactly 4 correct. Thus there are

different outcomes from the possible outcomes. Thus the probability of getting at least 4 correct is:

**Problem 2.46:**

How many people have to be in a room in order that the probability that at least two of them celebrate their birthday in the same month is at least ?

Assome that all possible monthly outcomes are equally likely.

Hint: understand example 2.5i.

Solution:The probability that there are at least 2 people in a group of

nwho have birthdays in the same month is just 1 minus the probability that allnhave birthdays in distinct months.npeople can fit distinctly into 12 slots indifferent ways, and the size of the sample space – the number of ways to put 12 people in 12 slots with overlap allowed – is just , yeilding the probability of a match being

Finding by trying various shows that when , the probability of a match is , or about 0.618056. When , this probability is only .427083, so is the answer.

Conditional Probability, Independence, and the “baby” version of Bayes’ Formula. Basically sections 3.1-3.2, 3.4, and the basic idea of 3.3.

**Midterm Exam on Friday!**Be prepared.

**Due 06/30 - Wednesday:** Problems 3.9, 3.10, 3.14, 3.62.

**Recommended Problems:** Problems 3.20, 3.37; Self-Test problems 3.9, 3.13, 3.18.

**Problem 3.9:**

Consider 3 urns. Urn A contains 2 white and 4 red balls; urn B contains 8 white and 4 red balls; and urn C contains 1 white and 3 red balls. If 1 ball is selected from each urn, what is the probability that the ball chosen from urn A was white, given that exactly 2 white balls were selected?

Solution:This problem requires us to use conditional probability. Let

and similarly for red. Then the event we’re conditioning on, , is the event that there are exactly 2 white balls selected, i.e.

We’re then interested in the probability

Now

So

where the last step comes from the events being mutually exclusive. Now the urns are independent, and these probabilities can be easily calculated. We thus have that:

Plugging in the numbers and simplifying gives the final solution, .

**Problem 3.10:**

Three cards are randomly selected, without replacement, from an ordinary deck of 52 playing cards. Compute the conditional probability that the first card selected is a spade given that the second and third cards are spades.

Solution:There are several ways of doing this problem. First, one can note that the reduced sample space – formed by “fixing” two cards in the draw of three cards to be spades – is just a regular deck of cards minus 2 spades. (Convince yourself that it’s fine to condition on events that occur after the first card is dealt out.) The answer would then be

It’s also possible to do this using the definition of conditional probability. In this case, we would have

which works out to be the same solution.

**Problem 3.14:**

An urn initially contains 5 white and 7 black balls. Each time a ball is selected, its color is noted and it is replaced in the run along with 2 other balls of the same color. Compute the probability that

- The first 2 balls selected are black and the next 2 white;
- Of the first 4 balls selected, exactly 2 are black.

Solution:a. We’ll do this using conditional probability, though we could do it similar to the way we did it in part (b).

We want to find . Using the multiplication rule which we discussed earlier, we can expand this as:

Each of these probabilities is easily calculatable:

Multiplying these together gives us , or 0.0455729.

b. This problem can be done two ways. The “sure” way is to do the same as above for the different cases. This is easier than it looks, as one can notice that all that matters are what balls were drawn prior to the current one. Thus

and so on. Furthermore, when one does this for all 6 terms we find that they are all equal; i.e. it doesn’t matter on the order.

One could guess, however, that this would be the case initially. If we look at the probability in (a):

The number of balls is always increasing by 2, so the denominator is the same in all cases. Furthermore, there will always be 7 black balls the first time a black ball is drawn and 9 black balls the second time a black ball is drawn. Same with white; there will always be 5 white balls when a white ball is first drawn and 7 the second time it is drawn. In general, this is an example of Exchangability; I don’t expect you to know it, but it’s a weaker condition than independence and essentially says that all orders are equally likely.

So, summarizing,

**Problem 3.62:**

Barbara and Dianne go target shooting. Suppose that each of Barbara’s shots hits the wooden duck target with probability and each of Dianne’s shots its the target with probability . Suppose they both shoot simultaneously at the same target. If the wooden duck is knocked over, indicating it was hit, what is the probability that

- Both shots hit the duck.
- Barbara’s shot hit the duck?
What independence assumptions have you made?

Solution:a. Let be the event that Barbara hit the duck, and let be the event that Dianne hit the duck, and then is the event that the duck was hit. We’re interested in

Now, if we assume that and are independent (which is what I asked for),

Thus

- Similarly, we’re interested in the conditional probability:
If we suspect that the shots hitting the target are not independent – e.g. Dianne’s bullet knocks it over before Barbara’s bullet gets there – then . However, we don’t have enough information to consider this case mathematically.

No homework, more on conditional probability, exam review.

The midterm exam will be closed book, closed notes. 50% - 75% of the material will be directly from the recommended problems, so make sure you understand them.

The exam will be one hour (the first hour), and then I’ll jump into the next topic – more advanced use of Bayes’ theorem.

You will **not** be able to use a calculator on the exam.

Here is a reference sheet of the basic equations, propositions, and axioms that you can refer to on the exam. The exam is intended to test your ability to reason about probability problems similar to what we’ve encountered thus far both formally and intuitively.

The test material will cover the following sections:

Chapter 1:

Sections 1-6, except for the binomial and multinomial theorems for polynomial equations and related examples.

Chapter 2:

Sections 1-5. You won’t be responsible for the general inclusion/exclusion formula (proposition 4.4) except what’s on the reference sheet, the proofs of propositions 4.1-4.3, or examples 5j,5k,5m,5n, and 5o.

Chapter 3:

Sections 1,2, 4, and the basic idea of 5; that is a probability measure. You won’t be responsible for example 4j and the subsequent material in section 4.

In general, I won’t require you to know concepts for the exam that you haven’t seen in the homework, recommended problems, or in examples discussed in class. If you’ve kept up and understand all the problems, you should do fine and there should be no surprises.

**Due Wednesday, 07/05:** Problems 3.31, 3.70, 3.76, 3.83, Short Essay (see below).

**Recomended Problems:** Problems: 3.44, 3.48.

**Problems 3.31:**

Ms. Aquina has just had a biopsy on a possibly cancerous tumor. Not wanting to spoil a weekend family event, she does not want to hear any bad news in the next few days. But if she tells the doctor to only call if the news is good, then if the doctor does not call, Ms. Aquina can conclude that the news is bad. So, being a student of probability, she instructs the doctor to flip a coin. If it comes up heads, the doctor is to call if the news is good and not call if the news is bad. If the coin comes up tails, the doctor is not to call. In this way, even if the doctor doesn’t call, the news is not necessarily bad.

Let be the probability that the tumer is cancerous; let be the conditional probability that the tumor is cancerous given that the doctor does not call.

- Which should be larger, or ?
- Find in terms of , and prove your answer in part (a).

Solution:

One would think that would be larger, since the conditional sample space is the unconditional sample space with the event that the doctor calls excluded, and this event only occurs if the tumor is not cancerous.

This is a straightforward application of Bayes’ rule. Let be the event that the tumor is cancerous, and let be the event that the doctor’s coin flip comes up heads. Then the event that doctor does not call is just . Continuing,

Now and as the two events are independent. Thus we have that

**Problems 3.70:**

There is a 50-50 chance that the queen carries the gene for hemophilia. If she is a carrier, then each prince has a 50-50 chance of having hemophilia. (a) If the queen has had three princes without the disease, what is the probability that the queen is a carrier? (b) If there is a fourth prince, what is the probability that he will have hemophilia?

Solution:

Let , , etc. be the events that the first, second, etc. princes have hemophilia, and let be the event that the queen is a carrier. Again, using Bayes’ rule,

Now the events that the princes have hemophilia are independent only when you condition on the state of the queen. Thus

And

Thus

For this problem, we’re looking at . The concern with this problem is just that we need to be careful about the independence assumptions. In particular, the state of the fourth prince depends on the state of the previous three princes only through the event that the queen is a carrier. Thus we know that we’ll have to include the state of the queen somewhere in our analysis. Here’s one way to do it:

Looking at the individual terms, we have

Thus we can plug these values in:

**Problem 3.76:**

Suppose that and are mutually exclusive events of an experiment. Show that if independent trials of this experiment are performed, then will occur before with probability .

Solution:There are two ways to do this problem, one a bit more formally correct than the other; the slightly less formal one is all I expect you to know, so I’ll just present that solution here. Informally, consider repeating an experiment and then stopping when either event or event occurs. Then the event that you stop the expirement is the same as the event . So

where the last step follows as and are mutually exclusive.

**Problem 3.83:**

Die A has 4 red and 2 white faces, whereas die B has 2 red and 4 white faces. A fair coin is flipped once. If it lands on heads, the game continues with die A; if it lands on tails, then die B is to be used.

- Show that the probability of red at any throw is .
- If the first two throws result in red, what is the probability of red at the third throw?
- If red turns up at the first two throws, what is the probability that it is die A that is being used?

Solution:

Let be the event that throw is red, and let and be the events that the die chosen is die A and die B, respectively. Then

I think it’s easier to do (c) first, so here we go. The probability we’re interested in is

Now once we know the die being used, the events of getting reds are independent. Thus

So

This time we’re interested in :

The fifth problem is to look at one of four classic probabalistic paradoxes and write a short essay on them. The four paradoxes to choose from are Berkson’s paradox, Bertrand’s Box paradox, Sleeping Beauty Problem, or the Three Prisoner’s problem. For whichever one you choose, I want you to cover 3 things:

- Why is it counterintuitive? In other words, why do people often think of it wrongly? What is it easy to forget?
- What is a correct way of thinking about it? Is there a correct but intuitive way of reasoning about it?
- Mathematically, what is going on? What are the conditional probabilities? Do they work out correctly? What is it easy to miss?

A suggested format is to write a paragraph / equations-with-explanation for each of the three points above. In class, we already talked about similar paradoxes, namely the Monty Hall Problem and the Boy-Girl problem. I tried to discuss the above three points on each, and I don’t expect more than that. However, going above and beyond the above guidelines may definitely earn you some extra credit points. Ways to do this include discussing several articles, looking at generalizations of the same phenomena, discussing a real-life-scenario where people might make this mistake, etc.

**Holiday**, no class.

Introduce Random Variables as extensions of previous events. Read sections 4.1, 4.2, 4.6, and 4.8. You may skip discussions about the expectation and variance of these random variables. Pay attention to the examples.

**Due 07/09 - Friday**: Problems 4.41, 4.48, 4.71.

**Recommended Problems:** Self Test 4.3 and 4.8; problems 4.7 and 4.18

**Extra Credit:** 4.11.

**Problem 4.41**:

A man claims to have extrasensory perception. As a test, a fair coin is flipped 10 times, and the man is asked to predict the outcome in advance. He gets 7 out of 10 correct. What is the probability that he would have done at least this well if he had no ESP?

Solution:Let be a random variable representing the number of correctly guessed flips. Now has a Binomial distribution with parameters and . Thus the probability mass function of is

Then

**Problem 4.48**:

It is known that diskettes produced by a certain company will be defective with probability 0.01, independently of each other. The company sells the diskettes in packages of size 10 and offers a money-back guarantee that at most 1 of the 10 diskettes in the package will be defective. If someone buys 3 packages, what is the probability that he or she will return exactly 1 of them?

Solution:Let be a random variable representing the number of defective disks in a package of 10. Then, . Thus the p.m.f. of is

We are interested in the probability that 2 or more disks are defective, the condition for returning a package, which is just

This is the probability that an individual package is returned. Now, let be the number of returned packages in a shipment of 3. Then is also going to be a random variable with a Binomial distribution, this time with parameters and . Thus the probability that exactly one is returned is just

**Problem 4.71**:

Consider a roulette wheel consisting of 38 numbers – 1 through 36, 0, and double 0. If Smith always bets that the outcome will be one of the numbers 1 through 12, what is the probability that

- Smith will lose his first 5 bets;
- his first win will occur on his fourth bet?

Solution:

This can be calculated many ways; the easiest are as or as the probability that 5 independent trials in a row are all failures.

This is the probability that a geometric random variable having a probability of success takes on the value 4. Thus,

Expectation, variance, more on probability mass functions, and the cumulative distribution function. Sections 4.3-4.5.

**Due 07/12 - Monday**: Problems 4.33, 4.43, 4.75; Theory Exercise 4.32.

**Recommended Problems**: Problems 4.18, 4.21; Self-Test Problems 4.21, 4.9, 4.22.

**Problem 4.33:**

A newsboy purchases papers at 10 cents and sells them at 15 cents. However, he is not allowed to return unsold papers. If his daily demand is a binomial random variable with and , approximately how many papers should he purchase so as to maximize his expected profit?

Hint: Understand / use example 4.4b.

Solution:For this problem, define the following variables:

The profit, as a function of items sold, is then

The expected profit is just the expected value of this function, i.e.

There are several ways to maximize this function; the first way is just to plug and play with different values of . The example in the book, 4.4b, gives a comprehensive treatment of various ways to make this calculation easier. From there, we have the following useful equation; stocking units is better than stocking units whenever

where . Using any of these ways should show that the optimal number of papers to stock up on is 3.

**Problem 4.43:**

A communications channel transmits the digits 0 and 1. However, due to static, the digit transmitted is incorrectly received with probability 0.2. Suppose that we want to transmit an important message consisting of one binary digit. To reduct the chance of error, we transmit 00000 instead of 0 and 11111 instead of 1. If the reciever of the message uses “majority” decoding, what is the probability that the message will be wrong when decoded? What independence assumptions are you making?

Solution:Assume independence between flips on the bits. This is then just the probability that at least 3 bits are flipped. Let represent the number of bits flipped.

**Problem 4.75:**

A fair coin is continually flipped until heads appears for the tenth time. Let denote the number of tails that occur. Compute the probability mass function of .

Solution:Let represent the number of trials before 10 heads occur. Then has a negative binomial distribution with parameters and . Now let denote the number of tails. Because every coin flip that doesn’t come up heads comes up tails, we know that . We’re interested in the probability mass function of , so we can procede as follows:

**Theoretical Exercise 4.32:**

A jar contains chips. Suppose that a boy successively draws a chip from the jar, each time replacing the one drawn before drawing another. This continues until the boy draws a chip that he has previously drawn before. Let denote the number of draws, and find the probability mass function of .

Let

Then

Now the probability of not drawing a previously seen chip given that there have been no repeat draws is just the number of unseen chips divided by the total number of chips. On draw , this is just . Similarly, the probability of drawing a previously seen chip on draw , given that there have been no repeats thus far, is just . Thus the above becomes:

Finally, since it is impossible to stop on the first draw, or draw a new one on the draw, we can give the following formula that includes the domain information:

Poisson random variables, begin discussion of continuous random variables.

**Due 07/14 - Wednesday**: Problems 4.60, 4.65, 5.2, 5.4

**Recommended Problems**: Problems 4.29, 4.30, 4.55, Self Test 4.22, 5.2.

**Problem 4.60:**

The number of times that a person contracts a cold in a given year is a Poisson random variable with parameter . Suppose that a new wonder drug (based on large quantities of vitimin C) has just been marketed that reduces the Posson parameter to for 75 percent of the population. For the other 25 percent of the population, the drug has no appreciatble effect on colds. If an individual tries the drug for a year and has 2 colds in that time, how likely is it that the drug is beneficial for him or her? (I.e. they are in that group).

Solution:This is just a standard Bayes probability problem in which we calculate the final probabilities using the given distribution functions. Let

Then we are interested in

Now

Thus

**Problem 4.65:**

Each of 500 soldiers in an army company independently has a certain disease with probability . This disease will show up in a blood test, and to facilitate matters, blood sample from all 500 are pooled and tested.

- What is the (approximate) probability that the blood test will be positive (and so at least one person has the disease)?
Suppose now that the blood test yields a positive result.

- What is the probability, under this circumstance, that more than one person has the disease?
One of the 500 people is Jones, who knows that he has the disease.

- What does Jones think is the probability that more than one person has the disease?
As the pooled test was positive, the authorities have decided to test each individual separately. The first of these tests were negative, and the one – which was on Jones – was positive.

- Given the preceding, as a function of , what is the probability that any of the remaining people have the disease?

Solution:

Let be the number of sick soldiers. In this case, it’s justified to use the Poisson approximation since is small relative to .

Using the Poisson approximation,

For this part of the problem we need to first define some more events. Let

Then the probability that more than one soldier has the desease, given that the test is positive, is as follows. Let represent the probability mass the Poisson at . Then

Since Jones knows he has the disease, and that entirely explains the result of the test, the probability that more than one person has the disease (from his point of view) is really the probability that someone other than he has it. Or in other words, the probability that at least one of the remaining 499 people has the disease. Thus the problem is the same as (a), but with 499 people instead of 500. Thus, let be the number of people in this group that has the disease. In this case, again using the Poisson approximation,

(Note that the answer in the back of the book is wrong.

Even though we are given that the test was positive, this does not provide any more information about the probability of the remaining soldiers having the disease since, with Jones being the person, the positive test result is completely explained. Thus it is simply the probability that one person in the remaining group of people has it. Let this event be . Then, using the Poisson approximation – which is still valid, since is really small relative to – gives

Now, let’s see how close this really is the true probability of the Binomial. If we plot the probabilities given by the two different methods as a function of , we get the following.

Plotting their values is so close that they are indistinguishable on the graph. Looking at their difference, the bottom plot, indeed shows that they are very similar; the difference is several orders of magnitude less than the values themselves. Thus the Poisson approximation is quite good.

**Problem 5.2:**

A system consisting of one original unit plus a spare can function for a random amount of time . If the density of is given (in units of months) by

what is the probability that the system functions for at least 5 months?

Hint: Use the assumption that to find C.

Solution:Since is a density function, the first step is to find the constant such that the total area under is 1.

Where we know that from the formula for the exponential distribution ().

Now can be evaluated to find the probability that the system functions for at least 5 months. Specifically, we have that

**Problem 5.5:**

A filling station is supplied with gasoline once a week. If its weekly volume of sales in thousands of gallons is a random variable with probability density function

what need the capacity of the tank be so that the probability of the supply’s being exhausted in a given week is 0.01?

Hint: Draw a graph of the pdf; the x axis is the number of gallons, which can’t be above 1 (units are in thousands of gallons). Then set up the correct integral for the problem.

Solution:Plotting this probability function helps visualize what’s going on and how to set up the integral. We are looking for a constant , representing the size of the tank, such that the amount of probability mass larger than is . Solving for this boundary gives us:

More continuous random variables, exponential distribution, uniform distribution.

**Due Friday, 07/16:** Problems 5.32, 5.40; Theory Exercises 4.27,
5.26. On 5.40, also plot the p.d.f. of the new random variable. On
T.E. 5.26, Find the a new R.V. in terms of *X*.

**Recommended Problems:** 5.4, 5.17; Self-Test 5.1, 5.7; Theory
Exercise 5.29.

**Problem 5.32:**

The time (in hours) needed to repair a machine is an exponentially distributed random variable with parameter . What is

- The probability that a repair time exceeds 2 hours;
- The conditional probabilty that a repair takes at least 10 hours, given that its duration exceeds 9 hours?

Solution:

Let be the number of hours required to repaire the washing machine, with . Then

b. Now the probability we are interested in is . However, by the memoryless property of the exponential, this is just . Following the same steps as above, we get .

**Problem 5.40:**

If is uniformly distributed over , find the density function of . Plot this new density function.

Hint: be careful about the limits, and verify your final p.d.f. integrates to 1.

Solution:We’re interested in the density , but we need to get there through the density function of , .

where the second to last step follows since equals 1 if and 0 elsewhere. As a quick check, let’s make sure this indeed integrates to 1:

So we’re good to go. Plotting this gives:

**Theory Exercise 4.27:**

If is a geometric random variable, show analytically that

Give a verbal argument using the interpretation of a geometric random variable as to why the precedeing equation is true.

Solution:First, we prove this formally. The geometric distribution has a p.m.f of . Thus we proceed directly:

where the sum in the denominator is just one since that is a sum over all the points of a geometric p.m.f., which must sum to 1.

Intuitively, we would expect a geometric random variable to possess a “memoryless” property, as it measures the number of tries of independent trials before one trial succeeds. Since these trials are independent, we would expect that fact that you’ve reached a certain point without success has no connection with future trials; thus it’d be the experiment same as when you started.

**Theory Exercise 5.26.**

If is uniformly distributed over , what random variable, expressed as a linear function of , is uniformly distributed over ?

Solution:Consider, first, that the probability density function of is constant on the interval and 0 elsewhere. We want a new random variable, that is constant and uniform on the interval and 0 elsewhere. Thus we must effectively “slide” and “squish/stretch” the first interval, on which takes values uniformly, to fit the form of the second.

The operation of shifting it is done by subtracting , thus is uniformly distributed on the interval .

Squishing or stretching it is done by dividing by the original length so that the final end point is 1 instead of . This means that

has non-zero density exactly on the interval . A quick check (not required for the hw) ensures that it is also uniform on this interval:

which is exactly the cumulative distribution function of a R.V. uniform on .

One could also note that linear mappings should preserve the uniform distribution property, as we are simply shifting and scaling the input to the uniform p.d.f.; i.e. if is constant on an interval, then should also be constant but on a (possibly) different interval.

The normal distribution.

**Due Monday 07/19:** Problems 5.26, 5.29.

**Recommended Problems:** Self Test Problems 5.18, 5.19; Theory 5.29.

**Bonus problem:** Theory Exercise 5.31.

**Problem 5.26:**

Two types of coins are produced at a factory: a fair coin and a biased one that comes up heads 55 percent of the time. We have one of these coins but do not know whether it is a fair coin or a biased one. IOn order to ascertain which type of coin we have, we shall perform the following statistical test: We shall toss the coin 1000 times. If the coin lands on heads 525 or more times, then we shall conclude that it is a biased coin, whereas, if it lands heads less than 525 times, then we shall conclude that it is the fair coin,. If the coin is actually fair, what is the probabilityh that we shall reach a false conclusion? What would it be if the coin were biased?

*Solution:*

Define

Then

where is the cdf of a standard normal random variable.

Going the other way, the probability of incorrectly deciding it’s a fair coin if it’s actually biased is:

**Problem 5.29:**

A model for the movement of a stock supposes that if the present price of the stock is , then after one time period it will be either with probability or with probability . Assuming that successive movements are independent, approximate the probability that the stock’s price will be up at least 30 percent after the next 1000 time periods if , , and . (Note: You may assume that ).

*Solution:*

The tricky part of this problem is figuring out how many steps up or down need to be taken. Note that ; surprisingly, the small difference between and makes a big difference numerically.

Let

Note that . Then the price after 1000 movements is just ; each movement is multiplicative, so the operations commute. Thus it doesn’t matter which order we record them in, as all that matters is the total number up and the total number down.

We now need to find the minimum number of movements up required to put the final stock price above , a 30% increase:

Since this problem follows a distribution, we can reasonably approximate with a normal distribution using the DeMoivre-Laplace approximation. Let be the number of movements up. Then:

Review for final exam.

The final will be the entire class period (a little over 2 hours long) and will cover the entire course with an emphasis on the material after the midterm. There will be 8-10 problems of a similar format to the midterm. Again, 50-75 percent will come directly from the recommended problems, and pretty much everything will directly relate to the homeworks or examples presented in class. Thus a good way of preparing is making sure you understand the recommended problems and homework.

**Sections Covered.**

While the material on the exam is pretty much bounded by what you’ve seen in the homework, recommended problems, or in class, here’s a reading guide to the sections of the book that are covered:

Chapter 1 (from midterm) :

Sections 1-6, except for the binomial and multinomial theorems for polynomial equations and related examples.

Chapter 2 (from midterm):

Sections 1-5. You won’t be responsible for the general inclusion/exclusion formula (proposition 4.4) except what’s on the reference sheet, the proofs of propositions 4.1-4.3, or examples 5j,5k,5m,5n, and 5o.

Chapter 3 (mostly from midterm):

Sections 1,2, 3, 4, and the basic idea of 5; that is a probability measure. You won’t be responsible for examples 3b, 3g, 3i, 3m, 3o, 4j, and the subsequent material in section 4.

Chapter 4 (new, random variables):

All material except for sections 4.6.2, 4.7.1, 4.8.4 and examples 1e, 4b, 4c, 6f, 6h, 6i, 7d, 7f, 8c, 8e, 8f, 8j. I’ll give you the formulas for the various distributions along with their expectations and variances. You should know when to use what distribution.

Chapter 5 (new, continuous random variables):

All material except for sections 5.5.1 (hazard rates) and section 5.6. In section 5.7, you will not need theorem 5.7.1 for variable transformations, but you will need to do one problem similar two what I’ve presented in class and in the homework. Thus the examples motivating this theorem are quite useful.

**Reference Sheet:**

Download here. This reference sheet will be given out with the exam.

(If you’re interested, here is the LaTeX source; you’ll need latexopts.sty to compile it.)