# Factorizing rational functions of curves

Let $f:X\to \mathbf{P}^1$ be a rational function of degree $d\geq 2$ on a curve $X$.

Let $n\geq 2$ be a divisor of $d$. Does there exist a curve $Y$ with a rational function $g:Y\to \mathbf{P}^1$ of degree $n$ such that $f$ factors through $g$

That is, can we factor $f$ in some sense?

Note that by de Franchis' theorem the curve $Y$, if it exists, will almost always be isomorphic to $X$.

Example. The rational function $x\mapsto x^d$ clearly factors as $x\mapsto x^{d/n}$ and $y\mapsto y^n$.

-

Construct a cover of degree 4 such that over $0\in\mathbb P^1$ there is an unramified point and a point of ramification index 3. Then this cover can't factorize through of subcover of degree $2$ (edit because it would force the ramification indexes to be $1$ or even). eg: $k(X)$ given by $y^3(y+1)+x=0$ and $f$ given by $(x,y)\mapsto x$. In this case $X$ is even isomorphic to $\mathbb P^1$ !
This question is equivalent to the following. Let $S=f^{-1}(x)$ for some regular value $x\in\mathbb{P}^1$ and let $G$ be the monodromy group of $f$ (a group of permutations of $S$). Is the action of $G$ on $S$ primitive? If yes, there is no $g$. If the action is not primitive then there is a $g$ (for some $n$). In general $G$ is the group of all the permutations of $S$, so it is primitive - but you can cook up imprimitive examples.
(Field-theoretically you're asking whether for a field extension of degree $d$ there is a subextension of degree $n$; from this point of view my answer uses Galois theory, $G$ being the Galois group of the Galois closure of the extension. However, I find the purely geometrical point of view (monodromy) simpler.)