Reply by brijrajv June 16, 20042004-06-16
Hi all,

I am having problems using the combination of conv and deconv
function.
I have a large number of random processes which I convolve with its
fliped version, then I deconvolve the result obtained from
convolution with the fliped version of random process, the procedure
works for all but some specific cases.
The code below should help you understand the problem. %%%%%%% Code starts %%%%%%%%%%%%%%
t_bit-6;
r_bit=1/t_bit;
fc1= 2*r_bit;
n=4;
input_stream1=[0 1 0 1];

i=1;
j=1;

% Value of m depends on the order of the modulation
for m=1:n:(length(input_stream1)-n+1)

k=1;
% Extracting number of bits to be represented in a symbol
bit_stream1=input_stream1(1,m:(m+n-1));
dec1=bin_to_dec(bit_stream1);
% Calculating phase angle depending on the decimal equivalent
theta1(j)1* ((2*pi)/M);

for t=(m-1)*t_bit*(1/n):1/(20*fc1):((m+(n-1))*t_bit*(1/n))-(1/
(20*fc1))
% Formulae to find of the M-PSK signal
s1(k)=amp1*cos(2*pi*fc1*t + theta1(j));
y(i)=t;
i=i+1;
k=k+1;
end

% Convolution
fliped_s1=fliplr(s1);
r_s1=conv(s1,fliped_s1);

% Deconvolution
s_1onv(r_s1,fliped_s1);
diff = s1 - s_1
end

%%%%%%%%% Code ends%%%%%%%%%%%%%%%%%

The diff in this case should be zero but it is not, this problem
occurs for the input_stream1= 0 1 0 1 and 1 1 0 1 for all other 4 bit
combinations the diff is rightly zero. I am trying to find out as to
why am I not getting the diff as 0 for all cases.

Please can someone help me find out the problem.

Thanking you all in anticipation

Brijraj