modifications to Set, not fully completed yet