Points for products of projective spaces

This class builds on the projective space class and its point and morphism classes.

EXAMPLES:

We construct products projective spaces of various dimensions over the same ring.:

sage: P1xP1.<x,y, u,v> = ProductProjectiveSpaces(QQ, [1, 1])
sage: P1xP1([2, 1, 3, 1])
(2 : 1 , 3 : 1)
>>> from sage.all import *
>>> P1xP1 = ProductProjectiveSpaces(QQ, [Integer(1), Integer(1)], names=('x', 'y', 'u', 'v',)); (x, y, u, v,) = P1xP1._first_ngens(4)
>>> P1xP1([Integer(2), Integer(1), Integer(3), Integer(1)])
(2 : 1 , 3 : 1)
P1xP1.<x,y, u,v> = ProductProjectiveSpaces(QQ, [1, 1])
P1xP1([2, 1, 3, 1])
class sage.schemes.product_projective.point.ProductProjectiveSpaces_point_field(parent, polys, check=True)[source]

Bases: ProductProjectiveSpaces_point_ring

intersection_multiplicity(X)[source]

Return the intersection multiplicity of the codomain of this point and subscheme X at this point.

This uses the subscheme implementation of intersection_multiplicity. This point must be a point on a subscheme of a product of projective spaces.

INPUT:

  • X – a subscheme in the same ambient space as the codomain of this point

OUTPUT: integer

EXAMPLES:

sage: PP.<x,y,z,u,v> = ProductProjectiveSpaces(QQ, [2, 1])
sage: X = PP.subscheme([y^2*z^3*u - x^5*v])
sage: Y = PP.subscheme([u^3 - v^3, x - y])
sage: Q = X([0,0,1,1,1])
sage: Q.intersection_multiplicity(Y)                                        # needs sage.libs.singular
2
>>> from sage.all import *
>>> PP = ProductProjectiveSpaces(QQ, [Integer(2), Integer(1)], names=('x', 'y', 'z', 'u', 'v',)); (x, y, z, u, v,) = PP._first_ngens(5)
>>> X = PP.subscheme([y**Integer(2)*z**Integer(3)*u - x**Integer(5)*v])
>>> Y = PP.subscheme([u**Integer(3) - v**Integer(3), x - y])
>>> Q = X([Integer(0),Integer(0),Integer(1),Integer(1),Integer(1)])
>>> Q.intersection_multiplicity(Y)                                        # needs sage.libs.singular
2
PP.<x,y,z,u,v> = ProductProjectiveSpaces(QQ, [2, 1])
X = PP.subscheme([y^2*z^3*u - x^5*v])
Y = PP.subscheme([u^3 - v^3, x - y])
Q = X([0,0,1,1,1])
Q.intersection_multiplicity(Y)                                        # needs sage.libs.singular
multiplicity()[source]

Return the multiplicity of this point on its codomain.

This uses the subscheme implementation of multiplicity. This point must be a point on a subscheme of a product of projective spaces.

OUTPUT: integer

EXAMPLES:

