# defining a translation surface

I would like to define a translation surface of only single rectangle but haven't found how online. Can anyone show how to do so?

edit retag close merge delete

Sort by » oldest newest most voted

Install surface_dynamics and sage-flatsurf following instructions on the

Then launch Sage and follow the

Start by importing flatsurf:

sage: import flatsurf


Say we wish to define a flat surface from a two by one rectangle with opposite sides glued together.

Start by constructing the rectangle with one of these commands:

sage: p = flatsurf.polygons((2, 0), (0, 1), (-2, 0), (0, -1))
sage: p = flatsurf.polygons(vertices=[(0, 0), (2, 0), (2, 1), (0, 1)])


Observe the result:

sage: p
Polygon: (0, 0), (2, 0), (2, 1), (0, 1)


Construct a surface dictionary:

sage: from flatsurf import Surface_dict
sage: s = Surface_dict(base_ring=p.base_ring())
'A'
sage: s.change_polygon_gluings("A", [("A", (e + 2) % 4) for e in range(4)])
sage: s.change_base_label("A")
sage: s.set_immutable()
sage: s


Construct a translation surface:

sage: from flatsurf import TranslationSurface
sage: t = TranslationSurface(s)
sage: t
TranslationSurface built from 1 polygon
sage: t.plot()
Launched png viewer for Graphics object consisting of 10 graphics primitives


Check that we got a genus one surface:

sage: t.genus()
1


If we constructed a similarity surface by using a different side pairing for the gluings, we might get a genus zero surface.

For reference here are the versions that were used in this answer:

sage: print(version())
SageMath version 9.2.beta12, Release Date: 2020-09-06
sage: import surface_dynamics
sage: print(surface_dynamics.version.version)
0.4.4
sage: import flatsurf
sage: print(flatsurf.version.version)
0.3

more

Thank you!

( 2020-10-05 23:24:33 +0200 )edit

You're welcome!

Consider accepting the answer to mark the question as solved.

This is done by clicking the "accept" button, the button consisting of a tick mark "✓" icon, located to the left of the top of the answer, below the "upvote" and "downvote" buttons and the answer's score.

( 2021-01-02 07:15:32 +0200 )edit