tightened IsPointOnSegment function constants, added check for no union case in union function