the uniform distribution

Nas

Apr 2010
11
0
Does anyone have a clue on how to do this?

A random variable x with a probability density function
f(x):=| 1/(b-a)
| 0

a≤x≥b
x<a or x>b
is said to be uniforly distributed over the interval (a,b)

a) Find the mean of x
b) Find the variance of x
 
May 2009
959
362
EDIT: \(\displaystyle \mu = \frac{1}{2} \int^{b}_{a} x \ dx = \frac{1}{b-a} \frac{x^{2}}{2}|^{b}_{a} = \frac{1}{b-a} \frac{b^{2}-a^{2}}{2} = \frac{b+a}{2}\)
 
Last edited:

Nas

Apr 2010
11
0
thank you for the help.

In order to calculate the variance, do I use the formula where the variance is equal to the integral of (x-mean)^2*f(x)dx?
 
May 2009
959
362
EDIT: \(\displaystyle \sigma^{2} = \frac{1}{b-a} \int^{b}_{a} (x-\mu)^{2} \ dx = \frac{1}{b-a} \int^{b}_{a} \Big(x-\frac{b+a}{2}\Big)^{2} \ dx\)

\(\displaystyle = \frac{1}{b-a} \int^{b}_{a} \Big( x^{2} - (b+a) x + \frac{(b+a)^{2}}{4} \Big) \ dx \)

\(\displaystyle = \frac{1} {b-a} \Big( \frac{x^{3}}{3} - (b+a) \ \frac{x^{2}}{2} + \frac{(b+a)^{2}}{4} \ x \Big)\Big|^{b}_{a} \)

\(\displaystyle = \frac{1}{b-a} \Big(\frac{b^{3}}{3} - (b+a) \frac{b^{2}}{2} + \frac{(b+a)^{2}}{4} b - \frac{a^{3}}{3} + (b+a) \frac{a^{2}}{2} - \frac{(b+a)^{2}}{4} a \Big) \)

\(\displaystyle = \frac{1}{b-a} \Big(\frac{b^{3}-a^{3}}{3} + \frac{b+a}{2} (a^{2}-b^{2}) + \frac{(b+a)^{2}}{4} \ (b-a) \Big) \)

\(\displaystyle = \frac{b^{2}+ab+a^{2}}{3} - \frac{(b+a)^{2}}{2} + \frac{(b+a)^{2}}{4} \)

\(\displaystyle = \frac{4b^{2}+4ab+4a^{2}-6b^{2}-12ab-6a^{2} + 3b^{2}+6ab + 3a^{2}}{12} \)

\(\displaystyle = \frac{b^{2}-2ab+a^{2}}{12} = \frac{(b-a)^{2}}{12} \)
 
Last edited:
Jan 2010
354
173
The mean should be:

\(\displaystyle \mu = E[X]= \int_{-\infty}^{\infty} x \, f(x) \, dx = \frac{1}{b-a} \int_a^b x \, dx = \frac{1}{b-a} \cdot \frac{b^2-a^2}{2} = \frac{a+b}{2}\)
 
  • Like
Reactions: Random Variable
May 2009
959
362
The mean should be:

\(\displaystyle \mu = E[X]= \int_{-\infty}^{\infty} x \, f(x) \, dx = \frac{1}{b-a} \int_a^b x \, dx = \frac{1}{b-a} \cdot \frac{b^2-a^2}{2} = \frac{a+b}{2}\)
(Doh)


I fixed both of my previous posts.
 
Last edited:

mr fantastic

MHF Hall of Fame
Dec 2007
16,948
6,768
Zeitgeist
thank you for the help.

In order to calculate the variance, do I use the formula where the variance is equal to the integral of (x-mean)^2*f(x)dx?
Easier to calculate E(X^2). Then \(\displaystyle Var(X) = E(X^2) - (E(X))^2\).