It is known that the pushout in $\mathsf{Top}$ has same underlying set as the pushout in $\mathsf{Set}$ (this is because the forgetful functor $\mathsf{Top}\to\mathsf{Set}$ is a left adjoint). Consider, either in $\mathsf{Set}$ or in $\mathsf{Top}$, a pushout diagram \begin{align*}\tag{1}\label{diag} \require{AMScd} \begin{CD} A @>{g}>> Y\\ @V{f}VV @VV{\overline{f}}V \\ X @>>{\overline{g}}> Z \end{CD} \end{align*} where $Z$ has underlying set $\frac{X\sqcup Y}{\mathcal{R}}$, and where the relation $\mathcal{R}$ on $X\sqcup Y$ equals $\mathcal{R}=R^e$, where $R$ is the relation $$ R=\{(f(a),g(a))\mid a\in A\}\subset(X\sqcup Y)^2, $$ and where we denote $(-)^e$ to the equivalence closure (defined to be the smallest equivalence relation on a set that contains some given relation).
The situation becomes more interesting if we suppose that at least one of $f$ or $g$ are injective. On one hand, if $f$ is injective we get that the map $\overline{f}$ from \eqref{diag} turns out to be injective as well (see this answer). On the other hand, if at least one of $f$ or $g$ are injective, then now the relation $\mathcal{R}$ can be also written as $$\tag{2}\label{eq} \mathcal{R}=R^e=\tilde{R}^{rs}, $$ where $\tilde{R}$ is the relation $$ \begin{align} \tilde{R}=R&\cup\{(f(a),f(b))\mid a,b\in A,\; g(a)=g(b)\}\\ &\cup\{(g(a),g(b))\mid a,b\in A,\; f(a)=f(b)\}, \end{align} $$ and where we denote $(-)^r$ and $(-)^s$, respectively, to the reflexive and symmetric closure (these closures are defined to be, respectively, the smallest reflexive or symmetric relation on a set that contains some given relation. It can be checked that the reflexive and symmetric closures commute, $(-)^{rs}=(-)^{sr}$). The explanation of where the equation \eqref{eq} comes from can be found on the comments of this answer.
Because of \eqref{eq}, I was wondering whether a more simple description of $\mathcal{R}$ is possible in the case that at least one of $f$ or $g$ are injective. You know, a simple characterization of the type “for $u,v\in X\sqcup Y$, we have $u\mathcal{R}v$ if and only if...”.