def usecase__get_linear_series__P1P1_DP6(): ''' Construct linear series of curves in P^1xP^1, with a given tree of (infinitely near) base points. ''' # construct ring over Gaussian rationals # ring = PolyRing('x,y,v,w', True) ring.ext_num_field('t^2 + 1') a0 = ring.root_gens()[0] # setup base point tree for 2 simple complex conjugate base points. # bp_tree = BasePointTree(['xv', 'xw', 'yv', 'yw']) bp = bp_tree.add('xv', (-a0, a0), 1) bp = bp_tree.add('xv', (a0, -a0), 1) LSTools.p( 'We consider linear series of curves in P^1xP^1 with the following base point tree:' ) LSTools.p(bp_tree) # # Construct linear series is defined by a list of polynomials # in (x:y)(v:w) of bi-degree (2,2) with base points as in "bp_tree". # The defining polynomials of this linear series, correspond to a parametric map # of an anticanonical model of a Del Pezzo surface of degree 6 in P^6. # # We expect that the linear series is defined by the following set of polynomials: # # [ 'x^2*v^2 - y^2*w^2', 'x^2*v*w + y^2*v*w', 'x^2*w^2 + y^2*w^2', 'x*y*v^2 - y^2*v*w', # 'x*y*v*w - y^2*w^2', 'y^2*v*w + x*y*w^2', 'y^2*v^2 + y^2*w^2' ] # ls = LinearSeries.get([2, 2], bp_tree) LSTools.p( 'The linear series of bi-degree (2,2) corresponding to this base point tree is as follows:' ) LSTools.p(ls.get_bp_tree()) # # construct corresponding linear series of bi-degree (1,1) # and 2 simple complex conjugate base points # # We expect that the linear series is defined by the following set of polynomials: # # ['x * v - y * w', 'y * v + x * w' ] # # ls = LinearSeries.get([1, 1], bp_tree) LSTools.p( 'The linear series of bi-degree (1,1) corresponding to this base point tree is as follows:' ) LSTools.p(ls.get_bp_tree())
def usecase__get_base_points__P2(): ''' We obtain (infinitely near) base points of a linear series defined over a number field. ''' ring = PolyRing('x,y,z', True) ring.ext_num_field('t^2 + 1') ring.ext_num_field('t^3 + a0') a0, a1 = ring.root_gens() x, y, z = ring.gens() pol_lst = [x**2 + a0 * y * z, y + a1 * z + x] ls = LinearSeries(pol_lst, ring) LSTools.p(ls) bp_tree = ls.get_bp_tree() LSTools.p(bp_tree)