Morphisms on projective schemes

This module defines morphisms from projective schemes. A morphism from a projective scheme to a projective scheme is defined by homogeneous polynomials of the same degree that define what the morphism does on points in the ambient projective space. A morphism from a projective scheme to an affine scheme is determined by rational function, that is, quotients of homogeneous polynomials of the same degree.

EXAMPLES:

sage: P2.<x0,x1,x2> = ProjectiveSpace(QQ, 2)
sage: A2.<x,y> = AffineSpace(QQ, 2)
sage: P2.hom([x0, x1, x1 + x2], P2)
Scheme endomorphism of Projective Space of dimension 2 over Rational Field
  Defn: Defined on coordinates by sending (x0 : x1 : x2) to (x0 : x1 : x1 + x2)
sage: P2.hom([x1/x0, (x1 + x2)/x0], A2)
Scheme morphism:
  From: Projective Space of dimension 2 over Rational Field
  To:   Affine Space of dimension 2 over Rational Field
  Defn: Defined on coordinates by sending (x0 : x1 : x2) to (x1/x0, (x1 + x2)/x0)
>>> from sage.all import *
>>> P2 = ProjectiveSpace(QQ, Integer(2), names=('x0', 'x1', 'x2',)); (x0, x1, x2,) = P2._first_ngens(3)
>>> A2 = AffineSpace(QQ, Integer(2), names=('x', 'y',)); (x, y,) = A2._first_ngens(2)
>>> P2.hom([x0, x1, x1 + x2], P2)
Scheme endomorphism of Projective Space of dimension 2 over Rational Field
  Defn: Defined on coordinates by sending (x0 : x1 : x2) to (x0 : x1 : x1 + x2)
>>> P2.hom([x1/x0, (x1 + x2)/x0], A2)
Scheme morphism:
  From: Projective Space of dimension 2 over Rational Field
  To:   Affine Space of dimension 2 over Rational Field
  Defn: Defined on coordinates by sending (x0 : x1 : x2) to (x1/x0, (x1 + x2)/x0)
P2.<x0,x1,x2> = ProjectiveSpace(QQ, 2)
A2.<x,y> = AffineSpace(QQ, 2)
P2.hom([x0, x1, x1 + x2], P2)
P2.hom([x1/x0, (x1 + x2)/x0], A2)

AUTHORS:

  • David Kohel, William Stein: initial version

  • William Stein (2006-02-11): fixed bug where P(0,0,0) was allowed as a projective point

  • Volker Braun (2011-08-08): renamed classes, more documentation, misc cleanups

  • Ben Hutz (2013-03): iteration functionality and new directory structure for affine/projective, height functionality

  • Brian Stout, Ben Hutz (2013-11): added minimal model functionality

  • Dillon Rose (2014-01): speed enhancements

  • Ben Hutz (2015-11): iteration of subschemes

  • Kwankyu Lee (2020-02): added indeterminacy_locus() and image()

  • Kwankyu Lee (2022-05): added graph(), projective_degrees(), and degree()

class sage.schemes.projective.projective_morphism.SchemeMorphism_polynomial_projective_space(parent, polys, check=True)[source]

Bases: SchemeMorphism_polynomial

A morphism of schemes determined by rational functions that define what the morphism does on points in the ambient projective space.

EXAMPLES:

sage: R.<x,y> = QQ[]
sage: P1 = ProjectiveSpace(R)
sage: H = P1.Hom(P1)
sage: H([y,2*x])
Scheme endomorphism of Projective Space of dimension 1 over Rational Field
  Defn: Defined on coordinates by sending (x : y) to
        (y : 2*x)
>>> from sage.all import *
>>> R = QQ['x, y']; (x, y,) = R._first_ngens(2)
>>> P1 = ProjectiveSpace(R)
>>> H = P1.Hom(P1)
>>> H([y,Integer(2)*x])
Scheme endomorphism of Projective Space of dimension 1 over Rational Field
  Defn: Defined on coordinates by sending (x : y) to
        (y : 2*x)
R.<x,y> = QQ[]
P1 = ProjectiveSpace(R)
H = P1.Hom(P1)
H([y,2*x])

An example of a morphism between projective plane curves (see Issue #10297):

sage: # needs sage.schemes
sage: P2.<x,y,z> = ProjectiveSpace(QQ, 2)
sage: f = x^3 + y^3 + 60*z^3
sage: g = y^2*z - (x^3 - 6400*z^3/3)
sage: C = Curve(f)
sage: E = Curve(g)
sage: xbar,ybar,zbar = C.coordinate_ring().gens()
sage: H = C.Hom(E)
sage: H([zbar, xbar - ybar, -(xbar+ybar)/80])
Scheme morphism:
  From: Projective Plane Curve over Rational Field defined by x^3 + y^3 + 60*z^3
  To:   Projective Plane Curve over Rational Field defined by -x^3 + y^2*z + 6400/3*z^3
  Defn: Defined on coordinates by sending (x : y : z) to
        (z : x - y : -1/80*x - 1/80*y)
>>> from sage.all import *
>>> # needs sage.schemes
>>> P2 = ProjectiveSpace(QQ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P2._first_ngens(3)
>>> f = x**Integer(3) + y**Integer(3) + Integer(60)*z**Integer(3)
>>> g = y**Integer(2)*z - (x**Integer(3) - Integer(6400)*z**Integer(3)/Integer(3))
>>> C = Curve(f)
>>> E = Curve(g)
>>> xbar,ybar,zbar = C.coordinate_ring().gens()
>>> H = C.Hom(E)
>>> H([zbar, xbar - ybar, -(xbar+ybar)/Integer(80)])
Scheme morphism:
  From: Projective Plane Curve over Rational Field defined by x^3 + y^3 + 60*z^3
  To:   Projective Plane Curve over Rational Field defined by -x^3 + y^2*z + 6400/3*z^3
  Defn: Defined on coordinates by sending (x : y : z) to
        (z : x - y : -1/80*x - 1/80*y)
# needs sage.schemes
P2.<x,y,z> = ProjectiveSpace(QQ, 2)
f = x^3 + y^3 + 60*z^3
g = y^2*z - (x^3 - 6400*z^3/3)
C = Curve(f)
E = Curve(g)
xbar,ybar,zbar = C.coordinate_ring().gens()
H = C.Hom(E)
H([zbar, xbar - ybar, -(xbar+ybar)/80])

A more complicated example:

sage: P2.<x,y,z> = ProjectiveSpace(2, QQ)
sage: P1 = P2.subscheme(x - y)
sage: H12 = P1.Hom(P2)
sage: H12([x^2, x*z, z^2])
Scheme morphism:
  From: Closed subscheme of Projective Space of dimension 2 over Rational Field
        defined by: x - y
  To:   Projective Space of dimension 2 over Rational Field
  Defn: Defined on coordinates by sending (x : y : z) to (x^2 : x*z : z^2)
>>> from sage.all import *
>>> P2 = ProjectiveSpace(Integer(2), QQ, names=('x', 'y', 'z',)); (x, y, z,) = P2._first_ngens(3)
>>> P1 = P2.subscheme(x - y)
>>> H12 = P1.Hom(P2)
>>> H12([x**Integer(2), x*z, z**Integer(2)])
Scheme morphism:
  From: Closed subscheme of Projective Space of dimension 2 over Rational Field
        defined by: x - y
  To:   Projective Space of dimension 2 over Rational Field
  Defn: Defined on coordinates by sending (x : y : z) to (x^2 : x*z : z^2)
P2.<x,y,z> = ProjectiveSpace(2, QQ)
P1 = P2.subscheme(x - y)
H12 = P1.Hom(P2)
H12([x^2, x*z, z^2])

We illustrate some error checking:

sage: R.<x,y> = QQ[]
sage: P1 = ProjectiveSpace(R)
sage: H = P1.Hom(P1)
sage: f = H([x - y, x*y])
Traceback (most recent call last):
...
ValueError: polys (=[x - y, x*y]) must be of the same degree

sage: H([x - 1, x*y + x])
Traceback (most recent call last):
...
ValueError: polys (=[x - 1, x*y + x]) must be homogeneous

sage: H([exp(x), exp(y)])                                                       # needs sage.symbolic
Traceback (most recent call last):
...
TypeError: polys (=[e^x, e^y]) must be elements of
Multivariate Polynomial Ring in x, y over Rational Field
>>> from sage.all import *
>>> R = QQ['x, y']; (x, y,) = R._first_ngens(2)
>>> P1 = ProjectiveSpace(R)
>>> H = P1.Hom(P1)
>>> f = H([x - y, x*y])
Traceback (most recent call last):
...
ValueError: polys (=[x - y, x*y]) must be of the same degree

>>> H([x - Integer(1), x*y + x])
Traceback (most recent call last):
...
ValueError: polys (=[x - 1, x*y + x]) must be homogeneous

>>> H([exp(x), exp(y)])                                                       # needs sage.symbolic
Traceback (most recent call last):
...
TypeError: polys (=[e^x, e^y]) must be elements of
Multivariate Polynomial Ring in x, y over Rational Field
R.<x,y> = QQ[]
P1 = ProjectiveSpace(R)
H = P1.Hom(P1)
f = H([x - y, x*y])
H([x - 1, x*y + x])
H([exp(x), exp(y)])                                                       # needs sage.symbolic

We can also compute the forward image of subschemes through elimination. In particular, let \(X = V(h_1,\ldots, h_t)\) and define the ideal \(I = (h_1,\ldots,h_t,y_0-f_0(\bar{x}), \ldots, y_n-f_n(\bar{x}))\). Then the elimination ideal \(I_{n+1} = I \cap K[y_0,\ldots,y_n]\) is a homogeneous ideal and \(f(X) = V(I_{n+1})\):

sage: P.<x,y,z> = ProjectiveSpace(QQ, 2)
sage: H = End(P)
sage: f = H([(x-2*y)^2, (x-2*z)^2, x^2])
sage: X = P.subscheme(y-z)
sage: f(f(f(X)))                                                                # needs sage.libs.singular
Closed subscheme of Projective Space of dimension 2 over Rational Field
 defined by:
  y - z
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = End(P)
>>> f = H([(x-Integer(2)*y)**Integer(2), (x-Integer(2)*z)**Integer(2), x**Integer(2)])
>>> X = P.subscheme(y-z)
>>> f(f(f(X)))                                                                # needs sage.libs.singular
Closed subscheme of Projective Space of dimension 2 over Rational Field
 defined by:
  y - z
P.<x,y,z> = ProjectiveSpace(QQ, 2)
H = End(P)
f = H([(x-2*y)^2, (x-2*z)^2, x^2])
X = P.subscheme(y-z)
f(f(f(X)))                                                                # needs sage.libs.singular
sage: P.<x,y,z,w> = ProjectiveSpace(QQ, 3)
sage: H = End(P)
sage: f = H([(x-2*y)^2, (x-2*z)^2, (x-2*w)^2, x^2])
sage: f(P.subscheme([x,y,z]))                                                   # needs sage.libs.singular
Closed subscheme of Projective Space of dimension 3 over Rational Field
 defined by:
  w,
  y,
  x
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(3), names=('x', 'y', 'z', 'w',)); (x, y, z, w,) = P._first_ngens(4)
>>> H = End(P)
>>> f = H([(x-Integer(2)*y)**Integer(2), (x-Integer(2)*z)**Integer(2), (x-Integer(2)*w)**Integer(2), x**Integer(2)])
>>> f(P.subscheme([x,y,z]))                                                   # needs sage.libs.singular
Closed subscheme of Projective Space of dimension 3 over Rational Field
 defined by:
  w,
  y,
  x
P.<x,y,z,w> = ProjectiveSpace(QQ, 3)
H = End(P)
f = H([(x-2*y)^2, (x-2*z)^2, (x-2*w)^2, x^2])
f(P.subscheme([x,y,z]))                                                   # needs sage.libs.singular
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(3), names=('x', 'y', 'z', 'w',)); (x, y, z, w,) = P._first_ngens(4)
>>> H = End(P)
>>> f = H([(x-Integer(2)*y)**Integer(2), (x-Integer(2)*z)**Integer(2), (x-Integer(2)*w)**Integer(2), x**Integer(2)])
>>> f(P.subscheme([x,y,z]))                                                   # needs sage.libs.singular
Closed subscheme of Projective Space of dimension 3 over Rational Field
 defined by:
  w,
  y,
  x
P.<x,y,z,w> = ProjectiveSpace(QQ, 3)
H = End(P)
f = H([(x-2*y)^2, (x-2*z)^2, (x-2*w)^2, x^2])
f(P.subscheme([x,y,z]))                                                   # needs sage.libs.singular
as_dynamical_system()[source]

Return this endomorphism as a DynamicalSystem_projective.

OUTPUT: DynamicalSystem_projective

EXAMPLES:

