iscircle.m
来自「matlab的常用函数工具包」· M 代码 · 共 15 行
M
15 行
function y=iscircle(C)
%C is the matrix of the path,its style is N*2
%The function returns 0 or 1
if all(size(C)==[1 2])||isempty(C)
y=0;
return
end
k1=length(C);
k2=length(union(C(:,1),C(:,2))');
if(k1==k2-1)
y=0;
else
y=1;
end
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?