How can I construct genus 2 curves One of the first big formula's you learn in algebraic geometry is the genus-degree formula which states that an irreducible homogeneous polynomial in $f \in \mathbb{C}[x,y,z]$ of degree $d$ gives a genus $(d-1)(d-2)/2$ curve. Unfortunately, this does not help with constructing genus 2 curves since we have the following table of degrees and genera for $f$
$$
\begin{matrix}
\text{degree} & 1 & 2 & 3 & 4 & 5 & \cdots \\
\text{genus} & 0 & 0 & 1 & 3 & 6 & \cdots
\end{matrix}
$$
How can I find a generalization of the genus-degree formula so that I can construct curves in some projective space with the desired genus?
 A: Let $f \in \mathbb{C}[x_0, x_1, y_0, y_1]$ be a polynomial such that $f(\lambda x_0, \lambda x_1, y_0, y_1) = \lambda^af(x_0, x_1, y_0, y_1)$ and $f(x_0, x_1, \mu y_0, \mu y_1) = \mu^bf(x_0, x_1, y_0, y_1)$, then $$X = \{([x_0, x_1], [y_0, y_1]) \in \mathbb{CP}^1\times\mathbb{CP}^1 \mid f(x_0, x_1, y_0, y_1) = 0\}$$ is a curve. If $X$ is smooth, it has genus $(a-1)(b-1)$, so every genus can be realised. As $\mathbb{CP}^1\times\mathbb{CP}^1$ embeds in $\mathbb{CP}^3$ via the Segre embedding, $X$ is a curve in $\mathbb{CP}^3$.
Another way of constructing curves in a projective space is via complete intersections. Let $f_1, \dots, f_{n-1} \in \mathbb{C}[x_0, \dots, x_n]$ be homogeneous polynomials of degrees $d_1, \dots, d_{n-1}$ respectively, then
$$Y = \{[x_0, \dots, x_n] \in \mathbb{CP}^n \mid f_1(x_0, \dots, x_n) = \dots = f_{n-1}(x_0, \dots, x_n) = 0\}$$
is a curve. If $Y$ is smooth, it has genus $1 - \frac{1}{2}(n + 1 - d_1 - \dots - d_{n-1})d_1\dots d_{n-1}$. This construction gives rise to many genera that don't appear in the degree-genus formula, but not all of them: see this sequence. For example, there is no choice of dimension $n$ and degrees $d_1, \dots, d_{n-1}$ which give rise to a genus two curve, i.e. a genus two curve is not a complete intersection.
