Summary: Let $G$ be a group such that the subgroup $T^2(G)=\{x\in G\mid (gx)^2=(xg)^2$, for all $g\in G\}$ is a proper subgroup. We define a graph $Γ$ with the vertex set $G\setminus T^2(G)$ in which two vertices $x,y$ are joined by an edge if $(xy)^2=(yx)^2$. In this note we study this graph and find a characterization of some dihedral groups in terms of this graph.