Intersects

版本 1.0.0 (1.3 KB) 作者: Mustafa Codur
Fast method for intersects. It finds intersect points between lines using arithmetic geometry formulas
24.0 次下载
更新 2020/10/5

查看许可证

It finds intersect points between lines using arithmetic geometry formulas. to find all intersects run it like following;

here, x1,x2,x3,x4 are defined as;

x1=rand(1,100); y1=rand(1,100); x2=rand(1,100); y2=rand(1,100);

x=[];
y=[];
tic
for i = 1:100
x2a = circshift(x2,i);
y2a = circshift(y2,i);
[xa,ya]=Intersects(x1,y1,x2a,y2a);
x=[x,xa];
y=[y,ya];
end
toc
plot(x1,y1,'g',x2,y2,'b',x,y,'ko'),

引用格式

Mustafa Codur (2026). Intersects (https://ww2.mathworks.cn/matlabcentral/fileexchange/80701-intersects), MATLAB Central File Exchange. 检索时间: .

MATLAB 版本兼容性
创建方式 R2020b
兼容任何版本
平台兼容性
Windows macOS Linux
标签 添加标签
版本 已发布 发行说明
1.0.0