Equivalence relation induced by a map