Math Help Forum

Math Help Forum Feed Site Feed

Go Back   Math Help Forum > University Math Help > Advanced Probability and Statistics
Reply
 
Thread Tools Display Modes
  #1  
Old April 8th, 2008, 01:02 PM
Member
 
Join Date: Feb 2008
Posts: 181
Country:
Thanks: 49
Thanked 41 Times in 40 Posts
hatsoff will become famous soon enough
Default Please help with basic issues

Hi, all.

I took single-variable calc in high school, and will be moving on to multi-variable calc (calc 3) this summer at the community college. However, it surprises me that in all of this we have not yet nor will we discuss probability theory. The only probability I learned was very basic stuff from grade school algebra. About the only thing I remember is that the probability of n events happening given n instances, with each event having an individual probability of p, is p^n. That's pretty much all I have to go on.

That said, I came across a random problem which I think I've solved, but which I'd like someone to explain to me in more proper, formal language...

Suppose you have a die with n sides, and you roll it again and again, until you roll a certain single-number result (e.g. roll a six-sided die until you get a 4). Then you repeat the experiment ad nauseum. Out of the multiple experiments, what is the average number of rolls it will take for you to get that certain result?

My solution is as follows:

Step one: The probability q of rolling an undesired result r times in a row is (\frac{n-1}{n})^r.

Step two (*this is the step with which I need the most help*): To get an average number of throws, we must let q=\frac{1}{2}. I know this intuitively, but how do I show it on paper?

Remaining steps:

\frac{1}{2} = (\frac{n-1}{n})^r

\ln{\frac{1}{2}} = \ln{(\frac{n-1}{n})^r}

\ln{\frac{1}{2}} = r \ln{\frac{n-1}{n}}

r = \frac{\ln{\frac{n-1}{n}}}{\ln{\frac{1}{2}}}

Thus, r is the average number of throws.

First, is my conclusion correct? If so, can someone please help me understand the steps?

Thanks!
Reply With Quote
Advertisement
 
  #2  
Old April 8th, 2008, 08:16 PM
mr fantastic's Avatar
Flow Master

 
Join Date: Dec 2007
Location: Zeitgeist
Posts: 12,237
Country:
Thanks: 2,574
Thanked 4,761 Times in 4,193 Posts
mr fantastic has a reputation beyond reputemr fantastic has a reputation beyond reputemr fantastic has a reputation beyond reputemr fantastic has a reputation beyond reputemr fantastic has a reputation beyond reputemr fantastic has a reputation beyond reputemr fantastic has a reputation beyond reputemr fantastic has a reputation beyond reputemr fantastic has a reputation beyond reputemr fantastic has a reputation beyond reputemr fantastic has a reputation beyond repute
Default

Quote:
Originally Posted by hatsoff View Post
Hi, all.

I took single-variable calc in high school, and will be moving on to multi-variable calc (calc 3) this summer at the community college. However, it surprises me that in all of this we have not yet nor will we discuss probability theory. The only probability I learned was very basic stuff from grade school algebra. About the only thing I remember is that the probability of n events happening given n instances, with each event having an individual probability of p, is p^n. That's pretty much all I have to go on.

That said, I came across a random problem which I think I've solved, but which I'd like someone to explain to me in more proper, formal language...

Suppose you have a die with n sides, and you roll it again and again, until you roll a certain single-number result (e.g. roll a six-sided die until you get a 4). Then you repeat the experiment ad nauseum. Out of the multiple experiments, what is the average number of rolls it will take for you to get that certain result?

My solution is as follows:

Step one: The probability q of rolling an undesired result r times in a row is (\frac{n-1}{n})^r.

Step two (*this is the step with which I need the most help*): To get an average number of throws, we must let q=\frac{1}{2}. I know this intuitively, but how do I show it on paper?

Remaining steps:

\frac{1}{2} = (\frac{n-1}{n})^r

