# Isomorphisms

## Isomorphisms with Standard Models

In this section we discuss isomorphisms between heterogeneous types — isomorphisms between combinations of curves of type `Crv`, `CrvCon`, and `CrvRat`, and their parametrisations by a projective line.

The first function which we treat here is `Conic`, which is as much a constructor as an isomorphism. It takes an arbitrary genus zero curve $C$ and uses the anti-canonical divisor $-K_C$ of degree $2$ to construct the Riemann–Roch space. For a genus zero curve this is a dimension $3$ space of degree $2$ functions and gives a projective embedding of $C$ in ${\mathbb{P}}^2$ as a conic. This provides the starting point to make any genus zero curve amenable to the powerful machinery for point finding and isomorphism classification of conics.

On the other hand, if $C$ is an arbitrary genus $0$ curve with a known non-singular point or place $p$, then a parametrization of $C$ can be constructed directly from the degree $1$ Riemann–Roch space. There are intrinsics to do this.

An isomorphism — provided that one exists — of the projective line with a conic can be described as follows. The $2$-uple embedding $\phi: {\mathbb{P}}^1 \rightarrow {\mathbb{P}}^2$ defined by $(u:v) \mapsto (u^2:uv:v^2)$ gives an isomorphism of ${\mathbb{P}}^1$ with the conic $C_0$ with defining equation $y^2 = xz$. The inverse isomorphism $C_0 \rightarrow {\mathbb{P}}^1$ is defined by the maps

$$
\begin{matrix}(x:y:z) \mapsto (x:y) \hbox{ on } x \ne 0,\\
(x:y:z) \mapsto (y:z) \hbox{ on } z \ne 0,\end{matrix}
$$

respectively. Since these open sets cover the conic $C_0$ this defines an isomorphism and not just a birational map. In order to describe an isomorphism of a conic $C_1$ with ${\mathbb{P}}^1$ it is then necessary and sufficient to give a change of variables which maps $C_0 = \phi({\mathbb{P}}^1)$ onto the conic $C_1$. This matrix is called the *parametrisation matrix* and is stored with $C_1$ once a rational point is found.

