Effectiveness of the distinguished theta characteristic in characteristic 2

Let $k$ be an algebraically closed field of characteristic 2. Let $C$ be a (smooth projective connected) curve over $k$. Can there exist a rational function on $C$ whose differential is holomorphic but nonzero? (Note that every perfect square has zero differential.)

Alternate formulation: at the end of his paper "Theta characteristics of an algebraic curve", Mumford points out that the canonical sheaf on $C$ has a distinguished square root $\mathcal{L}$: for any rational function $f$ on $C$ which is not a perfect square, the divisor $(df)$ is even and the class of $\frac{1}{2}(df)$ does not depend on $f$. The question is then whether $\mathcal{L}$ can admit a nonzero section.

For example, it is an entertaining exercise to check (from a Weierstrass model) that this can never occur for ordinary elliptic curves.

-
Using duality between trace and differential via the residue pairing (Ch. II, sec. 13 of Serre's book on class fields), to make such an $f$ (in any characteristic) seems amount to making a separable branched cover $f:X \rightarrow \mathbf{P}^1$ whose relative different ideal on $X$ is contained in $O_X(-2\infty)$. This is a condition solely on the ramification profile over $\infty$, so for a sufficiently ramified dvr extension $R$ of $\widehat{O}_{\infty}$ find a monic equation defining this finite extension and globalize it. Hard to see the genus here (or to control hyperellipticity, etc.) –  user36938 Aug 18 '13 at 9:39

Let $F:X\to X$ be the relative Frobenius morphism. It is a finite morphism of degree $2$, and we have an exact sequence $$0\to \mathcal{O}_X\to F_*\mathcal{O}_X \to L \to 0$$ for some invertible sheaf $L$ on $X$. The standard formula for the canonical class of a finite morphism tells us that $\omega_X = F^*(\omega_X\otimes L^{-1}) = \omega_X^{\otimes 2}\otimes L^{\otimes -2}.$ This implies that $L = \theta$ is a theta characteristic on $X$. I believe this is the theta characteristic discussed by Mumford. Now apply the cohomology to the first exact sequence to get that $H^1(X,\theta) \cong H^0(X,\theta)^*$ is the cokernel of the Frobenius map $H^1(X,\mathcal{O}_X) \to H^1(X,\mathcal{O}_X)$.

So, $\theta$ is effective if and only if the curve is not ordinary.

-
This answer needs some editing because $F$ is not an endomorphism of $X$, but rather is a $k$-morphism from $X$ to its Frobenius twist $X'$. So in the exact sequence displayed one has $O_{X'} \rightarrow F_{\ast}(O_X)$ and one really has to use that $F^{\ast}(\omega_{X'}) \simeq \omega_X^{\otimes 2}$ (by a small calculation, not a tautology). Likewise see that it is not $L^{\otimes -2}$ that arises, but rather $F^{\ast}(L)^{-1}$, and $L$ lives on $X'$, not $X$. So to get $L^{\otimes 2}$ is not quite "right". I'm a bit confused here, so didn't edit it myself; perhaps user37622 can fix it. –  user36938 Aug 19 '13 at 1:06
 Hi, Kiran, welcome to MO.
Supersingular elliptic curves in characteristic two have exact holomorphic differentials. On $y^2+y=x^3+ax+b$, $dx$ is holomorphic. In general, there are such things if and only if the curve (or its Jacobian) is not ordinary. This is discussed in §3 of my paper with Stohr, "A formula for the Cartier operator on plane algebraic curves" Crelle 377 (1987), 49-64.