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

📄 knearest.m

📁 这是一个关于混沌系统的比较全面的工具箱
💻 M
字号:
function lock=Knearest(y,Y,K,p)
%Syntax: lock=Knearest(y,Y,K,p)
%______________________________
%
% Locks the K nearest neighbors of a reference point that lie in a
% phase-space.
%
% lock returns the points located.
% y is the vector.
% Y is tha phase space.
% K is the number of the nearest neighbors.
% p is the norm indicator.
%
% Alexandros Leontitsis
% Department of Education
% University of Ioannina
% 45110 - Dourouti
% Ioannina
% Greece
%
% University e-mail: me00743@cc.uoi.gr
% Lifetime e-mail: leoaleq@yahoo.com
% Homepage: http://www.geocities.com/CapeCanaveral/Lab/1421
%
% June 15, 2001.

% Define the length of the phase space
T=size(Y,1);

for i=1:T
   dist(i)=norm(y-Y(i,:),p);
end

[dist,j]=sort(dist);
[j,f]=sort(j);
lock=f(1:K);

⌨️ 快捷键说明

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