plot3d hyperelliptic singular curve

24 Views Asked by At

I am trying to draw a singular hyperelliptic curve of genus two in Sage. My goal is to obtain something that looks like (including the oriented one-cycles): enter image description here

I think that the equation of such a pinched Riemann surface is given by $y^2=x^2(x-a)(x-b)(x-c)(x-d)$ for pairwise distinct complex numbers $a,b,c,d$.

here is the code I use, it doesn't give me a pinched Riemann surface

x, y, z=var('x,y,z')
f=y**2-x**2*(x-1)*(x-2)*(x-3)*(x-4)
f
implicit_plot3d(f,(x,-pi,pi),(y,-pi,pi),(z,-1,1),color="automatic",thickness=3, aspect_ratio=(1,1,1))

It gives something different:

enter image description here

I suspect that the problem is that my variables $x,y$ are real and not complex. Thanks for any help.