added class TwoElementSet, which implements exactly what the name says; useful for use within FlowFunction, as it is much more efficient than using a two-element HashSet