Given a parametrization over the rationals of an arbitrary genus $0$ curve in ordinary projective space, a simpler parametrization can often be found using the intrinsic [`ImproveParametrization`](../../AlgebraicGeometry/Schemes/maps.md#function-sch-imp-para) from the `Scheme` chapter of the handbook.

### `Conic(C): Crv -> MapSch`

Given a curve of genus zero, returns a conic determined by the anti-canonical embedding of $C$.

### `Example (ex-564e2f)`

We demonstrate the function `Conic` on the curve of Example [Example: Rational Curve Example](crvgen0-sec:main.md#example-ex-626aa7) to find a conic model, even though we know that it admits a rational parametrisation.

```magma
> P2<x,y,z> := ProjectivePlane(FiniteField(71));
> C0 := Curve(P2, (x^3 + y^2*z)^2 - x^5*z);
> C1, m := Conic(C0);
> C1;
Conic over GF(71) defined by
x^2 + 70*x*z + y^2
> m : Minimal;
(x : y : z) -> (x^3*y*z : 70*x^5 + x^4*z + 70*x^2*y^2*z : x^3*y*z + y^3*z^2)

```

### `ParametrizationMatrix(C): CrvCon -> ModMatRngElt`

This function is an optimised routine for parametrising a conic $C$ defined over ${\mathbb{Z}}$ or ${\mathbb{Q}}$. It returns a $3 \times 3$ matrix $M$ which defines a parametrisation of $C$ as a projective change of variables from the $2$-uple embedding of a projective line in the projective plane; i.e., for a point $(x_0:y_0:z_0)$ on $C$, the point

$$
(x_1:y_1:z_1) = (x_0:y_0:z_0) M
$$

satisfies the equation $y_1^2 = x_1z_1$. Note that as usual in Magma the action of $M$ is on the right and, consistently, the action of scheme maps is also on the right.

### `Example (ex-c3a025)`

In this example we demonstrate that the parametrisation matrix determines the precise change of variables to transform the conic equation into the equation $y^2 = xz$. We begin with a singular plane curve $C_0$ of genus zero and construct a nonsingular conic model in the plane.

```magma
> P2<x,y,z> := ProjectiveSpace(Rationals(), 2);
> C0 := Curve(P2, (x^3 + y^2*z)^2 - x^5*z);
> C1, m := Conic(C0);
> C1;
Conic over Rational Field defined by
x^2 - x*z + y^2

```

The curve $C_1$ has obvious points, such as $(1\,:\,0\,:\,1)$, which Magma internally verifies without requiring an explicit user call to `HasRationalPoint`.

```magma
> ParametrizationMatrix(C1);
[1 0 1]
[0 1 0]
[0 0 1]
> Evaluate(DefiningPolynomial(C1), [x, y, x+z]);
-x*z + y^2

```

We note (as is standard in Magma) that the action of matrices, as with maps of schemes, is a right action on coordinates $(x\,:\,y\,:\,z)$.

### `Parametrization(C): CrvCon -> MapSch`

### `Parametrization(C, P): CrvCon, Crv -> MapSch`

### `Parametrization(C, p): Crv, Pt -> MapSch`

### `Parametrization(C, p): Crv, PlcCrvElt -> MapSch`

### `Parametrization(C, p, P): CrvCon, Pt, Crv -> MapSch`

### `Parametrization(C, p, P): CrvRat, Pt, Crv -> MapSch`

### `Parametrization(C, p, P): CrvCon, PlcCrvElt, Crv -> MapSch`

### `Parametrization(C, p, P): CrvRat, PlcCrvElt, Crv -> MapSch`

Given a conic curve $C$ over a general field, these functions return a parametrisation as an isomorphism of schemes $P \rightarrow C$. Here $P$ is a copy of a projective line; it may be specified as one of the arguments or a new projective line will be created. Note that it is now required that $P$ is given (or created) as a curve rather than as an ambient space (as used to be permitted). This allows the immediate use of pullback/push-forward functionality for the parametrisation map.

When a rational point or place is not specified as one of the arguments then the base field of $C$ must be one of the kinds allowed in `HasRationalPoint`. If the conic has no rational points then an error results.

### `ParametrizeOrdinaryCurve(C): Crv -> MapSch`

### `ParametrizeOrdinaryCurve(C, p): Crv, Pt -> MapSch`

### `ParametrizeOrdinaryCurve(C, p): Crv, PlcCrvElt -> MapSch`

### `ParametrizeOrdinaryCurve(C, p, I): Crv, Pt, RngMPol -> MapSch`

### `ParametrizeOrdinaryCurve(C, p, I): Crv, PlcCrvElt, RngMPol -> MapSch`

### `ParametrizeRationalNormalCurve(C): Crv -> MapSch`

These functions are as above (see `Parametrization`), but use different algorithms.

When $C$ is a plane curve with only ordinary singularities (see subsection [Ordinary Plane Curves](../../AlgebraicGeometry/AlgebraicCurves/curves.md#crv-ord-pl-crvs)) then a slightly different procedure is followed that relies less on the general function field machinery and tends to be faster and can produce nicer parametrisations. The variants `ParametrizeOrdinaryCurve` allow direct calls to these more specialised procedures. The $I$ argument is the adjoint ideal of $C$ (*loc. cit.*), which may be passed in if already computed.

The final function listed is slightly different; it applies only to rational normal curves. i.e., non-singular rational curves of degree $d$ in ordinary $d$-dimensional projective space for $d \ge 1$. For the sake of speed the irreducibility of $C$ is not checked. The function uses adjoint maps to find either a line or conic parametrisation of $C$: If $d$ is odd then an isomorphism from the projective line to $C$ is returned, and if $d$ is even then an isomorphism from a plane conic is returned. The method uses no function field machinery and can be much faster than the general function.

### `Example: Rational Parametrization (ex-270a43)`

In this example we show how to parametrise a projective rational curve with a map from the one-dimensional projective space. First we construct a singular plane curve and verify that it has geometric genus zero.

```magma
> k := FiniteField(101);
> P2<x,y,z> := ProjectiveSpace(k, 2);
> f := x^7 + 3*x^3*y^2*z^2 + 5*y^4*z^3;
> C := Curve(P2, f);
> Genus(C);
0

```

In order to parametrise the curve $C$ we need to find a nonsingular point on it, or at least a point of $C$ over which there exists a unique degree one place; geometrically, such a point is one at which $C$ has a cusp. To find such a point we invoke the intrinsic `RationalPoints` on $C$; since $C$ is defined over a finite field this call returns an indexed set of all the points of $C$ that are rational over its base field.

Having done the previous in the background, we demonstrate that the particular point $(2\,:\,33\,:\,1)$ is such a nonsingular rational point.

```magma
> p := C![2,33,1];
> p;
(2 : 33 : 1)
> IsNonsingular(C, p);
true

```

The parametrisation function takes a projective line as the third argument; this will be used as the domain of the parametrisation map.

```magma
> P1<u,v> := ProjectiveSpace(k, 1);
> phi := Parametrization(C, Place(p), Curve(P1));
> phi;
Mapping from: Prj: P1 to Prj: P2
with equations :
2*u^7 + 5*u^6*v + 81*u^5*v^2 + 80*u^4*v^3 + 13*u^3*v^4
33*u^7 + 88*u^6*v + 90*u^5*v^2 + 73*u^4*v^3 + 25*u^3*v^4 +
    83*u^2*v^5 + 72*u*v^6 + 24*v^7
u^7

```

Finally we confirm that the map really does parametrise the curve $C$. Note that the map is normalised so that the point at infinity on the projective line $P_1$ maps to the prescribed point $p$.

```magma
> Image(phi);
Scheme over GF(101) defined by
x^7 + 3*x^3*y^2*z^2 + 5*y^4*z^3
> DefiningIdeal(Image(phi)) eq DefiningIdeal(C);
true
> phi(P1![1, 0]);
(2 : 33 : 1)

```
