Assume we have regular real random variables $X$ and $Y$ and real-valued functions $g,f \in \mathcal{G}$. Assume that $g(X)=f(Y)$ almost surely.
I would like to know under which conditions on $\mathcal{G}$ there exists an isomorphism $h$ such that $X=h(Y)$.
There is the obvious case where $g$ and $f$ are invertible but I am interested in the case where $\mathcal{G}=\{g:\mathbb{R}^q \rightarrow \mathbb{R}^p\}$ where $p>q$ and thus $g$ and $h$ are not invertible. I was wondering if there exists some lemma such as 5.25 in Einsiedler and Ward's Ergodic Theory with a View Towards Number Theory which guarantees that if $X=g(Z)$ and $Y=f(Z)$ there is an isomorphism between $X$ and $Y$. I have the inverse scenario in my case.
Finally, I think I have an easy proof for this when the function is injective. First I restate the result.
Let $\mathcal{X}$ and $\mathcal{Z}$ be subsets of $R^p$, for some $p<\infty$. Let $g:\mathcal{X}\rightarrow \mathcal{Z}$ be injective and $X$ a continuous random variable with support $\mathcal{X}$. Then $\forall f:\mathcal{X}\rightarrow \mathcal{Z}$ and $Y$ with a continuous distribution on $\mathcal{X}$, $g(Z)=f(Y)$ implies that there exists an invertible map $H:\mathcal{X}\rightarrow \mathcal{X}$ such that $Y= H(X)$.
Proof:
First we show that $f$ has to be bijective on $g(\mathcal{X})$. One can replace the codomain of $g$ by its image $g(\mathcal{X})$ in order to make $g$ bijective. This implies that $\mathcal{X}$ and $g(\mathcal{X})$ have the same "size" (in the sense that a bijection exists between the two sets). As $g(X)=f(Y)$, $g$ and $f$ have the same image and thus $f$ is a bijection between $\mathcal{X}$ and $g(\mathcal{X})$.
Now for any $x$, $\exists!z$ such that $z=g(x)$. Then it exists a unique $y$ such that $z=g(y)$. We then denote by $H$ the invertible map that links this $x$ to this $y$.