Search for question
Question

1. (3 points) We will reconsider Question 4 of HW3 and investigate how the MMSE estimators we ob-

tained therein actually perform using MATLAB simulations. For this question, please provide the

MATLAB script you used to obtain the answers (or the Python script if you choose to use Python).

Otherwise, partial or no credit will be given.

First, recall the setting of Question 4 of HW3: Suppose that we want to estimate a random signal

value Y N(0, 1) based on observation of a subset of the following noisy measurements:

X₁ = Y + W₁, X₂=0.5Y+W₂, X3 = 5Y+W3

(1)

where W₁ N(0, 1), W₂

N(0, 1), and W3 N(0, 1); Y, W₁, W₂, and W3 are independent.

We can use the MATLAB command randn to create a Gaussian random variable with zero mean and

variance one. For instance, if you type

>> A = randn (4,1)

in MATLAB, then MATLAB will generate a four by one vector A consisting of samples of four inde-

pendent Gaussian random variables with zero mean and variance one (type help randn at MATLAB

to see more details). And, if you subsequently type

>> B = randn (4,1)

1/nthen MATLAB will generate another four by one vector B, consisting of samples of four independent

Gaussian random variables with zero mean and variance one, that is independent of A.

Use the randn function to generate 100 independent samples from the distribution of (Y, W₁, W₂, W3):

(y(100), w

(100))}

(100)(100)

{(y(¹), w{"), w), w), (y(²), w(²), w), w(²)),

Then, generate samples of random measurements using the measurement equations as follows: for

i = 1,..., 100,

x = y +w{), x) = 0.5y +w₂), r = 5y + wg.

Then, we can have 100 independent samples of Y, X₁, X2, and X3:

{(y(¹), x{¹), x¹), x(¹), (y(²), (²), 1²), (²)),

(y(100) (100) (100)(100).

(100))}

100

¡Σ(y(¹) - ÎMMSE(x,x))²

w

We will use these samples to evaluate the MMSE estimators we obtained in HW3.

(a) Let MMSE (1, 2) denote the MMSE estimator of Y given observation of X₁ and X₂ (that you

obtained in HW3). Use the generated samples of (Y, X₁, X₂, X3) to evaluate the MSE of this

estimator. In particular, for i = 1,..., 100, compute the squared error (y) — ÎMMSE(TT))².

Then, take the average squared error as an estimate of the MSE:

100

Σ(y¹ - ÿMMSE(x,x))²

i=1

Compare this MSE with the MSE of part (a) and provide interpretation.

100

(2)

(b) Let MMSE (1,3) denote the MMSE estimator of Y given observation of X₁ and X3 (that you

obtained in HW3). Use the generated samples of (Y, X₁, X2, X3) to evaluate the MSE of this

estimator. In particular, for i = 1,..., 100, compute the squared error (y)-MMSE(I),19)))².

Then, take the average squared error as an estimate of the MSE:

(3)

(4)

Fig: 1

Fig: 2