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

📄 trellis_encoder.m

📁 it is very good codes for space-time systerms
💻 M
字号:
function enc_data = trellis_encoder(data,dlt,slt)

%**************************************************************************
%   Space-time trellis channel encoder
%   Q = TRELLIS_ENCODER(D,DLT,SLT) performs the data (D) encoding based on 
%   the DLT and SLT look-up tables. The tables for AT&T space-time codes 
%   these tables may be easily obtained from the LTABLE function. In fact 
%   the structure of look-up tables is as general as possible. 
%   The encoder doesn't care about the content of the look-up tables. 
%   This feature allows you to force the encoder's operation mode into 
%   the arbitrary scheme. Even an encoding based on block codes may be
%   performed using the space function. This is when the slt table is
%   filled with equal entries. 
%**************************************************************************

[fr_length,l,frames] = size(data);

s = 1; % setting up initial state

for k = 1:frames
	for i = 1:fr_length  
		d = data(i,1,k) + 1; % data_dim=1       % stc encoder                      
    enc_data(i,:,k) = dlt(s,d,:) ;              % stc encoder
    s = slt(s,d,:)  ;                           % stc encoder
    end                                         % stc encoder

end

⌨️ 快捷键说明

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