Answer:
(a) The mean of X is 2.
(b) The variance X is [tex]\frac{7}{3}[/tex].
Step-by-step explanation:
The random variable X defined as follows:
X = heads, then X follows Uniform (0, 1).
X = tails, then X follows Uniform (3, 4).
(a)
The expected value of a Uniform random variable U (a, b) is:
[tex]Mean=\frac{1}{2}(a+b)[/tex]
Compute the expected value of X = heads as follows:
[tex]E(X=heads)=\frac{1}{2}(0+1)=\frac{1}{2}=0.50[/tex]
Compute the expected value of X = tails as follows:
[tex]E(X=tails)=\frac{1}{2}(3+4)=\frac{7}{2}=3.50[/tex]
Compute the mean of X as follows:
[tex]E(X)=\frac{E(X=heads)+E(X=tails)}{2} =\frac{0.50+3.50}{2}=\frac{4.00}{2}=2[/tex]
Thus, the mean of X is 2.
(b)
Compute the variance of X as follows:
[tex]V(X)=\frac{1}{2}\int\limits^{1}_{0} {\frac{1}{1-0}[X-E(X)]^{2}} \, dx +\frac{1}{2}\int\limits^{4}_{3} {\frac{1}{4-3}[X-E(X)]^{2}} \, dx \\=\frac{1}{2}\int\limits^{1}_{0} {[x-2]^{2}} \, dx +\frac{1}{2}\int\limits^{4}_{3} {[x-2]^{2}} \, dx \\=\frac{1}{2}[\frac{(x-2)^{3}}{3}]^{1}_{0}+\frac{1}{2}[\frac{(x-2)^{3}}{3}]^{4}_{3}\\=(\frac{1}{2}\times\frac{7}{3})+(\frac{1}{2}\times\frac{7}{3})\\=\frac{7}{3}[/tex]
Thus, the variance X is [tex]\frac{7}{3}[/tex].