← Back to Portal

Tutorial Sheet 5

Joint Distributions & Correlation

15 Problems Solved

👨‍🏫

Professor's Note

Welcome to Tutorial 5! Here, we move beyond single variables to analyze relationships between two random variables. Pay close attention to double integrals for joint PDFs and summation for joint PMFs. Covariance and Correlation are key metrics you must master.

Q1

Drive-in and Walk-in Facilities

X and Y are proportions of time drive-in and walk-in facilities are in use. Joint density: \[ f(x,y) = \begin{cases} \frac{2}{5}(2x+3y) & 0 \le x,y \le 1 \\ 0 & \text{otherwise} \end{cases} \] Find \( P((X,Y) \in A) \) where \( A = \{(x,y) \mid 0 \le x \le 1/2, 1/4 \le y \le 1/2\} \).

💡 Hints

Set up a double integral with limits \( x \in [0, 1/2] \) and \( y \in [1/4, 1/2] \).

📚 Concepts Used

\[ P((X,Y) \in A) = \iint_A f(x,y) \, dx \, dy \]

✍️ Full Solution

Integrating over the region:

\[ \int_{1/4}^{1/2} \int_0^{1/2} \frac{2}{5}(2x+3y) \, dx \, dy \]

Inner integral w.r.t. \( x \):

\[ \frac{2}{5} [x^2 + 3xy]_0^{1/2} = \frac{2}{5}(1/4 + 3y/2) = \frac{1+6y}{10} \]

Outer integral w.r.t. \( y \):

\[ \int_{1/4}^{1/2} \frac{1+6y}{10} \, dy = \frac{1}{10} [y + 3y^2]_{1/4}^{1/2} \]

\[ = \frac{1}{10} [(1/2 + 3/4) - (1/4 + 3/16)] = \frac{1}{10} [5/4 - 7/16] \]

Final Answer: 13/160 = 0.08125
Q2

Marginal PDFs

Find the marginal PDFs for random variables X and Y for the density function in Problem 1.

💡 Hints

Integrate out the "other" variable over its entire range (0 to 1).

✍️ Full Solution

Marginal of X:

\[ g(x) = \int_0^1 f(x,y) \, dy = \int_0^1 \frac{2}{5}(2x+3y) \, dy = \frac{2}{5}[2xy + \frac{3y^2}{2}]_0^1 = \frac{4x+3}{5} \]

Marginal of Y:

\[ h(y) = \int_0^1 f(x,y) \, dx = \int_0^1 \frac{2}{5}(2x+3y) \, dx = \frac{2}{5}[x^2 + 3xy]_0^1 = \frac{2(1+3y)}{5} \]

Range: \( 0 \le x,y \le 1 \).
Q3

Selecting Ballpoint Pens

3 Blue, 2 Red, 3 Green pens. Select 2 at random. X = number of Blue, Y = number of Red. Find (a) Joint PMF, (b) \( P(X+Y \le 1) \).

💡 Hints

Use combination formula \(\binom{n}{r}\). Total ways = \(\binom{8}{2} = 28\).

✍️ Full Solution

(a) Joint PMF Table:

(x,y) Ways P(X=x, Y=y)
(0,0) \(\binom{3}{0}\binom{2}{0}\binom{3}{2}=3\) 3/28
(1,0) \(\binom{3}{1}\binom{2}{0}\binom{3}{1}=9\) 9/28
(2,0) \(\binom{3}{2}\binom{2}{0}\binom{3}{0}=3\) 3/28
(0,1) \(\binom{3}{0}\binom{2}{1}\binom{3}{1}=6\) 6/28
(1,1) \(\binom{3}{1}\binom{2}{1}\binom{3}{0}=6\) 6/28
(0,2) \(\binom{3}{0}\binom{2}{2}\binom{3}{0}=1\) 1/28

(b) \( P(X+Y \le 1) \):

\[ P = f(0,0) + f(1,0) + f(0,1) = \frac{3+9+6}{28} = \frac{18}{28} = \frac{9}{14} \]

Q4

Conditional Distribution

In Problem 3, find the conditional distribution of X given Y=1. Calculate \( P(X=0 \mid Y=1) \).

