?? cp0201_repcode.m
字號(hào):
%
% FUNCTION 2.2 : "cp0201_repcode"
%
% Introduces a repetition code for the stream of 'bits' in
% input:
% 'Ns' identical binary values are generated from the same
% bit
% 'repbits' represents the output binary sequence
%
% Programmed by Guerino Giancola
%
function [repbits]=cp0201_repcode(bits,Ns)
% ----------------------------------------------
% Step One - Introduction of the repetition code
% ----------------------------------------------
numbits = length(bits);
temprect=ones(1,Ns);
temp1=zeros(1,numbits*Ns);
temp1(1:Ns:1+Ns*(numbits-1))=bits;
temp2=conv(temp1,temprect);
repbits=temp2(1:Ns*numbits);
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號(hào)
Ctrl + =
減小字號(hào)
Ctrl + -