sage: P.<x,y,z> = ProjectiveSpace(ZZ, 2)
sage: H = End(P)
sage: f = H([x^2, y^2, z^2])
sage: type(f.as_dynamical_system())                                         # needs sage.schemes
<class 'sage.dynamics.arithmetic_dynamics.projective_ds.DynamicalSystem_projective'>
>>> from sage.all import *
>>> P = ProjectiveSpace(ZZ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = End(P)
>>> f = H([x**Integer(2), y**Integer(2), z**Integer(2)])
>>> type(f.as_dynamical_system())                                         # needs sage.schemes
<class 'sage.dynamics.arithmetic_dynamics.projective_ds.DynamicalSystem_projective'>
P.<x,y,z> = ProjectiveSpace(ZZ, 2)
H = End(P)
f = H([x^2, y^2, z^2])
type(f.as_dynamical_system())                                         # needs sage.schemes
sage: P.<x,y> = ProjectiveSpace(QQ, 1)
sage: H = End(P)
sage: f = H([x^2 - y^2, y^2])
sage: type(f.as_dynamical_system())                                         # needs sage.schemes
<class 'sage.dynamics.arithmetic_dynamics.projective_ds.DynamicalSystem_projective_field'>
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = End(P)
>>> f = H([x**Integer(2) - y**Integer(2), y**Integer(2)])
>>> type(f.as_dynamical_system())                                         # needs sage.schemes
<class 'sage.dynamics.arithmetic_dynamics.projective_ds.DynamicalSystem_projective_field'>
P.<x,y> = ProjectiveSpace(QQ, 1)
H = End(P)
f = H([x^2 - y^2, y^2])
type(f.as_dynamical_system())                                         # needs sage.schemes
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = End(P)
>>> f = H([x**Integer(2) - y**Integer(2), y**Integer(2)])
>>> type(f.as_dynamical_system())                                         # needs sage.schemes
<class 'sage.dynamics.arithmetic_dynamics.projective_ds.DynamicalSystem_projective_field'>
P.<x,y> = ProjectiveSpace(QQ, 1)
H = End(P)
f = H([x^2 - y^2, y^2])
type(f.as_dynamical_system())                                         # needs sage.schemes
sage: P.<x,y> = ProjectiveSpace(GF(5), 1)
sage: H = End(P)
sage: f = H([x^2, y^2])
sage: type(f.as_dynamical_system())                                         # needs sage.schemes
<class 'sage.dynamics.arithmetic_dynamics.projective_ds.DynamicalSystem_projective_finite_field'>
>>> from sage.all import *
>>> P = ProjectiveSpace(GF(Integer(5)), Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = End(P)
>>> f = H([x**Integer(2), y**Integer(2)])
>>> type(f.as_dynamical_system())                                         # needs sage.schemes
<class 'sage.dynamics.arithmetic_dynamics.projective_ds.DynamicalSystem_projective_finite_field'>
P.<x,y> = ProjectiveSpace(GF(5), 1)
H = End(P)
f = H([x^2, y^2])
type(f.as_dynamical_system())                                         # needs sage.schemes
>>> from sage.all import *
>>> P = ProjectiveSpace(GF(Integer(5)), Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = End(P)
>>> f = H([x**Integer(2), y**Integer(2)])
>>> type(f.as_dynamical_system())                                         # needs sage.schemes
<class 'sage.dynamics.arithmetic_dynamics.projective_ds.DynamicalSystem_projective_finite_field'>
P.<x,y> = ProjectiveSpace(GF(5), 1)
H = End(P)
f = H([x^2, y^2])
type(f.as_dynamical_system())                                         # needs sage.schemes
sage: P.<x,y> = ProjectiveSpace(RR, 1)
sage: f = DynamicalSystem([x^2 + y^2, y^2], P)                              # needs sage.schemes
sage: g = f.as_dynamical_system()                                           # needs sage.schemes
sage: g is f                                                                # needs sage.schemes
True
>>> from sage.all import *
>>> P = ProjectiveSpace(RR, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> f = DynamicalSystem([x**Integer(2) + y**Integer(2), y**Integer(2)], P)                              # needs sage.schemes
>>> g = f.as_dynamical_system()                                           # needs sage.schemes
>>> g is f                                                                # needs sage.schemes
True
P.<x,y> = ProjectiveSpace(RR, 1)
f = DynamicalSystem([x^2 + y^2, y^2], P)                              # needs sage.schemes
g = f.as_dynamical_system()                                           # needs sage.schemes
g is f                                                                # needs sage.schemes
>>> from sage.all import *
>>> P = ProjectiveSpace(RR, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> f = DynamicalSystem([x**Integer(2) + y**Integer(2), y**Integer(2)], P)                              # needs sage.schemes
>>> g = f.as_dynamical_system()                                           # needs sage.schemes
>>> g is f                                                                # needs sage.schemes
True
P.<x,y> = ProjectiveSpace(RR, 1)
f = DynamicalSystem([x^2 + y^2, y^2], P)                              # needs sage.schemes
g = f.as_dynamical_system()                                           # needs sage.schemes
g is f                                                                # needs sage.schemes
degree()[source]

Return the degree of this map.

The degree is defined as the degree of the homogeneous polynomials that are the coordinates of this map.

OUTPUT: positive integer

EXAMPLES:

sage: P.<x,y> = ProjectiveSpace(QQ, 1)
sage: H = Hom(P, P)
sage: f = H([x^2 + y^2, y^2])
sage: f.degree()
2
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = Hom(P, P)
>>> f = H([x**Integer(2) + y**Integer(2), y**Integer(2)])
>>> f.degree()
2
P.<x,y> = ProjectiveSpace(QQ, 1)
H = Hom(P, P)
f = H([x^2 + y^2, y^2])
f.degree()
sage: # needs sage.rings.real_mpfr
sage: P.<x,y,z> = ProjectiveSpace(CC, 2)
sage: H = Hom(P, P)
sage: f = H([x^3 + y^3, y^2*z, z*x*y])
sage: f.degree()
3
>>> from sage.all import *
>>> # needs sage.rings.real_mpfr
>>> P = ProjectiveSpace(CC, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = Hom(P, P)
>>> f = H([x**Integer(3) + y**Integer(3), y**Integer(2)*z, z*x*y])
>>> f.degree()
3
# needs sage.rings.real_mpfr
P.<x,y,z> = ProjectiveSpace(CC, 2)
H = Hom(P, P)
f = H([x^3 + y^3, y^2*z, z*x*y])
f.degree()
>>> from sage.all import *
>>> # needs sage.rings.real_mpfr
>>> P = ProjectiveSpace(CC, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = Hom(P, P)
>>> f = H([x**Integer(3) + y**Integer(3), y**Integer(2)*z, z*x*y])
>>> f.degree()
3
# needs sage.rings.real_mpfr
P.<x,y,z> = ProjectiveSpace(CC, 2)
H = Hom(P, P)
f = H([x^3 + y^3, y^2*z, z*x*y])
f.degree()
sage: R.<t> = PolynomialRing(QQ)
sage: P.<x,y,z> = ProjectiveSpace(R, 2)
sage: H = Hom(P, P)
sage: f = H([x^2 + t*y^2, (2-t)*y^2, z^2])
sage: f.degree()
2
>>> from sage.all import *
>>> R = PolynomialRing(QQ, names=('t',)); (t,) = R._first_ngens(1)
>>> P = ProjectiveSpace(R, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = Hom(P, P)
>>> f = H([x**Integer(2) + t*y**Integer(2), (Integer(2)-t)*y**Integer(2), z**Integer(2)])
>>> f.degree()
2
R.<t> = PolynomialRing(QQ)
P.<x,y,z> = ProjectiveSpace(R, 2)
H = Hom(P, P)
f = H([x^2 + t*y^2, (2-t)*y^2, z^2])
f.degree()
>>> from sage.all import *
>>> R = PolynomialRing(QQ, names=('t',)); (t,) = R._first_ngens(1)
>>> P = ProjectiveSpace(R, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = Hom(P, P)
>>> f = H([x**Integer(2) + t*y**Integer(2), (Integer(2)-t)*y**Integer(2), z**Integer(2)])
>>> f.degree()
2
R.<t> = PolynomialRing(QQ)
P.<x,y,z> = ProjectiveSpace(R, 2)
H = Hom(P, P)
f = H([x^2 + t*y^2, (2-t)*y^2, z^2])
f.degree()
sage: P.<x,y,z> = ProjectiveSpace(ZZ, 2)
sage: X = P.subscheme(x^2 - y^2)
sage: H = Hom(X, X)
sage: f = H([x^2, y^2, z^2])
sage: f.degree()
2
>>> from sage.all import *
>>> P = ProjectiveSpace(ZZ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> X = P.subscheme(x**Integer(2) - y**Integer(2))
>>> H = Hom(X, X)
>>> f = H([x**Integer(2), y**Integer(2), z**Integer(2)])
>>> f.degree()
2
P.<x,y,z> = ProjectiveSpace(ZZ, 2)
X = P.subscheme(x^2 - y^2)
H = Hom(X, X)
f = H([x^2, y^2, z^2])
f.degree()
>>> from sage.all import *
>>> P = ProjectiveSpace(ZZ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> X = P.subscheme(x**Integer(2) - y**Integer(2))
>>> H = Hom(X, X)
>>> f = H([x**Integer(2), y**Integer(2), z**Integer(2)])
>>> f.degree()
2
P.<x,y,z> = ProjectiveSpace(ZZ, 2)
X = P.subscheme(x^2 - y^2)
H = Hom(X, X)
f = H([x^2, y^2, z^2])
f.degree()
dehomogenize(n)[source]

Return the standard dehomogenization at the n[0] coordinate for the domain and the n[1] coordinate for the codomain.

Note that the new function is defined over the fraction field of the base ring of this map.

INPUT:

  • n – tuple of nonnegative integers; if n is an integer, then the two values of the tuple are assumed to be the same

OUTPUT: SchemeMorphism_polynomial_affine_space

EXAMPLES:

sage: P.<x,y> = ProjectiveSpace(ZZ, 1)
sage: H = Hom(P, P)
sage: f = H([x^2 + y^2, y^2])
sage: f.dehomogenize(0)
Scheme endomorphism of Affine Space of dimension 1 over Integer Ring
  Defn: Defined on coordinates by sending (y) to (y^2/(y^2 + 1))
>>> from sage.all import *
>>> P = ProjectiveSpace(ZZ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = Hom(P, P)
>>> f = H([x**Integer(2) + y**Integer(2), y**Integer(2)])
>>> f.dehomogenize(Integer(0))
Scheme endomorphism of Affine Space of dimension 1 over Integer Ring
  Defn: Defined on coordinates by sending (y) to (y^2/(y^2 + 1))
P.<x,y> = ProjectiveSpace(ZZ, 1)
H = Hom(P, P)
f = H([x^2 + y^2, y^2])
f.dehomogenize(0)
sage: P.<x,y> = ProjectiveSpace(QQ, 1)
sage: H = Hom(P, P)
sage: f = H([x^2 - y^2, y^2])
sage: f.dehomogenize((0,1))
Scheme morphism:
  From: Affine Space of dimension 1 over Rational Field
  To:   Affine Space of dimension 1 over Rational Field
  Defn: Defined on coordinates by sending (y) to ((-y^2 + 1)/y^2)
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = Hom(P, P)
>>> f = H([x**Integer(2) - y**Integer(2), y**Integer(2)])
>>> f.dehomogenize((Integer(0),Integer(1)))
Scheme morphism:
  From: Affine Space of dimension 1 over Rational Field
  To:   Affine Space of dimension 1 over Rational Field
  Defn: Defined on coordinates by sending (y) to ((-y^2 + 1)/y^2)
P.<x,y> = ProjectiveSpace(QQ, 1)
H = Hom(P, P)
f = H([x^2 - y^2, y^2])
f.dehomogenize((0,1))
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = Hom(P, P)
>>> f = H([x**Integer(2) - y**Integer(2), y**Integer(2)])
>>> f.dehomogenize((Integer(0),Integer(1)))
Scheme morphism:
  From: Affine Space of dimension 1 over Rational Field
  To:   Affine Space of dimension 1 over Rational Field
  Defn: Defined on coordinates by sending (y) to ((-y^2 + 1)/y^2)
P.<x,y> = ProjectiveSpace(QQ, 1)
H = Hom(P, P)
f = H([x^2 - y^2, y^2])
f.dehomogenize((0,1))
sage: P.<x,y,z> = ProjectiveSpace(QQ, 2)
sage: H = Hom(P, P)
sage: f = H([x^2 + y^2, y^2 - z^2, 2*z^2])
sage: f.dehomogenize(2)
Scheme endomorphism of Affine Space of dimension 2 over Rational Field
  Defn: Defined on coordinates by sending (x, y) to
        (1/2*x^2 + 1/2*y^2, 1/2*y^2 - 1/2)
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = Hom(P, P)
>>> f = H([x**Integer(2) + y**Integer(2), y**Integer(2) - z**Integer(2), Integer(2)*z**Integer(2)])
>>> f.dehomogenize(Integer(2))
Scheme endomorphism of Affine Space of dimension 2 over Rational Field
  Defn: Defined on coordinates by sending (x, y) to
        (1/2*x^2 + 1/2*y^2, 1/2*y^2 - 1/2)
P.<x,y,z> = ProjectiveSpace(QQ, 2)
H = Hom(P, P)
f = H([x^2 + y^2, y^2 - z^2, 2*z^2])
f.dehomogenize(2)
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = Hom(P, P)
>>> f = H([x**Integer(2) + y**Integer(2), y**Integer(2) - z**Integer(2), Integer(2)*z**Integer(2)])
>>> f.dehomogenize(Integer(2))
Scheme endomorphism of Affine Space of dimension 2 over Rational Field
  Defn: Defined on coordinates by sending (x, y) to
        (1/2*x^2 + 1/2*y^2, 1/2*y^2 - 1/2)
P.<x,y,z> = ProjectiveSpace(QQ, 2)
H = Hom(P, P)
f = H([x^2 + y^2, y^2 - z^2, 2*z^2])
f.dehomogenize(2)
sage: R.<t> = PolynomialRing(QQ)
sage: P.<x,y,z> = ProjectiveSpace(FractionField(R),2)
sage: H = Hom(P,P)
sage: f = H([x^2 + t*y^2, t*y^2 - z^2, t*z^2])
sage: f.dehomogenize(2)
Scheme endomorphism of Affine Space of dimension 2 over Fraction Field
 of Univariate Polynomial Ring in t over Rational Field
  Defn: Defined on coordinates by sending (x, y) to
        (1/t*x^2 + y^2, y^2 - 1/t)
>>> from sage.all import *
>>> R = PolynomialRing(QQ, names=('t',)); (t,) = R._first_ngens(1)
>>> P = ProjectiveSpace(FractionField(R),Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = Hom(P,P)
>>> f = H([x**Integer(2) + t*y**Integer(2), t*y**Integer(2) - z**Integer(2), t*z**Integer(2)])
>>> f.dehomogenize(Integer(2))
Scheme endomorphism of Affine Space of dimension 2 over Fraction Field
 of Univariate Polynomial Ring in t over Rational Field
  Defn: Defined on coordinates by sending (x, y) to
        (1/t*x^2 + y^2, y^2 - 1/t)
R.<t> = PolynomialRing(QQ)
P.<x,y,z> = ProjectiveSpace(FractionField(R),2)
H = Hom(P,P)
f = H([x^2 + t*y^2, t*y^2 - z^2, t*z^2])
f.dehomogenize(2)
>>> from sage.all import *
>>> R = PolynomialRing(QQ, names=('t',)); (t,) = R._first_ngens(1)
>>> P = ProjectiveSpace(FractionField(R),Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = Hom(P,P)
>>> f = H([x**Integer(2) + t*y**Integer(2), t*y**Integer(2) - z**Integer(2), t*z**Integer(2)])
>>> f.dehomogenize(Integer(2))
Scheme endomorphism of Affine Space of dimension 2 over Fraction Field
 of Univariate Polynomial Ring in t over Rational Field
  Defn: Defined on coordinates by sending (x, y) to
        (1/t*x^2 + y^2, y^2 - 1/t)
R.<t> = PolynomialRing(QQ)
P.<x,y,z> = ProjectiveSpace(FractionField(R),2)
H = Hom(P,P)
f = H([x^2 + t*y^2, t*y^2 - z^2, t*z^2])
f.dehomogenize(2)
sage: P.<x,y,z> = ProjectiveSpace(ZZ, 2)
sage: X = P.subscheme(x^2 - y^2)
sage: H = Hom(X, X)
sage: f = H([x^2, y^2, x*z])
sage: f.dehomogenize(2)                                                     # needs sage.libs.singular
Scheme endomorphism of Closed subscheme of Affine Space of dimension 2
 over Integer Ring defined by: x^2 - y^2
  Defn: Defined on coordinates by sending (x, y) to (x, y^2/x)
>>> from sage.all import *
>>> P = ProjectiveSpace(ZZ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> X = P.subscheme(x**Integer(2) - y**Integer(2))
>>> H = Hom(X, X)
>>> f = H([x**Integer(2), y**Integer(2), x*z])
>>> f.dehomogenize(Integer(2))                                                     # needs sage.libs.singular
Scheme endomorphism of Closed subscheme of Affine Space of dimension 2
 over Integer Ring defined by: x^2 - y^2
  Defn: Defined on coordinates by sending (x, y) to (x, y^2/x)
P.<x,y,z> = ProjectiveSpace(ZZ, 2)
X = P.subscheme(x^2 - y^2)
H = Hom(X, X)
f = H([x^2, y^2, x*z])
f.dehomogenize(2)                                                     # needs sage.libs.singular
>>> from sage.all import *
>>> P = ProjectiveSpace(ZZ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> X = P.subscheme(x**Integer(2) - y**Integer(2))
>>> H = Hom(X, X)
>>> f = H([x**Integer(2), y**Integer(2), x*z])
>>> f.dehomogenize(Integer(2))                                                     # needs sage.libs.singular
Scheme endomorphism of Closed subscheme of Affine Space of dimension 2
 over Integer Ring defined by: x^2 - y^2
  Defn: Defined on coordinates by sending (x, y) to (x, y^2/x)
P.<x,y,z> = ProjectiveSpace(ZZ, 2)
X = P.subscheme(x^2 - y^2)
H = Hom(X, X)
f = H([x^2, y^2, x*z])
f.dehomogenize(2)                                                     # needs sage.libs.singular
sage: P.<x,y> = ProjectiveSpace(QQ, 1)
sage: H = End(P)
sage: f = H([x^2 - 2*x*y, y^2])
sage: f.dehomogenize(0).homogenize(0) == f
True
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = End(P)
>>> f = H([x**Integer(2) - Integer(2)*x*y, y**Integer(2)])
>>> f.dehomogenize(Integer(0)).homogenize(Integer(0)) == f
True
P.<x,y> = ProjectiveSpace(QQ, 1)
H = End(P)
f = H([x^2 - 2*x*y, y^2])
f.dehomogenize(0).homogenize(0) == f
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = End(P)
>>> f = H([x**Integer(2) - Integer(2)*x*y, y**Integer(2)])
>>> f.dehomogenize(Integer(0)).homogenize(Integer(0)) == f
True
P.<x,y> = ProjectiveSpace(QQ, 1)
H = End(P)
f = H([x^2 - 2*x*y, y^2])
f.dehomogenize(0).homogenize(0) == f
sage: # needs sage.rings.number_field
sage: K.<w> = QuadraticField(3)
sage: O = K.ring_of_integers()
sage: P.<x,y> = ProjectiveSpace(O, 1)
sage: H = End(P)
sage: f = H([x^2 - O(w)*y^2, y^2])
sage: f.dehomogenize(1)
Scheme endomorphism of Affine Space of dimension 1 over
 Maximal Order generated by w in Number Field in w with defining polynomial x^2 - 3
  with w = 1.732050807568878?
  Defn: Defined on coordinates by sending (x) to (x^2 - w)
>>> from sage.all import *
>>> # needs sage.rings.number_field
>>> K = QuadraticField(Integer(3), names=('w',)); (w,) = K._first_ngens(1)
>>> O = K.ring_of_integers()
>>> P = ProjectiveSpace(O, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = End(P)
>>> f = H([x**Integer(2) - O(w)*y**Integer(2), y**Integer(2)])
>>> f.dehomogenize(Integer(1))
Scheme endomorphism of Affine Space of dimension 1 over
 Maximal Order generated by w in Number Field in w with defining polynomial x^2 - 3
  with w = 1.732050807568878?
  Defn: Defined on coordinates by sending (x) to (x^2 - w)
# needs sage.rings.number_field
K.<w> = QuadraticField(3)
O = K.ring_of_integers()
P.<x,y> = ProjectiveSpace(O, 1)
H = End(P)
f = H([x^2 - O(w)*y^2, y^2])
f.dehomogenize(1)
>>> from sage.all import *
>>> # needs sage.rings.number_field
>>> K = QuadraticField(Integer(3), names=('w',)); (w,) = K._first_ngens(1)
>>> O = K.ring_of_integers()
>>> P = ProjectiveSpace(O, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = End(P)
>>> f = H([x**Integer(2) - O(w)*y**Integer(2), y**Integer(2)])
>>> f.dehomogenize(Integer(1))
Scheme endomorphism of Affine Space of dimension 1 over
 Maximal Order generated by w in Number Field in w with defining polynomial x^2 - 3
  with w = 1.732050807568878?
  Defn: Defined on coordinates by sending (x) to (x^2 - w)
# needs sage.rings.number_field
K.<w> = QuadraticField(3)
O = K.ring_of_integers()
P.<x,y> = ProjectiveSpace(O, 1)
H = End(P)
f = H([x^2 - O(w)*y^2, y^2])
f.dehomogenize(1)
sage: P1.<x,y> = ProjectiveSpace(QQ, 1)
sage: P2.<u,v,w> = ProjectiveSpace(QQ, 2)
sage: H = Hom(P2, P1)
sage: f = H([u*w, v^2 + w^2])
sage: f.dehomogenize((2,1))
Scheme morphism:
  From: Affine Space of dimension 2 over Rational Field
  To:   Affine Space of dimension 1 over Rational Field
  Defn: Defined on coordinates by sending (u, v) to (u/(v^2 + 1))
>>> from sage.all import *
>>> P1 = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P1._first_ngens(2)
>>> P2 = ProjectiveSpace(QQ, Integer(2), names=('u', 'v', 'w',)); (u, v, w,) = P2._first_ngens(3)
>>> H = Hom(P2, P1)
>>> f = H([u*w, v**Integer(2) + w**Integer(2)])
>>> f.dehomogenize((Integer(2),Integer(1)))
Scheme morphism:
  From: Affine Space of dimension 2 over Rational Field
  To:   Affine Space of dimension 1 over Rational Field
  Defn: Defined on coordinates by sending (u, v) to (u/(v^2 + 1))
P1.<x,y> = ProjectiveSpace(QQ, 1)
P2.<u,v,w> = ProjectiveSpace(QQ, 2)
H = Hom(P2, P1)
f = H([u*w, v^2 + w^2])
f.dehomogenize((2,1))
>>> from sage.all import *
>>> P1 = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P1._first_ngens(2)
>>> P2 = ProjectiveSpace(QQ, Integer(2), names=('u', 'v', 'w',)); (u, v, w,) = P2._first_ngens(3)
>>> H = Hom(P2, P1)
>>> f = H([u*w, v**Integer(2) + w**Integer(2)])
>>> f.dehomogenize((Integer(2),Integer(1)))
Scheme morphism:
  From: Affine Space of dimension 2 over Rational Field
  To:   Affine Space of dimension 1 over Rational Field
  Defn: Defined on coordinates by sending (u, v) to (u/(v^2 + 1))
P1.<x,y> = ProjectiveSpace(QQ, 1)
P2.<u,v,w> = ProjectiveSpace(QQ, 2)
H = Hom(P2, P1)
f = H([u*w, v^2 + w^2])
f.dehomogenize((2,1))
global_height(prec=None)[source]

Return the global height of the coefficients as a projective point.

INPUT:

  • prec – desired floating point precision (default: default RealField precision)

OUTPUT: a real number

EXAMPLES:

sage: P.<x,y> = ProjectiveSpace(QQ, 1)
sage: H = Hom(P, P)
sage: f = H([1/1331*x^2 + 1/4000*y^2, 210*x*y]);
sage: f.global_height()                                                     # needs sage.symbolic
20.8348429892146
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = Hom(P, P)
>>> f = H([Integer(1)/Integer(1331)*x**Integer(2) + Integer(1)/Integer(4000)*y**Integer(2), Integer(210)*x*y]);
>>> f.global_height()                                                     # needs sage.symbolic
20.8348429892146
P.<x,y> = ProjectiveSpace(QQ, 1)
H = Hom(P, P)
f = H([1/1331*x^2 + 1/4000*y^2, 210*x*y]);
f.global_height()                                                     # needs sage.symbolic
sage: P.<x,y> = ProjectiveSpace(QQ, 1)
sage: H = Hom(P, P)
sage: f = H([1/1331*x^2 + 1/4000*y^2, 210*x*y]);
sage: f.global_height(prec=11)                                              # needs sage.symbolic
20.8
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = Hom(P, P)
>>> f = H([Integer(1)/Integer(1331)*x**Integer(2) + Integer(1)/Integer(4000)*y**Integer(2), Integer(210)*x*y]);
>>> f.global_height(prec=Integer(11))                                              # needs sage.symbolic
20.8
P.<x,y> = ProjectiveSpace(QQ, 1)
H = Hom(P, P)
f = H([1/1331*x^2 + 1/4000*y^2, 210*x*y]);
f.global_height(prec=11)                                              # needs sage.symbolic
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = Hom(P, P)
>>> f = H([Integer(1)/Integer(1331)*x**Integer(2) + Integer(1)/Integer(4000)*y**Integer(2), Integer(210)*x*y]);
>>> f.global_height(prec=Integer(11))                                              # needs sage.symbolic
20.8
P.<x,y> = ProjectiveSpace(QQ, 1)
H = Hom(P, P)
f = H([1/1331*x^2 + 1/4000*y^2, 210*x*y]);
f.global_height(prec=11)                                              # needs sage.symbolic
sage: P.<x,y,z> = ProjectiveSpace(ZZ, 2)
sage: H = Hom(P, P)
sage: f = H([4*x^2 + 100*y^2, 210*x*y, 10000*z^2]);
sage: f.global_height()                                                     # needs sage.symbolic
8.51719319141624
>>> from sage.all import *
>>> P = ProjectiveSpace(ZZ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = Hom(P, P)
>>> f = H([Integer(4)*x**Integer(2) + Integer(100)*y**Integer(2), Integer(210)*x*y, Integer(10000)*z**Integer(2)]);
>>> f.global_height()                                                     # needs sage.symbolic
8.51719319141624
P.<x,y,z> = ProjectiveSpace(ZZ, 2)
H = Hom(P, P)
f = H([4*x^2 + 100*y^2, 210*x*y, 10000*z^2]);
f.global_height()                                                     # needs sage.symbolic
>>> from sage.all import *
>>> P = ProjectiveSpace(ZZ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = Hom(P, P)
>>> f = H([Integer(4)*x**Integer(2) + Integer(100)*y**Integer(2), Integer(210)*x*y, Integer(10000)*z**Integer(2)]);
>>> f.global_height()                                                     # needs sage.symbolic
8.51719319141624
P.<x,y,z> = ProjectiveSpace(ZZ, 2)
H = Hom(P, P)
f = H([4*x^2 + 100*y^2, 210*x*y, 10000*z^2]);
f.global_height()                                                     # needs sage.symbolic
sage: # needs sage.rings.number_field
sage: R.<z> = PolynomialRing(QQ)
sage: K.<w> = NumberField(z^2 - 2)
sage: O = K.maximal_order()
sage: P.<x,y> = ProjectiveSpace(O, 1)
sage: H = Hom(P, P)
sage: f = H([2*x^2 + 3*O(w)*y^2, O(w)*y^2])
sage: f.global_height()
1.09861228866811
>>> from sage.all import *
>>> # needs sage.rings.number_field
>>> R = PolynomialRing(QQ, names=('z',)); (z,) = R._first_ngens(1)
>>> K = NumberField(z**Integer(2) - Integer(2), names=('w',)); (w,) = K._first_ngens(1)
>>> O = K.maximal_order()
>>> P = ProjectiveSpace(O, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = Hom(P, P)
>>> f = H([Integer(2)*x**Integer(2) + Integer(3)*O(w)*y**Integer(2), O(w)*y**Integer(2)])
>>> f.global_height()
1.09861228866811
# needs sage.rings.number_field
R.<z> = PolynomialRing(QQ)
K.<w> = NumberField(z^2 - 2)
O = K.maximal_order()
P.<x,y> = ProjectiveSpace(O, 1)
H = Hom(P, P)
f = H([2*x^2 + 3*O(w)*y^2, O(w)*y^2])
f.global_height()
>>> from sage.all import *
>>> # needs sage.rings.number_field
>>> R = PolynomialRing(QQ, names=('z',)); (z,) = R._first_ngens(1)
>>> K = NumberField(z**Integer(2) - Integer(2), names=('w',)); (w,) = K._first_ngens(1)
>>> O = K.maximal_order()
>>> P = ProjectiveSpace(O, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = Hom(P, P)
>>> f = H([Integer(2)*x**Integer(2) + Integer(3)*O(w)*y**Integer(2), O(w)*y**Integer(2)])
>>> f.global_height()
1.09861228866811
# needs sage.rings.number_field
R.<z> = PolynomialRing(QQ)
K.<w> = NumberField(z^2 - 2)
O = K.maximal_order()
P.<x,y> = ProjectiveSpace(O, 1)
H = Hom(P, P)
f = H([2*x^2 + 3*O(w)*y^2, O(w)*y^2])
f.global_height()
sage: # needs sage.rings.number_field sage.symbolic
sage: P.<x,y> = ProjectiveSpace(QQbar, 1)
sage: P2.<u,v,w> = ProjectiveSpace(QQbar, 2)
sage: H = Hom(P, P2)
sage: f = H([x^2 + QQbar(I)*x*y + 3*y^2, y^2, QQbar(sqrt(5))*x*y])
sage: f.global_height()
1.09861228866811
>>> from sage.all import *
>>> # needs sage.rings.number_field sage.symbolic
>>> P = ProjectiveSpace(QQbar, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> P2 = ProjectiveSpace(QQbar, Integer(2), names=('u', 'v', 'w',)); (u, v, w,) = P2._first_ngens(3)
>>> H = Hom(P, P2)
>>> f = H([x**Integer(2) + QQbar(I)*x*y + Integer(3)*y**Integer(2), y**Integer(2), QQbar(sqrt(Integer(5)))*x*y])
>>> f.global_height()
1.09861228866811
# needs sage.rings.number_field sage.symbolic
P.<x,y> = ProjectiveSpace(QQbar, 1)
P2.<u,v,w> = ProjectiveSpace(QQbar, 2)
H = Hom(P, P2)
f = H([x^2 + QQbar(I)*x*y + 3*y^2, y^2, QQbar(sqrt(5))*x*y])
f.global_height()
>>> from sage.all import *
>>> # needs sage.rings.number_field sage.symbolic
>>> P = ProjectiveSpace(QQbar, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> P2 = ProjectiveSpace(QQbar, Integer(2), names=('u', 'v', 'w',)); (u, v, w,) = P2._first_ngens(3)
>>> H = Hom(P, P2)
>>> f = H([x**Integer(2) + QQbar(I)*x*y + Integer(3)*y**Integer(2), y**Integer(2), QQbar(sqrt(Integer(5)))*x*y])
>>> f.global_height()
1.09861228866811
# needs sage.rings.number_field sage.symbolic
P.<x,y> = ProjectiveSpace(QQbar, 1)
P2.<u,v,w> = ProjectiveSpace(QQbar, 2)
H = Hom(P, P2)
f = H([x^2 + QQbar(I)*x*y + 3*y^2, y^2, QQbar(sqrt(5))*x*y])
f.global_height()
sage: P.<x,y,z> = ProjectiveSpace(QQ, 2)
sage: A.<z,w> = ProjectiveSpace(QQ, 1)
sage: H = Hom(P, A)
sage: f = H([1/1331*x^2 + 4000*y*z, y^2])
sage: f.global_height()                                                     # needs sage.symbolic
15.4877354584971
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> A = ProjectiveSpace(QQ, Integer(1), names=('z', 'w',)); (z, w,) = A._first_ngens(2)
>>> H = Hom(P, A)
>>> f = H([Integer(1)/Integer(1331)*x**Integer(2) + Integer(4000)*y*z, y**Integer(2)])
>>> f.global_height()                                                     # needs sage.symbolic
15.4877354584971
P.<x,y,z> = ProjectiveSpace(QQ, 2)
A.<z,w> = ProjectiveSpace(QQ, 1)
H = Hom(P, A)
f = H([1/1331*x^2 + 4000*y*z, y^2])
f.global_height()                                                     # needs sage.symbolic
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> A = ProjectiveSpace(QQ, Integer(1), names=('z', 'w',)); (z, w,) = A._first_ngens(2)
>>> H = Hom(P, A)
>>> f = H([Integer(1)/Integer(1331)*x**Integer(2) + Integer(4000)*y*z, y**Integer(2)])
>>> f.global_height()                                                     # needs sage.symbolic
15.4877354584971
P.<x,y,z> = ProjectiveSpace(QQ, 2)
A.<z,w> = ProjectiveSpace(QQ, 1)
H = Hom(P, A)
f = H([1/1331*x^2 + 4000*y*z, y^2])
f.global_height()                                                     # needs sage.symbolic
sage: P.<x,y> = ProjectiveSpace(QQ, 1)
sage: f = DynamicalSystem([1/25*x^2 + 25/3*x*y + y^2, 1*y^2])
sage: exp(f.global_height())                                                # needs sage.symbolic
625.000000000000
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> f = DynamicalSystem([Integer(1)/Integer(25)*x**Integer(2) + Integer(25)/Integer(3)*x*y + y**Integer(2), Integer(1)*y**Integer(2)])
>>> exp(f.global_height())                                                # needs sage.symbolic
625.000000000000
P.<x,y> = ProjectiveSpace(QQ, 1)
f = DynamicalSystem([1/25*x^2 + 25/3*x*y + y^2, 1*y^2])
exp(f.global_height())                                                # needs sage.symbolic
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> f = DynamicalSystem([Integer(1)/Integer(25)*x**Integer(2) + Integer(25)/Integer(3)*x*y + y**Integer(2), Integer(1)*y**Integer(2)])
>>> exp(f.global_height())                                                # needs sage.symbolic
625.000000000000
P.<x,y> = ProjectiveSpace(QQ, 1)
f = DynamicalSystem([1/25*x^2 + 25/3*x*y + y^2, 1*y^2])
exp(f.global_height())                                                # needs sage.symbolic

Scaling should not change the result:

sage: P.<x,y> = ProjectiveSpace(QQ, 1)
sage: f = DynamicalSystem([1/25*x^2 + 25/3*x*y + y^2, 1*y^2])
sage: f.global_height()                                                     # needs sage.symbolic
6.43775164973640
sage: c = 10000
sage: f.scale_by(c)
sage: f.global_height()                                                     # needs sage.symbolic
6.43775164973640
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> f = DynamicalSystem([Integer(1)/Integer(25)*x**Integer(2) + Integer(25)/Integer(3)*x*y + y**Integer(2), Integer(1)*y**Integer(2)])
>>> f.global_height()                                                     # needs sage.symbolic
6.43775164973640
>>> c = Integer(10000)
>>> f.scale_by(c)
>>> f.global_height()                                                     # needs sage.symbolic
6.43775164973640
P.<x,y> = ProjectiveSpace(QQ, 1)
f = DynamicalSystem([1/25*x^2 + 25/3*x*y + y^2, 1*y^2])
f.global_height()                                                     # needs sage.symbolic
c = 10000
f.scale_by(c)
f.global_height()                                                     # needs sage.symbolic
is_morphism()[source]

Return True if this map is a morphism.

The map is a morphism if and only if the ideal generated by the defining polynomials is the unit ideal (no common zeros of the defining polynomials).

OUTPUT: boolean

EXAMPLES:

sage: P.<x,y> = ProjectiveSpace(QQ, 1)
sage: H = Hom(P, P)
sage: f = H([x^2 + y^2, y^2])
sage: f.is_morphism()                                                       # needs sage.libs.singular
True
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = Hom(P, P)
>>> f = H([x**Integer(2) + y**Integer(2), y**Integer(2)])
>>> f.is_morphism()                                                       # needs sage.libs.singular
True
P.<x,y> = ProjectiveSpace(QQ, 1)
H = Hom(P, P)
f = H([x^2 + y^2, y^2])
f.is_morphism()                                                       # needs sage.libs.singular
sage: P.<x,y,z> = ProjectiveSpace(RR, 2)
sage: H = Hom(P, P)
sage: f = H([x*z - y*z, x^2 - y^2, z^2])
sage: f.is_morphism()                                                       # needs sage.libs.singular
False
>>> from sage.all import *
>>> P = ProjectiveSpace(RR, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = Hom(P, P)
>>> f = H([x*z - y*z, x**Integer(2) - y**Integer(2), z**Integer(2)])
>>> f.is_morphism()                                                       # needs sage.libs.singular
False
P.<x,y,z> = ProjectiveSpace(RR, 2)
H = Hom(P, P)
f = H([x*z - y*z, x^2 - y^2, z^2])
f.is_morphism()                                                       # needs sage.libs.singular
>>> from sage.all import *
>>> P = ProjectiveSpace(RR, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = Hom(P, P)
>>> f = H([x*z - y*z, x**Integer(2) - y**Integer(2), z**Integer(2)])
>>> f.is_morphism()                                                       # needs sage.libs.singular
False
P.<x,y,z> = ProjectiveSpace(RR, 2)
H = Hom(P, P)
f = H([x*z - y*z, x^2 - y^2, z^2])
f.is_morphism()                                                       # needs sage.libs.singular
sage: R.<t> = PolynomialRing(GF(5))
sage: P.<x,y,z> = ProjectiveSpace(R, 2)
sage: H = Hom(P, P)
sage: f = H([x*z - t*y^2, x^2 - y^2, t*z^2])
sage: f.is_morphism()                                                       # needs sage.libs.singular
True
>>> from sage.all import *
>>> R = PolynomialRing(GF(Integer(5)), names=('t',)); (t,) = R._first_ngens(1)
>>> P = ProjectiveSpace(R, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = Hom(P, P)
>>> f = H([x*z - t*y**Integer(2), x**Integer(2) - y**Integer(2), t*z**Integer(2)])
>>> f.is_morphism()                                                       # needs sage.libs.singular
True
R.<t> = PolynomialRing(GF(5))
P.<x,y,z> = ProjectiveSpace(R, 2)
H = Hom(P, P)
f = H([x*z - t*y^2, x^2 - y^2, t*z^2])
f.is_morphism()                                                       # needs sage.libs.singular
>>> from sage.all import *
>>> R = PolynomialRing(GF(Integer(5)), names=('t',)); (t,) = R._first_ngens(1)
>>> P = ProjectiveSpace(R, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = Hom(P, P)
>>> f = H([x*z - t*y**Integer(2), x**Integer(2) - y**Integer(2), t*z**Integer(2)])
>>> f.is_morphism()                                                       # needs sage.libs.singular
True
R.<t> = PolynomialRing(GF(5))
P.<x,y,z> = ProjectiveSpace(R, 2)
H = Hom(P, P)
f = H([x*z - t*y^2, x^2 - y^2, t*z^2])
f.is_morphism()                                                       # needs sage.libs.singular

Map that is not morphism on projective space, but is over a subscheme:

sage: P.<x,y,z> = ProjectiveSpace(RR, 2)
sage: X = P.subscheme([x*y + y*z])
sage: H = Hom(X, X)
sage: f = H([x*z - y*z, x^2 - y^2, z^2])
sage: f.is_morphism()                                                       # needs sage.libs.singular
True
>>> from sage.all import *
>>> P = ProjectiveSpace(RR, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> X = P.subscheme([x*y + y*z])
>>> H = Hom(X, X)
>>> f = H([x*z - y*z, x**Integer(2) - y**Integer(2), z**Integer(2)])
>>> f.is_morphism()                                                       # needs sage.libs.singular
True
P.<x,y,z> = ProjectiveSpace(RR, 2)
X = P.subscheme([x*y + y*z])
H = Hom(X, X)
f = H([x*z - y*z, x^2 - y^2, z^2])
f.is_morphism()                                                       # needs sage.libs.singular
local_height(v, prec=None)[source]

Return the maximum of the local height of the coefficients in any of the coordinate functions of this map.

INPUT:

  • v – a prime or prime ideal of the base ring

  • prec – desired floating point precision (default: default RealField precision)

OUTPUT: a real number

EXAMPLES:

sage: P.<x,y> = ProjectiveSpace(QQ, 1)
sage: H = Hom(P, P)
sage: f = H([1/1331*x^2 + 1/4000*y^2, 210*x*y])
sage: f.local_height(1331)                                                  # needs sage.rings.real_mpfr
7.19368581839511
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = Hom(P, P)
>>> f = H([Integer(1)/Integer(1331)*x**Integer(2) + Integer(1)/Integer(4000)*y**Integer(2), Integer(210)*x*y])
>>> f.local_height(Integer(1331))                                                  # needs sage.rings.real_mpfr
7.19368581839511
P.<x,y> = ProjectiveSpace(QQ, 1)
H = Hom(P, P)
f = H([1/1331*x^2 + 1/4000*y^2, 210*x*y])
f.local_height(1331)                                                  # needs sage.rings.real_mpfr
sage: P.<x,y> = ProjectiveSpace(QQ, 1)
sage: H = Hom(P, P)
sage: f = H([1/1331*x^2 + 1/4000*y^2, 210*x*y])
sage: f.local_height(1331, prec=2)                                          # needs sage.rings.real_mpfr
8.0
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = Hom(P, P)
>>> f = H([Integer(1)/Integer(1331)*x**Integer(2) + Integer(1)/Integer(4000)*y**Integer(2), Integer(210)*x*y])
>>> f.local_height(Integer(1331), prec=Integer(2))                                          # needs sage.rings.real_mpfr
8.0
P.<x,y> = ProjectiveSpace(QQ, 1)
H = Hom(P, P)
f = H([1/1331*x^2 + 1/4000*y^2, 210*x*y])
f.local_height(1331, prec=2)                                          # needs sage.rings.real_mpfr
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = Hom(P, P)
>>> f = H([Integer(1)/Integer(1331)*x**Integer(2) + Integer(1)/Integer(4000)*y**Integer(2), Integer(210)*x*y])
>>> f.local_height(Integer(1331), prec=Integer(2))                                          # needs sage.rings.real_mpfr
8.0
P.<x,y> = ProjectiveSpace(QQ, 1)
H = Hom(P, P)
f = H([1/1331*x^2 + 1/4000*y^2, 210*x*y])
f.local_height(1331, prec=2)                                          # needs sage.rings.real_mpfr

This function does not automatically normalize:

sage: P.<x,y,z> = ProjectiveSpace(QQ, 2)
sage: H = Hom(P, P)
sage: f = H([4*x^2 + 3/100*y^2, 8/210*x*y, 1/10000*z^2])
sage: f.local_height(2)                                                     # needs sage.rings.real_mpfr
2.77258872223978
sage: f.normalize_coordinates()                                             # needs sage.libs.singular
sage: f.local_height(2)                                                     # needs sage.libs.singular
0.000000000000000
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = Hom(P, P)
>>> f = H([Integer(4)*x**Integer(2) + Integer(3)/Integer(100)*y**Integer(2), Integer(8)/Integer(210)*x*y, Integer(1)/Integer(10000)*z**Integer(2)])
>>> f.local_height(Integer(2))                                                     # needs sage.rings.real_mpfr
2.77258872223978
>>> f.normalize_coordinates()                                             # needs sage.libs.singular
>>> f.local_height(Integer(2))                                                     # needs sage.libs.singular
0.000000000000000
P.<x,y,z> = ProjectiveSpace(QQ, 2)
H = Hom(P, P)
f = H([4*x^2 + 3/100*y^2, 8/210*x*y, 1/10000*z^2])
f.local_height(2)                                                     # needs sage.rings.real_mpfr
f.normalize_coordinates()                                             # needs sage.libs.singular
f.local_height(2)                                                     # needs sage.libs.singular
sage: # needs sage.rings.number_field
sage: R.<z> = PolynomialRing(QQ)
sage: K.<w> = NumberField(z^2 - 2)
sage: P.<x,y> = ProjectiveSpace(K, 1)
sage: H = Hom(P, P)
sage: f = H([2*x^2 + w/3*y^2, 1/w*y^2])
sage: f.local_height(K.ideal(3))
1.09861228866811
>>> from sage.all import *
>>> # needs sage.rings.number_field
>>> R = PolynomialRing(QQ, names=('z',)); (z,) = R._first_ngens(1)
>>> K = NumberField(z**Integer(2) - Integer(2), names=('w',)); (w,) = K._first_ngens(1)
>>> P = ProjectiveSpace(K, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = Hom(P, P)
>>> f = H([Integer(2)*x**Integer(2) + w/Integer(3)*y**Integer(2), Integer(1)/w*y**Integer(2)])
>>> f.local_height(K.ideal(Integer(3)))
1.09861228866811
# needs sage.rings.number_field
R.<z> = PolynomialRing(QQ)
K.<w> = NumberField(z^2 - 2)
P.<x,y> = ProjectiveSpace(K, 1)
H = Hom(P, P)
f = H([2*x^2 + w/3*y^2, 1/w*y^2])
f.local_height(K.ideal(3))
>>> from sage.all import *
>>> # needs sage.rings.number_field
>>> R = PolynomialRing(QQ, names=('z',)); (z,) = R._first_ngens(1)
>>> K = NumberField(z**Integer(2) - Integer(2), names=('w',)); (w,) = K._first_ngens(1)
>>> P = ProjectiveSpace(K, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = Hom(P, P)
>>> f = H([Integer(2)*x**Integer(2) + w/Integer(3)*y**Integer(2), Integer(1)/w*y**Integer(2)])
>>> f.local_height(K.ideal(Integer(3)))
1.09861228866811
# needs sage.rings.number_field
R.<z> = PolynomialRing(QQ)
K.<w> = NumberField(z^2 - 2)
P.<x,y> = ProjectiveSpace(K, 1)
H = Hom(P, P)
f = H([2*x^2 + w/3*y^2, 1/w*y^2])
f.local_height(K.ideal(3))
local_height_arch(i, prec=None)[source]

Return the maximum of the local height at the i-th infinite place of the coefficients in any of the coordinate functions of this map.

INPUT:

  • i – integer

  • prec – desired floating point precision (default: default RealField precision)

OUTPUT: a real number

EXAMPLES:

sage: P.<x,y> = ProjectiveSpace(QQ, 1)
sage: H = Hom(P, P)
sage: f = H([1/1331*x^2 + 1/4000*y^2, 210*x*y])
sage: f.local_height_arch(0)                                                # needs sage.rings.real_mpfr
5.34710753071747
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = Hom(P, P)
>>> f = H([Integer(1)/Integer(1331)*x**Integer(2) + Integer(1)/Integer(4000)*y**Integer(2), Integer(210)*x*y])
>>> f.local_height_arch(Integer(0))                                                # needs sage.rings.real_mpfr
5.34710753071747
P.<x,y> = ProjectiveSpace(QQ, 1)
H = Hom(P, P)
f = H([1/1331*x^2 + 1/4000*y^2, 210*x*y])
f.local_height_arch(0)                                                # needs sage.rings.real_mpfr
sage: P.<x,y> = ProjectiveSpace(QQ, 1)
sage: H = Hom(P, P)
sage: f = H([1/1331*x^2 + 1/4000*y^2, 210*x*y])
sage: f.local_height_arch(0, prec=5)                                        # needs sage.rings.real_mpfr
5.2
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = Hom(P, P)
>>> f = H([Integer(1)/Integer(1331)*x**Integer(2) + Integer(1)/Integer(4000)*y**Integer(2), Integer(210)*x*y])
>>> f.local_height_arch(Integer(0), prec=Integer(5))                                        # needs sage.rings.real_mpfr
5.2
P.<x,y> = ProjectiveSpace(QQ, 1)
H = Hom(P, P)
f = H([1/1331*x^2 + 1/4000*y^2, 210*x*y])
f.local_height_arch(0, prec=5)                                        # needs sage.rings.real_mpfr
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = Hom(P, P)
>>> f = H([Integer(1)/Integer(1331)*x**Integer(2) + Integer(1)/Integer(4000)*y**Integer(2), Integer(210)*x*y])
>>> f.local_height_arch(Integer(0), prec=Integer(5))                                        # needs sage.rings.real_mpfr
5.2
P.<x,y> = ProjectiveSpace(QQ, 1)
H = Hom(P, P)
f = H([1/1331*x^2 + 1/4000*y^2, 210*x*y])
f.local_height_arch(0, prec=5)                                        # needs sage.rings.real_mpfr
sage: # needs sage.rings.number_field
sage: R.<z> = PolynomialRing(QQ)
sage: K.<w> = NumberField(z^2 - 2)
sage: P.<x,y> = ProjectiveSpace(K, 1)
sage: H = Hom(P, P)
sage: f = H([2*x^2 + w/3*y^2, 1/w*y^2])
sage: f.local_height_arch(1)
0.6931471805599453094172321214582
>>> from sage.all import *
>>> # needs sage.rings.number_field
>>> R = PolynomialRing(QQ, names=('z',)); (z,) = R._first_ngens(1)
>>> K = NumberField(z**Integer(2) - Integer(2), names=('w',)); (w,) = K._first_ngens(1)
>>> P = ProjectiveSpace(K, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = Hom(P, P)
>>> f = H([Integer(2)*x**Integer(2) + w/Integer(3)*y**Integer(2), Integer(1)/w*y**Integer(2)])
>>> f.local_height_arch(Integer(1))
0.6931471805599453094172321214582
# needs sage.rings.number_field
R.<z> = PolynomialRing(QQ)
K.<w> = NumberField(z^2 - 2)
P.<x,y> = ProjectiveSpace(K, 1)
H = Hom(P, P)
f = H([2*x^2 + w/3*y^2, 1/w*y^2])
f.local_height_arch(1)
>>> from sage.all import *
>>> # needs sage.rings.number_field
>>> R = PolynomialRing(QQ, names=('z',)); (z,) = R._first_ngens(1)
>>> K = NumberField(z**Integer(2) - Integer(2), names=('w',)); (w,) = K._first_ngens(1)
>>> P = ProjectiveSpace(K, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = Hom(P, P)
>>> f = H([Integer(2)*x**Integer(2) + w/Integer(3)*y**Integer(2), Integer(1)/w*y**Integer(2)])
>>> f.local_height_arch(Integer(1))
0.6931471805599453094172321214582
# needs sage.rings.number_field
R.<z> = PolynomialRing(QQ)
K.<w> = NumberField(z^2 - 2)
P.<x,y> = ProjectiveSpace(K, 1)
H = Hom(P, P)
f = H([2*x^2 + w/3*y^2, 1/w*y^2])
f.local_height_arch(1)
normalize_coordinates(**kwds)[source]

Ensures that this morphism has integral coefficients. If the coordinate ring has a GCD, then it ensures that the coefficients have no common factor.

It also makes the leading coefficients of the first polynomial positive (if positive has meaning in the coordinate ring). This is done in place.

When ideal or valuation is specified, normalization occurs with respect to the absolute value defined by the ideal or valuation. That is, the coefficients are scaled such that one coefficient has absolute value 1 while the others have absolute value less than or equal to 1. Only supported when the base ring is a number field.

INPUT: keyword arguments:

  • ideal – (optional) a prime ideal of the base ring of this morphism

  • valuation – (optional) a valuation of the base ring of this morphism

OUTPUT: none

EXAMPLES:

sage: P.<x,y> = ProjectiveSpace(QQ, 1)
sage: H = Hom(P, P)
sage: f = H([5/4*x^3, 5*x*y^2])
sage: f.normalize_coordinates(); f
Scheme endomorphism of Projective Space of dimension 1 over Rational Field
  Defn: Defined on coordinates by sending (x : y) to (x^2 : 4*y^2)
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = Hom(P, P)
>>> f = H([Integer(5)/Integer(4)*x**Integer(3), Integer(5)*x*y**Integer(2)])
>>> f.normalize_coordinates(); f
Scheme endomorphism of Projective Space of dimension 1 over Rational Field
  Defn: Defined on coordinates by sending (x : y) to (x^2 : 4*y^2)
P.<x,y> = ProjectiveSpace(QQ, 1)
H = Hom(P, P)
f = H([5/4*x^3, 5*x*y^2])
f.normalize_coordinates(); f
sage: P.<x,y,z> = ProjectiveSpace(GF(7), 2)
sage: X = P.subscheme(x^2 - y^2)
sage: H = Hom(X, X)
sage: f = H([x^3 + x*y^2, x*y^2, x*z^2])
sage: f.normalize_coordinates(); f                                          # needs sage.libs.singular
Scheme endomorphism of Closed subscheme of Projective Space of dimension 2
 over Finite Field of size 7 defined by: x^2 - y^2
  Defn: Defined on coordinates by sending (x : y : z) to (2*y^2 : y^2 : z^2)
>>> from sage.all import *
>>> P = ProjectiveSpace(GF(Integer(7)), Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> X = P.subscheme(x**Integer(2) - y**Integer(2))
>>> H = Hom(X, X)
>>> f = H([x**Integer(3) + x*y**Integer(2), x*y**Integer(2), x*z**Integer(2)])
>>> f.normalize_coordinates(); f                                          # needs sage.libs.singular
Scheme endomorphism of Closed subscheme of Projective Space of dimension 2
 over Finite Field of size 7 defined by: x^2 - y^2
  Defn: Defined on coordinates by sending (x : y : z) to (2*y^2 : y^2 : z^2)
P.<x,y,z> = ProjectiveSpace(GF(7), 2)
X = P.subscheme(x^2 - y^2)
H = Hom(X, X)
f = H([x^3 + x*y^2, x*y^2, x*z^2])
f.normalize_coordinates(); f                                          # needs sage.libs.singular
>>> from sage.all import *
>>> P = ProjectiveSpace(GF(Integer(7)), Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> X = P.subscheme(x**Integer(2) - y**Integer(2))
>>> H = Hom(X, X)
>>> f = H([x**Integer(3) + x*y**Integer(2), x*y**Integer(2), x*z**Integer(2)])
>>> f.normalize_coordinates(); f                                          # needs sage.libs.singular
Scheme endomorphism of Closed subscheme of Projective Space of dimension 2
 over Finite Field of size 7 defined by: x^2 - y^2
  Defn: Defined on coordinates by sending (x : y : z) to (2*y^2 : y^2 : z^2)
P.<x,y,z> = ProjectiveSpace(GF(7), 2)
X = P.subscheme(x^2 - y^2)
H = Hom(X, X)
f = H([x^3 + x*y^2, x*y^2, x*z^2])
f.normalize_coordinates(); f                                          # needs sage.libs.singular
sage: R.<a,b> = QQ[]
sage: P.<x,y,z> = ProjectiveSpace(R, 2)
sage: H = End(P)
sage: f = H([a*(x*z + y^2)*x^2, a*b*(x*z + y^2)*y^2, a*(x*z + y^2)*z^2])
sage: f.normalize_coordinates(); f
Scheme endomorphism of Projective Space of dimension 2 over
 Multivariate Polynomial Ring in a, b over Rational Field
  Defn: Defined on coordinates by sending (x : y : z) to (x^2 : b*y^2 : z^2)
>>> from sage.all import *
>>> R = QQ['a, b']; (a, b,) = R._first_ngens(2)
>>> P = ProjectiveSpace(R, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = End(P)
>>> f = H([a*(x*z + y**Integer(2))*x**Integer(2), a*b*(x*z + y**Integer(2))*y**Integer(2), a*(x*z + y**Integer(2))*z**Integer(2)])
>>> f.normalize_coordinates(); f
Scheme endomorphism of Projective Space of dimension 2 over
 Multivariate Polynomial Ring in a, b over Rational Field
  Defn: Defined on coordinates by sending (x : y : z) to (x^2 : b*y^2 : z^2)
R.<a,b> = QQ[]
P.<x,y,z> = ProjectiveSpace(R, 2)
H = End(P)
f = H([a*(x*z + y^2)*x^2, a*b*(x*z + y^2)*y^2, a*(x*z + y^2)*z^2])
f.normalize_coordinates(); f
>>> from sage.all import *
>>> R = QQ['a, b']; (a, b,) = R._first_ngens(2)
>>> P = ProjectiveSpace(R, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = End(P)
>>> f = H([a*(x*z + y**Integer(2))*x**Integer(2), a*b*(x*z + y**Integer(2))*y**Integer(2), a*(x*z + y**Integer(2))*z**Integer(2)])
>>> f.normalize_coordinates(); f
Scheme endomorphism of Projective Space of dimension 2 over
 Multivariate Polynomial Ring in a, b over Rational Field
  Defn: Defined on coordinates by sending (x : y : z) to (x^2 : b*y^2 : z^2)
R.<a,b> = QQ[]
P.<x,y,z> = ProjectiveSpace(R, 2)
H = End(P)
f = H([a*(x*z + y^2)*x^2, a*b*(x*z + y^2)*y^2, a*(x*z + y^2)*z^2])
f.normalize_coordinates(); f
sage: # needs sage.rings.number_field
sage: K.<w> = QuadraticField(5)
sage: P.<x,y> = ProjectiveSpace(K, 1)
sage: f = DynamicalSystem([w*x^2 + (1/5*w)*y^2, w*y^2])
sage: f.normalize_coordinates(); f
Dynamical System of Projective Space of dimension 1 over Number Field in w
 with defining polynomial x^2 - 5 with w = 2.236067977499790?
  Defn: Defined on coordinates by sending (x : y) to (5*x^2 + y^2 : 5*y^2)
>>> from sage.all import *
>>> # needs sage.rings.number_field
>>> K = QuadraticField(Integer(5), names=('w',)); (w,) = K._first_ngens(1)
>>> P = ProjectiveSpace(K, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> f = DynamicalSystem([w*x**Integer(2) + (Integer(1)/Integer(5)*w)*y**Integer(2), w*y**Integer(2)])
>>> f.normalize_coordinates(); f
Dynamical System of Projective Space of dimension 1 over Number Field in w
 with defining polynomial x^2 - 5 with w = 2.236067977499790?
  Defn: Defined on coordinates by sending (x : y) to (5*x^2 + y^2 : 5*y^2)
# needs sage.rings.number_field
K.<w> = QuadraticField(5)
P.<x,y> = ProjectiveSpace(K, 1)
f = DynamicalSystem([w*x^2 + (1/5*w)*y^2, w*y^2])
f.normalize_coordinates(); f
>>> from sage.all import *
>>> # needs sage.rings.number_field
>>> K = QuadraticField(Integer(5), names=('w',)); (w,) = K._first_ngens(1)
>>> P = ProjectiveSpace(K, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> f = DynamicalSystem([w*x**Integer(2) + (Integer(1)/Integer(5)*w)*y**Integer(2), w*y**Integer(2)])
>>> f.normalize_coordinates(); f
Dynamical System of Projective Space of dimension 1 over Number Field in w
 with defining polynomial x^2 - 5 with w = 2.236067977499790?
  Defn: Defined on coordinates by sending (x : y) to (5*x^2 + y^2 : 5*y^2)
# needs sage.rings.number_field
K.<w> = QuadraticField(5)
P.<x,y> = ProjectiveSpace(K, 1)
f = DynamicalSystem([w*x^2 + (1/5*w)*y^2, w*y^2])
f.normalize_coordinates(); f
sage: # needs sage.rings.number_field
sage: R.<t> = PolynomialRing(ZZ)
sage: K.<b> = NumberField(t^3 - 11)
sage: a = 7/(b - 1)
sage: P.<x,y> = ProjectiveSpace(K, 1)
sage: f = DynamicalSystem_projective([a*y^2 - (a*y - x)^2, y^2])
sage: f.normalize_coordinates(); f
Dynamical System of Projective Space of dimension 1 over
 Number Field in b with defining polynomial t^3 - 11
  Defn: Defined on coordinates by sending (x : y) to
        (-100*x^2 + (140*b^2 + 140*b + 140)*x*y + (-77*b^2 - 567*b - 1057)*y^2
         : 100*y^2)
>>> from sage.all import *
>>> # needs sage.rings.number_field
>>> R = PolynomialRing(ZZ, names=('t',)); (t,) = R._first_ngens(1)
>>> K = NumberField(t**Integer(3) - Integer(11), names=('b',)); (b,) = K._first_ngens(1)
>>> a = Integer(7)/(b - Integer(1))
>>> P = ProjectiveSpace(K, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> f = DynamicalSystem_projective([a*y**Integer(2) - (a*y - x)**Integer(2), y**Integer(2)])
>>> f.normalize_coordinates(); f
Dynamical System of Projective Space of dimension 1 over
 Number Field in b with defining polynomial t^3 - 11
  Defn: Defined on coordinates by sending (x : y) to
        (-100*x^2 + (140*b^2 + 140*b + 140)*x*y + (-77*b^2 - 567*b - 1057)*y^2
         : 100*y^2)
# needs sage.rings.number_field
R.<t> = PolynomialRing(ZZ)
K.<b> = NumberField(t^3 - 11)
a = 7/(b - 1)
P.<x,y> = ProjectiveSpace(K, 1)
f = DynamicalSystem_projective([a*y^2 - (a*y - x)^2, y^2])
f.normalize_coordinates(); f
>>> from sage.all import *
>>> # needs sage.rings.number_field
>>> R = PolynomialRing(ZZ, names=('t',)); (t,) = R._first_ngens(1)
>>> K = NumberField(t**Integer(3) - Integer(11), names=('b',)); (b,) = K._first_ngens(1)
>>> a = Integer(7)/(b - Integer(1))
>>> P = ProjectiveSpace(K, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> f = DynamicalSystem_projective([a*y**Integer(2) - (a*y - x)**Integer(2), y**Integer(2)])
>>> f.normalize_coordinates(); f
Dynamical System of Projective Space of dimension 1 over
 Number Field in b with defining polynomial t^3 - 11
  Defn: Defined on coordinates by sending (x : y) to
        (-100*x^2 + (140*b^2 + 140*b + 140)*x*y + (-77*b^2 - 567*b - 1057)*y^2
         : 100*y^2)
# needs sage.rings.number_field
R.<t> = PolynomialRing(ZZ)
K.<b> = NumberField(t^3 - 11)
a = 7/(b - 1)
P.<x,y> = ProjectiveSpace(K, 1)
f = DynamicalSystem_projective([a*y^2 - (a*y - x)^2, y^2])
f.normalize_coordinates(); f

We can used ideal to scale with respect to a norm defined by an ideal:

sage: P.<x,y> = ProjectiveSpace(QQ, 1)
sage: f = DynamicalSystem_projective([2*x^3, 2*x^2*y + 4*x*y^2])
sage: f.normalize_coordinates(ideal=2); f
Dynamical System of Projective Space of dimension 1 over Rational Field
  Defn: Defined on coordinates by sending (x : y) to (x^3 : x^2*y + 2*x*y^2)
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> f = DynamicalSystem_projective([Integer(2)*x**Integer(3), Integer(2)*x**Integer(2)*y + Integer(4)*x*y**Integer(2)])
>>> f.normalize_coordinates(ideal=Integer(2)); f
Dynamical System of Projective Space of dimension 1 over Rational Field
  Defn: Defined on coordinates by sending (x : y) to (x^3 : x^2*y + 2*x*y^2)
P.<x,y> = ProjectiveSpace(QQ, 1)
f = DynamicalSystem_projective([2*x^3, 2*x^2*y + 4*x*y^2])
f.normalize_coordinates(ideal=2); f
sage: # needs sage.rings.number_field
sage: R.<w> = QQ[]
sage: A.<a> = NumberField(w^2 + 1)
sage: P.<x,y,z> = ProjectiveSpace(A, 2)
sage: X = P.subscheme(x^2 - y^2)
sage: H = Hom(X, X)
sage: f = H([(a+1)*x^3 + 2*x*y^2, 4*x*y^2, 8*x*z^2])
sage: f.normalize_coordinates(ideal=A.prime_above(2)); f
Scheme endomorphism of Closed subscheme of Projective Space of dimension 2 over
 Number Field in a with defining polynomial w^2 + 1 defined by: x^2 - y^2
  Defn: Defined on coordinates by sending (x : y : z) to
        ((-a + 2)*x*y^2 : (-2*a + 2)*x*y^2 : (-4*a + 4)*x*z^2)
>>> from sage.all import *
>>> # needs sage.rings.number_field
>>> R = QQ['w']; (w,) = R._first_ngens(1)
>>> A = NumberField(w**Integer(2) + Integer(1), names=('a',)); (a,) = A._first_ngens(1)
>>> P = ProjectiveSpace(A, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> X = P.subscheme(x**Integer(2) - y**Integer(2))
>>> H = Hom(X, X)
>>> f = H([(a+Integer(1))*x**Integer(3) + Integer(2)*x*y**Integer(2), Integer(4)*x*y**Integer(2), Integer(8)*x*z**Integer(2)])
>>> f.normalize_coordinates(ideal=A.prime_above(Integer(2))); f
Scheme endomorphism of Closed subscheme of Projective Space of dimension 2 over
 Number Field in a with defining polynomial w^2 + 1 defined by: x^2 - y^2
  Defn: Defined on coordinates by sending (x : y : z) to
        ((-a + 2)*x*y^2 : (-2*a + 2)*x*y^2 : (-4*a + 4)*x*z^2)
# needs sage.rings.number_field
R.<w> = QQ[]
A.<a> = NumberField(w^2 + 1)
P.<x,y,z> = ProjectiveSpace(A, 2)
X = P.subscheme(x^2 - y^2)
H = Hom(X, X)
f = H([(a+1)*x^3 + 2*x*y^2, 4*x*y^2, 8*x*z^2])
f.normalize_coordinates(ideal=A.prime_above(2)); f
>>> from sage.all import *
>>> # needs sage.rings.number_field
>>> R = QQ['w']; (w,) = R._first_ngens(1)
>>> A = NumberField(w**Integer(2) + Integer(1), names=('a',)); (a,) = A._first_ngens(1)
>>> P = ProjectiveSpace(A, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> X = P.subscheme(x**Integer(2) - y**Integer(2))
>>> H = Hom(X, X)
>>> f = H([(a+Integer(1))*x**Integer(3) + Integer(2)*x*y**Integer(2), Integer(4)*x*y**Integer(2), Integer(8)*x*z**Integer(2)])
>>> f.normalize_coordinates(ideal=A.prime_above(Integer(2))); f
Scheme endomorphism of Closed subscheme of Projective Space of dimension 2 over
 Number Field in a with defining polynomial w^2 + 1 defined by: x^2 - y^2
  Defn: Defined on coordinates by sending (x : y : z) to
        ((-a + 2)*x*y^2 : (-2*a + 2)*x*y^2 : (-4*a + 4)*x*z^2)
# needs sage.rings.number_field
R.<w> = QQ[]
A.<a> = NumberField(w^2 + 1)
P.<x,y,z> = ProjectiveSpace(A, 2)
X = P.subscheme(x^2 - y^2)
H = Hom(X, X)
f = H([(a+1)*x^3 + 2*x*y^2, 4*x*y^2, 8*x*z^2])
f.normalize_coordinates(ideal=A.prime_above(2)); f

We can pass in a valuation to valuation:

sage: g = H([(a+1)*x^3 + 2*x*y^2, 4*x*y^2, 8*x*z^2])                        # needs sage.rings.number_field
sage: g.normalize_coordinates(valuation=A.valuation(A.prime_above(2)))      # needs sage.rings.number_field
sage: g == f                                                                # needs sage.rings.number_field
True
>>> from sage.all import *
>>> g = H([(a+Integer(1))*x**Integer(3) + Integer(2)*x*y**Integer(2), Integer(4)*x*y**Integer(2), Integer(8)*x*z**Integer(2)])                        # needs sage.rings.number_field
>>> g.normalize_coordinates(valuation=A.valuation(A.prime_above(Integer(2))))      # needs sage.rings.number_field
>>> g == f                                                                # needs sage.rings.number_field
True
g = H([(a+1)*x^3 + 2*x*y^2, 4*x*y^2, 8*x*z^2])                        # needs sage.rings.number_field
g.normalize_coordinates(valuation=A.valuation(A.prime_above(2)))      # needs sage.rings.number_field
g == f                                                                # needs sage.rings.number_field
sage: P.<x,y> = ProjectiveSpace(Qp(3), 1)                                   # needs sage.rings.padics
sage: f = DynamicalSystem_projective([3*x^2 + 6*y^2, 9*x*y])                # needs sage.rings.padics
sage: f.normalize_coordinates(); f                                          # needs sage.rings.padics
Dynamical System of Projective Space of dimension 1 over
 3-adic Field with capped relative precision 20
  Defn: Defined on coordinates by sending (x : y) to
        (x^2 + (2 + O(3^20))*y^2 : (3 + O(3^21))*x*y)
>>> from sage.all import *
>>> P = ProjectiveSpace(Qp(Integer(3)), Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)# needs sage.rings.padics
>>> f = DynamicalSystem_projective([Integer(3)*x**Integer(2) + Integer(6)*y**Integer(2), Integer(9)*x*y])                # needs sage.rings.padics
>>> f.normalize_coordinates(); f                                          # needs sage.rings.padics
Dynamical System of Projective Space of dimension 1 over
 3-adic Field with capped relative precision 20
  Defn: Defined on coordinates by sending (x : y) to
        (x^2 + (2 + O(3^20))*y^2 : (3 + O(3^21))*x*y)
P.<x,y> = ProjectiveSpace(Qp(3), 1)                                   # needs sage.rings.padics
f = DynamicalSystem_projective([3*x^2 + 6*y^2, 9*x*y])                # needs sage.rings.padics
f.normalize_coordinates(); f                                          # needs sage.rings.padics
>>> from sage.all import *
>>> P = ProjectiveSpace(Qp(Integer(3)), Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)# needs sage.rings.padics
>>> f = DynamicalSystem_projective([Integer(3)*x**Integer(2) + Integer(6)*y**Integer(2), Integer(9)*x*y])                # needs sage.rings.padics
>>> f.normalize_coordinates(); f                                          # needs sage.rings.padics
Dynamical System of Projective Space of dimension 1 over
 3-adic Field with capped relative precision 20
  Defn: Defined on coordinates by sending (x : y) to
        (x^2 + (2 + O(3^20))*y^2 : (3 + O(3^21))*x*y)
P.<x,y> = ProjectiveSpace(Qp(3), 1)                                   # needs sage.rings.padics
f = DynamicalSystem_projective([3*x^2 + 6*y^2, 9*x*y])                # needs sage.rings.padics
f.normalize_coordinates(); f                                          # needs sage.rings.padics

Check that #35797 is fixed:

sage: # needs sage.rings.number_field
sage: R.<x> = QQ[]
sage: K.<a> = NumberField(3*x^2 + 1)
sage: P.<z,w> = ProjectiveSpace(K, 1)
sage: f = DynamicalSystem_projective([a*(z^2 + w^2), z*w])
sage: f.normalize_coordinates(); f
Dynamical System of Projective Space of dimension 1 over
Number Field in a with defining polynomial 3*x^2 + 1
Defn: Defined on coordinates by sending (z : w) to
    ((-3/2*a + 1/2)*z^2 + (-3/2*a + 1/2)*w^2 : (-3/2*a - 3/2)*z*w)
>>> from sage.all import *
>>> # needs sage.rings.number_field
>>> R = QQ['x']; (x,) = R._first_ngens(1)
>>> K = NumberField(Integer(3)*x**Integer(2) + Integer(1), names=('a',)); (a,) = K._first_ngens(1)
>>> P = ProjectiveSpace(K, Integer(1), names=('z', 'w',)); (z, w,) = P._first_ngens(2)
>>> f = DynamicalSystem_projective([a*(z**Integer(2) + w**Integer(2)), z*w])
>>> f.normalize_coordinates(); f
Dynamical System of Projective Space of dimension 1 over
Number Field in a with defining polynomial 3*x^2 + 1
Defn: Defined on coordinates by sending (z : w) to
    ((-3/2*a + 1/2)*z^2 + (-3/2*a + 1/2)*w^2 : (-3/2*a - 3/2)*z*w)
# needs sage.rings.number_field
R.<x> = QQ[]
K.<a> = NumberField(3*x^2 + 1)
P.<z,w> = ProjectiveSpace(K, 1)
f = DynamicalSystem_projective([a*(z^2 + w^2), z*w])
f.normalize_coordinates(); f
sage: R.<a,b> = QQ[]
sage: P.<x,y,z> = ProjectiveSpace(FractionField(R), 2)
sage: H = End(P)
sage: f = H([a/b*(x*z + y^2)*x^2, a*b*(x*z + y^2)*y^2, a*(x*z + y^2)*z^2])
sage: f.normalize_coordinates(); f
Scheme endomorphism of Projective Space of dimension 2 over Fraction
Field of Multivariate Polynomial Ring in a, b over Rational Field
Defn: Defined on coordinates by sending (x : y : z) to
    (x^2 : (b^2)*y^2 : b*z^2)
>>> from sage.all import *
>>> R = QQ['a, b']; (a, b,) = R._first_ngens(2)
>>> P = ProjectiveSpace(FractionField(R), Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = End(P)
>>> f = H([a/b*(x*z + y**Integer(2))*x**Integer(2), a*b*(x*z + y**Integer(2))*y**Integer(2), a*(x*z + y**Integer(2))*z**Integer(2)])
>>> f.normalize_coordinates(); f
Scheme endomorphism of Projective Space of dimension 2 over Fraction
Field of Multivariate Polynomial Ring in a, b over Rational Field
Defn: Defined on coordinates by sending (x : y : z) to
    (x^2 : (b^2)*y^2 : b*z^2)
R.<a,b> = QQ[]
P.<x,y,z> = ProjectiveSpace(FractionField(R), 2)
H = End(P)
f = H([a/b*(x*z + y^2)*x^2, a*b*(x*z + y^2)*y^2, a*(x*z + y^2)*z^2])
f.normalize_coordinates(); f
>>> from sage.all import *
>>> R = QQ['a, b']; (a, b,) = R._first_ngens(2)
>>> P = ProjectiveSpace(FractionField(R), Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = End(P)
>>> f = H([a/b*(x*z + y**Integer(2))*x**Integer(2), a*b*(x*z + y**Integer(2))*y**Integer(2), a*(x*z + y**Integer(2))*z**Integer(2)])
>>> f.normalize_coordinates(); f
Scheme endomorphism of Projective Space of dimension 2 over Fraction
Field of Multivariate Polynomial Ring in a, b over Rational Field
Defn: Defined on coordinates by sending (x : y : z) to
    (x^2 : (b^2)*y^2 : b*z^2)
R.<a,b> = QQ[]
P.<x,y,z> = ProjectiveSpace(FractionField(R), 2)
H = End(P)
f = H([a/b*(x*z + y^2)*x^2, a*b*(x*z + y^2)*y^2, a*(x*z + y^2)*z^2])
f.normalize_coordinates(); f
scale_by(t)[source]

Scale each coordinate by a factor of t.

A TypeError occurs if the point is not in the coordinate ring of the parent after scaling.

INPUT:

  • t – a ring element

OUTPUT: none

EXAMPLES:

sage: A.<x,y> = ProjectiveSpace(QQ, 1)
sage: H = Hom(A, A)
sage: f = H([x^3 - 2*x*y^2, x^2*y])
sage: f.scale_by(1/x)
sage: f
Scheme endomorphism of Projective Space of dimension 1 over Rational Field
  Defn: Defined on coordinates by sending (x : y) to (x^2 - 2*y^2 : x*y)
>>> from sage.all import *
>>> A = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = A._first_ngens(2)
>>> H = Hom(A, A)
>>> f = H([x**Integer(3) - Integer(2)*x*y**Integer(2), x**Integer(2)*y])
>>> f.scale_by(Integer(1)/x)
>>> f
Scheme endomorphism of Projective Space of dimension 1 over Rational Field
  Defn: Defined on coordinates by sending (x : y) to (x^2 - 2*y^2 : x*y)
A.<x,y> = ProjectiveSpace(QQ, 1)
H = Hom(A, A)
f = H([x^3 - 2*x*y^2, x^2*y])
f.scale_by(1/x)
f
sage: R.<t> = PolynomialRing(QQ)
sage: P.<x,y> = ProjectiveSpace(R, 1)
sage: H = Hom(P,P)
sage: f = H([3/5*x^2, 6*y^2])
sage: f.scale_by(5/3*t); f
Scheme endomorphism of Projective Space of dimension 1 over
 Univariate Polynomial Ring in t over Rational Field
  Defn: Defined on coordinates by sending (x : y) to (t*x^2 : 10*t*y^2)
>>> from sage.all import *
>>> R = PolynomialRing(QQ, names=('t',)); (t,) = R._first_ngens(1)
>>> P = ProjectiveSpace(R, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = Hom(P,P)
>>> f = H([Integer(3)/Integer(5)*x**Integer(2), Integer(6)*y**Integer(2)])
>>> f.scale_by(Integer(5)/Integer(3)*t); f
Scheme endomorphism of Projective Space of dimension 1 over
 Univariate Polynomial Ring in t over Rational Field
  Defn: Defined on coordinates by sending (x : y) to (t*x^2 : 10*t*y^2)
R.<t> = PolynomialRing(QQ)
P.<x,y> = ProjectiveSpace(R, 1)
H = Hom(P,P)
f = H([3/5*x^2, 6*y^2])
f.scale_by(5/3*t); f
>>> from sage.all import *
>>> R = PolynomialRing(QQ, names=('t',)); (t,) = R._first_ngens(1)
>>> P = ProjectiveSpace(R, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = Hom(P,P)
>>> f = H([Integer(3)/Integer(5)*x**Integer(2), Integer(6)*y**Integer(2)])
>>> f.scale_by(Integer(5)/Integer(3)*t); f
Scheme endomorphism of Projective Space of dimension 1 over
 Univariate Polynomial Ring in t over Rational Field
  Defn: Defined on coordinates by sending (x : y) to (t*x^2 : 10*t*y^2)
R.<t> = PolynomialRing(QQ)
P.<x,y> = ProjectiveSpace(R, 1)
H = Hom(P,P)
f = H([3/5*x^2, 6*y^2])
f.scale_by(5/3*t); f
sage: P.<x,y,z> = ProjectiveSpace(GF(7), 2)
sage: X = P.subscheme(x^2 - y^2)
sage: H = Hom(X, X)
sage: f = H([x^2, y^2, z^2])
sage: f.scale_by(x - y); f                                                  # needs sage.libs.singular
Scheme endomorphism of Closed subscheme of Projective Space of dimension 2
 over Finite Field of size 7 defined by: x^2 - y^2
  Defn: Defined on coordinates by sending (x : y : z) to
        (x*y^2 - y^3 : x*y^2 - y^3 : x*z^2 - y*z^2)
>>> from sage.all import *
>>> P = ProjectiveSpace(GF(Integer(7)), Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> X = P.subscheme(x**Integer(2) - y**Integer(2))
>>> H = Hom(X, X)
>>> f = H([x**Integer(2), y**Integer(2), z**Integer(2)])
>>> f.scale_by(x - y); f                                                  # needs sage.libs.singular
Scheme endomorphism of Closed subscheme of Projective Space of dimension 2
 over Finite Field of size 7 defined by: x^2 - y^2
  Defn: Defined on coordinates by sending (x : y : z) to
        (x*y^2 - y^3 : x*y^2 - y^3 : x*z^2 - y*z^2)
P.<x,y,z> = ProjectiveSpace(GF(7), 2)
X = P.subscheme(x^2 - y^2)
H = Hom(X, X)
f = H([x^2, y^2, z^2])
f.scale_by(x - y); f                                                  # needs sage.libs.singular
>>> from sage.all import *
>>> P = ProjectiveSpace(GF(Integer(7)), Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> X = P.subscheme(x**Integer(2) - y**Integer(2))
>>> H = Hom(X, X)
>>> f = H([x**Integer(2), y**Integer(2), z**Integer(2)])
>>> f.scale_by(x - y); f                                                  # needs sage.libs.singular
Scheme endomorphism of Closed subscheme of Projective Space of dimension 2
 over Finite Field of size 7 defined by: x^2 - y^2
  Defn: Defined on coordinates by sending (x : y : z) to
        (x*y^2 - y^3 : x*y^2 - y^3 : x*z^2 - y*z^2)
P.<x,y,z> = ProjectiveSpace(GF(7), 2)
X = P.subscheme(x^2 - y^2)
H = Hom(X, X)
f = H([x^2, y^2, z^2])
f.scale_by(x - y); f                                                  # needs sage.libs.singular
wronskian_ideal()[source]

Return the ideal generated by the critical point locus.

This is the vanishing of the maximal minors of the Jacobian matrix. Not implemented for subvarieties.

OUTPUT: an ideal in the coordinate ring of the domain of this map

EXAMPLES:

sage: # needs sage.rings.number_field
sage: R.<x> = PolynomialRing(QQ)
sage: K.<w> = NumberField(x^2 + 11)
sage: P.<x,y> = ProjectiveSpace(K, 1)
sage: H = End(P)
sage: f = H([x^2 - w*y^2, w*y^2])
sage: f.wronskian_ideal()
Ideal ((4*w)*x*y) of Multivariate Polynomial Ring in x, y
 over Number Field in w with defining polynomial x^2 + 11
>>> from sage.all import *
>>> # needs sage.rings.number_field
>>> R = PolynomialRing(QQ, names=('x',)); (x,) = R._first_ngens(1)
>>> K = NumberField(x**Integer(2) + Integer(11), names=('w',)); (w,) = K._first_ngens(1)
>>> P = ProjectiveSpace(K, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = End(P)
>>> f = H([x**Integer(2) - w*y**Integer(2), w*y**Integer(2)])
>>> f.wronskian_ideal()
Ideal ((4*w)*x*y) of Multivariate Polynomial Ring in x, y
 over Number Field in w with defining polynomial x^2 + 11
# needs sage.rings.number_field
R.<x> = PolynomialRing(QQ)
K.<w> = NumberField(x^2 + 11)
P.<x,y> = ProjectiveSpace(K, 1)
H = End(P)
f = H([x^2 - w*y^2, w*y^2])
f.wronskian_ideal()
sage: # needs sage.rings.number_field
sage: P.<x,y> = ProjectiveSpace(QQ, 1)
sage: P2.<u,v,t> = ProjectiveSpace(K, 2)
sage: H = Hom(P, P2)
sage: f = H([x^2 - 2*y^2, y^2, x*y])
sage: f.wronskian_ideal()
Ideal (4*x*y, 2*x^2 + 4*y^2, -2*y^2) of
 Multivariate Polynomial Ring in x, y over Rational Field
>>> from sage.all import *
>>> # needs sage.rings.number_field
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> P2 = ProjectiveSpace(K, Integer(2), names=('u', 'v', 't',)); (u, v, t,) = P2._first_ngens(3)
>>> H = Hom(P, P2)
>>> f = H([x**Integer(2) - Integer(2)*y**Integer(2), y**Integer(2), x*y])
>>> f.wronskian_ideal()
Ideal (4*x*y, 2*x^2 + 4*y^2, -2*y^2) of
 Multivariate Polynomial Ring in x, y over Rational Field
# needs sage.rings.number_field
P.<x,y> = ProjectiveSpace(QQ, 1)
P2.<u,v,t> = ProjectiveSpace(K, 2)
H = Hom(P, P2)
f = H([x^2 - 2*y^2, y^2, x*y])
f.wronskian_ideal()
>>> from sage.all import *
>>> # needs sage.rings.number_field
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> P2 = ProjectiveSpace(K, Integer(2), names=('u', 'v', 't',)); (u, v, t,) = P2._first_ngens(3)
>>> H = Hom(P, P2)
>>> f = H([x**Integer(2) - Integer(2)*y**Integer(2), y**Integer(2), x*y])
>>> f.wronskian_ideal()
Ideal (4*x*y, 2*x^2 + 4*y^2, -2*y^2) of
 Multivariate Polynomial Ring in x, y over Rational Field
# needs sage.rings.number_field
P.<x,y> = ProjectiveSpace(QQ, 1)
P2.<u,v,t> = ProjectiveSpace(K, 2)
H = Hom(P, P2)
f = H([x^2 - 2*y^2, y^2, x*y])
f.wronskian_ideal()
class sage.schemes.projective.projective_morphism.SchemeMorphism_polynomial_projective_space_field(parent, polys, check=True)[source]

Bases: SchemeMorphism_polynomial_projective_space

base_indeterminacy_locus()[source]

Return the base indeterminacy locus of this map.

The base indeterminacy locus is the set of points in projective space at which all of the defining polynomials of the rational map simultaneously vanish.

OUTPUT: a subscheme of the domain of the map

EXAMPLES:

sage: P.<x,y,z> = ProjectiveSpace(QQ, 2)
sage: H = End(P)
sage: f = H([x*z - y*z, x^2 - y^2, z^2])
sage: f.base_indeterminacy_locus()
Closed subscheme of Projective Space of dimension 2 over Rational Field defined by:
  x*z - y*z,
  x^2 - y^2,
  z^2
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = End(P)
>>> f = H([x*z - y*z, x**Integer(2) - y**Integer(2), z**Integer(2)])
>>> f.base_indeterminacy_locus()
Closed subscheme of Projective Space of dimension 2 over Rational Field defined by:
  x*z - y*z,
  x^2 - y^2,
  z^2
P.<x,y,z> = ProjectiveSpace(QQ, 2)
H = End(P)
f = H([x*z - y*z, x^2 - y^2, z^2])
f.base_indeterminacy_locus()
sage: P.<x,y,z> = ProjectiveSpace(QQ, 2)
sage: H = End(P)
sage: f = H([x^2, y^2, z^2])
sage: f.base_indeterminacy_locus()
Closed subscheme of Projective Space of dimension 2 over Rational Field
 defined by:
  x^2,
  y^2,
  z^2
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = End(P)
>>> f = H([x**Integer(2), y**Integer(2), z**Integer(2)])
>>> f.base_indeterminacy_locus()
Closed subscheme of Projective Space of dimension 2 over Rational Field
 defined by:
  x^2,
  y^2,
  z^2
P.<x,y,z> = ProjectiveSpace(QQ, 2)
H = End(P)
f = H([x^2, y^2, z^2])
f.base_indeterminacy_locus()
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = End(P)
>>> f = H([x**Integer(2), y**Integer(2), z**Integer(2)])
>>> f.base_indeterminacy_locus()
Closed subscheme of Projective Space of dimension 2 over Rational Field
 defined by:
  x^2,
  y^2,
  z^2
P.<x,y,z> = ProjectiveSpace(QQ, 2)
H = End(P)
f = H([x^2, y^2, z^2])
f.base_indeterminacy_locus()
sage: P1.<x,y,z> = ProjectiveSpace(RR, 2)
sage: P2.<t,u,v,w> = ProjectiveSpace(RR, 3)
sage: H = Hom(P1, P2)
sage: h = H([y^3*z^3, x^3*z^3, y^3*z^3, x^2*y^2*z^2])
sage: h.base_indeterminacy_locus()                                          # needs sage.rings.real_mpfr
Closed subscheme of Projective Space of dimension 2 over
 Real Field with 53 bits of precision defined by:
  y^3*z^3,
  x^3*z^3,
  y^3*z^3,
  x^2*y^2*z^2
>>> from sage.all import *
>>> P1 = ProjectiveSpace(RR, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P1._first_ngens(3)
>>> P2 = ProjectiveSpace(RR, Integer(3), names=('t', 'u', 'v', 'w',)); (t, u, v, w,) = P2._first_ngens(4)
>>> H = Hom(P1, P2)
>>> h = H([y**Integer(3)*z**Integer(3), x**Integer(3)*z**Integer(3), y**Integer(3)*z**Integer(3), x**Integer(2)*y**Integer(2)*z**Integer(2)])
>>> h.base_indeterminacy_locus()                                          # needs sage.rings.real_mpfr
Closed subscheme of Projective Space of dimension 2 over
 Real Field with 53 bits of precision defined by:
  y^3*z^3,
  x^3*z^3,
  y^3*z^3,
  x^2*y^2*z^2
P1.<x,y,z> = ProjectiveSpace(RR, 2)
P2.<t,u,v,w> = ProjectiveSpace(RR, 3)
H = Hom(P1, P2)
h = H([y^3*z^3, x^3*z^3, y^3*z^3, x^2*y^2*z^2])
h.base_indeterminacy_locus()                                          # needs sage.rings.real_mpfr
>>> from sage.all import *
>>> P1 = ProjectiveSpace(RR, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P1._first_ngens(3)
>>> P2 = ProjectiveSpace(RR, Integer(3), names=('t', 'u', 'v', 'w',)); (t, u, v, w,) = P2._first_ngens(4)
>>> H = Hom(P1, P2)
>>> h = H([y**Integer(3)*z**Integer(3), x**Integer(3)*z**Integer(3), y**Integer(3)*z**Integer(3), x**Integer(2)*y**Integer(2)*z**Integer(2)])
>>> h.base_indeterminacy_locus()                                          # needs sage.rings.real_mpfr
Closed subscheme of Projective Space of dimension 2 over
 Real Field with 53 bits of precision defined by:
  y^3*z^3,
  x^3*z^3,
  y^3*z^3,
  x^2*y^2*z^2
P1.<x,y,z> = ProjectiveSpace(RR, 2)
P2.<t,u,v,w> = ProjectiveSpace(RR, 3)
H = Hom(P1, P2)
h = H([y^3*z^3, x^3*z^3, y^3*z^3, x^2*y^2*z^2])
h.base_indeterminacy_locus()                                          # needs sage.rings.real_mpfr

If defining polynomials are not normalized, output scheme will not be normalized:

sage: P.<x,y,z> = ProjectiveSpace(QQ,2)
sage: H = End(P)
sage: f = H([x*x^2,x*y^2,x*z^2])
sage: f.base_indeterminacy_locus()
Closed subscheme of Projective Space of dimension 2 over Rational Field
 defined by:
  x^3,
  x*y^2,
  x*z^2
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ,Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = End(P)
>>> f = H([x*x**Integer(2),x*y**Integer(2),x*z**Integer(2)])
>>> f.base_indeterminacy_locus()
Closed subscheme of Projective Space of dimension 2 over Rational Field
 defined by:
  x^3,
  x*y^2,
  x*z^2
P.<x,y,z> = ProjectiveSpace(QQ,2)
H = End(P)
f = H([x*x^2,x*y^2,x*z^2])
f.base_indeterminacy_locus()
image()[source]

Return the scheme-theoretic image of the morphism.

OUTPUT: a subscheme of the ambient space of the codomain

EXAMPLES:

sage: P2.<x0,x1,x2> = ProjectiveSpace(QQ, 2)
sage: f = P2.hom([x0^3, x0^2*x1, x0*x1^2], P2)
sage: f.image()                                                             # needs sage.libs.singular
Closed subscheme of Projective Space of dimension 2 over Rational Field defined by:
  x1^2 - x0*x2
sage: f = P2.hom([x0 - x1, x0 - x2, x1 - x2], P2)
sage: f.image()                                                             # needs sage.libs.singular
Closed subscheme of Projective Space of dimension 2 over Rational Field defined by:
  x0 - x1 + x2
>>> from sage.all import *
>>> P2 = ProjectiveSpace(QQ, Integer(2), names=('x0', 'x1', 'x2',)); (x0, x1, x2,) = P2._first_ngens(3)
>>> f = P2.hom([x0**Integer(3), x0**Integer(2)*x1, x0*x1**Integer(2)], P2)
>>> f.image()                                                             # needs sage.libs.singular
Closed subscheme of Projective Space of dimension 2 over Rational Field defined by:
  x1^2 - x0*x2
>>> f = P2.hom([x0 - x1, x0 - x2, x1 - x2], P2)
>>> f.image()                                                             # needs sage.libs.singular
Closed subscheme of Projective Space of dimension 2 over Rational Field defined by:
  x0 - x1 + x2
P2.<x0,x1,x2> = ProjectiveSpace(QQ, 2)
f = P2.hom([x0^3, x0^2*x1, x0*x1^2], P2)
f.image()                                                             # needs sage.libs.singular
f = P2.hom([x0 - x1, x0 - x2, x1 - x2], P2)
f.image()                                                             # needs sage.libs.singular
sage: P2.<x0,x1,x2> = ProjectiveSpace(QQ, 2)
sage: A2.<x,y> = AffineSpace(QQ, 2)
sage: f = P2.hom([1, x0/x1], A2)
sage: f.image()                                                             # needs sage.libs.singular
Closed subscheme of Affine Space of dimension 2 over Rational Field defined by:
  -x + 1
>>> from sage.all import *
>>> P2 = ProjectiveSpace(QQ, Integer(2), names=('x0', 'x1', 'x2',)); (x0, x1, x2,) = P2._first_ngens(3)
>>> A2 = AffineSpace(QQ, Integer(2), names=('x', 'y',)); (x, y,) = A2._first_ngens(2)
>>> f = P2.hom([Integer(1), x0/x1], A2)
>>> f.image()                                                             # needs sage.libs.singular
Closed subscheme of Affine Space of dimension 2 over Rational Field defined by:
  -x + 1
P2.<x0,x1,x2> = ProjectiveSpace(QQ, 2)
A2.<x,y> = AffineSpace(QQ, 2)
f = P2.hom([1, x0/x1], A2)
f.image()                                                             # needs sage.libs.singular
>>> from sage.all import *
>>> P2 = ProjectiveSpace(QQ, Integer(2), names=('x0', 'x1', 'x2',)); (x0, x1, x2,) = P2._first_ngens(3)
>>> A2 = AffineSpace(QQ, Integer(2), names=('x', 'y',)); (x, y,) = A2._first_ngens(2)
>>> f = P2.hom([Integer(1), x0/x1], A2)
>>> f.image()                                                             # needs sage.libs.singular
Closed subscheme of Affine Space of dimension 2 over Rational Field defined by:
  -x + 1
P2.<x0,x1,x2> = ProjectiveSpace(QQ, 2)
A2.<x,y> = AffineSpace(QQ, 2)
f = P2.hom([1, x0/x1], A2)
f.image()                                                             # needs sage.libs.singular
indeterminacy_locus()[source]

Return the indeterminacy locus of this map as a rational map on the domain.

The indeterminacy locus is the intersection of all the base indeterminacy locuses of maps that define the same rational map as by this map.

OUTPUT: a subscheme of the domain of the map

EXAMPLES:

sage: P.<x,y,z> = ProjectiveSpace(QQ, 2)
sage: H = End(P)
sage: f = H([x^2, y^2, z^2])
sage: f.indeterminacy_locus()                                               # needs sage.libs.singular
... DeprecationWarning: The meaning of indeterminacy_locus() has changed.
Read the docstring. See https://github.com/sagemath/sage/issues/29145 for details.
Closed subscheme of Projective Space of dimension 2 over Rational Field defined by:
  z,
  y,
  x
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = End(P)
>>> f = H([x**Integer(2), y**Integer(2), z**Integer(2)])
>>> f.indeterminacy_locus()                                               # needs sage.libs.singular
... DeprecationWarning: The meaning of indeterminacy_locus() has changed.
Read the docstring. See https://github.com/sagemath/sage/issues/29145 for details.
Closed subscheme of Projective Space of dimension 2 over Rational Field defined by:
  z,
  y,
  x
P.<x,y,z> = ProjectiveSpace(QQ, 2)
H = End(P)
f = H([x^2, y^2, z^2])
f.indeterminacy_locus()                                               # needs sage.libs.singular
sage: P.<x,y,z> = ProjectiveSpace(QQ, 2)
sage: H = End(P)
sage: f = H([x*z - y*z, x^2 - y^2, z^2])
sage: f.indeterminacy_locus()                                               # needs sage.libs.singular
Closed subscheme of Projective Space of dimension 2 over Rational Field defined by:
  z,
  x^2 - y^2
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = End(P)
>>> f = H([x*z - y*z, x**Integer(2) - y**Integer(2), z**Integer(2)])
>>> f.indeterminacy_locus()                                               # needs sage.libs.singular
Closed subscheme of Projective Space of dimension 2 over Rational Field defined by:
  z,
  x^2 - y^2
P.<x,y,z> = ProjectiveSpace(QQ, 2)
H = End(P)
f = H([x*z - y*z, x^2 - y^2, z^2])
f.indeterminacy_locus()                                               # needs sage.libs.singular
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = End(P)
>>> f = H([x*z - y*z, x**Integer(2) - y**Integer(2), z**Integer(2)])
>>> f.indeterminacy_locus()                                               # needs sage.libs.singular
Closed subscheme of Projective Space of dimension 2 over Rational Field defined by:
  z,
  x^2 - y^2
P.<x,y,z> = ProjectiveSpace(QQ, 2)
H = End(P)
f = H([x*z - y*z, x^2 - y^2, z^2])
f.indeterminacy_locus()                                               # needs sage.libs.singular

There is related base_indeterminacy_locus() method. This computes the indeterminacy locus only from the defining polynomials of the map:

sage: P.<x,y,z> = ProjectiveSpace(QQ, 2)
sage: H = End(P)
sage: f = H([x*z - y*z, x^2 - y^2, z^2])
sage: f.base_indeterminacy_locus()
Closed subscheme of Projective Space of dimension 2 over Rational Field defined by:
  x*z - y*z,
  x^2 - y^2,
  z^2
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = End(P)
>>> f = H([x*z - y*z, x**Integer(2) - y**Integer(2), z**Integer(2)])
>>> f.base_indeterminacy_locus()
Closed subscheme of Projective Space of dimension 2 over Rational Field defined by:
  x*z - y*z,
  x^2 - y^2,
  z^2
P.<x,y,z> = ProjectiveSpace(QQ, 2)
H = End(P)
f = H([x*z - y*z, x^2 - y^2, z^2])
f.base_indeterminacy_locus()
indeterminacy_points(F=None, base=False)[source]

Return the points in the indeterminacy locus of this map.

If the dimension of the indeterminacy locus is not zero, an error is raised.

INPUT:

  • F – a field; if not given, the base ring of the domain is assumed

  • base – if True, the base indeterminacy locus is used

OUTPUT: indeterminacy points of the map defined over F

EXAMPLES:

sage: P.<x,y,z> = ProjectiveSpace(QQ, 2)
sage: H = End(P)
sage: f = H([x*z - y*z, x^2 - y^2, z^2])
sage: f.indeterminacy_points()                                              # needs sage.libs.singular
... DeprecationWarning: The meaning of indeterminacy_locus() has changed.
Read the docstring. See https://github.com/sagemath/sage/issues/29145 for details.
[(-1 : 1 : 0), (1 : 1 : 0)]
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = End(P)
>>> f = H([x*z - y*z, x**Integer(2) - y**Integer(2), z**Integer(2)])
>>> f.indeterminacy_points()                                              # needs sage.libs.singular
... DeprecationWarning: The meaning of indeterminacy_locus() has changed.
Read the docstring. See https://github.com/sagemath/sage/issues/29145 for details.
[(-1 : 1 : 0), (1 : 1 : 0)]
P.<x,y,z> = ProjectiveSpace(QQ, 2)
H = End(P)
f = H([x*z - y*z, x^2 - y^2, z^2])
f.indeterminacy_points()                                              # needs sage.libs.singular
sage: P1.<x,y,z> = ProjectiveSpace(RR, 2)
sage: P2.<t,u,v,w> = ProjectiveSpace(RR, 3)
sage: H = Hom(P1, P2)
sage: h = H([x + y, y, z + y, y])
sage: set_verbose(None)
sage: h.indeterminacy_points(base=True)                                     # needs sage.libs.singular
[]
sage: g = H([y^3*z^3, x^3*z^3, y^3*z^3, x^2*y^2*z^2])
sage: g.indeterminacy_points(base=True)                                     # needs sage.libs.singular
Traceback (most recent call last):
...
ValueError: indeterminacy scheme is not dimension 0
>>> from sage.all import *
>>> P1 = ProjectiveSpace(RR, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P1._first_ngens(3)
>>> P2 = ProjectiveSpace(RR, Integer(3), names=('t', 'u', 'v', 'w',)); (t, u, v, w,) = P2._first_ngens(4)
>>> H = Hom(P1, P2)
>>> h = H([x + y, y, z + y, y])
>>> set_verbose(None)
>>> h.indeterminacy_points(base=True)                                     # needs sage.libs.singular
[]
>>> g = H([y**Integer(3)*z**Integer(3), x**Integer(3)*z**Integer(3), y**Integer(3)*z**Integer(3), x**Integer(2)*y**Integer(2)*z**Integer(2)])
>>> g.indeterminacy_points(base=True)                                     # needs sage.libs.singular
Traceback (most recent call last):
...
ValueError: indeterminacy scheme is not dimension 0
P1.<x,y,z> = ProjectiveSpace(RR, 2)
P2.<t,u,v,w> = ProjectiveSpace(RR, 3)
H = Hom(P1, P2)
h = H([x + y, y, z + y, y])
set_verbose(None)
h.indeterminacy_points(base=True)                                     # needs sage.libs.singular
g = H([y^3*z^3, x^3*z^3, y^3*z^3, x^2*y^2*z^2])
g.indeterminacy_points(base=True)                                     # needs sage.libs.singular
>>> from sage.all import *
>>> P1 = ProjectiveSpace(RR, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P1._first_ngens(3)
>>> P2 = ProjectiveSpace(RR, Integer(3), names=('t', 'u', 'v', 'w',)); (t, u, v, w,) = P2._first_ngens(4)
>>> H = Hom(P1, P2)
>>> h = H([x + y, y, z + y, y])
>>> set_verbose(None)
>>> h.indeterminacy_points(base=True)                                     # needs sage.libs.singular
[]
>>> g = H([y**Integer(3)*z**Integer(3), x**Integer(3)*z**Integer(3), y**Integer(3)*z**Integer(3), x**Integer(2)*y**Integer(2)*z**Integer(2)])
>>> g.indeterminacy_points(base=True)                                     # needs sage.libs.singular
Traceback (most recent call last):
...
ValueError: indeterminacy scheme is not dimension 0
P1.<x,y,z> = ProjectiveSpace(RR, 2)
P2.<t,u,v,w> = ProjectiveSpace(RR, 3)
H = Hom(P1, P2)
h = H([x + y, y, z + y, y])
set_verbose(None)
h.indeterminacy_points(base=True)                                     # needs sage.libs.singular
g = H([y^3*z^3, x^3*z^3, y^3*z^3, x^2*y^2*z^2])
g.indeterminacy_points(base=True)                                     # needs sage.libs.singular
sage: P.<x,y,z> = ProjectiveSpace(QQ, 2)
sage: H = End(P)
sage: f = H([x^2 + y^2, x*z, x^2 + y^2])
sage: f.indeterminacy_points()                                              # needs sage.libs.singular
[(0 : 0 : 1)]

sage: R.<t> = QQ[]
sage: K.<a> = NumberField(t^2 + 1)                                          # needs sage.rings.number_field
sage: f.indeterminacy_points(F=K)                                           # needs sage.libs.singular sage.rings.number_field
[(-a : 1 : 0), (0 : 0 : 1), (a : 1 : 0)]
sage: set_verbose(None)
sage: f.indeterminacy_points(F=QQbar, base=True)                            # needs sage.libs.singular sage.rings.number_field
[(-1*I : 1 : 0), (0 : 0 : 1), (1*I : 1 : 0)]
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = End(P)
>>> f = H([x**Integer(2) + y**Integer(2), x*z, x**Integer(2) + y**Integer(2)])
>>> f.indeterminacy_points()                                              # needs sage.libs.singular
[(0 : 0 : 1)]

>>> R = QQ['t']; (t,) = R._first_ngens(1)
>>> K = NumberField(t**Integer(2) + Integer(1), names=('a',)); (a,) = K._first_ngens(1)# needs sage.rings.number_field
>>> f.indeterminacy_points(F=K)                                           # needs sage.libs.singular sage.rings.number_field
[(-a : 1 : 0), (0 : 0 : 1), (a : 1 : 0)]
>>> set_verbose(None)
>>> f.indeterminacy_points(F=QQbar, base=True)                            # needs sage.libs.singular sage.rings.number_field
[(-1*I : 1 : 0), (0 : 0 : 1), (1*I : 1 : 0)]
P.<x,y,z> = ProjectiveSpace(QQ, 2)
H = End(P)
f = H([x^2 + y^2, x*z, x^2 + y^2])
f.indeterminacy_points()                                              # needs sage.libs.singular
R.<t> = QQ[]
K.<a> = NumberField(t^2 + 1)                                          # needs sage.rings.number_field
f.indeterminacy_points(F=K)                                           # needs sage.libs.singular sage.rings.number_field
set_verbose(None)
f.indeterminacy_points(F=QQbar, base=True)                            # needs sage.libs.singular sage.rings.number_field
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = End(P)
>>> f = H([x**Integer(2) + y**Integer(2), x*z, x**Integer(2) + y**Integer(2)])
>>> f.indeterminacy_points()                                              # needs sage.libs.singular
[(0 : 0 : 1)]

>>> R = QQ['t']; (t,) = R._first_ngens(1)
>>> K = NumberField(t**Integer(2) + Integer(1), names=('a',)); (a,) = K._first_ngens(1)# needs sage.rings.number_field
>>> f.indeterminacy_points(F=K)                                           # needs sage.libs.singular sage.rings.number_field
[(-a : 1 : 0), (0 : 0 : 1), (a : 1 : 0)]
>>> set_verbose(None)
>>> f.indeterminacy_points(F=QQbar, base=True)                            # needs sage.libs.singular sage.rings.number_field
[(-1*I : 1 : 0), (0 : 0 : 1), (1*I : 1 : 0)]
P.<x,y,z> = ProjectiveSpace(QQ, 2)
H = End(P)
f = H([x^2 + y^2, x*z, x^2 + y^2])
f.indeterminacy_points()                                              # needs sage.libs.singular
R.<t> = QQ[]
K.<a> = NumberField(t^2 + 1)                                          # needs sage.rings.number_field
f.indeterminacy_points(F=K)                                           # needs sage.libs.singular sage.rings.number_field
set_verbose(None)
f.indeterminacy_points(F=QQbar, base=True)                            # needs sage.libs.singular sage.rings.number_field
sage: set_verbose(None)
sage: K.<t> = FunctionField(QQ)
sage: P.<x,y,z> = ProjectiveSpace(K, 2)
sage: H = End(P)
sage: f = H([x^2 - t^2*y^2, y^2 - z^2, x^2 - t^2*z^2])
sage: f.indeterminacy_points(base=True)                                     # needs sage.libs.singular
[(-t : -1 : 1), (-t : 1 : 1), (t : -1 : 1), (t : 1 : 1)]
>>> from sage.all import *
>>> set_verbose(None)
>>> K = FunctionField(QQ, names=('t',)); (t,) = K._first_ngens(1)
>>> P = ProjectiveSpace(K, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = End(P)
>>> f = H([x**Integer(2) - t**Integer(2)*y**Integer(2), y**Integer(2) - z**Integer(2), x**Integer(2) - t**Integer(2)*z**Integer(2)])
>>> f.indeterminacy_points(base=True)                                     # needs sage.libs.singular
[(-t : -1 : 1), (-t : 1 : 1), (t : -1 : 1), (t : 1 : 1)]
set_verbose(None)
K.<t> = FunctionField(QQ)
P.<x,y,z> = ProjectiveSpace(K, 2)
H = End(P)
f = H([x^2 - t^2*y^2, y^2 - z^2, x^2 - t^2*z^2])
f.indeterminacy_points(base=True)                                     # needs sage.libs.singular
>>> from sage.all import *
>>> set_verbose(None)
>>> K = FunctionField(QQ, names=('t',)); (t,) = K._first_ngens(1)
>>> P = ProjectiveSpace(K, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = End(P)
>>> f = H([x**Integer(2) - t**Integer(2)*y**Integer(2), y**Integer(2) - z**Integer(2), x**Integer(2) - t**Integer(2)*z**Integer(2)])
>>> f.indeterminacy_points(base=True)                                     # needs sage.libs.singular
[(-t : -1 : 1), (-t : 1 : 1), (t : -1 : 1), (t : 1 : 1)]
set_verbose(None)
K.<t> = FunctionField(QQ)
P.<x,y,z> = ProjectiveSpace(K, 2)
H = End(P)
f = H([x^2 - t^2*y^2, y^2 - z^2, x^2 - t^2*z^2])
f.indeterminacy_points(base=True)                                     # needs sage.libs.singular
sage: # needs sage.rings.padics
sage: set_verbose(None)
sage: P.<x,y,z> = ProjectiveSpace(Qp(3), 2)
sage: H = End(P)
sage: f = H([x^2 - 7*y^2, y^2 - z^2, x^2 - 7*z^2])
sage: f.indeterminacy_points(base=True)                                     # needs sage.libs.singular
[(2 + 3 + 3^2 + 2*3^3 + 2*3^5 + 2*3^6 + 3^8
    + 3^9 + 2*3^11 + 3^15 + 2*3^16 + 3^18 + O(3^20) : 1 + O(3^20) : 1 + O(3^20)),
 (2 + 3 + 3^2 + 2*3^3 + 2*3^5 + 2*3^6 + 3^8 + 3^9 + 2*3^11 + 3^15
    + 2*3^16 + 3^18 + O(3^20) : 2 + 2*3 + 2*3^2 + 2*3^3 + 2*3^4 + 2*3^5
    + 2*3^6 + 2*3^7 + 2*3^8 + 2*3^9 + 2*3^10 + 2*3^11 + 2*3^12 + 2*3^13
    + 2*3^14 + 2*3^15 + 2*3^16 + 2*3^17 + 2*3^18 + 2*3^19 + O(3^20) : 1 + O(3^20)),
 (1 + 3 + 3^2 + 2*3^4 + 2*3^7 + 3^8 + 3^9 + 2*3^10 + 2*3^12 + 2*3^13
    + 2*3^14 + 3^15 + 2*3^17 + 3^18 + 2*3^19 + O(3^20) : 1 + O(3^20) : 1 + O(3^20)),
 (1 + 3 + 3^2 + 2*3^4 + 2*3^7 + 3^8 + 3^9 + 2*3^10 + 2*3^12 + 2*3^13
    + 2*3^14 + 3^15 + 2*3^17 + 3^18 + 2*3^19 + O(3^20) : 2 + 2*3 + 2*3^2
    + 2*3^3 + 2*3^4 + 2*3^5 + 2*3^6 + 2*3^7 + 2*3^8 + 2*3^9 + 2*3^10 + 2*3^11
    + 2*3^12 + 2*3^13 + 2*3^14 + 2*3^15 + 2*3^16 + 2*3^17 + 2*3^18 + 2*3^19
    + O(3^20) : 1 + O(3^20))]
>>> from sage.all import *
>>> # needs sage.rings.padics
>>> set_verbose(None)
>>> P = ProjectiveSpace(Qp(Integer(3)), Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = End(P)
>>> f = H([x**Integer(2) - Integer(7)*y**Integer(2), y**Integer(2) - z**Integer(2), x**Integer(2) - Integer(7)*z**Integer(2)])
>>> f.indeterminacy_points(base=True)                                     # needs sage.libs.singular
[(2 + 3 + 3^2 + 2*3^3 + 2*3^5 + 2*3^6 + 3^8
    + 3^9 + 2*3^11 + 3^15 + 2*3^16 + 3^18 + O(3^20) : 1 + O(3^20) : 1 + O(3^20)),
 (2 + 3 + 3^2 + 2*3^3 + 2*3^5 + 2*3^6 + 3^8 + 3^9 + 2*3^11 + 3^15
    + 2*3^16 + 3^18 + O(3^20) : 2 + 2*3 + 2*3^2 + 2*3^3 + 2*3^4 + 2*3^5
    + 2*3^6 + 2*3^7 + 2*3^8 + 2*3^9 + 2*3^10 + 2*3^11 + 2*3^12 + 2*3^13
    + 2*3^14 + 2*3^15 + 2*3^16 + 2*3^17 + 2*3^18 + 2*3^19 + O(3^20) : 1 + O(3^20)),
 (1 + 3 + 3^2 + 2*3^4 + 2*3^7 + 3^8 + 3^9 + 2*3^10 + 2*3^12 + 2*3^13
    + 2*3^14 + 3^15 + 2*3^17 + 3^18 + 2*3^19 + O(3^20) : 1 + O(3^20) : 1 + O(3^20)),
 (1 + 3 + 3^2 + 2*3^4 + 2*3^7 + 3^8 + 3^9 + 2*3^10 + 2*3^12 + 2*3^13
    + 2*3^14 + 3^15 + 2*3^17 + 3^18 + 2*3^19 + O(3^20) : 2 + 2*3 + 2*3^2
    + 2*3^3 + 2*3^4 + 2*3^5 + 2*3^6 + 2*3^7 + 2*3^8 + 2*3^9 + 2*3^10 + 2*3^11
    + 2*3^12 + 2*3^13 + 2*3^14 + 2*3^15 + 2*3^16 + 2*3^17 + 2*3^18 + 2*3^19
    + O(3^20) : 1 + O(3^20))]
# needs sage.rings.padics
set_verbose(None)
P.<x,y,z> = ProjectiveSpace(Qp(3), 2)
H = End(P)
f = H([x^2 - 7*y^2, y^2 - z^2, x^2 - 7*z^2])
f.indeterminacy_points(base=True)                                     # needs sage.libs.singular
>>> from sage.all import *
>>> # needs sage.rings.padics
>>> set_verbose(None)
>>> P = ProjectiveSpace(Qp(Integer(3)), Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = End(P)
>>> f = H([x**Integer(2) - Integer(7)*y**Integer(2), y**Integer(2) - z**Integer(2), x**Integer(2) - Integer(7)*z**Integer(2)])
>>> f.indeterminacy_points(base=True)                                     # needs sage.libs.singular
[(2 + 3 + 3^2 + 2*3^3 + 2*3^5 + 2*3^6 + 3^8
    + 3^9 + 2*3^11 + 3^15 + 2*3^16 + 3^18 + O(3^20) : 1 + O(3^20) : 1 + O(3^20)),
 (2 + 3 + 3^2 + 2*3^3 + 2*3^5 + 2*3^6 + 3^8 + 3^9 + 2*3^11 + 3^15
    + 2*3^16 + 3^18 + O(3^20) : 2 + 2*3 + 2*3^2 + 2*3^3 + 2*3^4 + 2*3^5
    + 2*3^6 + 2*3^7 + 2*3^8 + 2*3^9 + 2*3^10 + 2*3^11 + 2*3^12 + 2*3^13
    + 2*3^14 + 2*3^15 + 2*3^16 + 2*3^17 + 2*3^18 + 2*3^19 + O(3^20) : 1 + O(3^20)),
 (1 + 3 + 3^2 + 2*3^4 + 2*3^7 + 3^8 + 3^9 + 2*3^10 + 2*3^12 + 2*3^13
    + 2*3^14 + 3^15 + 2*3^17 + 3^18 + 2*3^19 + O(3^20) : 1 + O(3^20) : 1 + O(3^20)),
 (1 + 3 + 3^2 + 2*3^4 + 2*3^7 + 3^8 + 3^9 + 2*3^10 + 2*3^12 + 2*3^13
    + 2*3^14 + 3^15 + 2*3^17 + 3^18 + 2*3^19 + O(3^20) : 2 + 2*3 + 2*3^2
    + 2*3^3 + 2*3^4 + 2*3^5 + 2*3^6 + 2*3^7 + 2*3^8 + 2*3^9 + 2*3^10 + 2*3^11
    + 2*3^12 + 2*3^13 + 2*3^14 + 2*3^15 + 2*3^16 + 2*3^17 + 2*3^18 + 2*3^19
    + O(3^20) : 1 + O(3^20))]
# needs sage.rings.padics
set_verbose(None)
P.<x,y,z> = ProjectiveSpace(Qp(3), 2)
H = End(P)
f = H([x^2 - 7*y^2, y^2 - z^2, x^2 - 7*z^2])
f.indeterminacy_points(base=True)                                     # needs sage.libs.singular
rational_preimages(Q, k=1)[source]

Determine all of the rational \(k\)-th preimages of Q by this map.

Given a rational point Q in the domain of this map, return all the rational points P in the domain with \(f^k(P)==Q\). In other words, the set of \(k\)-th preimages of Q. The map must be defined over a number field and be an endomorphism for \(k > 1\).

If Q is a subscheme, then return the subscheme that maps to Q by this map. In particular, \(f^{-k}(V(h_1,\ldots,h_t)) = V(h_1 \circ f^k, \ldots, h_t \circ f^k)\).

INPUT:

  • Q – a rational point or subscheme in the domain of this map

  • k – positive integer

OUTPUT: a list of rational points or a subscheme in the domain of this map

EXAMPLES:

sage: P.<x,y> = ProjectiveSpace(QQ, 1)
sage: H = End(P)
sage: f = H([16*x^2 - 29*y^2, 16*y^2])
sage: f.rational_preimages(P(-1, 4))                                        # needs sage.libs.singular
[(-5/4 : 1), (5/4 : 1)]
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = End(P)
>>> f = H([Integer(16)*x**Integer(2) - Integer(29)*y**Integer(2), Integer(16)*y**Integer(2)])
>>> f.rational_preimages(P(-Integer(1), Integer(4)))                                        # needs sage.libs.singular
[(-5/4 : 1), (5/4 : 1)]
P.<x,y> = ProjectiveSpace(QQ, 1)
H = End(P)
f = H([16*x^2 - 29*y^2, 16*y^2])
f.rational_preimages(P(-1, 4))                                        # needs sage.libs.singular
sage: P.<x,y,z> = ProjectiveSpace(QQ, 2)
sage: H = End(P)
sage: f = H([76*x^2 - 180*x*y + 45*y^2 + 14*x*z + 45*y*z - 90*z^2,
....:        67*x^2 - 180*x*y - 157*x*z + 90*y*z,
....:        -90*z^2])
sage: f.rational_preimages(P(-9, -4, 1))                                    # needs sage.libs.singular
[(0 : 4 : 1)]
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = End(P)
>>> f = H([Integer(76)*x**Integer(2) - Integer(180)*x*y + Integer(45)*y**Integer(2) + Integer(14)*x*z + Integer(45)*y*z - Integer(90)*z**Integer(2),
...        Integer(67)*x**Integer(2) - Integer(180)*x*y - Integer(157)*x*z + Integer(90)*y*z,
...        -Integer(90)*z**Integer(2)])
>>> f.rational_preimages(P(-Integer(9), -Integer(4), Integer(1)))                                    # needs sage.libs.singular
[(0 : 4 : 1)]
P.<x,y,z> = ProjectiveSpace(QQ, 2)
H = End(P)
f = H([76*x^2 - 180*x*y + 45*y^2 + 14*x*z + 45*y*z - 90*z^2,
       67*x^2 - 180*x*y - 157*x*z + 90*y*z,
       -90*z^2])
f.rational_preimages(P(-9, -4, 1))                                    # needs sage.libs.singular
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> H = End(P)
>>> f = H([Integer(76)*x**Integer(2) - Integer(180)*x*y + Integer(45)*y**Integer(2) + Integer(14)*x*z + Integer(45)*y*z - Integer(90)*z**Integer(2),
...        Integer(67)*x**Integer(2) - Integer(180)*x*y - Integer(157)*x*z + Integer(90)*y*z,
...        -Integer(90)*z**Integer(2)])
>>> f.rational_preimages(P(-Integer(9), -Integer(4), Integer(1)))                                    # needs sage.libs.singular
[(0 : 4 : 1)]
P.<x,y,z> = ProjectiveSpace(QQ, 2)
H = End(P)
f = H([76*x^2 - 180*x*y + 45*y^2 + 14*x*z + 45*y*z - 90*z^2,
       67*x^2 - 180*x*y - 157*x*z + 90*y*z,
       -90*z^2])
f.rational_preimages(P(-9, -4, 1))                                    # needs sage.libs.singular

A non-periodic example

sage: P.<x,y> = ProjectiveSpace(QQ, 1)
sage: H = End(P)
sage: f = H([x^2 + y^2, 2*x*y])
sage: f.rational_preimages(P(17, 15))                                       # needs sage.libs.singular
[(3/5 : 1), (5/3 : 1)]
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = End(P)
>>> f = H([x**Integer(2) + y**Integer(2), Integer(2)*x*y])
>>> f.rational_preimages(P(Integer(17), Integer(15)))                                       # needs sage.libs.singular
[(3/5 : 1), (5/3 : 1)]
P.<x,y> = ProjectiveSpace(QQ, 1)
H = End(P)
f = H([x^2 + y^2, 2*x*y])
f.rational_preimages(P(17, 15))                                       # needs sage.libs.singular
sage: P.<x,y,z,w> = ProjectiveSpace(QQ, 3)
sage: H = End(P)
sage: f = H([x^2 - 2*y*w - 3*w^2, -2*x^2 + y^2 - 2*x*z + 4*y*w + 3*w^2,
....:        x^2 - y^2 + 2*x*z + z^2 - 2*y*w - w^2,
....:        w^2])
sage: f.rational_preimages(P(0, -1, 0, 1))                                  # needs sage.libs.singular
[]
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(3), names=('x', 'y', 'z', 'w',)); (x, y, z, w,) = P._first_ngens(4)
>>> H = End(P)
>>> f = H([x**Integer(2) - Integer(2)*y*w - Integer(3)*w**Integer(2), -Integer(2)*x**Integer(2) + y**Integer(2) - Integer(2)*x*z + Integer(4)*y*w + Integer(3)*w**Integer(2),
...        x**Integer(2) - y**Integer(2) + Integer(2)*x*z + z**Integer(2) - Integer(2)*y*w - w**Integer(2),
...        w**Integer(2)])
>>> f.rational_preimages(P(Integer(0), -Integer(1), Integer(0), Integer(1)))                                  # needs sage.libs.singular
[]
P.<x,y,z,w> = ProjectiveSpace(QQ, 3)
H = End(P)
f = H([x^2 - 2*y*w - 3*w^2, -2*x^2 + y^2 - 2*x*z + 4*y*w + 3*w^2,
       x^2 - y^2 + 2*x*z + z^2 - 2*y*w - w^2,
       w^2])
f.rational_preimages(P(0, -1, 0, 1))                                  # needs sage.libs.singular
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(3), names=('x', 'y', 'z', 'w',)); (x, y, z, w,) = P._first_ngens(4)
>>> H = End(P)
>>> f = H([x**Integer(2) - Integer(2)*y*w - Integer(3)*w**Integer(2), -Integer(2)*x**Integer(2) + y**Integer(2) - Integer(2)*x*z + Integer(4)*y*w + Integer(3)*w**Integer(2),
...        x**Integer(2) - y**Integer(2) + Integer(2)*x*z + z**Integer(2) - Integer(2)*y*w - w**Integer(2),
...        w**Integer(2)])
>>> f.rational_preimages(P(Integer(0), -Integer(1), Integer(0), Integer(1)))                                  # needs sage.libs.singular
[]
P.<x,y,z,w> = ProjectiveSpace(QQ, 3)
H = End(P)
f = H([x^2 - 2*y*w - 3*w^2, -2*x^2 + y^2 - 2*x*z + 4*y*w + 3*w^2,
       x^2 - y^2 + 2*x*z + z^2 - 2*y*w - w^2,
       w^2])
f.rational_preimages(P(0, -1, 0, 1))                                  # needs sage.libs.singular
sage: P.<x,y> = ProjectiveSpace(QQ, 1)
sage: H = End(P)
sage: f = H([x^2 + y^2, 2*x*y])
sage: f.rational_preimages([CC.0, 1])                                       # needs sage.libs.singular
Traceback (most recent call last):
...
TypeError: point must be in codomain of self
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = End(P)
>>> f = H([x**Integer(2) + y**Integer(2), Integer(2)*x*y])
>>> f.rational_preimages([CC.gen(0), Integer(1)])                                       # needs sage.libs.singular
Traceback (most recent call last):
...
TypeError: point must be in codomain of self
P.<x,y> = ProjectiveSpace(QQ, 1)
H = End(P)
f = H([x^2 + y^2, 2*x*y])
f.rational_preimages([CC.0, 1])                                       # needs sage.libs.singular
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = End(P)
>>> f = H([x**Integer(2) + y**Integer(2), Integer(2)*x*y])
>>> f.rational_preimages([CC.gen(0), Integer(1)])                                       # needs sage.libs.singular
Traceback (most recent call last):
...
TypeError: point must be in codomain of self
P.<x,y> = ProjectiveSpace(QQ, 1)
H = End(P)
f = H([x^2 + y^2, 2*x*y])
f.rational_preimages([CC.0, 1])                                       # needs sage.libs.singular

A number field example

sage: # needs sage.rings.number_field
sage: z = QQ['z'].0
sage: K.<a> = NumberField(z^2 - 2)
sage: P.<x,y> = ProjectiveSpace(K, 1)
sage: H = End(P)
sage: f = H([x^2 + y^2, y^2])
sage: f.rational_preimages(P(3, 1))                                         # needs sage.libs.singular
[(-a : 1), (a : 1)]
>>> from sage.all import *
>>> # needs sage.rings.number_field
>>> z = QQ['z'].gen(0)
>>> K = NumberField(z**Integer(2) - Integer(2), names=('a',)); (a,) = K._first_ngens(1)
>>> P = ProjectiveSpace(K, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = End(P)
>>> f = H([x**Integer(2) + y**Integer(2), y**Integer(2)])
>>> f.rational_preimages(P(Integer(3), Integer(1)))                                         # needs sage.libs.singular
[(-a : 1), (a : 1)]
# needs sage.rings.number_field
z = QQ['z'].0
K.<a> = NumberField(z^2 - 2)
P.<x,y> = ProjectiveSpace(K, 1)
H = End(P)
f = H([x^2 + y^2, y^2])
f.rational_preimages(P(3, 1))                                         # needs sage.libs.singular
sage: # needs sage.rings.number_field
sage: z = QQ['z'].0
sage: K.<a> = NumberField(z^2 - 2)
sage: P.<x,y,z> = ProjectiveSpace(K, 2)
sage: X = P.subscheme([x^2 - z^2])
sage: H = End(X)
sage: f= H([x^2 - z^2, a*y^2, z^2 - x^2])
sage: f.rational_preimages(X([1, 2, -1]))                                   # needs sage.libs.singular
[]
>>> from sage.all import *
>>> # needs sage.rings.number_field
>>> z = QQ['z'].gen(0)
>>> K = NumberField(z**Integer(2) - Integer(2), names=('a',)); (a,) = K._first_ngens(1)
>>> P = ProjectiveSpace(K, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> X = P.subscheme([x**Integer(2) - z**Integer(2)])
>>> H = End(X)
>>> f= H([x**Integer(2) - z**Integer(2), a*y**Integer(2), z**Integer(2) - x**Integer(2)])
>>> f.rational_preimages(X([Integer(1), Integer(2), -Integer(1)]))                                   # needs sage.libs.singular
[]
# needs sage.rings.number_field
z = QQ['z'].0
K.<a> = NumberField(z^2 - 2)
P.<x,y,z> = ProjectiveSpace(K, 2)
X = P.subscheme([x^2 - z^2])
H = End(X)
f= H([x^2 - z^2, a*y^2, z^2 - x^2])
f.rational_preimages(X([1, 2, -1]))                                   # needs sage.libs.singular
>>> from sage.all import *
>>> # needs sage.rings.number_field
>>> z = QQ['z'].gen(0)
>>> K = NumberField(z**Integer(2) - Integer(2), names=('a',)); (a,) = K._first_ngens(1)
>>> P = ProjectiveSpace(K, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> X = P.subscheme([x**Integer(2) - z**Integer(2)])
>>> H = End(X)
>>> f= H([x**Integer(2) - z**Integer(2), a*y**Integer(2), z**Integer(2) - x**Integer(2)])
>>> f.rational_preimages(X([Integer(1), Integer(2), -Integer(1)]))                                   # needs sage.libs.singular
[]
# needs sage.rings.number_field
z = QQ['z'].0
K.<a> = NumberField(z^2 - 2)
P.<x,y,z> = ProjectiveSpace(K, 2)
X = P.subscheme([x^2 - z^2])
H = End(X)
f= H([x^2 - z^2, a*y^2, z^2 - x^2])
f.rational_preimages(X([1, 2, -1]))                                   # needs sage.libs.singular
sage: P.<x,y,z> = ProjectiveSpace(QQ, 2)
sage: X = P.subscheme([x^2 - z^2])
sage: H = End(X)
sage: f = H([x^2-z^2, y^2, z^2-x^2])
sage: f.rational_preimages(X([0, 1, 0]))                                    # needs sage.libs.singular
Closed subscheme of Projective Space of dimension 2 over Rational Field defined by:
  x^2 - z^2,
  -x^2 + z^2,
  0,
  -x^2 + z^2
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> X = P.subscheme([x**Integer(2) - z**Integer(2)])
>>> H = End(X)
>>> f = H([x**Integer(2)-z**Integer(2), y**Integer(2), z**Integer(2)-x**Integer(2)])
>>> f.rational_preimages(X([Integer(0), Integer(1), Integer(0)]))                                    # needs sage.libs.singular
Closed subscheme of Projective Space of dimension 2 over Rational Field defined by:
  x^2 - z^2,
  -x^2 + z^2,
  0,
  -x^2 + z^2
P.<x,y,z> = ProjectiveSpace(QQ, 2)
X = P.subscheme([x^2 - z^2])
H = End(X)
f = H([x^2-z^2, y^2, z^2-x^2])
f.rational_preimages(X([0, 1, 0]))                                    # needs sage.libs.singular
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> X = P.subscheme([x**Integer(2) - z**Integer(2)])
>>> H = End(X)
>>> f = H([x**Integer(2)-z**Integer(2), y**Integer(2), z**Integer(2)-x**Integer(2)])
>>> f.rational_preimages(X([Integer(0), Integer(1), Integer(0)]))                                    # needs sage.libs.singular
Closed subscheme of Projective Space of dimension 2 over Rational Field defined by:
  x^2 - z^2,
  -x^2 + z^2,
  0,
  -x^2 + z^2
P.<x,y,z> = ProjectiveSpace(QQ, 2)
X = P.subscheme([x^2 - z^2])
H = End(X)
f = H([x^2-z^2, y^2, z^2-x^2])
f.rational_preimages(X([0, 1, 0]))                                    # needs sage.libs.singular
sage: P.<x, y> = ProjectiveSpace(QQ, 1)
sage: H = End(P)
sage: f = H([x^2 - y^2, y^2])
sage: f.rational_preimages(P.subscheme([x]))                                # needs sage.libs.singular
Closed subscheme of Projective Space of dimension 1 over Rational Field
 defined by: x^2 - y^2
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = End(P)
>>> f = H([x**Integer(2) - y**Integer(2), y**Integer(2)])
>>> f.rational_preimages(P.subscheme([x]))                                # needs sage.libs.singular
Closed subscheme of Projective Space of dimension 1 over Rational Field
 defined by: x^2 - y^2
P.<x, y> = ProjectiveSpace(QQ, 1)
H = End(P)
f = H([x^2 - y^2, y^2])
f.rational_preimages(P.subscheme([x]))                                # needs sage.libs.singular
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = End(P)
>>> f = H([x**Integer(2) - y**Integer(2), y**Integer(2)])
>>> f.rational_preimages(P.subscheme([x]))                                # needs sage.libs.singular
Closed subscheme of Projective Space of dimension 1 over Rational Field
 defined by: x^2 - y^2
P.<x, y> = ProjectiveSpace(QQ, 1)
H = End(P)
f = H([x^2 - y^2, y^2])
f.rational_preimages(P.subscheme([x]))                                # needs sage.libs.singular
sage: P.<x,y> = ProjectiveSpace(QQ, 1)
sage: H = End(P)
sage: f = H([x^2 - 29/16*y^2, y^2])
sage: f.rational_preimages(P(5/4, 1), k=4)                                  # needs sage.libs.singular
[(-3/4 : 1), (3/4 : 1), (-7/4 : 1), (7/4 : 1)]
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = End(P)
>>> f = H([x**Integer(2) - Integer(29)/Integer(16)*y**Integer(2), y**Integer(2)])
>>> f.rational_preimages(P(Integer(5)/Integer(4), Integer(1)), k=Integer(4))                                  # needs sage.libs.singular
[(-3/4 : 1), (3/4 : 1), (-7/4 : 1), (7/4 : 1)]
P.<x,y> = ProjectiveSpace(QQ, 1)
H = End(P)
f = H([x^2 - 29/16*y^2, y^2])
f.rational_preimages(P(5/4, 1), k=4)                                  # needs sage.libs.singular
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = End(P)
>>> f = H([x**Integer(2) - Integer(29)/Integer(16)*y**Integer(2), y**Integer(2)])
>>> f.rational_preimages(P(Integer(5)/Integer(4), Integer(1)), k=Integer(4))                                  # needs sage.libs.singular
[(-3/4 : 1), (3/4 : 1), (-7/4 : 1), (7/4 : 1)]
P.<x,y> = ProjectiveSpace(QQ, 1)
H = End(P)
f = H([x^2 - 29/16*y^2, y^2])
f.rational_preimages(P(5/4, 1), k=4)                                  # needs sage.libs.singular
sage: P.<x,y> = ProjectiveSpace(QQ, 1)
sage: P2.<u,v,w> = ProjectiveSpace(QQ, 2)
sage: H = Hom(P, P2)
sage: f = H([x^2, y^2, x^2-y^2])
sage: f.rational_preimages(P2(1, 1, 0))                                     # needs sage.libs.singular
[(-1 : 1), (1 : 1)]
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> P2 = ProjectiveSpace(QQ, Integer(2), names=('u', 'v', 'w',)); (u, v, w,) = P2._first_ngens(3)
>>> H = Hom(P, P2)
>>> f = H([x**Integer(2), y**Integer(2), x**Integer(2)-y**Integer(2)])
>>> f.rational_preimages(P2(Integer(1), Integer(1), Integer(0)))                                     # needs sage.libs.singular
[(-1 : 1), (1 : 1)]
P.<x,y> = ProjectiveSpace(QQ, 1)
P2.<u,v,w> = ProjectiveSpace(QQ, 2)
H = Hom(P, P2)
f = H([x^2, y^2, x^2-y^2])
f.rational_preimages(P2(1, 1, 0))                                     # needs sage.libs.singular
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> P2 = ProjectiveSpace(QQ, Integer(2), names=('u', 'v', 'w',)); (u, v, w,) = P2._first_ngens(3)
>>> H = Hom(P, P2)
>>> f = H([x**Integer(2), y**Integer(2), x**Integer(2)-y**Integer(2)])
>>> f.rational_preimages(P2(Integer(1), Integer(1), Integer(0)))                                     # needs sage.libs.singular
[(-1 : 1), (1 : 1)]
P.<x,y> = ProjectiveSpace(QQ, 1)
P2.<u,v,w> = ProjectiveSpace(QQ, 2)
H = Hom(P, P2)
f = H([x^2, y^2, x^2-y^2])
f.rational_preimages(P2(1, 1, 0))                                     # needs sage.libs.singular
reduce_base_field()[source]

Return this map defined over the field of definition of the coefficients.

The base field of the map could be strictly larger than the field where all of the coefficients are defined. This function reduces the base field to the minimal possible. This can be done when the base ring is a number field, QQbar, a finite field, or algebraic closure of a finite field.

OUTPUT: a scheme morphism

EXAMPLES:

sage: # needs sage.rings.finite_rings
sage: K.<t> = GF(3^4)
sage: P.<x,y> = ProjectiveSpace(K, 1)
sage: P2.<a,b,c> = ProjectiveSpace(K, 2)
sage: H = End(P)
sage: H2 = Hom(P, P2)
sage: H3 = Hom(P2, P)
sage: f = H([x^2 + (2*t^3 + 2*t^2 + 1)*y^2, y^2])
sage: f.reduce_base_field()                                                 # needs sage.libs.singular sage.modules
Scheme endomorphism of Projective Space of dimension 1
 over Finite Field in t2 of size 3^2
  Defn: Defined on coordinates by sending (x : y) to (x^2 + t2*y^2 : y^2)
sage: f2 = H2([x^2 + 5*y^2, y^2, 2*x*y])
sage: f2.reduce_base_field()                                                # needs sage.libs.singular sage.modules
Scheme morphism:
  From: Projective Space of dimension 1 over Finite Field of size 3
  To:   Projective Space of dimension 2 over Finite Field of size 3
  Defn: Defined on coordinates by sending (x : y) to (x^2 - y^2 : y^2 : -x*y)
sage: f3 = H3([a^2 + t*b^2, c^2])
sage: f3.reduce_base_field()                                                # needs sage.libs.singular sage.modules
Scheme morphism:
  From: Projective Space of dimension 2 over Finite Field in t of size 3^4
  To:   Projective Space of dimension 1 over Finite Field in t of size 3^4
  Defn: Defined on coordinates by sending (a : b : c) to (a^2 + t*b^2 : c^2)
>>> from sage.all import *
>>> # needs sage.rings.finite_rings
>>> K = GF(Integer(3)**Integer(4), names=('t',)); (t,) = K._first_ngens(1)
>>> P = ProjectiveSpace(K, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> P2 = ProjectiveSpace(K, Integer(2), names=('a', 'b', 'c',)); (a, b, c,) = P2._first_ngens(3)
>>> H = End(P)
>>> H2 = Hom(P, P2)
>>> H3 = Hom(P2, P)
>>> f = H([x**Integer(2) + (Integer(2)*t**Integer(3) + Integer(2)*t**Integer(2) + Integer(1))*y**Integer(2), y**Integer(2)])
>>> f.reduce_base_field()                                                 # needs sage.libs.singular sage.modules
Scheme endomorphism of Projective Space of dimension 1
 over Finite Field in t2 of size 3^2
  Defn: Defined on coordinates by sending (x : y) to (x^2 + t2*y^2 : y^2)
>>> f2 = H2([x**Integer(2) + Integer(5)*y**Integer(2), y**Integer(2), Integer(2)*x*y])
>>> f2.reduce_base_field()                                                # needs sage.libs.singular sage.modules
Scheme morphism:
  From: Projective Space of dimension 1 over Finite Field of size 3
  To:   Projective Space of dimension 2 over Finite Field of size 3
  Defn: Defined on coordinates by sending (x : y) to (x^2 - y^2 : y^2 : -x*y)
>>> f3 = H3([a**Integer(2) + t*b**Integer(2), c**Integer(2)])
>>> f3.reduce_base_field()                                                # needs sage.libs.singular sage.modules
Scheme morphism:
  From: Projective Space of dimension 2 over Finite Field in t of size 3^4
  To:   Projective Space of dimension 1 over Finite Field in t of size 3^4
  Defn: Defined on coordinates by sending (a : b : c) to (a^2 + t*b^2 : c^2)
# needs sage.rings.finite_rings
K.<t> = GF(3^4)
P.<x,y> = ProjectiveSpace(K, 1)
P2.<a,b,c> = ProjectiveSpace(K, 2)
H = End(P)
H2 = Hom(P, P2)
H3 = Hom(P2, P)
f = H([x^2 + (2*t^3 + 2*t^2 + 1)*y^2, y^2])
f.reduce_base_field()                                                 # needs sage.libs.singular sage.modules
f2 = H2([x^2 + 5*y^2, y^2, 2*x*y])
f2.reduce_base_field()                                                # needs sage.libs.singular sage.modules
f3 = H3([a^2 + t*b^2, c^2])
f3.reduce_base_field()                                                # needs sage.libs.singular sage.modules
sage: # needs sage.rings.number_field
sage: K.<v> = CyclotomicField(4)
sage: P.<x,y> = ProjectiveSpace(K, 1)
sage: H = End(P)
sage: f = H([x^2 + 2*y^2, y^2])
sage: f.reduce_base_field()                                                 # needs sage.libs.singular
Scheme endomorphism of Projective Space of dimension 1 over Rational Field
  Defn: Defined on coordinates by sending (x : y) to (x^2 + 2*y^2 : y^2)
>>> from sage.all import *
>>> # needs sage.rings.number_field
>>> K = CyclotomicField(Integer(4), names=('v',)); (v,) = K._first_ngens(1)
>>> P = ProjectiveSpace(K, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = End(P)
>>> f = H([x**Integer(2) + Integer(2)*y**Integer(2), y**Integer(2)])
>>> f.reduce_base_field()                                                 # needs sage.libs.singular
Scheme endomorphism of Projective Space of dimension 1 over Rational Field
  Defn: Defined on coordinates by sending (x : y) to (x^2 + 2*y^2 : y^2)
# needs sage.rings.number_field
K.<v> = CyclotomicField(4)
P.<x,y> = ProjectiveSpace(K, 1)
H = End(P)
f = H([x^2 + 2*y^2, y^2])
f.reduce_base_field()                                                 # needs sage.libs.singular
>>> from sage.all import *
>>> # needs sage.rings.number_field
>>> K = CyclotomicField(Integer(4), names=('v',)); (v,) = K._first_ngens(1)
>>> P = ProjectiveSpace(K, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = End(P)
>>> f = H([x**Integer(2) + Integer(2)*y**Integer(2), y**Integer(2)])
>>> f.reduce_base_field()                                                 # needs sage.libs.singular
Scheme endomorphism of Projective Space of dimension 1 over Rational Field
  Defn: Defined on coordinates by sending (x : y) to (x^2 + 2*y^2 : y^2)
# needs sage.rings.number_field
K.<v> = CyclotomicField(4)
P.<x,y> = ProjectiveSpace(K, 1)
H = End(P)
f = H([x^2 + 2*y^2, y^2])
f.reduce_base_field()                                                 # needs sage.libs.singular
sage: # needs sage.rings.finite_rings
sage: K.<v> = GF(5)
sage: L = K.algebraic_closure()
sage: P.<x,y> = ProjectiveSpace(L, 1)
sage: H = End(P)
sage: f = H([(L.gen(2))*x^2 + L.gen(4)*y^2, x*y])
sage: f.reduce_base_field()                                                 # needs sage.libs.singular
Scheme endomorphism of Projective Space of dimension 1
 over Finite Field in z4 of size 5^4
  Defn: Defined on coordinates by sending (x : y) to
        ((z4^3 + z4^2 + z4 - 2)*x^2 + z4*y^2 : x*y)
sage: f = DynamicalSystem_projective([L.gen(3)*x^2 + L.gen(2)*y^2, x*y])    # needs sage.schemes
sage: f.reduce_base_field()                                                 # needs sage.libs.singular sage.schemes
Dynamical System of Projective Space of dimension 1
 over Finite Field in z6 of size 5^6
  Defn: Defined on coordinates by sending (x : y) to
        ((-z6^5 + z6^4 - z6^3 - z6^2 - 2*z6 - 2)*x^2
         + (z6^5 - 2*z6^4 + z6^2 - z6 + 1)*y^2 : x*y)
>>> from sage.all import *
>>> # needs sage.rings.finite_rings
>>> K = GF(Integer(5), names=('v',)); (v,) = K._first_ngens(1)
>>> L = K.algebraic_closure()
>>> P = ProjectiveSpace(L, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = End(P)
>>> f = H([(L.gen(Integer(2)))*x**Integer(2) + L.gen(Integer(4))*y**Integer(2), x*y])
>>> f.reduce_base_field()                                                 # needs sage.libs.singular
Scheme endomorphism of Projective Space of dimension 1
 over Finite Field in z4 of size 5^4
  Defn: Defined on coordinates by sending (x : y) to
        ((z4^3 + z4^2 + z4 - 2)*x^2 + z4*y^2 : x*y)
>>> f = DynamicalSystem_projective([L.gen(Integer(3))*x**Integer(2) + L.gen(Integer(2))*y**Integer(2), x*y])    # needs sage.schemes
>>> f.reduce_base_field()                                                 # needs sage.libs.singular sage.schemes
Dynamical System of Projective Space of dimension 1
 over Finite Field in z6 of size 5^6
  Defn: Defined on coordinates by sending (x : y) to
        ((-z6^5 + z6^4 - z6^3 - z6^2 - 2*z6 - 2)*x^2
         + (z6^5 - 2*z6^4 + z6^2 - z6 + 1)*y^2 : x*y)
# needs sage.rings.finite_rings
K.<v> = GF(5)
L = K.algebraic_closure()
P.<x,y> = ProjectiveSpace(L, 1)
H = End(P)
f = H([(L.gen(2))*x^2 + L.gen(4)*y^2, x*y])
f.reduce_base_field()                                                 # needs sage.libs.singular
f = DynamicalSystem_projective([L.gen(3)*x^2 + L.gen(2)*y^2, x*y])    # needs sage.schemes
f.reduce_base_field()                                                 # needs sage.libs.singular sage.schemes
>>> from sage.all import *
>>> # needs sage.rings.finite_rings
>>> K = GF(Integer(5), names=('v',)); (v,) = K._first_ngens(1)
>>> L = K.algebraic_closure()
>>> P = ProjectiveSpace(L, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> H = End(P)
>>> f = H([(L.gen(Integer(2)))*x**Integer(2) + L.gen(Integer(4))*y**Integer(2), x*y])
>>> f.reduce_base_field()                                                 # needs sage.libs.singular
Scheme endomorphism of Projective Space of dimension 1
 over Finite Field in z4 of size 5^4
  Defn: Defined on coordinates by sending (x : y) to
        ((z4^3 + z4^2 + z4 - 2)*x^2 + z4*y^2 : x*y)
>>> f = DynamicalSystem_projective([L.gen(Integer(3))*x**Integer(2) + L.gen(Integer(2))*y**Integer(2), x*y])    # needs sage.schemes
>>> f.reduce_base_field()                                                 # needs sage.libs.singular sage.schemes
Dynamical System of Projective Space of dimension 1
 over Finite Field in z6 of size 5^6
  Defn: Defined on coordinates by sending (x : y) to
        ((-z6^5 + z6^4 - z6^3 - z6^2 - 2*z6 - 2)*x^2
         + (z6^5 - 2*z6^4 + z6^2 - z6 + 1)*y^2 : x*y)
# needs sage.rings.finite_rings
K.<v> = GF(5)
L = K.algebraic_closure()
P.<x,y> = ProjectiveSpace(L, 1)
H = End(P)
f = H([(L.gen(2))*x^2 + L.gen(4)*y^2, x*y])
f.reduce_base_field()                                                 # needs sage.libs.singular
f = DynamicalSystem_projective([L.gen(3)*x^2 + L.gen(2)*y^2, x*y])    # needs sage.schemes
f.reduce_base_field()                                                 # needs sage.libs.singular sage.schemes
class sage.schemes.projective.projective_morphism.SchemeMorphism_polynomial_projective_space_finite_field(parent, polys, check=True)[source]

Bases: SchemeMorphism_polynomial_projective_space_field

class sage.schemes.projective.projective_morphism.SchemeMorphism_polynomial_projective_subscheme_field(parent, polys, check=True)[source]

Bases: SchemeMorphism_polynomial_projective_space_field

Morphisms from subschemes of projective spaces defined over fields.

degree()[source]

Return the degree of this rational map.

EXAMPLES:

sage: # needs sage.schemes
sage: k = GF(11)
sage: E = EllipticCurve(k, [1,1])
sage: Q = E(6, 5)
sage: phi = E.scalar_multiplication(2)
sage: mor = phi.as_morphism()
sage: mor.degree()
4
>>> from sage.all import *
>>> # needs sage.schemes
>>> k = GF(Integer(11))
>>> E = EllipticCurve(k, [Integer(1),Integer(1)])
>>> Q = E(Integer(6), Integer(5))
>>> phi = E.scalar_multiplication(Integer(2))
>>> mor = phi.as_morphism()
>>> mor.degree()
4
# needs sage.schemes
k = GF(11)
E = EllipticCurve(k, [1,1])
Q = E(6, 5)
phi = E.scalar_multiplication(2)
mor = phi.as_morphism()
mor.degree()
graph()[source]

Return the graph of this morphism.

The graph is a subscheme of the product of the ambient spaces of the domain and the codomain. If the ambient space of the codomain is an affine space, it is first embedded into a projective space.

EXAMPLES:

We get the standard quadratic curve as the graph of a quadratic function of an affine line.

sage: A1.<x> = AffineSpace(1, QQ)
sage: X = A1.subscheme(0)  # affine line
sage: phi = X.hom([x^2], A1)
sage: mor = phi.homogenize(0)                                               # needs sage.libs.singular
sage: G = mor.graph(); G                                                    # needs sage.libs.singular
Closed subscheme of Product of projective spaces P^1 x P^1
  over Rational Field defined by: x1^2*x2 - x0^2*x3
sage: G.affine_patch([0, 0])                                                # needs sage.libs.singular
Closed subscheme of Affine Space of dimension 2
  over Rational Field defined by: x0^2 - x1
>>> from sage.all import *
>>> A1 = AffineSpace(Integer(1), QQ, names=('x',)); (x,) = A1._first_ngens(1)
>>> X = A1.subscheme(Integer(0))  # affine line
>>> phi = X.hom([x**Integer(2)], A1)
>>> mor = phi.homogenize(Integer(0))                                               # needs sage.libs.singular
>>> G = mor.graph(); G                                                    # needs sage.libs.singular
Closed subscheme of Product of projective spaces P^1 x P^1
  over Rational Field defined by: x1^2*x2 - x0^2*x3
>>> G.affine_patch([Integer(0), Integer(0)])                                                # needs sage.libs.singular
Closed subscheme of Affine Space of dimension 2
  over Rational Field defined by: x0^2 - x1
A1.<x> = AffineSpace(1, QQ)
X = A1.subscheme(0)  # affine line
phi = X.hom([x^2], A1)
mor = phi.homogenize(0)                                               # needs sage.libs.singular
G = mor.graph(); G                                                    # needs sage.libs.singular
G.affine_patch([0, 0])                                                # needs sage.libs.singular
image()[source]

Return the scheme-theoretic image of the morphism.

EXAMPLES:

sage: P.<x,y> = ProjectiveSpace(QQ, 1)
sage: P2.<x0,x1,x2> = ProjectiveSpace(QQ, 2)
sage: X = P2.subscheme(0)
sage: f = X.hom([x1,x0], P)
sage: f.image()                                                             # needs sage.libs.singular
Closed subscheme of Projective Space of dimension 1 over Rational Field defined by:
  (no polynomials)
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> P2 = ProjectiveSpace(QQ, Integer(2), names=('x0', 'x1', 'x2',)); (x0, x1, x2,) = P2._first_ngens(3)
>>> X = P2.subscheme(Integer(0))
>>> f = X.hom([x1,x0], P)
>>> f.image()                                                             # needs sage.libs.singular
Closed subscheme of Projective Space of dimension 1 over Rational Field defined by:
  (no polynomials)
P.<x,y> = ProjectiveSpace(QQ, 1)
P2.<x0,x1,x2> = ProjectiveSpace(QQ, 2)
X = P2.subscheme(0)
f = X.hom([x1,x0], P)
f.image()                                                             # needs sage.libs.singular
sage: P2.<x,y,z> = ProjectiveSpace(QQ,2)
sage: X = P2.subscheme([z^3 - x*y^2 + y^3])
sage: f = X.hom([x*z, x*y, x^2 + y*z], P2)
sage: f.image()                                                             # needs sage.libs.singular
Closed subscheme of Projective Space of dimension 2 over Rational Field defined by:
  x^6 + 2*x^3*y^3 + x*y^5 + y^6 - x^3*y^2*z - y^5*z
>>> from sage.all import *
>>> P2 = ProjectiveSpace(QQ,Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P2._first_ngens(3)
>>> X = P2.subscheme([z**Integer(3) - x*y**Integer(2) + y**Integer(3)])
>>> f = X.hom([x*z, x*y, x**Integer(2) + y*z], P2)
>>> f.image()                                                             # needs sage.libs.singular
Closed subscheme of Projective Space of dimension 2 over Rational Field defined by:
  x^6 + 2*x^3*y^3 + x*y^5 + y^6 - x^3*y^2*z - y^5*z
P2.<x,y,z> = ProjectiveSpace(QQ,2)
X = P2.subscheme([z^3 - x*y^2 + y^3])
f = X.hom([x*z, x*y, x^2 + y*z], P2)
f.image()                                                             # needs sage.libs.singular
>>> from sage.all import *
>>> P2 = ProjectiveSpace(QQ,Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P2._first_ngens(3)
>>> X = P2.subscheme([z**Integer(3) - x*y**Integer(2) + y**Integer(3)])
>>> f = X.hom([x*z, x*y, x**Integer(2) + y*z], P2)
>>> f.image()                                                             # needs sage.libs.singular
Closed subscheme of Projective Space of dimension 2 over Rational Field defined by:
  x^6 + 2*x^3*y^3 + x*y^5 + y^6 - x^3*y^2*z - y^5*z
P2.<x,y,z> = ProjectiveSpace(QQ,2)
X = P2.subscheme([z^3 - x*y^2 + y^3])
f = X.hom([x*z, x*y, x^2 + y*z], P2)
f.image()                                                             # needs sage.libs.singular
indeterminacy_locus()[source]

Return the indeterminacy locus of this map.

The map defines a rational map on the domain. The output is the subscheme of the domain on which the rational map is not defined by any representative of the rational map. See representatives().

EXAMPLES:

sage: P.<x,y> = ProjectiveSpace(QQ, 1)
sage: P2.<x0,x1,x2> = ProjectiveSpace(QQ, 2)
sage: X = P2.subscheme(0)
sage: f = X.hom([x1,x0], P)
sage: L = f.indeterminacy_locus()                                           # needs sage.libs.singular
sage: L.rational_points()                                                   # needs sage.libs.singular
[(0 : 0 : 1)]
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(1), names=('x', 'y',)); (x, y,) = P._first_ngens(2)
>>> P2 = ProjectiveSpace(QQ, Integer(2), names=('x0', 'x1', 'x2',)); (x0, x1, x2,) = P2._first_ngens(3)
>>> X = P2.subscheme(Integer(0))
>>> f = X.hom([x1,x0], P)
>>> L = f.indeterminacy_locus()                                           # needs sage.libs.singular
>>> L.rational_points()                                                   # needs sage.libs.singular
[(0 : 0 : 1)]
P.<x,y> = ProjectiveSpace(QQ, 1)
P2.<x0,x1,x2> = ProjectiveSpace(QQ, 2)
X = P2.subscheme(0)
f = X.hom([x1,x0], P)
L = f.indeterminacy_locus()                                           # needs sage.libs.singular
L.rational_points()                                                   # needs sage.libs.singular
sage: P2.<x,y,z> = ProjectiveSpace(QQ, 2)
sage: P1.<a,b> = ProjectiveSpace(QQ, 1)
sage: X = P2.subscheme([x^2 - y^2 - y*z])
sage: f = X.hom([x,y], P1)
sage: f.indeterminacy_locus()                                               # needs sage.libs.singular
Closed subscheme of Projective Space of dimension 2 over Rational Field defined by:
  z,
  y,
  x
>>> from sage.all import *
>>> P2 = ProjectiveSpace(QQ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P2._first_ngens(3)
>>> P1 = ProjectiveSpace(QQ, Integer(1), names=('a', 'b',)); (a, b,) = P1._first_ngens(2)
>>> X = P2.subscheme([x**Integer(2) - y**Integer(2) - y*z])
>>> f = X.hom([x,y], P1)
>>> f.indeterminacy_locus()                                               # needs sage.libs.singular
Closed subscheme of Projective Space of dimension 2 over Rational Field defined by:
  z,
  y,
  x
P2.<x,y,z> = ProjectiveSpace(QQ, 2)
P1.<a,b> = ProjectiveSpace(QQ, 1)
X = P2.subscheme([x^2 - y^2 - y*z])
f = X.hom([x,y], P1)
f.indeterminacy_locus()                                               # needs sage.libs.singular
>>> from sage.all import *
>>> P2 = ProjectiveSpace(QQ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P2._first_ngens(3)
>>> P1 = ProjectiveSpace(QQ, Integer(1), names=('a', 'b',)); (a, b,) = P1._first_ngens(2)
>>> X = P2.subscheme([x**Integer(2) - y**Integer(2) - y*z])
>>> f = X.hom([x,y], P1)
>>> f.indeterminacy_locus()                                               # needs sage.libs.singular
Closed subscheme of Projective Space of dimension 2 over Rational Field defined by:
  z,
  y,
  x
P2.<x,y,z> = ProjectiveSpace(QQ, 2)
P1.<a,b> = ProjectiveSpace(QQ, 1)
X = P2.subscheme([x^2 - y^2 - y*z])
f = X.hom([x,y], P1)
f.indeterminacy_locus()                                               # needs sage.libs.singular
sage: P3.<x,y,z,w> = ProjectiveSpace(QQ, 3)
sage: P2.<a,b,c> = ProjectiveSpace(QQ, 2)
sage: X = P3.subscheme(x^2 - w*y - x*z)
sage: f = X.hom([x*y, y*z, z*x], P2)
sage: L = f.indeterminacy_locus()                                           # needs sage.libs.singular
sage: L.dimension()                                                         # needs sage.libs.singular
0
sage: L.degree()                                                            # needs sage.libs.singular
2
sage: L.rational_points()                                                   # needs sage.libs.singular
[(0 : 0 : 0 : 1), (0 : 1 : 0 : 0)]
>>> from sage.all import *
>>> P3 = ProjectiveSpace(QQ, Integer(3), names=('x', 'y', 'z', 'w',)); (x, y, z, w,) = P3._first_ngens(4)
>>> P2 = ProjectiveSpace(QQ, Integer(2), names=('a', 'b', 'c',)); (a, b, c,) = P2._first_ngens(3)
>>> X = P3.subscheme(x**Integer(2) - w*y - x*z)
>>> f = X.hom([x*y, y*z, z*x], P2)
>>> L = f.indeterminacy_locus()                                           # needs sage.libs.singular
>>> L.dimension()                                                         # needs sage.libs.singular
0
>>> L.degree()                                                            # needs sage.libs.singular
2
>>> L.rational_points()                                                   # needs sage.libs.singular
[(0 : 0 : 0 : 1), (0 : 1 : 0 : 0)]
P3.<x,y,z,w> = ProjectiveSpace(QQ, 3)
P2.<a,b,c> = ProjectiveSpace(QQ, 2)
X = P3.subscheme(x^2 - w*y - x*z)
f = X.hom([x*y, y*z, z*x], P2)
L = f.indeterminacy_locus()                                           # needs sage.libs.singular
L.dimension()                                                         # needs sage.libs.singular
L.degree()                                                            # needs sage.libs.singular
L.rational_points()                                                   # needs sage.libs.singular
>>> from sage.all import *
>>> P3 = ProjectiveSpace(QQ, Integer(3), names=('x', 'y', 'z', 'w',)); (x, y, z, w,) = P3._first_ngens(4)
>>> P2 = ProjectiveSpace(QQ, Integer(2), names=('a', 'b', 'c',)); (a, b, c,) = P2._first_ngens(3)
>>> X = P3.subscheme(x**Integer(2) - w*y - x*z)
>>> f = X.hom([x*y, y*z, z*x], P2)
>>> L = f.indeterminacy_locus()                                           # needs sage.libs.singular
>>> L.dimension()                                                         # needs sage.libs.singular
0
>>> L.degree()                                                            # needs sage.libs.singular
2
>>> L.rational_points()                                                   # needs sage.libs.singular
[(0 : 0 : 0 : 1), (0 : 1 : 0 : 0)]
P3.<x,y,z,w> = ProjectiveSpace(QQ, 3)
P2.<a,b,c> = ProjectiveSpace(QQ, 2)
X = P3.subscheme(x^2 - w*y - x*z)
f = X.hom([x*y, y*z, z*x], P2)
L = f.indeterminacy_locus()                                           # needs sage.libs.singular
L.dimension()                                                         # needs sage.libs.singular
L.degree()                                                            # needs sage.libs.singular
L.rational_points()                                                   # needs sage.libs.singular
sage: P3.<x,y,z,w> = ProjectiveSpace(QQ, 3)
sage: A2.<a,b> = AffineSpace(QQ, 2)
sage: X = P3.subscheme(x^2 - w*y - x*z)
sage: f = X.hom([x/z, y/x], A2)
sage: L = f.indeterminacy_locus()                                           # needs sage.libs.singular
sage: L.rational_points()                                                   # needs sage.libs.singular
[(0 : 0 : 0 : 1), (0 : 1 : 0 : 0)]
>>> from sage.all import *
>>> P3 = ProjectiveSpace(QQ, Integer(3), names=('x', 'y', 'z', 'w',)); (x, y, z, w,) = P3._first_ngens(4)
>>> A2 = AffineSpace(QQ, Integer(2), names=('a', 'b',)); (a, b,) = A2._first_ngens(2)
>>> X = P3.subscheme(x**Integer(2) - w*y - x*z)
>>> f = X.hom([x/z, y/x], A2)
>>> L = f.indeterminacy_locus()                                           # needs sage.libs.singular
>>> L.rational_points()                                                   # needs sage.libs.singular
[(0 : 0 : 0 : 1), (0 : 1 : 0 : 0)]
P3.<x,y,z,w> = ProjectiveSpace(QQ, 3)
A2.<a,b> = AffineSpace(QQ, 2)
X = P3.subscheme(x^2 - w*y - x*z)
f = X.hom([x/z, y/x], A2)
L = f.indeterminacy_locus()                                           # needs sage.libs.singular
L.rational_points()                                                   # needs sage.libs.singular
>>> from sage.all import *
>>> P3 = ProjectiveSpace(QQ, Integer(3), names=('x', 'y', 'z', 'w',)); (x, y, z, w,) = P3._first_ngens(4)
>>> A2 = AffineSpace(QQ, Integer(2), names=('a', 'b',)); (a, b,) = A2._first_ngens(2)
>>> X = P3.subscheme(x**Integer(2) - w*y - x*z)
>>> f = X.hom([x/z, y/x], A2)
>>> L = f.indeterminacy_locus()                                           # needs sage.libs.singular
>>> L.rational_points()                                                   # needs sage.libs.singular
[(0 : 0 : 0 : 1), (0 : 1 : 0 : 0)]
P3.<x,y,z,w> = ProjectiveSpace(QQ, 3)
A2.<a,b> = AffineSpace(QQ, 2)
X = P3.subscheme(x^2 - w*y - x*z)
f = X.hom([x/z, y/x], A2)
L = f.indeterminacy_locus()                                           # needs sage.libs.singular
L.rational_points()                                                   # needs sage.libs.singular
sage: P.<x,y,z> = ProjectiveSpace(QQ, 2)
sage: X = P.subscheme(x - y)
sage: H = End(X)
sage: f = H([x^2 - 4*y^2, y^2 - z^2, 4*z^2 - x^2])
sage: Z = f.indeterminacy_locus(); Z                                        # needs sage.libs.singular
Closed subscheme of Projective Space of dimension 2 over Rational Field defined by:
  z,
  y,
  x
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> X = P.subscheme(x - y)
>>> H = End(X)
>>> f = H([x**Integer(2) - Integer(4)*y**Integer(2), y**Integer(2) - z**Integer(2), Integer(4)*z**Integer(2) - x**Integer(2)])
>>> Z = f.indeterminacy_locus(); Z                                        # needs sage.libs.singular
Closed subscheme of Projective Space of dimension 2 over Rational Field defined by:
  z,
  y,
  x
P.<x,y,z> = ProjectiveSpace(QQ, 2)
X = P.subscheme(x - y)
H = End(X)
f = H([x^2 - 4*y^2, y^2 - z^2, 4*z^2 - x^2])
Z = f.indeterminacy_locus(); Z                                        # needs sage.libs.singular
>>> from sage.all import *
>>> P = ProjectiveSpace(QQ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P._first_ngens(3)
>>> X = P.subscheme(x - y)
>>> H = End(X)
>>> f = H([x**Integer(2) - Integer(4)*y**Integer(2), y**Integer(2) - z**Integer(2), Integer(4)*z**Integer(2) - x**Integer(2)])
>>> Z = f.indeterminacy_locus(); Z                                        # needs sage.libs.singular
Closed subscheme of Projective Space of dimension 2 over Rational Field defined by:
  z,
  y,
  x
P.<x,y,z> = ProjectiveSpace(QQ, 2)
X = P.subscheme(x - y)
H = End(X)
f = H([x^2 - 4*y^2, y^2 - z^2, 4*z^2 - x^2])
Z = f.indeterminacy_locus(); Z                                        # needs sage.libs.singular
is_morphism()[source]

Return True if the map is defined everywhere on the domain.

EXAMPLES:

sage: P2.<x,y,z> = ProjectiveSpace(QQ,2)
sage: P1.<a,b> = ProjectiveSpace(QQ, 1)
sage: X = P2.subscheme([x^2 - y^2 - y*z])
sage: f = X.hom([x,y], P1)
sage: f.is_morphism()                                                       # needs sage.libs.singular
True
>>> from sage.all import *
>>> P2 = ProjectiveSpace(QQ,Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P2._first_ngens(3)
>>> P1 = ProjectiveSpace(QQ, Integer(1), names=('a', 'b',)); (a, b,) = P1._first_ngens(2)
>>> X = P2.subscheme([x**Integer(2) - y**Integer(2) - y*z])
>>> f = X.hom([x,y], P1)
>>> f.is_morphism()                                                       # needs sage.libs.singular
True
P2.<x,y,z> = ProjectiveSpace(QQ,2)
P1.<a,b> = ProjectiveSpace(QQ, 1)
X = P2.subscheme([x^2 - y^2 - y*z])
f = X.hom([x,y], P1)
f.is_morphism()                                                       # needs sage.libs.singular
projective_degrees()[source]

Return the projective degrees of this rational map.

EXAMPLES:

sage: # needs sage.schemes
sage: k = GF(11)
sage: E = EllipticCurve(k, [1,1])
sage: Q = E(6, 5)
sage: phi = E.scalar_multiplication(2)
sage: mor = phi.as_morphism()
sage: mor.projective_degrees()
(12, 3)
>>> from sage.all import *
>>> # needs sage.schemes
>>> k = GF(Integer(11))
>>> E = EllipticCurve(k, [Integer(1),Integer(1)])
>>> Q = E(Integer(6), Integer(5))
>>> phi = E.scalar_multiplication(Integer(2))
>>> mor = phi.as_morphism()
>>> mor.projective_degrees()
(12, 3)
# needs sage.schemes
k = GF(11)
E = EllipticCurve(k, [1,1])
Q = E(6, 5)
phi = E.scalar_multiplication(2)
mor = phi.as_morphism()
mor.projective_degrees()
representatives()[source]

Return all maps representing the same rational map as by this map.

EXAMPLES:

sage: P2.<x,y,z> = ProjectiveSpace(QQ, 2)
sage: X = P2.subscheme(0)
sage: f = X.hom([x^2*y, x^2*z, x*y*z], P2)
sage: f.representatives()                                                   # needs sage.libs.singular
[Scheme morphism:
   From: Closed subscheme of Projective Space of dimension 2
         over Rational Field defined by: 0
   To:   Projective Space of dimension 2 over Rational Field
   Defn: Defined on coordinates by sending (x : y : z) to (x*y : x*z : y*z)]
>>> from sage.all import *
>>> P2 = ProjectiveSpace(QQ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P2._first_ngens(3)
>>> X = P2.subscheme(Integer(0))
>>> f = X.hom([x**Integer(2)*y, x**Integer(2)*z, x*y*z], P2)
>>> f.representatives()                                                   # needs sage.libs.singular
[Scheme morphism:
   From: Closed subscheme of Projective Space of dimension 2
         over Rational Field defined by: 0
   To:   Projective Space of dimension 2 over Rational Field
   Defn: Defined on coordinates by sending (x : y : z) to (x*y : x*z : y*z)]
P2.<x,y,z> = ProjectiveSpace(QQ, 2)
X = P2.subscheme(0)
f = X.hom([x^2*y, x^2*z, x*y*z], P2)
f.representatives()                                                   # needs sage.libs.singular
sage: P2.<x,y,z> = ProjectiveSpace(QQ, 2)
sage: P1.<a,b> = ProjectiveSpace(QQ, 1)
sage: X = P2.subscheme([x^2 - y^2 - y*z])
sage: f = X.hom([x, y], P1)
sage: f.representatives()                                                   # needs sage.libs.singular
[Scheme morphism:
   From: Closed subscheme of Projective Space of dimension 2
         over Rational Field defined by: x^2 - y^2 - y*z
   To:   Projective Space of dimension 1 over Rational Field
   Defn: Defined on coordinates by sending (x : y : z) to (y + z : x),
 Scheme morphism:
   From: Closed subscheme of Projective Space of dimension 2
         over Rational Field defined by: x^2 - y^2 - y*z
   To:   Projective Space of dimension 1 over Rational Field
   Defn: Defined on coordinates by sending (x : y : z) to (x : y)]
sage: g = _[0]                                                              # needs sage.libs.singular
sage: g.representatives()                                                   # needs sage.libs.singular
[Scheme morphism:
   From: Closed subscheme of Projective Space of dimension 2
         over Rational Field defined by: x^2 - y^2 - y*z
   To:   Projective Space of dimension 1 over Rational Field
   Defn: Defined on coordinates by sending (x : y : z) to (y + z : x),
 Scheme morphism:
   From: Closed subscheme of Projective Space of dimension 2
         over Rational Field defined by: x^2 - y^2 - y*z
   To:   Projective Space of dimension 1 over Rational Field
   Defn: Defined on coordinates by sending (x : y : z) to (x : y)]
>>> from sage.all import *
>>> P2 = ProjectiveSpace(QQ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P2._first_ngens(3)
>>> P1 = ProjectiveSpace(QQ, Integer(1), names=('a', 'b',)); (a, b,) = P1._first_ngens(2)
>>> X = P2.subscheme([x**Integer(2) - y**Integer(2) - y*z])
>>> f = X.hom([x, y], P1)
>>> f.representatives()                                                   # needs sage.libs.singular
[Scheme morphism:
   From: Closed subscheme of Projective Space of dimension 2
         over Rational Field defined by: x^2 - y^2 - y*z
   To:   Projective Space of dimension 1 over Rational Field
   Defn: Defined on coordinates by sending (x : y : z) to (y + z : x),
 Scheme morphism:
   From: Closed subscheme of Projective Space of dimension 2
         over Rational Field defined by: x^2 - y^2 - y*z
   To:   Projective Space of dimension 1 over Rational Field
   Defn: Defined on coordinates by sending (x : y : z) to (x : y)]
>>> g = _[Integer(0)]                                                              # needs sage.libs.singular
>>> g.representatives()                                                   # needs sage.libs.singular
[Scheme morphism:
   From: Closed subscheme of Projective Space of dimension 2
         over Rational Field defined by: x^2 - y^2 - y*z
   To:   Projective Space of dimension 1 over Rational Field
   Defn: Defined on coordinates by sending (x : y : z) to (y + z : x),
 Scheme morphism:
   From: Closed subscheme of Projective Space of dimension 2
         over Rational Field defined by: x^2 - y^2 - y*z
   To:   Projective Space of dimension 1 over Rational Field
   Defn: Defined on coordinates by sending (x : y : z) to (x : y)]
P2.<x,y,z> = ProjectiveSpace(QQ, 2)
P1.<a,b> = ProjectiveSpace(QQ, 1)
X = P2.subscheme([x^2 - y^2 - y*z])
f = X.hom([x, y], P1)
f.representatives()                                                   # needs sage.libs.singular
g = _[0]                                                              # needs sage.libs.singular
g.representatives()                                                   # needs sage.libs.singular
>>> from sage.all import *
>>> P2 = ProjectiveSpace(QQ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P2._first_ngens(3)
>>> P1 = ProjectiveSpace(QQ, Integer(1), names=('a', 'b',)); (a, b,) = P1._first_ngens(2)
>>> X = P2.subscheme([x**Integer(2) - y**Integer(2) - y*z])
>>> f = X.hom([x, y], P1)
>>> f.representatives()                                                   # needs sage.libs.singular
[Scheme morphism:
   From: Closed subscheme of Projective Space of dimension 2
         over Rational Field defined by: x^2 - y^2 - y*z
   To:   Projective Space of dimension 1 over Rational Field
   Defn: Defined on coordinates by sending (x : y : z) to (y + z : x),
 Scheme morphism:
   From: Closed subscheme of Projective Space of dimension 2
         over Rational Field defined by: x^2 - y^2 - y*z
   To:   Projective Space of dimension 1 over Rational Field
   Defn: Defined on coordinates by sending (x : y : z) to (x : y)]
>>> g = _[Integer(0)]                                                              # needs sage.libs.singular
>>> g.representatives()                                                   # needs sage.libs.singular
[Scheme morphism:
   From: Closed subscheme of Projective Space of dimension 2
         over Rational Field defined by: x^2 - y^2 - y*z
   To:   Projective Space of dimension 1 over Rational Field
   Defn: Defined on coordinates by sending (x : y : z) to (y + z : x),
 Scheme morphism:
   From: Closed subscheme of Projective Space of dimension 2
         over Rational Field defined by: x^2 - y^2 - y*z
   To:   Projective Space of dimension 1 over Rational Field
   Defn: Defined on coordinates by sending (x : y : z) to (x : y)]
P2.<x,y,z> = ProjectiveSpace(QQ, 2)
P1.<a,b> = ProjectiveSpace(QQ, 1)
X = P2.subscheme([x^2 - y^2 - y*z])
f = X.hom([x, y], P1)
f.representatives()                                                   # needs sage.libs.singular
g = _[0]                                                              # needs sage.libs.singular
g.representatives()                                                   # needs sage.libs.singular
sage: P2.<x,y,z> = ProjectiveSpace(QQ, 2)
sage: X = P2.subscheme([x^2 - y^2 - y*z])
sage: A1.<a> = AffineSpace(QQ, 1)
sage: g = X.hom([y/x], A1)
sage: g.representatives()                                                   # needs sage.libs.singular
[Scheme morphism:
   From: Closed subscheme of Projective Space of dimension 2
         over Rational Field defined by: x^2 - y^2 - y*z
   To:   Affine Space of dimension 1 over Rational Field
   Defn: Defined on coordinates by sending (x : y : z) to (x/(y + z)),
 Scheme morphism:
   From: Closed subscheme of Projective Space of dimension 2
         over Rational Field defined by: x^2 - y^2 - y*z
   To:   Affine Space of dimension 1 over Rational Field
   Defn: Defined on coordinates by sending (x : y : z) to (y/x)]
sage: g0, g1 = _                                                            # needs sage.libs.singular
sage: emb = A1.projective_embedding(0)
sage: emb*g0                                                                # needs sage.libs.singular
Scheme morphism:
  From: Closed subscheme of Projective Space of dimension 2
        over Rational Field defined by: x^2 - y^2 - y*z
  To:   Projective Space of dimension 1 over Rational Field
  Defn: Defined on coordinates by sending (x : y : z) to (y + z : x)
sage: emb*g1                                                                # needs sage.libs.singular
Scheme morphism:
  From: Closed subscheme of Projective Space of dimension 2
        over Rational Field defined by: x^2 - y^2 - y*z
  To:   Projective Space of dimension 1 over Rational Field
  Defn: Defined on coordinates by sending (x : y : z) to (x : y)
>>> from sage.all import *
>>> P2 = ProjectiveSpace(QQ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P2._first_ngens(3)
>>> X = P2.subscheme([x**Integer(2) - y**Integer(2) - y*z])
>>> A1 = AffineSpace(QQ, Integer(1), names=('a',)); (a,) = A1._first_ngens(1)
>>> g = X.hom([y/x], A1)
>>> g.representatives()                                                   # needs sage.libs.singular
[Scheme morphism:
   From: Closed subscheme of Projective Space of dimension 2
         over Rational Field defined by: x^2 - y^2 - y*z
   To:   Affine Space of dimension 1 over Rational Field
   Defn: Defined on coordinates by sending (x : y : z) to (x/(y + z)),
 Scheme morphism:
   From: Closed subscheme of Projective Space of dimension 2
         over Rational Field defined by: x^2 - y^2 - y*z
   To:   Affine Space of dimension 1 over Rational Field
   Defn: Defined on coordinates by sending (x : y : z) to (y/x)]
>>> g0, g1 = _                                                            # needs sage.libs.singular
>>> emb = A1.projective_embedding(Integer(0))
>>> emb*g0                                                                # needs sage.libs.singular
Scheme morphism:
  From: Closed subscheme of Projective Space of dimension 2
        over Rational Field defined by: x^2 - y^2 - y*z
  To:   Projective Space of dimension 1 over Rational Field
  Defn: Defined on coordinates by sending (x : y : z) to (y + z : x)
>>> emb*g1                                                                # needs sage.libs.singular
Scheme morphism:
  From: Closed subscheme of Projective Space of dimension 2
        over Rational Field defined by: x^2 - y^2 - y*z
  To:   Projective Space of dimension 1 over Rational Field
  Defn: Defined on coordinates by sending (x : y : z) to (x : y)
P2.<x,y,z> = ProjectiveSpace(QQ, 2)
X = P2.subscheme([x^2 - y^2 - y*z])
A1.<a> = AffineSpace(QQ, 1)
g = X.hom([y/x], A1)
g.representatives()                                                   # needs sage.libs.singular
g0, g1 = _                                                            # needs sage.libs.singular
emb = A1.projective_embedding(0)
emb*g0                                                                # needs sage.libs.singular
emb*g1                                                                # needs sage.libs.singular
>>> from sage.all import *
>>> P2 = ProjectiveSpace(QQ, Integer(2), names=('x', 'y', 'z',)); (x, y, z,) = P2._first_ngens(3)
>>> X = P2.subscheme([x**Integer(2) - y**Integer(2) - y*z])
>>> A1 = AffineSpace(QQ, Integer(1), names=('a',)); (a,) = A1._first_ngens(1)
>>> g = X.hom([y/x], A1)
>>> g.representatives()                                                   # needs sage.libs.singular
[Scheme morphism:
   From: Closed subscheme of Projective Space of dimension 2
         over Rational Field defined by: x^2 - y^2 - y*z
   To:   Affine Space of dimension 1 over Rational Field
   Defn: Defined on coordinates by sending (x : y : z) to (x/(y + z)),
 Scheme morphism:
   From: Closed subscheme of Projective Space of dimension 2
         over Rational Field defined by: x^2 - y^2 - y*z
   To:   Affine Space of dimension 1 over Rational Field
   Defn: Defined on coordinates by sending (x : y : z) to (y/x)]
>>> g0, g1 = _                                                            # needs sage.libs.singular
>>> emb = A1.projective_embedding(Integer(0))
>>> emb*g0                                                                # needs sage.libs.singular
Scheme morphism:
  From: Closed subscheme of Projective Space of dimension 2
        over Rational Field defined by: x^2 - y^2 - y*z
  To:   Projective Space of dimension 1 over Rational Field
  Defn: Defined on coordinates by sending (x : y : z) to (y + z : x)
>>> emb*g1                                                                # needs sage.libs.singular
Scheme morphism:
  From: Closed subscheme of Projective Space of dimension 2
        over Rational Field defined by: x^2 - y^2 - y*z
  To:   Projective Space of dimension 1 over Rational Field
  Defn: Defined on coordinates by sending (x : y : z) to (x : y)
P2.<x,y,z> = ProjectiveSpace(QQ, 2)
X = P2.subscheme([x^2 - y^2 - y*z])
A1.<a> = AffineSpace(QQ, 1)
g = X.hom([y/x], A1)
g.representatives()                                                   # needs sage.libs.singular
g0, g1 = _                                                            # needs sage.libs.singular
emb = A1.projective_embedding(0)
emb*g0                                                                # needs sage.libs.singular
emb*g1                                                                # needs sage.libs.singular

ALGORITHM:

The algorithm is from Proposition 1.1 in [Sim2004].