Let N,X1,Y1,X2,Y2,… be independent random variables. The random variable N takes positive integer values and has mean a and variance r. The random variables Xi are independent and identically distributed with mean b and variance s, and the random variables Yi are independent and identically distributed with mean c and variance t. Let

A=∑i=1NXiandB=∑i=1NYi.
Find cov(A,B). Express your answer in terms of the given means and variances using standard notation.

cov(A,B)= - unanswered
Find var(A+B). Express your answer in terms of the given means and variances using standard notation.

var(A+B)= - unanswered

To find the covariance of A and B, we can start by using the definition of covariance:

cov(A, B) = E[(A - E[A])(B - E[B])]

First, let's find E[A]. Since each Xi is independent and identically distributed with mean b, and N is independent of Xi, the expected value of A can be calculated as:

E[A] = E[∑i=1NXi]
= ∑i=1NE[Xi] (using linearity of expectation)
= N * E[Xi] (since Xi is identically distributed)
= N * b (since E[Xi] = b)

Similarly, we can find E[B]:

E[B] = E[∑i=1NYi]
= ∑i=1NE[Yi] (using linearity of expectation)
= N * E[Yi] (since Yi is identically distributed)
= N * c (since E[Yi] = c)

Now, let's compute the covariance:

cov(A, B) = E[(A - E[A])(B - E[B])]
= E[(∑i=1NXi - N * b)(∑i=1NYi - N * c)]

Since all the random variables are independent, we can split the expectation:

cov(A, B) = E[∑i=1NE[(Xi - b)(Yi - c)]]
= ∑i=1NE[(Xi - b)(Yi - c)] (using linearity of expectation)

Since Xi and Yi are identically distributed with mean b and c respectively, we have:

cov(A, B) = ∑i=1NE[(Xi - b)(Yi - c)]
= ∑i=1NE[(Xi * Yi - Xi * c - b * Yi + b * c)]
= ∑i=1N[E[Xi * Yi] - E[Xi * c] - E[b * Yi] + E[b * c]] (using linearity of expectation)
= ∑i=1NE[Xi * Yi] - ∑i=1NE[Xi * c] - ∑i=1NE[b * Yi] + ∑i=1NE[b * c] (using linearity of expectation)
= ∑i=1NE[Xi * Yi] - c * ∑i=1NE[Xi] - b * ∑i=1NE[Yi] + N * b * c (using linearity of expectation)
= ∑i=1NE[Xi * Yi] - c * N * b - b * N * c + N * b * c (since ∑i=1NE[Xi] = N * b and ∑i=1NE[Yi] = N * c)
= ∑i=1NE[Xi * Yi] - 2 * N * b * c + N * b * c
= ∑i=1NE[Xi * Yi] - N * b * c

Now, let's look at the variance of the sum A + B.

var(A + B) = var(∑i=1NXi + ∑i=1NYi)

Since the Xi and Yi are independent, we can use the property var(X + Y) = var(X) + var(Y) for independent random variables to get:

var(A + B) = var(∑i=1NXi) + var(∑i=1NYi)

Using the properties of variance, we know that var(kX) = k^2 * var(X) for any constant k.

var(A + B) = N * var(Xi) + N * var(Yi)
= N * s + N * t
= N * (s + t)

Therefore, the covariance of A and B is given by ∑i=1NE[Xi * Yi] - N * b * c and the variance of A + B is N * (s + t).