Toric lattice elements

This module was designed as a part of the framework for toric varieties (variety, fano_variety).

AUTHORS:

  • Andrey Novoseltsev (2010-05-27): initial version.

class sage.geometry.toric_lattice_element.ToricLatticeElement[source]

Bases: Vector_integer_dense

Create an element of a toric lattice.

Warning

You probably should not construct such elements explicitly.

INPUT:

OUTPUT: element of a toric lattice

plot(**options)[source]

Plot self.

INPUT:

OUTPUT: a plot

EXAMPLES:

sage: N = ToricLattice(3)
sage: n = N(1,2,3)
sage: n.plot()                                                              # needs sage.plot
Graphics3d Object
>>> from sage.all import *
>>> N = ToricLattice(Integer(3))
>>> n = N(Integer(1),Integer(2),Integer(3))
>>> n.plot()                                                              # needs sage.plot
Graphics3d Object
N = ToricLattice(3)
n = N(1,2,3)
n.plot()                                                              # needs sage.plot
sage.geometry.toric_lattice_element.unpickle_v1(parent, entries, degree, immutable)[source]

Unpickle a ToricLatticeElement.

INPUT:

  • parent – the parent toric lattice

  • entries – list; the coordinates of the lattice point

  • degree – integer; the dimension of the toric lattice

  • immutable – boolean; whether the lattice element is immutable

OUTPUT: the ToricLatticeElement determined by the input data

EXAMPLES:

sage: N = ToricLattice(3, "lattice")
sage: loads(dumps(N(1,2,3)))   # indirect test
lattice(1, 2, 3)
sage: from sage.geometry.toric_lattice_element import unpickle_v1
sage: unpickle_v1(N,[1,2,3],3,True)
lattice(1, 2, 3)
>>> from sage.all import *
>>> N = ToricLattice(Integer(3), "lattice")
>>> loads(dumps(N(Integer(1),Integer(2),Integer(3))))   # indirect test
lattice(1, 2, 3)
>>> from sage.geometry.toric_lattice_element import unpickle_v1
>>> unpickle_v1(N,[Integer(1),Integer(2),Integer(3)],Integer(3),True)
lattice(1, 2, 3)
N = ToricLattice(3, "lattice")
loads(dumps(N(1,2,3)))   # indirect test
from sage.geometry.toric_lattice_element import unpickle_v1
unpickle_v1(N,[1,2,3],3,True)