I want to implement Least Square (LS) channel estimation method in the presense of AWGN noise in MATLAB.
$y(n) = x(n) * h(n)$
$Y(k) = X(k)H(K)$
Y(k) is the received signal in frequency domain. According to LS algorithm, to estimate the channel
$H_{estimate} = Y(k)/X(k)$
Mean square error (MSE) is used to measure the performance of the estimator. MSE is defined as
MSE = $E(|H(k) - H_{estimate}|^2)$
Question is, how to get the value of $H(k)$ of white noise?
I wrote the following code in matlab, but it doesn't produce constant values in frequency.
white_noise_time_domain = sqrt(1/2)*(randn(N,1)+1i*randn(n,1));
white_noise_freq_response = fftshift(fft(white_noise_time_domain));
white_noise_freq_response doesn't give flat response. I guess this is not the right way to calculate the frequency responce of white noise. Could someone explain me how to get frequency response of white noise in MATLAB?