public static int optimalNumOfBits(long inputEntries, double fpp) {
        int numBits = (int) (-inputEntries * Math.log(fpp) / (Math.log(2) * Math.log(2)));
        return numBits;
    }
@Test
    void testBloomNumBits() {
        assertThat(BloomFilter.optimalNumOfBits(0, 0)).isZero();
        assertThat(BloomFilter.optimalNumOfBits(0, 0)).isZero();
        assertThat(BloomFilter.optimalNumOfBits(0, 1)).isZero();
        assertThat(BloomFilter.optimalNumOfBits(1, 1)).isZero();
        assertThat(BloomFilter.optimalNumOfBits(1, 0.03)).isEqualTo(7);
        assertThat(BloomFilter.optimalNumOfBits(10, 0.03)).isEqualTo(72);
        assertThat(BloomFilter.optimalNumOfBits(100, 0.03)).isEqualTo(729);
        assertThat(BloomFilter.optimalNumOfBits(1000, 0.03)).isEqualTo(7298);
        assertThat(BloomFilter.optimalNumOfBits(10000, 0.03)).isEqualTo(72984);
        assertThat(BloomFilter.optimalNumOfBits(100000, 0.03)).isEqualTo(729844);
        assertThat(BloomFilter.optimalNumOfBits(1000000, 0.03)).isEqualTo(7298440);
        assertThat(BloomFilter.optimalNumOfBits(1000000, 0.05)).isEqualTo(6235224);
    }