Let be $k$ an algebraically closed field and let be $X$ a projective nonsingular curve.
Notations
We call $X_h : = X\setminus V(h)$ for any homogeneous polynomial $h$.
A function $f:X\longrightarrow k$ is called regular at $p\in X$ if there exist two homogenous polynomials $F,G$ of the same degree such that $p\in X_G$ and, for every $q\in X_G$ we have $f(q)=F(q)/G(q)$.
Let be $U_f$ the set of the points of $X$ in which $f$ is regular as in the above definition. It's straightforward that $U_f$ is open in $X$.
- If $U_f$ is dense, we call $f$ rational;
- if $U_f=X$ we call $f$ regular.
A map $\phi: X\subseteq \mathbb{P}^m \dashrightarrow Y\subseteq \mathbb{P}^n$ defined in an open set $V_{\phi}$ between quasi-projective varieties is called $rational$ if for every $p\in V_{\phi}$ there exist homogenous polynomials $F_0,\ldots ,F_n$ such that $p\in X_{F_0}\cup\ldots\cup X_{F_n}$ and for every $q\in X_{F_0}\cup\ldots\cup X_{F_n}$ we have $\phi(q)=[F_0(q):\ldots :F_n(q)]$.
The facts
I want to prove that each rational function $f\in k(X)$ induces a morphism (i.e. a regular mapping) $\phi : X\longrightarrow \mathbb{P}^1_k$.
We can put $\phi (p)=[1:f(p)]$ if $p\in U_f:=\{q\in X\mid f \text{ regular at }p\}$ and $\phi(p)=[0:1]$ if $p\notin U_f$. In fact, I cannot prove properly that $\phi$ is regular. I want to show that for every $p\in X$ there are two homogeneous polynomials $F,G$ of the same degree such that $p\in X_G\cup X_F$ and for every $q\in X_F\cup X_G$ we have $\phi(q)=[G(q):F(q)]$.
Let be $p\in U_f$; then by rationality of $f$ we have two homogeneous polynomials $F,G$ of the same degree such that $p\in X_G$ and, for every $q\in X_G$ we have $f(q)=F(q)/G(q)$. In this situation I can prove that $$\phi(q)=[G(q):F(q)]$$ for every $q\in X_G$ but how can I prove this when $q\in X_F\setminus X_G$??
Edit
I've been told that $X_F\cap U_f\subseteq X_G $ (*) so in this case $X_F\setminus X_G$ does not contain points in which $f$ is regular, thus for every $q\in X_F\setminus X_G$ we have $$\phi(q)=[0:1]=[G(q):F(q)]$$ Another problem comes from the points $p\in X\setminus U_f$? I know that $X\setminus U_f = X\cap V(h_1,\ldots ,h_s)$ for some polynomials, but only this. I started thinking about choosing $h=\mathrm{gcd}(h_1,\ldots,h_s)$ so if $p\in X\setminus U_f$ we have $p\in V(h)$. If we put $p=[a_0:\ldots :a_n]$ in homogeneous coordinates, there is a $j$ such that $a_j\neq 0$. So put $l=X_j^{\mathrm{deg}\,h}$. With these choiches, we have $p\in X_l\subseteq X_l\cup X_h$ and we must prove that for every $q\in X_l\cup X_h$ there holds $\phi(q)=[h(q):l(q)]$.
This is somewhat annoying, because
- if $q\in X_l\setminus X_h$ then $q\in X\setminus X_h = V(h)\cap X\subseteq V(h_1,\ldots,,h_s)\cap X = X\setminus U_f$. So $$\phi (q) = [0:1]=[h(q):l(q)]$$ and we have done;
- if $q\in X_h$ I've no idea of what could happen. Seems rather logical that $V(h)=V(h_1,\ldots,h_s)$ but this would bring to the unpleasant idea that $$q\in X_h=X\setminus (X\cap V(h))=X\setminus (X\cap V(h_1,\ldots,h_s))=X\setminus(X\setminus U_f)=U_f$$ . This is unpleasant because $\phi(q)\neq [0:1]$ and I see no way to make $\phi(q)=[h(q):l(q)]$.
2nd. Edit
I managed to prove the part (*), that is for every quasi-projective variety $X$ and for every rational function $f\in k(X)$ with a local expression $F/G$, we have $U_f\cap (X_F\setminus X_G)=\varnothing $ where $U_f$ is the regular locus of $f$. This is really simple: if $p\in U_f\cap (X_F\setminus X_G)$ the fact that $G(p)=0$ but $p$ is regular point means that we must find another local expression, that is two homogenous polynomials $M,N$ of the same degree such that $N(p)\neq 0$ and $f=M/N$ over $X_N$; by hypothesis we have also $G(p)=0$ and $F(p)\neq 0$. But two local expression must satisfy $MG=FN$ and evaluating at $p$ we get $0\neq F(p)=M(p)G(p)/N(p)=0$ which is contradictory.
So the only thing to prove is the quoted part above.
The point is to prove that $\phi : X\longrightarrow \mathbf{P}^1_k$ as defined above is regular at every point of $X$, even in these which $f$ is not regular at.
The argument must use the fact that $X$ is non-singular, as there are curves such that the extension $\phi$ is not defined. In particular, one must proceed as Hoot suggested in one of the comments.
Let $p\in X\setminus U_f$; we know that there is a regular function $u$ such that $u(p)=0$ and such that $m_p =(u)$, where $m_p$ is the maximal ideal of $\mathscr O _{X,p}$. Then, as $f\in k(X)=\mathrm{Quot}(\mathscr O _{X,p}$ but $f\notin O _{X,p}$, writing $f=\alpha /\beta$ for $\alpha,\beta \in \mathscr{O}_{X,p}$ leads to $\beta \in m_p$. So there is $\beta _1 \in \mathscr O _{X,p}$ such that $\beta = \beta _1 \cdot u$.
If $\beta _1 \notin m_p$, it's great because $\alpha /\beta_1$ is regular and nonzero at $p$ and $f=(\alpha /\beta _1)u^{-1}$ so $$\phi(p)=[0:1] = [u(p):\alpha (p)/\beta(p)]$$ Else, if $\beta _1\in m_p$ we can repeat the argument and find $\beta_2\in \mathscr O _{X,p}$ such that $f=(\alpha /\beta _2)u^{-1}$. If we could repeat in this way for infinitely many times, we could buid a sequence $\{\beta _j\}_{j\geq 1}$ such that $\beta_j\mid \beta _{j-1}$, and this can't be possibile is the sequence is not finite, being $\mathscr{O}_{X,p}$ an UFD.
So in every case we can write $f=\rho\cdot u^{-\nu}$ where $\rho$ is regular and nonzero at $p$ and $u$ is regular and vanishes at $p$, for some natural $\nu$. Clearly this proves that $$\phi(p)=[0:1]=[u^{\nu}(p):\rho(p)]$$ defines a regular function for $p\notin U_f$.