Java知识分享网 - 轻松学习从此开始!    

Java知识分享网

Java1234官方群25:java1234官方群17
Java1234官方群25:838462530
        
SpringBoot+SpringSecurity+Vue+ElementPlus权限系统实战课程 震撼发布        

最新Java全栈就业实战课程(免费)

springcloud分布式电商秒杀实战课程

IDEA永久激活

66套java实战课程无套路领取

锋哥开始收Java学员啦!

Python学习路线图

锋哥开始收Java学员啦!
当前位置: 主页 > Java文档 > Java基础相关 >

kdtrees文档 PDF 下载


分享到:
时间:2021-02-09 10:50来源:http://www.java1234.com 作者:转载  侵权举报
kdtrees文档 PDF 下载
失效链接处理
kdtrees文档 PDF 下载


本站整理下载:
提取码:6pss 
 
 
相关截图:
 
主要内容:


Insert Code
insert(Point x, KDNode t, int cd) {
 if t == null
 t = new KDNode(x)
 else if (x == t.data)
 // error! duplicate
 else if (x[cd] < t.data[cd])
 t.left = insert(x, t.left, (cd+1) % DIM)
 else
 t.right = insert(x, t.right, (cd+1) % DIM)
 return t
}
FindMin in kd-trees
• FindMin(d): find the point with the smallest value in 
the dth dimension.
• Recursively traverse the tree
• If cutdim(current_node) = d, then the minimum 
can’t be in the right subtree, so recurse on just the 
left subtree 
- if no left subtree, then current node is the min for tree 
rooted at this node.
• If cutdim(current_node) ≠ d, then minimum could 
be in either subtree, so recurse on both subtrees.
- (unlike in 1-d structures, often have to explore several 
paths down the tree)

 

------分隔线----------------------------

锋哥公众号


锋哥微信


关注公众号
【Java资料站】
回复 666
获取 
66套java
从菜鸡到大神
项目实战课程

锋哥推荐