AUTHORS:
- Joris Vankerschaver (2012-06-16)
A class consisting of generators for several common parametrized surfaces in 3D.
Returns a catenoid surface, with parametric representation
INPUT:
EXAMPLES:
sage: cat = surfaces.Catenoid(); cat
Parametrized surface ('Catenoid') with equation (cos(u)*cosh(v), cosh(v)*sin(u), v)
sage: cat.plot()
Graphics3d Object
Returns a crosscap surface, with parametrization
INPUT:
EXAMPLES:
sage: crosscap = surfaces.Crosscap(); crosscap
Parametrized surface ('Crosscap') with equation ((cos(v) + 1)*cos(u), (cos(v) + 1)*sin(u), -sin(v)*tanh(-pi + u))
sage: crosscap.plot()
Graphics3d Object
Returns Dini’s surface, with parametrization
INPUT:
EXAMPLES:
sage: dini = surfaces.Dini(a=3, b=4); dini
Parametrized surface ('Dini's surface') with equation (3*cos(u)*sin(v), 3*sin(u)*sin(v), 4*u + 3*cos(v) + 3*log(tan(1/2*v)))
sage: dini.plot() # not tested -- known bug (see #10132)
Returns an ellipsoid centered at center whose semi-principal axes have lengths given by the components of axes. The parametrization of the ellipsoid is given by
INPUT:
EXAMPLES:
sage: ell = surfaces.Ellipsoid(axes=(1, 2, 3)); ell
Parametrized surface ('Ellipsoid') with equation (cos(u)*cos(v), 2*cos(v)*sin(u), 3*sin(v))
sage: ell.plot()
Graphics3d Object
Returns Enneper’s surface, with parametrization
INPUT:
EXAMPLES:
sage: enn = surfaces.Enneper(); enn
Parametrized surface ('Enneper's surface') with equation (-1/9*(u^2 - 3*v^2 - 3)*u, -1/9*(3*u^2 - v^2 + 3)*v, 1/3*u^2 - 1/3*v^2)
sage: enn.plot()
Graphics3d Object
Returns a helicoid surface, with parametrization
INPUT:
EXAMPLES:
sage: helicoid = surfaces.Helicoid(h=2); helicoid
Parametrized surface ('Helicoid') with equation (rho*cos(theta), rho*sin(theta), theta/pi)
sage: helicoid.plot()
Graphics3d Object
Returns the Klein bottle, in the figure-8 parametrization given by
INPUT:
EXAMPLES:
sage: klein = surfaces.Klein(); klein
Parametrized surface ('Klein bottle') with equation (-(sin(1/2*u)*sin(2*v) - cos(1/2*u)*sin(v) - 1)*cos(u), -(sin(1/2*u)*sin(2*v) - cos(1/2*u)*sin(v) - 1)*sin(u), cos(1/2*u)*sin(2*v) + sin(1/2*u)*sin(v))
sage: klein.plot()
Graphics3d Object
Returns a monkey saddle surface, with equation
INPUT:
EXAMPLES:
sage: saddle = surfaces.MonkeySaddle(); saddle
Parametrized surface ('Monkey saddle') with equation (u, v, u^3 - 3*u*v^2)
sage: saddle.plot()
Graphics3d Object
Returns a paraboloid with equation
When the plus sign is selected, the paraboloid is elliptic. Otherwise the surface is a hyperbolic paraboloid.
INPUT:
EXAMPLES:
sage: epar = surfaces.Paraboloid(1, 3, 2); epar
Parametrized surface ('Elliptic paraboloid') with equation (u, v, 2*u^2 + 2/9*v^2)
sage: epar.plot()
Graphics3d Object
sage: hpar = surfaces.Paraboloid(2, 3, 1, elliptic=False); hpar
Parametrized surface ('Hyperbolic paraboloid') with equation (u, v, -1/4*u^2 + 1/9*v^2)
sage: hpar.plot()
Graphics3d Object
Returns a sphere of radius R centered at center.
INPUT:
EXAMPLES:
sage: sphere = surfaces.Sphere(center=(0, 1, -1), R=2); sphere
Parametrized surface ('Sphere') with equation (2*cos(u)*cos(v), 2*cos(v)*sin(u) + 1, 2*sin(v) - 1)
sage: sphere.plot()
Graphics3d Object
Note that the radius of the sphere can be negative. The surface thus obtained is equal to the sphere (or part thereof) with positive radius, whose coordinate functions have been multiplied by -1. Compare for instant the first octant of the unit sphere with positive radius:
sage: octant1 = surfaces.Sphere(R=1); octant1
Parametrized surface ('Sphere') with equation (cos(u)*cos(v), cos(v)*sin(u), sin(v))
sage: octant1.plot((0, pi/2), (0, pi/2))
Graphics3d Object
with the first octant of the unit sphere with negative radius:
sage: octant2 = surfaces.Sphere(R=-1); octant2
Parametrized surface ('Sphere') with equation (-cos(u)*cos(v), -cos(v)*sin(u), -sin(v))
sage: octant2.plot((0, pi/2), (0, pi/2))
Graphics3d Object
Returns a torus obtained by revolving a circle of radius r around a coplanar axis R units away from the center of the circle. The parametrization used is
INPUT:
EXAMPLES:
sage: torus = surfaces.Torus(); torus
Parametrized surface ('Torus') with equation ((2*cos(v) + 3)*cos(u), (2*cos(v) + 3)*sin(u), 2*sin(v))
sage: torus.plot()
Graphics3d Object
Returns Whitney’s umbrella, with parametric representation
INPUT:
EXAMPLES:
sage: whitney = surfaces.WhitneyUmbrella(); whitney
Parametrized surface ('Whitney's umbrella') with equation (u*v, u, v^2)
sage: whitney.plot()
Graphics3d Object