文件名称:BloomFilter
-
所属分类:
- 标签属性:
- 上传时间:2016-11-03
-
文件大小:4.64kb
-
已下载:0次
-
提 供 者:
-
相关连接:无下载说明:别用迅雷下载,失败请重下,重下不扣分!
介绍说明--下载内容来自于网络,使用问题请自行百度
如需要判断一个元素是不是在一个集合中,我们通常做法是把所有元素保存下来,然后通过比较知道它是不是在集合内,链表、树都是基于这种思路,当集合内元素个数的变大,我们需要的空间和时间都线性变大,检索速度也越来越慢。 Bloom filter 采用的是哈希函数的方法,将一个元素映射到一个 m 长度的阵列上的一个点,当这个点是 1 时,那么这个元素在集合内,反之则不在集合内。这个方法的缺点就是当检测的元素很多的时候可能有冲突,解决方法就是使用 k 个哈希 函数对应 k 个点,如果所有点都是 1 的话,那么元素在集合内,如果有 0 的话,元素则不在集合内。-
Such as the need to determine an element is not in a collection, we usually practice is to save all the elements, and then by comparing it is not in the collection, linked list, the tree is based on this idea, when the number of elements within the collection Larger, we need the space and time are linearly larger, more and more slow retri speed. Bloom filter uses a hash function to map an element to a point on an array of length m. When the point is 1, then the element is within the set, and vice versa. The disadvantage of this method is that when the detection of many elements may have a conflict, the solution is to use k hash function corresponding to k points, if all points are 1, then the element in the set, if 0, then the element Is not in the collection.
Such as the need to determine an element is not in a collection, we usually practice is to save all the elements, and then by comparing it is not in the collection, linked list, the tree is based on this idea, when the number of elements within the collection Larger, we need the space and time are linearly larger, more and more slow retri speed. Bloom filter uses a hash function to map an element to a point on an array of length m. When the point is 1, then the element is within the set, and vice versa. The disadvantage of this method is that when the detection of many elements may have a conflict, the solution is to use k hash function corresponding to k points, if all points are 1, then the element in the set, if 0, then the element Is not in the collection.
(系统自动生成,下载前可以参看下载内容)
下载文件列表
BloomFilter/.classpath
BloomFilter/.project
BloomFilter/.settings/org.eclipse.jdt.core.prefs
BloomFilter/bin/BloomFilter$SimpleHash.class
BloomFilter/bin/BloomFilter.class
BloomFilter/bin/Test.class
BloomFilter/src/BloomFilter.java
BloomFilter/src/Test.java
BloomFilter/.settings
BloomFilter/bin
BloomFilter/src
BloomFilter
BloomFilter/.project
BloomFilter/.settings/org.eclipse.jdt.core.prefs
BloomFilter/bin/BloomFilter$SimpleHash.class
BloomFilter/bin/BloomFilter.class
BloomFilter/bin/Test.class
BloomFilter/src/BloomFilter.java
BloomFilter/src/Test.java
BloomFilter/.settings
BloomFilter/bin
BloomFilter/src
BloomFilter
本网站为编程资源及源代码搜集、介绍的搜索网站,版权归原作者所有! 粤ICP备11031372号
1999-2046 搜珍网 All Rights Reserved.