[proofplan]
We factor out the maximal power of $X_0$ dividing $g$, writing $g = X_0^m g'$ with $X_0 \nmid g'$. The polynomial $g'$ is itself homogeneous (the maximal $X_0$-power of a homogeneous polynomial is homogeneous, and the quotient by it remains homogeneous), and now $g'$ is the case where dehomogenisation is genuinely "lossless". Two short calculations finish the argument: the dehomogenisation of $g$ equals the dehomogenisation of $g'$ (the factor $X_0^m$ becomes $1^m = 1$), and the homogenisation of the dehomogenisation of any homogeneous polynomial $g'$ not divisible by $X_0$ is $g'$ itself. Combining gives $g = X_0^m f^h$.
[/proofplan]
[step:Factor $g$ as $X_0^m g'$ with $X_0 \nmid g'$]
Since $g \in k[X_0, X_1, \ldots, X_n]$ is a polynomial in $X_0$ with coefficients in $k[X_1, \ldots, X_n]$, define
\begin{align*}
m := \max\{ k \in \mathbb{N} \cup \{0\} : X_0^k \mid g \text{ in } k[X_0, \ldots, X_n]\}.
\end{align*}
This $m$ is well-defined: $X_0^0 = 1$ always divides $g$, and $m \le \deg g = d$ since $g$ has total degree $d$ (in particular, $g$ has $X_0$-degree at most $d$). By definition of $m$ there exists $g' \in k[X_0, \ldots, X_n]$ with
\begin{align*}
g = X_0^m \cdot g', \qquad X_0 \nmid g'.
\end{align*}
The factor $g'$ is unique (factor uniqueness in the polynomial ring $k[X_0, \ldots, X_n]$, which is an integral domain).
The polynomial $g'$ is homogeneous of degree $d - m$. Indeed, any homogeneous polynomial of degree $d$ has the form
\begin{align*}
g = \sum_{|\alpha| = d} c_\alpha X^\alpha,
\end{align*}
where $\alpha = (\alpha_0, \ldots, \alpha_n)$ ranges over multi-indices summing to $d$. Pulling out $X_0^m$:
\begin{align*}
g = X_0^m \sum_{\substack{|\alpha| = d \\ \alpha_0 \ge m}} c_\alpha X_0^{\alpha_0 - m} X_1^{\alpha_1} \cdots X_n^{\alpha_n} + \text{terms with } \alpha_0 < m.
\end{align*}
By definition of $m$, every monomial of $g$ has $\alpha_0 \ge m$ (else $X_0^m$ would not divide $g$), so the second sum vanishes and
\begin{align*}
g' = \sum_{\substack{|\alpha| = d \\ \alpha_0 \ge m}} c_\alpha X_0^{\alpha_0 - m} X_1^{\alpha_1} \cdots X_n^{\alpha_n}.
\end{align*}
Each term has total degree $(\alpha_0 - m) + \alpha_1 + \cdots + \alpha_n = d - m$, so $g'$ is homogeneous of degree $d - m$. Moreover by the maximality of $m$, $g'$ has at least one monomial with $\alpha_0 = m$ — i.e. with $X_0$-exponent zero in $g'$ — confirming $X_0 \nmid g'$.
[/step]
[step:Compute $f$ from $g$]
By definition of dehomogenisation,
\begin{align*}
f(Y_1, \ldots, Y_n) = g(1, Y_1, \ldots, Y_n).
\end{align*}
Using $g = X_0^m g'$:
\begin{align*}
f(Y_1, \ldots, Y_n) = (1)^m \cdot g'(1, Y_1, \ldots, Y_n) = g'(1, Y_1, \ldots, Y_n).
\end{align*}
So $f$ is also the dehomogenisation of $g'$ with respect to $X_0$. Crucially, $f$ depends on $g$ only through $g'$ — the $X_0^m$ factor is invisible to dehomogenisation.
[guided]
Why does the $X_0^m$ factor disappear? Dehomogenisation is the substitution $X_0 = 1$, and $1^m = 1$. So multiplying by $X_0^m$ before substitution leaves no trace afterward. The "information loss" of dehomogenisation lives entirely in the maximal power of $X_0$ dividing the original polynomial; everything else can be recovered.
This is the precise sense in which homogenisation–dehomogenisation is "almost an inverse pair": it is an inverse on the subset of homogeneous polynomials not divisible by $X_0$, and on the full set of homogeneous polynomials it loses exactly the $X_0$-power factor. The theorem is making this precise.
[/guided]
[/step]
[step:Verify $f^h = g'$ for $g'$ homogeneous and not divisible by $X_0$]
We show that the homogenisation of $f$ with respect to $X_0$ recovers $g'$.
By the standard definition, the homogenisation of a polynomial $f \in k[Y_1, \ldots, Y_n]$ of degree $e$ with respect to $X_0$ is
\begin{align*}
f^h(X_0, X_1, \ldots, X_n) = X_0^e \cdot f\!\left(\frac{X_1}{X_0}, \ldots, \frac{X_n}{X_0}\right) \in k[X_0, X_1, \ldots, X_n],
\end{align*}
which is homogeneous of degree $e$ (clearing the denominator $X_0^e$ in each term yields a homogeneous polynomial of total degree $e$).
We compute $f^h$ from the explicit form of $f$ obtained in Step 2. Writing $g'$ as in Step 1,
\begin{align*}
g' = \sum_{\substack{|\alpha| = d - m \\ \alpha = (\alpha_0, \ldots, \alpha_n)}} b_\alpha X_0^{\alpha_0} X_1^{\alpha_1} \cdots X_n^{\alpha_n},
\end{align*}
where the coefficients $b_\alpha \in k$ encode $g'$. Substituting $X_0 = 1$:
\begin{align*}
f(Y_1, \ldots, Y_n) = g'(1, Y_1, \ldots, Y_n) = \sum_\alpha b_\alpha Y_1^{\alpha_1} \cdots Y_n^{\alpha_n}.
\end{align*}
The monomial $Y_1^{\alpha_1} \cdots Y_n^{\alpha_n}$ has degree $\alpha_1 + \cdots + \alpha_n = (d - m) - \alpha_0$. Now we determine $\deg f$ as a polynomial in $Y$:
\begin{align*}
\deg f = \max_\alpha (\alpha_1 + \cdots + \alpha_n) = (d - m) - \min_\alpha \alpha_0 = (d - m) - 0 = d - m,
\end{align*}
where $\min_\alpha \alpha_0 = 0$ because, by Step 1, $X_0 \nmid g'$ — i.e. $g'$ contains a monomial with $\alpha_0 = 0$, which descends to a monomial of $f$ of full degree $d - m$.
Compute $f^h$:
\begin{align*}
f^h(X_0, X_1, \ldots, X_n)
&= X_0^{d - m} \cdot f\!\left(\frac{X_1}{X_0}, \ldots, \frac{X_n}{X_0}\right) \\
&= X_0^{d - m} \sum_\alpha b_\alpha \left(\frac{X_1}{X_0}\right)^{\alpha_1} \cdots \left(\frac{X_n}{X_0}\right)^{\alpha_n} \\
&= \sum_\alpha b_\alpha X_0^{d - m - (\alpha_1 + \cdots + \alpha_n)} X_1^{\alpha_1} \cdots X_n^{\alpha_n} \\
&= \sum_\alpha b_\alpha X_0^{\alpha_0} X_1^{\alpha_1} \cdots X_n^{\alpha_n} \\
&= g',
\end{align*}
using $d - m - (\alpha_1 + \cdots + \alpha_n) = d - m - ((d - m) - \alpha_0) = \alpha_0$. Hence $f^h = g'$.
[guided]
This step is the substantive computation: homogenisation is the "inverse" of dehomogenisation \emph{precisely} on homogeneous polynomials not divisible by $X_0$. We need to verify this rather than asserting it.
\textbf{What does homogenisation do to a polynomial $f \in k[Y_1, \ldots, Y_n]$?} It assigns each monomial $Y_1^{\alpha_1} \cdots Y_n^{\alpha_n}$ of degree $\alpha_1 + \cdots + \alpha_n$ a "filler" power of $X_0$ to bring the total degree up to $\deg f = e$. Concretely, the monomial of degree $e' \le e$ becomes $X_0^{e - e'} X_1^{\alpha_1} \cdots X_n^{\alpha_n}$, of total degree $e$. The result is homogeneous of degree $e$.
\textbf{Why doesn't this work for arbitrary homogeneous $g$?} Because dehomogenisation strips the $X_0$ entirely (sets it to $1$), and homogenisation cannot tell whether the $X_0$-power in the original polynomial was the "minimum" zero or some larger value. Homogenisation always re-fills $X_0$ to the \textbf{maximal} extent — fully saturating the total degree. For polynomials originally divisible by $X_0^m$ with $m > 0$, this re-filling produces a polynomial \emph{less} divisible by $X_0$ than the original.
The condition $X_0 \nmid g'$ ensures $g'$ already has a monomial of zero $X_0$-degree, hence $\deg f = \deg g'$, hence the re-filling exactly retraces the original $X_0$-degrees and recovers $g'$ exactly.
\textbf{The key arithmetic.} For each monomial of $g'$, $\alpha_0 + \alpha_1 + \cdots + \alpha_n = d - m$ (homogeneity), so $\alpha_0 = (d - m) - (\alpha_1 + \cdots + \alpha_n) = e - \deg(\text{the corresponding monomial of } f)$. This is exactly the filler power of $X_0$ that homogenisation assigns. Hence $f^h$ matches $g'$ monomial-by-monomial.
[/guided]
[/step]
[step:Combine to obtain $g = X_0^m f^h$]
By Step 1, $g = X_0^m g'$. By Step 3, $g' = f^h$. Substituting:
\begin{align*}
g(X_0, \ldots, X_n) = X_0^m \cdot f^h(X_0, \ldots, X_n).
\end{align*}
Uniqueness of $m$: any expression $g = X_0^{m'} h$ with $X_0 \nmid h$ forces $m' = m$ (since $m$ is the maximal $X_0$-power dividing $g$, and the other factor $h$ would have to coincide with $g'$ by factor uniqueness in the integral domain $k[X_0, \ldots, X_n]$). The case $m = 0$ corresponds exactly to $X_0 \nmid g$, in which case $g = f^h$ outright; the case $m = d$ corresponds to $g = c X_0^d$ for some $c \in k$ (and then $f = c$ a constant, and $f^h = c$, giving $g = c X_0^d$ as expected).
[/step]