有大佬帮忙解释一下这串代码的意思吗
function [X_hat] = ML_detector(y,H)
QAM_table = [-3-3j,-3-j,-3+3j,-3+j,...
-1-3j,-1-j,-1+3j,-1+j,...
3-3j,3-j,3+3j,3+j,...
1-3j,1-j,1+3j,1+j]/sqrt(10);%为啥要除10的开方啊
metric = 100000;
for k = 1:16
x_tmp(1) = QAM_table(k);
Esti_y1(:,1) = y - H(:,1)*x_tmp(1);
for m = 1:16
x_tmp(2) = QAM_table(m);
Esti_y2(:,1) = Esti_y1(:,1) - H(:,2)*x_tmp(2);
for n = 1:16
x_tmp(3) = QAM_table(n);
Esti_y3(:,1) = Esti_y2(:,1) - H(:,3)*x_tmp(3);
for o = 1:16
x_tmp(4) = QAM_table(o);
Esti_y4(:,1) = Esti_y3(:,1) - H(:,4)*x_tmp(4);
metric_tmp = sqrt(Esti_y4(:,1)'*Esti_y4(:,1));
if metric_tmp < metric
X_hat = x_tmp;
metric = metric_tmp;
end
end
end
end
end |