14

I know that standard Bloom Filters only have operations like inserting elements and checking if an element belongs to filter, but are also some modification of Bloom filters which enable a delete operation--for example: counting Bloom filters. I heard also about another method, which uses a second filter. If I want to remove an element I have to 'insert' it into this second filter. I can't find how this proposed structure operates, any article about it, or even the name of the originator. Maybe someone can share with me with a link to any interesting articles about this method? I found a lot of articles about counting Bloom filters and other methods, but I can't find any description of this one.

Raphael
  • 73,212
  • 30
  • 182
  • 400
Zix
  • 259
  • 3
  • 9

4 Answers4

8

I couldn't find the source, but the idea is simple: Use additional bloom filter to represent the set of the deletions.

As this is a very simple solution, it might be considered as a folklore.

Anyway, I found a short reference to this solution in the following paper (Theory and Practice of Bloom Filters for Distributed Systems):

http://www.dca.fee.unicamp.br/~chesteve/pubs/bloom-filter-ieee-survey-preprint.pdf

Search for:

Removal of an element can be implemented by using a second Bloom filter that contains elements that have been removed

In the third section of this paper, you can read about many techniques to deal with deletion. Maybe you will find there some reference (again - I'm not sure there is some paper about it, as it is a simple idea).

Gari BN
  • 356
  • 1
  • 6
3

Depending on your intended use, it might not be practical to use counters, e.g. integers instead of bits, but by doing so, you can increment each integer in the array instead of setting a bit when inserting. When removing an element, you can then decrement all of its related integers.

0

You can use the concept of invertible bloom filters. See here for a nice explanation. Invertible bloom filters allow you to retrieve and delete key/value pairs from the filter.

Καrτhικ
  • 101
  • 1
0

You can use a "counting bloom filter" which uses integers instead of bits for each item stored. Increase integer when adding, decrease integer when deleting. Uses more storage, of course.

https://en.wikipedia.org/wiki/Counting_Bloom_filter

s g
  • 101
  • 2