This is topic Math Help in forum Books, Films, Food and Culture at Hatrack River Forum.


To visit this topic, use this URL:
http://www.hatrack.com/ubb/main/ultimatebb.php?ubb=get_topic;f=2;t=037962

Posted by Paul Goldner (Member # 1910) on :
 
I know I haven't posted in a while, but I'm hoping there are still some math dorks out there who can help me [Smile] I'm taking a physics class where I don't really understand the math, so this thread may get bumped up every few days. For the moment, I'm working with the binomial distribution, and I'm being asked to calculate the average value of X^2 where x=n1-n2.

Or, basically, <x^2>=?
Now, I'm pretty sure the next step here is
< x^2 >=< {n1-n2}^2 >

I'm not making any mathematical mistakes in that step am I?

Assuming thats correct, where do I go from there?

If this were a first order calculation, I'd simply say that < x >=< n1-n2 >=Np-Nq (N the total number of trials, p and q the probability of each outcome). Can I stick that inside the brackets for the second order, and say < x^2 >=< {Np-Nq}^2 >? If not, can you explain why? And if so, what do I do from there? At that point, I don't even have a clue, really.
 
Posted by Tigger (Member # 8171) on :
 
What does this equation do? I mean - what is the practical application?
 
Posted by BannaOj (Member # 3206) on :
 
you've got to do the binomial expansion (or good old FOIL) so
{n1^2 +2*n1*(-n2)+(-n2)^2} is I think your next step... not sure where to go after that though
though simplified:


{n1^2+n2^2-2*n1*n2}

AJ
 
Posted by Rico (Member # 7533) on :
 
Well, whatever n1 and n2 stand for, plug them into the new equation and solve it [Smile]
 
Posted by El JT de Spang (Member # 7742) on :
 
Do? It doesn't do anything. That's the beauty of it.
 
Posted by Corwin (Member # 5705) on :
 
[Laugh] JT
 
Posted by rivka (Member # 4859) on :
 
Rico, it is unlikely n1 and n2 have been assigned numerical values. But Paul may have been given a range.

Were you, Paul? Good to see you back here, BTW. [Smile]

Meanwhile, this looked like it might be useful. If you have questions that are more physics-specific, I'm more likely to be helpful. Abstract calculus is not something I am overly fond of. [Razz]
 
Posted by Rico (Member # 7533) on :
 
Well usually in physics you're given some basic values in your typical word problem. I figured n1 stood for one number in the formula, and n2 stood for another.

Perhaps it might help more if Paul gave us an example problem in which this formula is used [Smile]
 
Posted by Sean (Member # 689) on :
 
If the question is:

n1 is a random variable that is 1 with probability p and 0 otherwise.

n2 is a random variable that is 1 with probability q and 0 otherwise.

What is the average value of (n1-n2)^2

Then you can go ahead (I'm assuming < > indicates average) and say:

< [n1-n2]^2 >
= < n1^2 + n2^2 - 2n1n2 >
= < n1^2 > + < n2^2 > - 2 < n1 > < n2 >
= p^2 + q^2 - 2pq

I'm guessing I don't understand what the question is though, since it has nothing to do with a number of trials. Could you explain it more?
 
Posted by SenojRetep (Member # 8614) on :
 
You can't say <2n1n2> = 2<n1><n2> unless you know that n1 and n2 are uncorrelated.

Paul, is p probability of sucess, q probability of failure, and N total number of trials?
 
Posted by Paul Goldner (Member # 1910) on :
 
HRm.

N is number of trials. q is probability of result 2 happening. p is probability of result 1 happening. n1 is number of events of result 1, n2 is number of events of result 2. They are uncorrelated events.
 
Posted by SenojRetep (Member # 8614) on :
 
What I meant was is N = n1+n2 (i.e. only two events. That's usually assumed in binomial, but sometimes people say binomial and mean multi-nomial).

If so then q = 1-p, and I would solve the problem:
<x^2> = <[n1-n2]^2>
= <n1^2> -2<n1><n2> + <n2^2>
= Npq+(Np)^2 - 2(Np)(Nq) + Npq+(Nq)^2

where I used the fact that <x^2> = Var(x)+<x>^2 and Var(n1) = Var(n2) = Npq and <n1> = Np and <n2> = Nq. If there are multiple possible events then the Var(n1) and Var(n2) are different.

Then, substituting in q = 1-p you may be able to simplify further. Of course there's no guarantee I did any of it right. I use stats a lot, but abuse it almost as much.
 
Posted by SenojRetep (Member # 8614) on :
 
<edit>
This isn't right. I think I see why. Are n1 and n2 two separate random variables, each with N trials? If so the correct final line should be:
= Np(1-p)+(Np)^2 - 2(Np)(Nq) + Nq(1-q)+(Nq)^2

since then Var(n1) = Np(1-p) and Var(n2) = Nq(1-q)

If n1 and n2 have a different number of trials, say N_1 and N_2, then the final line should be:
= N_1p(1-p)+(N_1p)^2 - 2(N_1p)(N_2q) + N_2q(1-q) + (N_2q)^2

I think.
 
Posted by Tigger (Member # 8171) on :
 
quote:
Originally posted by El JT de Spang:
Do? It doesn't do anything. That's the beauty of it.

That's really cruel . . .

*deflated springs*
 


Copyright © 2008 Hatrack River Enterprises Inc. All rights reserved.
Reproduction in whole or in part without permission is prohibited.


Powered by Infopop Corporation
UBB.classic™ 6.7.2