# Why is the rank of $f_\ast L$ the degree of $f$

Let $f:X\to Y$ be a finite morphism of curves. Let $L$ be a line bundle on $X$. Why is $f_\ast L$ a line bundle and is the degree of $f_\ast L$ equal to $\deg f$ or $\deg f+ \deg L$?

Here is my strategy and some related questions.

Firstly, since $f$ is proper, we have that $f_\ast L$ is coherent on $Y$. I want to see that it is locally free. I have read that this follows from the flatness, but this is too abstract for me.

Can't we do something more explicit? The problem is local on $Y$. Suppose that $V_1,\ldots,V_r$ are trivializing opens for $L$ on $X$. Then, how does one trivialize $f_\ast L$. Problems might occur at the branch point, but therefore I ask: if I show that $(f_\ast L)_y$ is free for all non-branch points $y$ of $f:X\to Y$, does it follow that $f_\ast L$ is locally free?

I don't want to use Grothendieck-Riemann-Roch or anything similar.

-

No, in general $f_*L$ is not a line bundle.
Suppose $X, Y$ are smooth with fields of functions $K(X), K(Y)$. Then $f$ is flat, so $L$ is flat over $Y$. As $f$ is affine, $f_*L$ is flat over $Y$. As you said it is coherent, so $f_*L$ is locally free. At the generic point of $Y$, the stalk of $f_*L$ is just $L\otimes k(X)\simeq K(X)$ viewed as a vector space over $K(Y)$, its dimension is $[K(X) : K(Y)]=\deg f$. So $f_*L$ is locally free of rank $\deg f$.
To say something more, suppose $X,Y$ are projective. We have to use Riemann-Roch which says that if $V$ is locally free of rank $r$ on $Y$, then the degree of the determinant of $V$ can be computed with the Euler-Poincaré characteristics $$\deg\det (V)= \chi(V)-r \chi(O_Y).$$ So $$\deg\det(f_*L)=\chi(f_*L)-r\chi(O_Y)=\chi(L)-r\chi(O_Y)=\deg L + \chi(O_X)-r\chi(O_Y).$$
If $L$ is associated to a divisor $D$ on $X$, then one can consider the pushforward $f_*D$ as a divisor on $Y$ and compare the locally free sheaf $f_*L$ with the divisor $f_*D$. We have $$\det(f_*L)\simeq \det(f_*O_X) \otimes O_Y(f_*D).$$