fix destructor
fix union and intersect and clean code