\ln{\frac{1}{2}} = \ln{(\frac{n-1}{n})^r}

\ln{\frac{1}{2}} = r \ln{\frac{n-1}{n}}

r = \frac{\ln{\frac{n-1}{n}}}{\ln{\frac{1}{2}}}

Thus, r is the average number of throws.

First, is my conclusion correct? If so, can someone please help me understand the steps?

Thanks!
You want the expected value of a random varibale that follows a geometric distribution: Geometric distribution - Wikipedia, the free encyclopedia
__________________
There are two things you should never try to prove: the impossible and the obvious.

The greater danger for most of us lies not in setting our aim too high and falling short; but in setting our aim too low and achieving our mark. (Michelangelo Buonarroti)

  • To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.

  • To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.

  • To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.

  • To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.

  • To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
Reply With Quote
The following users thank mr fantastic for this useful post:
Donate to MHF
  #3  
Old April 14th, 2008, 06:36 AM
Member
 
Join Date: Feb 2008
Posts: 181
Country:
Thanks: 49
Thanked 41 Times in 40 Posts
hatsoff will become famous soon enough
Default

Quote:
Originally Posted by mr fantastic View Post
You want the expected value of a random varibale that follows a geometric distribution: Geometric distribution - Wikipedia, the free encyclopedia
That's helpful, but still perplexing. Wikipedia gives this formula:



Yet my answer is:

\frac{\ln{\frac{n-1}{n}}}{\ln{\frac{1}{2}}}

IE, the numerator and denominators are reversed in mine and wikipedia's. I'm not sure what the problem is, here, and I still don't know how to prove step #2 in my OP.
Reply With Quote
  #4  
Old April 14th, 2008, 07:59 AM
CaptainBlack's Avatar
Grand Panjandrum
 
Join Date: Nov 2005
Location: South of England
Posts: 11,379
Country:
Thanks: 667
Thanked 3,619 Times in 2,916 Posts
CaptainBlack has a reputation beyond reputeCaptainBlack has a reputation beyond reputeCaptainBlack has a reputation beyond reputeCaptainBlack has a reputation beyond reputeCaptainBlack has a reputation beyond reputeCaptainBlack has a reputation beyond reputeCaptainBlack has a reputation beyond reputeCaptainBlack has a reputation beyond reputeCaptainBlack has a reputation beyond reputeCaptainBlack has a reputation beyond reputeCaptainBlack has a reputation beyond repute
Default

Quote:
Originally Posted by hatsoff View Post
Hi, all.

I took single-variable calc in high school, and will be moving on to multi-variable calc (calc 3) this summer at the community college. However, it surprises me that in all of this we have not yet nor will we discuss probability theory. The only probability I learned was very basic stuff from grade school algebra. About the only thing I remember is that the probability of n events happening given n instances, with each event having an individual probability of p, is p^n. That's pretty much all I have to go on.

That said, I came across a random problem which I think I've solved, but which I'd like someone to explain to me in more proper, formal language...

Suppose you have a die with n sides, and you roll it again and again, until you roll a certain single-number result (e.g. roll a six-sided die until you get a 4). Then you repeat the experiment ad nauseum. Out of the multiple experiments, what is the average number of rolls it will take for you to get that certain result?

My solution is as follows:

Step one: The probability q of rolling an undesired result r times in a row is (\frac{n-1}{n})^r.

Step two (*this is the step with which I need the most help*): To get an average number of throws, we must let q=\frac{1}{2}. I know this intuitively, but how do I show it on paper?

Remaining steps:

\frac{1}{2} = (\frac{n-1}{n})^r

\ln{\frac{1}{2}} = \ln{(\frac{n-1}{n})^r}

\ln{\frac{1}{2}} = r \ln{\frac{n-1}{n}}

r = \frac{\ln{\frac{n-1}{n}}}{\ln{\frac{1}{2}}}

Thus, r is the average number of throws.