💡 Hints

Divide the joint probabilities by the marginal total \( P(Y=1) \).

✍️ Full Solution

\[ P(Y=1) = f(0,1) + f(1,1) = 6/28 + 6/28 = 12/28 = 3/7 \]

Conditional distribution of X for \( Y=1 \):

  • \( P(X=0 \mid Y=1) = \frac{6/28}{12/28} = 1/2 \)
  • \( P(X=1 \mid Y=1) = \frac{6/28}{12/28} = 1/2 \)
Final Answer: 1/2
Q5

Expectation of XY

Determine \( E[XY] \) for the pens selection problem in Problem 3.

💡 Hints

Only the term where both \( x,y > 0 \) contributes to the sum.

✍️ Full Solution

\[ E[XY] = \sum_x \sum_y xy \cdot f(x,y) \]

The only non-zero term is \( (1 \times 1) \times f(1,1) \):

\[ E[XY] = 1 \times 1 \times \frac{6}{28} = \frac{3}{14} \]

Final Answer: 3/14 \(\approx 0.214\)
Q6

Covariance Calculation

Calculate the covariance \( Cov(X,Y) \) for the pens selection problem.

💡 Hints

Use formula: \( Cov(X,Y) = E[XY] - E[X]E[Y] \).

✍️ Full Solution

1. Find \( E[X] \): \( 1(\frac{9+6}{28}) + 2(\frac{3}{28}) = \frac{15+6}{28} = \frac{3}{4} \)

2. Find \( E[Y] \): \( 1(\frac{12}{28}) + 2(\frac{1}{28}) = \frac{14}{28} = \frac{1}{2} \)

3. \( Cov(X,Y) = \frac{3}{14} - (\frac{3}{4} \times \frac{1}{2}) = \frac{3}{14} - \frac{3}{8} \)

\[ Cov(X,Y) = \frac{12 - 21}{56} = -9/56 \]

Answer: -9/56. Negative covariance suggests an inverse relationship.
Q7

Correlation Coefficient

Determine the correlation coefficient \(\rho_{XY}\) for the pens selection problem.

💡 Hints

Divide covariance by the product of standard deviations.

✍️ Full Solution

1. \( Var(X) = E[X^2] - (E[X])^2 = 27/28 - 9/16 = 45/112 \)

2. \( Var(Y) = E[Y^2] - (E[Y])^2 = 4/7 - 1/4 = 9/28 \)

3. \( \rho = \frac{-9/56}{\sqrt{45/112 \times 9/28}} = -1/\sqrt{5} \)

Final Answer: -0.447
Q8

Atomic Spectrum Shift

Joint density: \( f(x,y) = 10xy^2, 0 < x < y < 1 \). (a) Find marginals and \( f(y|x) \). (b) \( P(Y> 1/2 \mid X = 0.25) \).

💡 Hints

Watch the limits! \( y \) goes from \( x \) to 1, and \( x \) goes from 0 to \( y \).

✍️ Full Solution

(a) Densities:

\( g(x) = \int_x^1 10xy^2 \, dy = \frac{10}{3}x(1-x^3) \)

\( h(y) = \int_0^y 10xy^2 \, dx = 5y^4 \)

\( f(y|x) = \frac{3y^2}{1-x^3} \)

(b) Probability:

\( P(Y > 1/2 \mid X=0.25) = \int_{1/2}^1 \frac{3y^2}{1-(1/4)^3} \, dy = 8/9 \)

Answer: 8/9
Q9

Independence Verification

\( f(x,y) = \frac{x(1+3y^2)}{4}, 0 < x < 2, 0 < y < 1 \). Find \( f(x|y) \) and evaluate \( P(1/4 < X < 1/2 \mid Y=1/3) \).

💡 Hints

Notice that the PDF can be factored into \( (x/2) \cdot ((1+3y^2)/2) \).

✍️ Full Solution

The variables are independent because \( f(x,y) = g(x)h(y) \).

\( f(x|y) = g(x) = x/2 \)