sage: PP.<x,y,z,w,u,v,t> = ProductProjectiveSpaces(QQ, [3, 2])
sage: X = PP.subscheme([x^8*t - y^8*t + z^5*w^3*v])
sage: Q1 = X([1,1,0,0,-1,-1,1])
sage: Q1.multiplicity()                                                     # needs sage.libs.singular
1
sage: Q2 = X([0,0,0,1,0,1,1])
sage: Q2.multiplicity()                                                     # needs sage.libs.singular
5
sage: Q3 = X([0,0,0,1,1,0,0])
sage: Q3.multiplicity()                                                     # needs sage.libs.singular
6
>>> from sage.all import *
>>> PP = ProductProjectiveSpaces(QQ, [Integer(3), Integer(2)], names=('x', 'y', 'z', 'w', 'u', 'v', 't',)); (x, y, z, w, u, v, t,) = PP._first_ngens(7)
>>> X = PP.subscheme([x**Integer(8)*t - y**Integer(8)*t + z**Integer(5)*w**Integer(3)*v])
>>> Q1 = X([Integer(1),Integer(1),Integer(0),Integer(0),-Integer(1),-Integer(1),Integer(1)])
>>> Q1.multiplicity()                                                     # needs sage.libs.singular
1
>>> Q2 = X([Integer(0),Integer(0),Integer(0),Integer(1),Integer(0),Integer(1),Integer(1)])
>>> Q2.multiplicity()                                                     # needs sage.libs.singular
5
>>> Q3 = X([Integer(0),Integer(0),Integer(0),Integer(1),Integer(1),Integer(0),Integer(0)])
>>> Q3.multiplicity()                                                     # needs sage.libs.singular
6
PP.<x,y,z,w,u,v,t> = ProductProjectiveSpaces(QQ, [3, 2])
X = PP.subscheme([x^8*t - y^8*t + z^5*w^3*v])
Q1 = X([1,1,0,0,-1,-1,1])
Q1.multiplicity()                                                     # needs sage.libs.singular
Q2 = X([0,0,0,1,0,1,1])
Q2.multiplicity()                                                     # needs sage.libs.singular
Q3 = X([0,0,0,1,1,0,0])
Q3.multiplicity()                                                     # needs sage.libs.singular
class sage.schemes.product_projective.point.ProductProjectiveSpaces_point_finite_field(parent, polys, check=True)[source]

Bases: ProductProjectiveSpaces_point_field

class sage.schemes.product_projective.point.ProductProjectiveSpaces_point_ring(parent, polys, check=True)[source]

Bases: SchemeMorphism_point

The class of points on products of projective spaces.

The components are projective space points.

EXAMPLES:

sage: T.<x,y,z,w,u> = ProductProjectiveSpaces([2, 1], QQ)
sage: T.point([1, 2, 3, 4, 5])
(1/3 : 2/3 : 1 , 4/5 : 1)
>>> from sage.all import *
>>> T = ProductProjectiveSpaces([Integer(2), Integer(1)], QQ, names=('x', 'y', 'z', 'w', 'u',)); (x, y, z, w, u,) = T._first_ngens(5)
>>> T.point([Integer(1), Integer(2), Integer(3), Integer(4), Integer(5)])
(1/3 : 2/3 : 1 , 4/5 : 1)
T.<x,y,z,w,u> = ProductProjectiveSpaces([2, 1], QQ)
T.point([1, 2, 3, 4, 5])
change_ring(R, **kwds)[source]

Return a new ProductProjectiveSpaces_point which is this point coerced to R.

If the keyword check is True, then the initialization checks are performed. The user may specify the embedding into R with a keyword.

INPUT:

  • R – ring

kwds:

  • check – boolean

  • embedding – field embedding from the base ring of this point to R

OUTPUT: ProductProjectiveSpaces_point

EXAMPLES:

sage: T.<x,y,z,u,v,w> = ProductProjectiveSpaces([1, 1, 1], ZZ)
sage: P = T.point([5, 3, 15, 4, 2, 6])
sage: P.change_ring(GF(3))
(1 : 0 , 0 : 1 , 1 : 0)
>>> from sage.all import *
>>> T = ProductProjectiveSpaces([Integer(1), Integer(1), Integer(1)], ZZ, names=('x', 'y', 'z', 'u', 'v', 'w',)); (x, y, z, u, v, w,) = T._first_ngens(6)
>>> P = T.point([Integer(5), Integer(3), Integer(15), Integer(4), Integer(2), Integer(6)])
>>> P.change_ring(GF(Integer(3)))
(1 : 0 , 0 : 1 , 1 : 0)
T.<x,y,z,u,v,w> = ProductProjectiveSpaces([1, 1, 1], ZZ)
P = T.point([5, 3, 15, 4, 2, 6])
P.change_ring(GF(3))
dehomogenize(L)[source]

Dehomogenize \(k\)-th point at \(L[k]\)-th coordinate.

This function computes the appropriate affine patch using L and then returns the dehomogenized point on of this affine space.

INPUT:

  • L – list of nonnegative integers

OUTPUT: SchemeMorphism_point_affine

EXAMPLES:

sage: PP = ProductProjectiveSpaces([2, 2, 2], QQ, 'x')
sage: A = PP([2, 4, 6, 23, 46, 23, 9, 3, 1])
sage: A.dehomogenize([0, 1, 2])
(2, 3, 1/2, 1/2, 9, 3)
>>> from sage.all import *
>>> PP = ProductProjectiveSpaces([Integer(2), Integer(2), Integer(2)], QQ, 'x')
>>> A = PP([Integer(2), Integer(4), Integer(6), Integer(23), Integer(46), Integer(23), Integer(9), Integer(3), Integer(1)])
>>> A.dehomogenize([Integer(0), Integer(1), Integer(2)])
(2, 3, 1/2, 1/2, 9, 3)
PP = ProductProjectiveSpaces([2, 2, 2], QQ, 'x')
A = PP([2, 4, 6, 23, 46, 23, 9, 3, 1])
A.dehomogenize([0, 1, 2])
sage: # needs sage.rings.real_mpfr sage.symbolic
sage: PP.<a,b,x,y,z> = ProductProjectiveSpaces([1, 2], CC)
sage: X = PP.subscheme([a^2 + b^2])
sage: P = X([2, 2*i, -3, 6*i, 3 - 6*i])
sage: P.dehomogenize([1,0])
(-1.00000000000000*I, -2.00000000000000*I, -1.00000000000000 + 2.00000000000000*I)
>>> from sage.all import *
>>> # needs sage.rings.real_mpfr sage.symbolic
>>> PP = ProductProjectiveSpaces([Integer(1), Integer(2)], CC, names=('a', 'b', 'x', 'y', 'z',)); (a, b, x, y, z,) = PP._first_ngens(5)
>>> X = PP.subscheme([a**Integer(2) + b**Integer(2)])
>>> P = X([Integer(2), Integer(2)*i, -Integer(3), Integer(6)*i, Integer(3) - Integer(6)*i])
>>> P.dehomogenize([Integer(1),Integer(0)])
(-1.00000000000000*I, -2.00000000000000*I, -1.00000000000000 + 2.00000000000000*I)
# needs sage.rings.real_mpfr sage.symbolic
PP.<a,b,x,y,z> = ProductProjectiveSpaces([1, 2], CC)
X = PP.subscheme([a^2 + b^2])
P = X([2, 2*i, -3, 6*i, 3 - 6*i])
P.dehomogenize([1,0])
>>> from sage.all import *
>>> # needs sage.rings.real_mpfr sage.symbolic
>>> PP = ProductProjectiveSpaces([Integer(1), Integer(2)], CC, names=('a', 'b', 'x', 'y', 'z',)); (a, b, x, y, z,) = PP._first_ngens(5)
>>> X = PP.subscheme([a**Integer(2) + b**Integer(2)])
>>> P = X([Integer(2), Integer(2)*i, -Integer(3), Integer(6)*i, Integer(3) - Integer(6)*i])
>>> P.dehomogenize([Integer(1),Integer(0)])
(-1.00000000000000*I, -2.00000000000000*I, -1.00000000000000 + 2.00000000000000*I)
# needs sage.rings.real_mpfr sage.symbolic
PP.<a,b,x,y,z> = ProductProjectiveSpaces([1, 2], CC)
X = PP.subscheme([a^2 + b^2])
P = X([2, 2*i, -3, 6*i, 3 - 6*i])
P.dehomogenize([1,0])
sage: PP = ProductProjectiveSpaces([1, 1], ZZ)
sage: A = PP([0,1,2,4])
sage: A.dehomogenize([0,0])
Traceback (most recent call last):
...
ValueError: can...t dehomogenize at 0 coordinate
>>> from sage.all import *
>>> PP = ProductProjectiveSpaces([Integer(1), Integer(1)], ZZ)
>>> A = PP([Integer(0),Integer(1),Integer(2),Integer(4)])
>>> A.dehomogenize([Integer(0),Integer(0)])
Traceback (most recent call last):
...
ValueError: can...t dehomogenize at 0 coordinate
PP = ProductProjectiveSpaces([1, 1], ZZ)
A = PP([0,1,2,4])
A.dehomogenize([0,0])
>>> from sage.all import *
>>> PP = ProductProjectiveSpaces([Integer(1), Integer(1)], ZZ)
>>> A = PP([Integer(0),Integer(1),Integer(2),Integer(4)])
>>> A.dehomogenize([Integer(0),Integer(0)])
Traceback (most recent call last):
...
ValueError: can...t dehomogenize at 0 coordinate
PP = ProductProjectiveSpaces([1, 1], ZZ)
A = PP([0,1,2,4])
A.dehomogenize([0,0])
global_height(prec=None)[source]

