⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 autocorrelation.m

📁 802.11仿真源码 对分析RSSI很有用的
💻 M
字号:
function Autocorrelation = Autocorrelation(file, Strength, lag)
% This function ->
%       Autocorrelation: open auto'i', calculates the autocorrelation with
%       the lag passed as an argument. The autocorrelation, Lags and bounds
%       are outputted to the screen while the specific autocorrelation is
%       printed to auto'i'
filename = sprintf('auto%d',file);
fid = fopen(filename,'w');
extract = '0';
if (fid == -1)
    disp(['ERROR: File not found or could not be opened for read. Please check auto file name']);
end

[ACF,Lags,Bounds] = autocorr(Strength, 16)

extract = ACF(lag + 1)
fprintf(fid, '%f\n', extract);

fclose(fid);

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -