www.gusucode.com > DS-cdma仿真matlab程序 > code8/cdma/ds_demod.m
%************************************************************************************* % This function does the DS-SS modulation % % AUTHOR: Wenbin Luo % DATE : 04/28/01 % % SYNOPSIS: x = ds_demod(c,y) % c ---> user code (column vector) % y ---> tmp = c*x, y = tmp(:) (ds-ss modulated signal, column vector) % x ---> input signal (row vector) %*********************************************************************************** function x = ds_demod(c,y) tmp = reshape(y, length(c), length(y)/length(c)); tmp = tmp'; %x is a column vector x = tmp * c; % convert to row vector x = x';