public static int optimalNumOfBits ( long inputEntries , double fpp ) { int numBits = ( int ) ( - inputEntries * Math . log ( fpp ) / ( Math . log ( 2 ) * Math . log ( 2 ) ) ) ; return numBits ; }
Compute optimal bits number with given input entries and expected false positive probability .