Return the absolute logarithmic height of the point.

This function computes the maximum of global height of each component point in the product. Global height of component point is computed using function for projective point.

INPUT:

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

OUTPUT: a real number

EXAMPLES:

sage: PP = ProductProjectiveSpaces(QQ, [2, 2], 'x')
sage: Q = PP([1, 7, 5, 18, 2, 3])
sage: Q.global_height()                                                     # needs sage.symbolic
2.89037175789616
>>> from sage.all import *
>>> PP = ProductProjectiveSpaces(QQ, [Integer(2), Integer(2)], 'x')
>>> Q = PP([Integer(1), Integer(7), Integer(5), Integer(18), Integer(2), Integer(3)])
>>> Q.global_height()                                                     # needs sage.symbolic
2.89037175789616
PP = ProductProjectiveSpaces(QQ, [2, 2], 'x')
Q = PP([1, 7, 5, 18, 2, 3])
Q.global_height()                                                     # needs sage.symbolic
sage: PP = ProductProjectiveSpaces(ZZ, [1, 1], 'x')
sage: A = PP([-30, 2, 1, 6])
sage: A.global_height()                                                     # needs sage.symbolic
2.70805020110221
>>> from sage.all import *
>>> PP = ProductProjectiveSpaces(ZZ, [Integer(1), Integer(1)], 'x')
>>> A = PP([-Integer(30), Integer(2), Integer(1), Integer(6)])
>>> A.global_height()                                                     # needs sage.symbolic
2.70805020110221
PP = ProductProjectiveSpaces(ZZ, [1, 1], 'x')
A = PP([-30, 2, 1, 6])
A.global_height()                                                     # needs sage.symbolic
>>> from sage.all import *
>>> PP = ProductProjectiveSpaces(ZZ, [Integer(1), Integer(1)], 'x')
>>> A = PP([-Integer(30), Integer(2), Integer(1), Integer(6)])
>>> A.global_height()                                                     # needs sage.symbolic
2.70805020110221
PP = ProductProjectiveSpaces(ZZ, [1, 1], 'x')
A = PP([-30, 2, 1, 6])
A.global_height()                                                     # needs sage.symbolic
sage: # needs sage.rings.number_field
sage: R.<x> = PolynomialRing(QQ)
sage: k.<w> = NumberField(x^2 + 5)
sage: PP = ProductProjectiveSpaces(k, [1, 2], 'y')
sage: Q = PP([3, 5*w + 1, 1, 7*w, 10])
sage: Q.global_height()
2.75062910527236
>>> 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(5), names=('w',)); (w,) = k._first_ngens(1)
>>> PP = ProductProjectiveSpaces(k, [Integer(1), Integer(2)], 'y')
>>> Q = PP([Integer(3), Integer(5)*w + Integer(1), Integer(1), Integer(7)*w, Integer(10)])
>>> Q.global_height()
2.75062910527236
# needs sage.rings.number_field
R.<x> = PolynomialRing(QQ)
k.<w> = NumberField(x^2 + 5)
PP = ProductProjectiveSpaces(k, [1, 2], 'y')
Q = PP([3, 5*w + 1, 1, 7*w, 10])
Q.global_height()
>>> 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(5), names=('w',)); (w,) = k._first_ngens(1)
>>> PP = ProductProjectiveSpaces(k, [Integer(1), Integer(2)], 'y')
>>> Q = PP([Integer(3), Integer(5)*w + Integer(1), Integer(1), Integer(7)*w, Integer(10)])
>>> Q.global_height()
2.75062910527236
# needs sage.rings.number_field
R.<x> = PolynomialRing(QQ)
k.<w> = NumberField(x^2 + 5)
PP = ProductProjectiveSpaces(k, [1, 2], 'y')
Q = PP([3, 5*w + 1, 1, 7*w, 10])
Q.global_height()
sage: PP = ProductProjectiveSpaces(QQbar, [1, 1], 'x')                      # needs sage.rings.number_field
sage: Q = PP([1, QQbar(sqrt(2)), QQbar(5^(1/3)), QQbar(3^(1/3))])           # needs sage.rings.number_field sage.symbolic
sage: Q.global_height()                                                     # needs sage.rings.number_field sage.symbolic
0.536479304144700
>>> from sage.all import *
>>> PP = ProductProjectiveSpaces(QQbar, [Integer(1), Integer(1)], 'x')                      # needs sage.rings.number_field
>>> Q = PP([Integer(1), QQbar(sqrt(Integer(2))), QQbar(Integer(5)**(Integer(1)/Integer(3))), QQbar(Integer(3)**(Integer(1)/Integer(3)))])           # needs sage.rings.number_field sage.symbolic
>>> Q.global_height()                                                     # needs sage.rings.number_field sage.symbolic
0.536479304144700
PP = ProductProjectiveSpaces(QQbar, [1, 1], 'x')                      # needs sage.rings.number_field
Q = PP([1, QQbar(sqrt(2)), QQbar(5^(1/3)), QQbar(3^(1/3))])           # needs sage.rings.number_field sage.symbolic
Q.global_height()                                                     # needs sage.rings.number_field sage.symbolic
>>> from sage.all import *
>>> PP = ProductProjectiveSpaces(QQbar, [Integer(1), Integer(1)], 'x')                      # needs sage.rings.number_field
>>> Q = PP([Integer(1), QQbar(sqrt(Integer(2))), QQbar(Integer(5)**(Integer(1)/Integer(3))), QQbar(Integer(3)**(Integer(1)/Integer(3)))])           # needs sage.rings.number_field sage.symbolic
>>> Q.global_height()                                                     # needs sage.rings.number_field sage.symbolic
0.536479304144700
PP = ProductProjectiveSpaces(QQbar, [1, 1], 'x')                      # needs sage.rings.number_field
Q = PP([1, QQbar(sqrt(2)), QQbar(5^(1/3)), QQbar(3^(1/3))])           # needs sage.rings.number_field sage.symbolic
Q.global_height()                                                     # needs sage.rings.number_field sage.symbolic
local_height(v, prec=None)[source]