First, is my conclusion correct? If so, can someone please help me understand the steps?

Thanks!
The average number of rolls to get a specified result is:

\bar{N}=\sum_{r=1}^{\infty} r~ p(r)

where p(r)=(1-p)^{r-1}p is the probability of getting the desired result for the forst time on the r'th roll, and p=1/n the probability of getting the desired result on a single roll.

That your result is not right can be seen by evaluating it for some value of n.

RonL
__________________
Truth does not change because it is, or is not, believed by a majority of the people.

Giordano Bruno
Reply With Quote
The following users thank CaptainBlack for this useful post:
Donate to MHF
  #5  
Old April 14th, 2008, 08:02 AM
CaptainBlack's Avatar
Grand Panjandrum
 
Join Date: Nov 2005
Location: South of England
Posts: 11,379
Country:
Thanks: 667
Thanked 3,619 Times in 2,916 Posts
CaptainBlack has a reputation beyond reputeCaptainBlack has a reputation beyond reputeCaptainBlack has a reputation beyond reputeCaptainBlack has a reputation beyond reputeCaptainBlack has a reputation beyond reputeCaptainBlack has a reputation beyond reputeCaptainBlack has a reputation beyond reputeCaptainBlack has a reputation beyond reputeCaptainBlack has a reputation beyond reputeCaptainBlack has a reputation beyond reputeCaptainBlack has a reputation beyond repute
Default

Quote:
Originally Posted by hatsoff View Post
That's helpful, but still perplexing. Wikipedia gives this formula:



Yet my answer is:

\frac{\ln{\frac{n-1}{n}}}{\ln{\frac{1}{2}}}

IE, the numerator and denominators are reversed in mine and wikipedia's. I'm not sure what the problem is, here, and I still don't know how to prove step #2 in my OP.
Because step 2 in your post is pulled out of the air, and is not relevant.

You might know it intuitivly, but its still wrong.

RonL
__________________
Truth does not change because it is, or is not, believed by a majority of the people.

Giordano Bruno
Reply With Quote
  #6  
Old April 14th, 2008, 08:19 AM
Member
 
Join Date: Feb 2008
Posts: 181
Country:
Thanks: 49
Thanked 41 Times in 40 Posts
hatsoff will become famous soon enough
Default

Quote:
Originally Posted by CaptainBlack View Post
The average number of rolls to get a specified result is:

\bar{N}=\sum_{r=1}^{\infty} r~ p(r)

where p(r)=(1-p)^{r-1}p is the probability of getting the desired result for the forst time on the r'th roll, and p=1/n the probability of getting the desired result on a single roll.

That your result is not right can be seen by evaluating it for some value of n.

RonL
So, let's say we use a six-sided die as an example, such that p=\frac{1}{6}

Then:

p(r)=(1-\frac{1}{6})^{r-1}\frac{1}{6}

p(r)=(\frac{5}{6})^{r-1}\frac{1}{6}

So:

\bar{N}=\frac{1}{6}\sum_{r=1}^{\infty} r~ (\frac{5}{6})^{r-1}

\bar{N}=\frac{1}{6}\sum_{r=1}^{\infty} r~ (\frac{5}{6})^{r}\frac{6}{5}

\bar{N}=\frac{1}{5}\sum_{r=1}^{\infty} r~ (\frac{5}{6})^{r}

That's as far as I can go at my current level. Would you mind finishing the solution, so I can compare it to my natural log equation?
Reply With Quote
  #7  
Old April 14th, 2008, 09:34 AM
Member
 
Join Date: Feb 2008
Posts: 181
Country:
Thanks: 49
Thanked 41 Times in 40 Posts
hatsoff will become famous soon enough
Default

Quote:
Originally Posted by CaptainBlack View Post
Because step 2 in your post is pulled out of the air, and is not relevant.

You might know it intuitivly, but its still wrong.

RonL
This isn't rigorous, I know, but here is my thinking...

