Manhattan Distance Calculation(曼...
来源:百度文库 编辑:神马文学网 时间:2024/04/29 20:52:33
Manhattan Distance Calculation(曼哈顿距离算法)
Thu, 25 Sep 2008 13:59:17 GMT | Permanent LinkComments[1]Visit[69]
首先介绍一下曼哈顿,曼哈顿是一个极为繁华的街区,高楼林立,街道纵横,从A地点到达B地点没有直线路径,必须绕道,而且至少要经C地点,走AC和CB才能到达,由于街道很规则,ACB就像一个直角3角形,AB是斜边,AC和CB是直角边,根据毕达格拉斯定理,或者向量理论,都可以知道用AC和CB可以表达AB的长度。
在早期的计算机图形学中,屏幕是由像素构成,是整数,点的坐标也一般是整数,原因是浮点运算很昂贵,很慢而且有误差,如果直接使用AB的距离,则必须要进行浮点运算,如果使用AC和CB,则只要计算加减法即可,这就大大提高了运算速度,而且不管累计运算多少次,都不会有误差。因此,计算机图形学就借用曼哈顿来命名这一表示方法。
在我们常用的平面CAD中,都会有格点,他是基本单位,定义了格点大小后,就可以使用整数来表示和运算,不会引入计算误差,又快又精确。
与此类似,在3维图形学中,空间向量也是用3个单位向量的和来表示的。
欧氏距离:
在二维和三维空间中的欧式距离的就是两点之间的距离,二维的公式是
d = sqrt((x1-x2)^+(y1-y2)^)
三维的公式是
d=sqrt(x1-x2)^+(y1-y2)^+z1-z2)^)
推广到n维空间,欧式距离的公式是
d=sqrt( ∑(xi1-xi2)^ ) 这里i=1,2..n
xi1表示第一个点的第i维坐标,xi2表示第二个点的第i维坐标
Manhattan Distance Calculation(曼...
Cooling Load Calculation
System Reliability and Availability Calculation
DEFINING OF DISTANCE LEARNING
Issues in Distance Learning
心理距离Psychical Distance
Interaction in Distance Education1...
DISTANCE EDUCATION AT A GLANCE
Mahalanobis Distance(马氏距离)
The furthest distance in world
DISTANCE EDUCATION AT A GLANCE
DISTANCE EDUCATION AT A GLANCkk
DISTANCE EDUCATION AT A GLANCEasfasf
DISTANCE EDUCATION AT A GLANCE2
Mahalanobis Distance (马氏距离)
Comparison of Cooling Load Calculation Methods (ASHRAE 942-RP)
Comparing Distance Education and Traditional Instruction
7 Success Strategies for Distance Learners
7 Success Strategies for Distance Learners
【综述】Comparing Distance Education and Traditional Instruction
Barriers to Learning in Distance Education
Online learning support services for distance...
From distance education to virtual communitie
The furthest distance in the world