Inverting away a coset Let $G$ be a group with subgroup $H$. I am curious about when the equation $$g_1 \cdot H \cdot x \cdot H = g_2 \cdot H \cdot x \cdot H$$ with $g_1,g_2,x \in G$ implies that $g_1 \cdot H = g_2 \cdot H.$
It is true when $H$ is normal, since in that case we can write \begin{align*} g_1 \cdot H &= g_1 \cdot H \cdot H \cdot x \cdot x^{-1} \\ &= g_1 \cdot H \cdot x \cdot H \cdot x^{-1} \\ &= g_2 \cdot H \cdot x \cdot H \cdot x^{-1} \\ &= g_2 \cdot H. \end{align*}
If $G$ is finite then I think the converse is true: if $G$ is not normal then one of the double cosets has size strictly larger than $H$, and therefore there are fewer double cosets $g_i \cdot H \cdot x \cdot H$ than there are (single) cosets $g_i \cdot H.$ What about when $G$ is infinite? Can pairs $(G,H)$ with this property be characterized?
 A: The converse is not true for $G$ finite: the problem is that the sets of the form $gHxH$ are not disjoint, and so you can't count how many there are by just looking at how big they are.  For example, let $G=S_n$ and let $H=S_{n-1}\subset S_n$ be the subgroup of permutations that fix $n$, which is not normal if $n>2$.  We may assume $x\not\in H$, since the statement is trivial if $x\in H$  If $x\not\in H$, then it is not hard to see that $HxH=G\setminus H$.  Moreover, for any $g\in G$, $gHxH$ is the set of permutations $f$ such that $f(n)\neq g(n)$.  So $g_1HxH=g_2HxH$ iff $g_1(n)=g_2(n)$.  But this condition is also equivalent to $g_1H=g_2H$, since $gH$ is the set of $f$ such that $f(n)=g(n)$.
Here is an example where the implication is not true.  Let $G\subset S_4$ be the group of permutations of $\{1,2,3,4\}$ that map the set $\{1,2\}$ either to itself or to the set $\{3,4\}$ (aka the dihedral group with $8$ elements).  Let $H\subset G$ be the subgroup of permutations that fix $1$ (and thus also fix $2$), let $x=(1\ 3)(2\ 4)$, and let $g=(1\ 2)(3\ 4)$.  Note that $xH$ is the set of permutations in $G$ that send $1$ to $3$, and so $HxH$ is the set of permutations in $G$ that send $1$ to either $3$ or $4$.  Thus $gHxH$ is also the set of permutations in $G$ that send $1$ to either $3$ or $4$, so $gHxH=HxH$.  But $gH\neq H$, since $g\not\in H$.
I don't know any simple general criterion for whether this holds, but let me suggest the following way of thinking about the question (which is how I came up with my second example above).  Instead of thinking in terms of the subgroup $H$, let us think of $G$ as acting transitively on a set $S$ with a chosen basepoint $s\in S$ (this is equivalent to having a subgroup of $G$, by letting $S=G/H$ and $s=H$).  Similarly, instead of thinking of an element $x\in G$, we can think of an element $t\in S$ (which corresponds to the coset $xH$).  The set $xH$ then corresponds to the set of $f\in G$ such that $f(s)=t$, and the set $HxH$ corresponds to the set of $f\in G$ such that $f(s)=h(t)$ for some $h\in G$ that fixes $s$.  So we have $gHxH=HxH$ iff $g$ maps the set of such elements $h(t)$ bijectively to itself.  On the other hand, $gH=H$ iff $g$ fixes $s$.  So your condition on $G$ and $H$ can be reinterpreted as a condition on a transitive action of $G$ on a set $S$: it says that if $s,t\in S$ and $g$ maps the set of images of $t$ under elements of $G$ that fix $s$ bijectively to itself, then $g$ must fix $s$.