If r throws of a die with n sides does not yield the target result, then the probability p of that happening is (\frac{n-1}{n})^r. Now, if we only throw the die r times such that p>\frac{1}{2}, then we should not expect to have thrown the target result. However, if p<\frac{1}{2}, then we should expect to throw the target result, because we have less than a 50% chance of not doing so. If we repeat this an infinite number of times, it seems to me that the average value of r throws to reach the desired result should reflect the expected values for each complete trial.

Or so I have been thinking.
Reply With Quote
  #8  
Old April 14th, 2008, 11:06 AM
CaptainBlack's Avatar
Grand Panjandrum
 
Join Date: Nov 2005
Location: South of England
Posts: 11,379
Country:
Thanks: 667
Thanked 3,619 Times in 2,916 Posts
CaptainBlack has a reputation beyond reputeCaptainBlack has a reputation beyond reputeCaptainBlack has a reputation beyond reputeCaptainBlack has a reputation beyond reputeCaptainBlack has a reputation beyond reputeCaptainBlack has a reputation beyond reputeCaptainBlack has a reputation beyond reputeCaptainBlack has a reputation beyond reputeCaptainBlack has a reputation beyond reputeCaptainBlack has a reputation beyond reputeCaptainBlack has a reputation beyond repute
Default

Quote:
Originally Posted by CaptainBlack View Post
The average number of rolls to get a specified result is:

\bar{N}=\sum_{r=1}^{\infty} r~ p(r)

where p(r)=(1-p)^{r-1}p is the probability of getting the desired result for the forst time on the r'th roll, and p=1/n the probability of getting the desired result on a single roll.

That your result is not right can be seen by evaluating it for some value of n.

RonL
And of course we have:

\bar{N}=\sum_{r=1}^{\infty} r~ (1-p)^{r-1}p = \frac{1}{p}=n

Which we could deduce from more general principles but its nice to see the series summed anyway.

RonL
__________________
Truth does not change because it is, or is not, believed by a majority of the people.

Giordano Bruno
Reply With Quote
The following users thank CaptainBlack for this useful post:
Donate to MHF
  #9  
Old April 14th, 2008, 11:41 AM
Member
 
Join Date: Feb 2008
Posts: 181
Country:
Thanks: 49
Thanked 41 Times in 40 Posts
hatsoff will become famous soon enough
Default

Quote:
Originally Posted by CaptainBlack View Post
And of course we have:

\bar{N}=\sum_{r=1}^{\infty} r~ (1-p)^{r-1}p = \frac{1}{p}=n

Which we could deduce from more general principles but its nice to see the series summed anyway.

RonL
Thank you. This helps a great deal. I see clearly now that I was mistaken, and I see where and why. However, though I do not doubt your conclusion, neither do I understand how you reached it. I therefore have a couple more questions...

Firstly, how did you get from here:

\sum_{r=1}^{\infty} r~ (1-p)^{r-1}p

to here:

\frac{1}{p}

? Also, would you be able to explain in newbie terms how you got this initial formula:

\bar{N}=\sum_{r=1}^{\infty} r~ p(r)

?

Thanks for all your help so far!
Reply With Quote
  #10  
Old April 14th, 2008, 05:27 PM
Member
 
Join Date: Feb 2008
Posts: 181
Country:
Thanks: 49
Thanked 41 Times in 40 Posts
hatsoff will become famous soon enough
Default

Okay, guys, after thinking about it a while, I think I understand. The probability p(r) of rolling a certain number in r trials can be multiplied by each value r and added up for all possible values of r (IE, \sum_{r=1}^{\infty}). What troubles me is that \sum_{r=1}^{\infty}p(r) does not seem to calculate out to 1. Consider:

p(r)=(1-p)^{r-1}p

p=\frac{1}{n}

p(r)=(1-\frac{1}{n})^{r-1}\frac{1}{n}

p(r)=(1-\frac{1}{n})^{r}(\frac{n}{n-1})(\frac{1}{n})