Return the maximum of the local height of the coordinates of this point.

This function computes the maximum of local height of each component point in the product. Local height of component point is computed using function for projective point.

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: PP = ProductProjectiveSpaces(QQ, [1, 1], 'x')
sage: A = PP([11, 5, 10, 2])
sage: A.local_height(5)                                                     # needs sage.rings.real_mpfr
1.60943791243410
>>> from sage.all import *
>>> PP = ProductProjectiveSpaces(QQ, [Integer(1), Integer(1)], 'x')
>>> A = PP([Integer(11), Integer(5), Integer(10), Integer(2)])
>>> A.local_height(Integer(5))                                                     # needs sage.rings.real_mpfr
1.60943791243410
PP = ProductProjectiveSpaces(QQ, [1, 1], 'x')
A = PP([11, 5, 10, 2])
A.local_height(5)                                                     # needs sage.rings.real_mpfr
sage: P = ProductProjectiveSpaces(QQ, [1, 2], 'x')
sage: Q = P([1, 4, 1/2, 2, 32])
sage: Q.local_height(2)                                                     # needs sage.rings.real_mpfr
4.15888308335967
>>> from sage.all import *
>>> P = ProductProjectiveSpaces(QQ, [Integer(1), Integer(2)], 'x')
>>> Q = P([Integer(1), Integer(4), Integer(1)/Integer(2), Integer(2), Integer(32)])
>>> Q.local_height(Integer(2))                                                     # needs sage.rings.real_mpfr
4.15888308335967
P = ProductProjectiveSpaces(QQ, [1, 2], 'x')
Q = P([1, 4, 1/2, 2, 32])
Q.local_height(2)                                                     # needs sage.rings.real_mpfr
>>> from sage.all import *
>>> P = ProductProjectiveSpaces(QQ, [Integer(1), Integer(2)], 'x')
>>> Q = P([Integer(1), Integer(4), Integer(1)/Integer(2), Integer(2), Integer(32)])
>>> Q.local_height(Integer(2))                                                     # needs sage.rings.real_mpfr
4.15888308335967
P = ProductProjectiveSpaces(QQ, [1, 2], 'x')
Q = P([1, 4, 1/2, 2, 32])
Q.local_height(2)                                                     # needs sage.rings.real_mpfr
normalize_coordinates()[source]

Remove common factors (componentwise) from the coordinates of this point (including \(-1\)).

OUTPUT: none

EXAMPLES:

sage: T.<x,y,z,u,v,w> = ProductProjectiveSpaces([2, 2], ZZ)
sage: P = T.point([5, 10, 15, 4, 2, 6]);
sage: P.normalize_coordinates()
sage: P
(1 : 2 : 3 , 2 : 1 : 3)
>>> from sage.all import *
>>> T = ProductProjectiveSpaces([Integer(2), Integer(2)], ZZ, names=('x', 'y', 'z', 'u', 'v', 'w',)); (x, y, z, u, v, w,) = T._first_ngens(6)
>>> P = T.point([Integer(5), Integer(10), Integer(15), Integer(4), Integer(2), Integer(6)]);
>>> P.normalize_coordinates()
>>> P
(1 : 2 : 3 , 2 : 1 : 3)
T.<x,y,z,u,v,w> = ProductProjectiveSpaces([2, 2], ZZ)
P = T.point([5, 10, 15, 4, 2, 6]);
P.normalize_coordinates()
P
scale_by(t)[source]

Scale the coordinates of the point by t, done componentwise.

A TypeError occurs if the point is not in the base ring of the codomain after scaling.

INPUT:

  • t – a ring element

EXAMPLES:

sage: T.<x, y, z, u, v, w> = ProductProjectiveSpaces([1, 1, 1], ZZ)
sage: P = T.point([5, 10, 15, 4, 2, 6]);
sage: P.scale_by([2, 1, 1])
sage: P
(10 : 20 , 15 : 4 , 2 : 6)
>>> from sage.all import *
>>> T = ProductProjectiveSpaces([Integer(1), Integer(1), Integer(1)], ZZ, names=('x', 'y', 'z', 'u', 'v', 'w',)); (x, y, z, u, v, w,) = T._first_ngens(6)
>>> P = T.point([Integer(5), Integer(10), Integer(15), Integer(4), Integer(2), Integer(6)]);
>>> P.scale_by([Integer(2), Integer(1), Integer(1)])
>>> P
(10 : 20 , 15 : 4 , 2 : 6)
T.<x, y, z, u, v, w> = ProductProjectiveSpaces([1, 1, 1], ZZ)
P = T.point([5, 10, 15, 4, 2, 6]);
P.scale_by([2, 1, 1])
P