www.gusucode.com > 均衡算法误码率对比源码程序 > 均衡算法误码率对比源码程序/Code/Sequence_Gen.m
function [Data_Seq,Sym_Seq] = Sequence_Gen(T,Const,ML_SearchSpace,BitsPerSymbol) for i = 1:ML_SearchSpace %ith sequence of transmitted symbols in the whole search space for j = 1:T %For jth transmitted symbol in ith sequence a = j*BitsPerSymbol; %last bit of jth transmitted symbol b = a - BitsPerSymbol + 1; %first bit of jth transmitted symbol Data_Seq(i,j) = binvect2dec_m(fliplr(bitget(i-1,b:a)));%decimal value for jth transmitted symbol Sym_Seq(i,j)= Const(Data_Seq(i,j)+1); end end