⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 discrim16.m

📁 正交频分复用系统(OFDM)的频率偏移误差抑制技术仿真程序
💻 M
字号:
function outcomplex=discrim16(FFTsym)
%------------------------------------------------
%this function takes in a complex symbol and
%outputs the nearest 16 QAM symbol inside the constellation
%this is done by finding the shortest distance
%to any possible constellation and assigning complex
%to the nearest symbol
%Author: 王博
%Filename: discrim16.m
%----------------------------------------------

%the following are the 16 QAM constellation points
  const(1)=-1-i; 
  const(2)=-3-i; 
const(3)=-1-3*i; 
const(4)=-3-3*i; 
const(5)=1-1*i; 
const(6)=1-3*i; 
const(7)=3-1*i; 
const(8)=3-3*i; 
const(9)=-1+i; 
const(10)=-1+3i; 
const(11)=-3+i; 
const(12)=-3+3i; 
const(13)=1+i; 
const(14)=3+i; 
const(15)= 1+3i; 
const(16)=3+3i; 


        %computing all possible distances from the constants declared
        for K=1:16
            comp16(K)=abs(FFTsym-const(K));
        end

[val, index]=min(comp16);    %finding the minimum distance
outcomplex=const(index);     %the nearest symbol is returned

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -