I am using the software "Singular" for computing the geometric genus of a space curve, but something is going wrong. Let me consider the following 3-dimensional curve:
$$\begin{array}{c}x_3 D(x_1,x_2)=N(x_1,x_2), \\ P(x_1,x_2,x_3)=0, \end{array} $$ where $D(x_1,x_2)$, $N(x_1,x_2)$ and $P(x_1,x_2,x_3)$ are certain polynomials. For a choice of them, The package “Singular” gives genus equal to 3. Then, I try something different. I use the first equation for eliminating the variable $x_3$. In this way, I get a plane curve. I compute the genus and I get 4. But, if I am not wrong, the plane curve and the original space curve are birationally equivalent. Thus, their genus should be equal. What is wrong?
P.S: Example. If I take the curve
$2842 \text{x1}^3+\text{x1}^2 (647 \text{x2}-22778 \text{x3}-777)-2 \text{x1} (\text{x2} (69 \text{x2}+10163 \text{x3}+34)+980 \text{x3})+\text{x2} (\text{x2} (2093 \text{x2}+601)-4 (527 \text{x2}+490) \text{x3})=0,$
$37828 \text{x1}^3+7 \text{x1}^2 (4488 \text{x2}-26516 \text{x3}-749)+\text{x1} \left(15239 \text{x2}^2+3 \text{x2} (889-53285 \text{x3})+2520 (\text{x3}-6) \text{x3}\right)+\text{x2} \left(21987 \text{x2}^2+\text{x2} (6482-11419 \text{x3})+2520 (\text{x3}-6) \text{x3}\right)=0,$
“Singular” says that the genus is 3. If I project away the third variable by using the first equation, the genus turns out to be equal to 4.