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

📄 complexity.m

📁 有用的几个动力学物理量。包括自相关函数(acorr.m)
💻 M
字号:
function cmp=complexity(x,n);% cmp = complexity(x,n);%% calculate the Lempel-Ziv complexity of the n-bit encoding of x. %% cmp is the normalised complexity, that is the number of distinct% symbol sequences in x, divided by the expected number of distinct % symbols for a noise sequence.%% Algorithm is implemented in complexitybs.c%% M. Small% ensmall@polyu.edu.hk% 7/10/04if nargin<2,    n=2;end;if length(n)>1,   for ni=1:length(n),        cmp(ni)=complexity(x,n(ni));    end;    else,    %do the binning, with equi-probably bins    x=x(:);    nx=length(x);    [xn,xi]=sort(x);    y=zeros(nx,1);    y=1:nx;    y=floor(y.*(n/(nx+1)));    x(xi)=y;    %compute complexity with complexitybs    cmp=complexitybs(x+eps);end;

⌨️ 快捷键说明

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