p(r)=(1-\frac{1}{n})^{r}\frac{1}{n-1}

\sum_{r=1}^{\infty}p(r)=\sum_{r=1}^{\infty}(1-\frac{1}{n})^{r}\frac{1}{n-1}

\sum_{r=1}^{\infty}p(r)=\frac{1}{n-1}\sum_{r=1}^{\infty}(1-\frac{1}{n})^{r}

\sum_{r=1}^{\infty}p(r)=\frac{1}{n-1}\sum_{r=1}^{\infty}(\frac{n-1}{n})^{r}

\sum_{r=1}^{\infty}p(r)=(\frac{1}{n-1})\frac{1}{1-\frac{n-1}{n}}

\sum_{r=1}^{\infty}p(r)=\frac{n}{n-1}

Am I doing something wrong, here? Shouldn't this come out to be 1, and not \frac{n}{n-1}?
Reply With Quote
  #11  
Old April 14th, 2008, 05:34 PM
mr fantastic's Avatar
Flow Master

 
Join Date: Dec 2007
Location: Zeitgeist
Posts: 12,237
Country:
Thanks: 2,574
Thanked 4,761 Times in 4,193 Posts
mr fantastic has a reputation beyond reputemr fantastic has a reputation beyond reputemr fantastic has a reputation beyond reputemr fantastic has a reputation beyond reputemr fantastic has a reputation beyond reputemr fantastic has a reputation beyond reputemr fantastic has a reputation beyond reputemr fantastic has a reputation beyond reputemr fantastic has a reputation beyond reputemr fantastic has a reputation beyond reputemr fantastic has a reputation beyond repute
Default

Quote:
Originally Posted by hatsoff View Post
Thank you. This helps a great deal. I see clearly now that I was mistaken, and I see where and why. However, though I do not doubt your conclusion, neither do I understand how you reached it. I therefore have a couple more questions...

Firstly, how did you get from here:

\sum_{r=1}^{\infty} r~ (1-p)^{r-1}p

to here:

\frac{1}{p}
[snip]
\sum_{r=1}^{\infty} r~ (1-p)^{r-1}p = p \sum_{r=1}^{\infty} r~ u^{r-1}

where u = 1 - p. Note that |u| < 1.

----------------------------------------------------------------------

Interlude:

A standard result (the sum of an infinite geometric series):

\sum_{r = 0}^{\infty} u^r = \frac{1}{1-u}, \, \, |u| < 1.

If you differentiate both sides of this result with respect to u:

\sum_{r = 1}^{\infty} r ~ u^{r-1} = \frac{1}{(1-u)^2}, \, \, |u| < 1.

End interlude.

-----------------------------------------------------------------------

Therefore p \sum_{r=1}^{\infty} r~ u^{r-1} = \frac{p}{(1 - u)^2} = \frac{p}{p^2} = \frac{1}{p}.


Quote:
Originally Posted by hatsoff View Post
[snip]
Also, would you be able to explain in newbie terms how you got this initial formula:

\bar{N}=\sum_{r=1}^{\infty} r~ p(r)
[snip]
By definition, the expected value of a function f(r) is \sum_{r=1}^{\infty} f(r) ~ p(r). You're interested in the expected value of r, the number of rolls. Therefore ......
__________________
There are two things you should never try to prove: the impossible and the obvious.

The greater danger for most of us lies not in setting our aim too high and falling short; but in setting our aim too low and achieving our mark. (Michelangelo Buonarroti)

  • To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.

  • To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.

  • To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.

  • To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.

  • To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off
Forum Jump


All times are GMT -7. The time now is 09:58 PM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0 ©2008, Crawlability, Inc.
©2005 - 2009 Math Help Forum


Math Help Forum is a community of maths forums with an emphasis on maths help in all levels of mathematics.
Register to post your math questions or just hang out and try some of our math games or visit the arcade.