Line-line intersection - Line segment intersection

Line-line intersection - Line segment intersection

1. Line-line intersection

In Euclidean geometry, the intersection of a line and a line can be the empty set, a point, or a line. Distinguishing these cases and finding the intersection point have use, for example, in computer graphics, motion planning, and collision detection.
在欧几里德几何中,直线和直线的交点可以是空集、点或直线。区分这些情况并找到交叉点可用于例如计算机图形、运动规划和碰撞检测。

In three-dimensional Euclidean geometry, if two lines are not in the same plane they are called skew lines and have no point of intersection. If they are in the same plane there are three possibilities: if they coincide (are not distinct lines) they have an infinitude of points in common (namely all of the points on either of them); if they are distinct but have the same slope they are said to be parallel and have no points in common; otherwise they have a single point of intersection.
在三维欧氏几何中,如果两条线不在同一平面中,则它们被称为斜线并且没有交点。如果它们在同一平面上,则有三种可能性:如果它们重合 (不是明显的线条),则它们具有无限的共同点 (所有交点在任一条线上)。如果它们是截然不同但具有相同的斜率,则称它们是平行的并且没有共同点,否则他们只有一个交叉点。

intersection [ɪntə'sekʃ(ə)n]:n. 交叉,十字路口,交集,交叉点
geometry [dʒɪ'ɒmɪtrɪ]:n. 几何学,几何结构
Euclidean [ju:'klidiən]:adj. 欧几里德几何学的,欧几里德的
collision [kə'lɪʒ(ə)n]:n. 碰撞,冲突,(意见、看法) 的抵触,(政党等的) 倾轧
skew [skjuː]:adj. 偏的,歪斜的,偏态的,异面的 n. 斜角,倾斜,偏见,偏态 v. 偏离,歪斜,扭转,偏转,歪曲,使 (分布) 偏态,斜视
infinitude [ɪn'fɪnɪtjuːd]:n. 无限,无穷
coincide [,kəʊɪn'saɪd]:vi. 一致,符合,同时发生 vi. (在性格、品质等方面) 完全一致,相符
distinct [dɪ'stɪŋ(k)t]:adj. 明显的,独特的,清楚的,有区别的
slope [sləʊp]:n. 斜坡,倾斜,斜率,扛枪姿势 vi. 倾斜,逃走 vt. 倾斜,使倾斜,扛

在这里插入图片描述

The intersection of lines.

2. Line segment intersection

In computational geometry, the line segment intersection problem supplies a list of line segments in the Euclidean plane and asks whether any two of them intersect (cross).
在计算几何中,线段交叉问题提供欧几里德平面中的线段列表,并询问它们中的任何两个是否相交 (交叉)。

Simple algorithms examine each pair of segments. However, if a large number of possibly intersecting segments are to be checked, this becomes increasingly inefficient since most pairs of segments are not close to one another in a typical input sequence. The most common, and more efficient, way to solve this problem for a high number of segments is to use a sweep line algorithm, where we imagine a line sliding across the line segments and we track which line segments it intersects at each point in time using a dynamic data structure based on binary search trees. The Shamos-Hoey algorithm [1] applies this principle to solve the line segment intersection detection problem, as stated above, of determining whether or not a set of line segments has an intersection; the Bentley-Ottmann algorithm works by the same principle to list all intersections in logarithmic time per intersection.
简单的算法检查每对线段。然而,如果要检查大量可能交叉的线段,这将变得越来越低效,因为在典型的输入序列中大多数线段对彼此不相近。解决大量细分问题的最常见、最有效的方法是使用扫描线算法,我们想象一条线在线段上滑动,我们跟踪它在每个时间点相交的线段使用基于二叉搜索树的动态数据结构。Shamos-Hoey 算法 [1] 应用该原理来解决如上所述的线段交叉检测问题,即确定一组线段是否具有交叉点。Bentley-Ottmann 算法以相同的原理工作,以每个交叉点的对数时间列出所有交叉点。

logarithmic [,lɒgə'rɪðmɪk]:adj. 对数的

References

[1] Geometric intersection problems. IEEE Symposium on Foundations of Computer Science (FOCS).
Line-Line Intersection Method With C Code Sample http://alienryderflex.com/intersect/

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

Yongqiang Cheng

梦想不是浮躁,而是沉淀和积累。

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值