\[ P(1/4 < X < 1/2)=\int_{1/4}^{1/2} x/2 \, dx=[x^2/4]_{1/4}^{1/2}=3/64 \]

Answer: 3/64 \(\approx 0.0469\)
Q10

Dependent Boundaries

\( f(x,y) = 6x, 0 < x < 1, 0 < y < 1-x \). Prove/Disprove independence.

💡 Hints

Look at the range. Does the range of Y depend on X?

Verification:

1. The range is triangular (\( y < 1-x \)).

2. For independence, the domain MUST be a rectangle.

3. Calculated Marginals: \( g(x) = 6x(1-x) \) and \( h(y) = 3(1-y)^2 \).

4. \( g(x)h(y) \neq f(x,y) \).

Result: Disproved. They are Dependent.
Q11

Male and Female Runners

\( f(x,y) = 8xy, 0 < y < x < 1 \). Find the covariance of X and Y.

💡 Hints

Use \( Cov(X,Y) = E[XY] - E[X]E[Y] \). Integrate carefully over the triangle.

✍️ Full Solution

  • \( E[X] = \int_0^1 \int_0^x 8x^2y \, dy \, dx = 4/5 \)
  • \( E[Y] = \int_0^1 \int_y^1 8xy^2 \, dx \, dy = 8/15 \)
  • \( E[XY] = \int_0^1 \int_0^x 8x^2y^2 \, dy \, dx = 4/9 \)

\[ Cov(X,Y) = 4/9 - (4/5 \times 8/15) = 4/225 \]

Answer: 4/225 \(\approx 0.0178\)
Q12

Correlation of Runners

Find the correlation coefficient for the runners in Problem 11.

💡 Hints

You need \( E[X^2] \) and \( E[Y^2] \) to find variances.

✍️ Full Solution

  • \( Var(X) = 2/3 - (4/5)^2 = 2/75 \)
  • \( Var(Y) = 1/3 - (8/15)^2 = 11/225 \)

\[ \rho = \frac{4/225}{\sqrt{2/75 \times 11/225}} = 4/\sqrt{66} \approx 0.492 \]

Answer: 0.492
Q13

Uniform Triangular Distribution

\( f(x,y) = 2, 0 < x < y < 1 \). Determine the correlation coefficient.

💡 Hints

The total area is 1/2, so height \( C=2 \) is correct. The variables are dependent.

✍️ Full Solution

Calculation yields:

  • \( E[X] = 1/3, Var(X) = 1/18 \)
  • \( E[Y] = 2/3, Var(Y) = 1/18 \)
  • \( Cov(X,Y) = 1/36 \)

\[ \rho = \frac{1/36}{\sqrt{1/18 \times 1/18}} = 1/2 = 0.5 \]

Answer: 0.5
Q14

Power Failure Statistics

Probabilities for 0, 1, 2, or 3 failures are 0.4, 0.3, 0.2, 0.1. Find mean and variance.

💡 Hints

Purely discrete PMF. Sum \( x \cdot P(x) \) and \( x^2 \cdot P(x) \).

✍️ Full Solution

Mean: \( 0(0.4) + 1(0.3) + 2(0.2) + 3(0.1) = 1.0 \)

\( E[X^2] \): \( 0(0.4) + 1(0.3) + 4(0.2) + 9(0.1) = 2.0 \)

Variance: \( 2.0 - 1.0^2 = 1.0 \)

Mean = 1.0, Variance = 1.0
Q15

Airplane Takeoff Clearance

\( Y = 3X - 2 \), where \( X \) has density \( f(x) = \frac{1}{4} e^{-x/4}, x > 0 \). Find mean and variance of Y.

💡 Hints

Identify X as an exponential distribution with parameter \(\lambda = 1/4\).

📚 Concepts Used

\[ E[aX+b] = aE[X]+b \]
\[ Var(aX+b) = a^2Var(X) \]

✍️ Full Solution

1. For \( X \sim Expo(1/4) \): \( E[X] = 4 \), \( Var(X) = 16 \).

2. \( E[Y] = 3(4) - 2 = 10 \).

3. \( Var(Y) = 3^2 \times 16 = 144 \).

Mean = 10, Variance = 144