I want to find the filtered signal and remove the noise from the discrete received signal from the radar and convirte it to continuos
4 views (last 30 days)
Show older comments
I want to find the filtered signal and remove the noise from the discrete received signal from the radar and convirte it to continuos but when i try to convert an error meassge apper and the filtered signal dosen't meake sence because the threshold is small compearing withe the magitude of the signal
% import the signal received
D= load('Cp2Data1.mat');
rec= D.r;
% plot the data
plot(rec);
xlabel('n');
ylabel('rec(n)');
title('recived signal');
% becuase we have white gous we find the aouto corrolation to find the mean
% and standard devison
filt= filter2(rec,rec,'same');
% we take the first 2000 sample to determine the threshold
d= datasample(filt,2000);
m= mean(d);
s= std(d);
% given that PF=10^-3
PF= 10^-3;
q= qfuncinv(PF);
% we calculate t= mean+ standard devison*q where t is the threshold
t= m+s*q;
% we use filter2 to filter the recived signal and find the important data
k= 0:199;
K=1000*sin(0.1*pi*k);
% then we corrolate the recived signal with the
filtered= filter2(K,rec,'same');
con_filtered= c2d(filtered,0.1);
plot(con_filtered);
hold on
yline(t);
Error using c2d (line 52)
Not enough input arguments.
Error in HW EE301 (line 26)
con_filtered= c2d(filtered,0.1);
Thanks
2 Comments
Jan
on 18 Feb 2023
@Abdullah Alaqal: The error message tells you, that the function c2d() requires more input arguments.But the documentation looks, like 2 inputs are sufficient.
Answers (1)
See Also
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!