I am currently using hyperloglog to estimate the cardinality of sets (# of unique items)
Its quite trivial to calculate the cardinality for the union of 2 sets and the cardinality for the intersection of 2 sets (|A intersect B| = |A| + |B| - |A union B|)
But I couldn't quite find a way to chain the operators of union and intersection together (note: the method of only allow calculating the cardinality not hyperloglog of intersection, that is, it is possible to get a new hyperloglog via A union B but not A intersect B).
Are there alternative algorithms that can estimate the cardinality of the result of chained union and intersection?