canonical ideal for quaternion covers
This commit is contained in:
parent
1891b447b6
commit
a8e8dbbaa3
@ -91,8 +91,17 @@ class as_symmetric_product_forms:
|
|||||||
def __init__(self, forms_and_coeffs):
|
def __init__(self, forms_and_coeffs):
|
||||||
'''Elements of forms_and_coeffs are of the form [coeff, form1, ..., formn]'''
|
'''Elements of forms_and_coeffs are of the form [coeff, form1, ..., formn]'''
|
||||||
self.n = len(forms_and_coeffs[0]) - 1
|
self.n = len(forms_and_coeffs[0]) - 1
|
||||||
self.tuples = forms_and_coeffs
|
forms_and_coeffs1 = []
|
||||||
self.curve = forms_and_coeffs[0][1].curve
|
for atuple in forms_and_coeffs:
|
||||||
|
if atuple[0] != 0 and atuple[1:] not in [a[1:] for a in forms_and_coeffs1]:
|
||||||
|
forms_and_coeffs1 += [atuple]
|
||||||
|
elif atuple[1:] in [a[1:] for a in forms_and_coeffs1]:
|
||||||
|
i = [a[1:] for a in forms_and_coeffs1].index(atuple[1:])
|
||||||
|
forms_and_coeffs1[i][0] += atuple[0]
|
||||||
|
if len(forms_and_coeffs1) == 0:
|
||||||
|
forms_and_coeffs1 = [[0] + forms_and_coeffs[0][1:]]
|
||||||
|
self.tuples = forms_and_coeffs1
|
||||||
|
self.curve = forms_and_coeffs1[0][1].curve
|
||||||
|
|
||||||
def coordinates(self, basis = 0):
|
def coordinates(self, basis = 0):
|
||||||
AS = self.curve
|
AS = self.curve
|
||||||
@ -172,13 +181,28 @@ class as_symmetric_product_forms:
|
|||||||
return result
|
return result
|
||||||
|
|
||||||
def group_action(self, elt):
|
def group_action(self, elt):
|
||||||
p = self.base_ring.characteristic()
|
p = self.curve.base_ring.characteristic()
|
||||||
n = self.height
|
n = self.curve.height
|
||||||
aux_tuples = []
|
aux_tuples = []
|
||||||
for atuple in self.tuples:
|
for atuple in self.tuples:
|
||||||
aux_tuple = atuple[0] + [a.group_action(elt) for a in atuple[1:]]
|
aux_tuple = [atuple[0]] + [a.group_action(elt) for a in atuple[1:]]
|
||||||
aux_tuples += [aux_tuple]
|
aux_tuples += [aux_tuple]
|
||||||
return as_symmetric_product_forms(aux_tuples)
|
return as_symmetric_product_forms(aux_tuples)
|
||||||
|
|
||||||
def non_decreasing(L):
|
def non_decreasing(L):
|
||||||
return all(x<=y for x, y in zip(L, L[1:]))
|
return all(x<=y for x, y in zip(L, L[1:]))
|
||||||
|
|
||||||
|
def as_matrices_group_action_canonical_ideal(AS, mult, threshold = 8):
|
||||||
|
K = as_canonical_ideal(AS, mult, threshold = threshold)
|
||||||
|
n = AS.height
|
||||||
|
F = AS.base_ring
|
||||||
|
K_polynomials = [a.polynomial() for a in K]
|
||||||
|
r = len(K)
|
||||||
|
matrices = []
|
||||||
|
for i in range(n):
|
||||||
|
M = matrix(F, r, r)
|
||||||
|
K_group_action_polynomials = [a.group_action([j == i for j in range(n)]).polynomial() for a in K]
|
||||||
|
for i in range(r):
|
||||||
|
M[i, :] = vector(linear_representation_polynomials(K_group_action_polynomials[i], K_polynomials))
|
||||||
|
matrices += [M]
|
||||||
|
return matrices
|
@ -1,4 +1,4 @@
|
|||||||
def group_action_matrices(space, list_of_group_elements, basis):
|
def group_action_matrices(F, space, list_of_group_elements, basis):
|
||||||
n = len(list_of_group_elements)
|
n = len(list_of_group_elements)
|
||||||
d = len(space)
|
d = len(space)
|
||||||
A = [matrix(F, d, d) for i in range(n)]
|
A = [matrix(F, d, d) for i in range(n)]
|
||||||
@ -18,7 +18,8 @@ def group_action_matrices_holo(AS, basis=0, threshold=10):
|
|||||||
generators += [ei]
|
generators += [ei]
|
||||||
if basis == 0:
|
if basis == 0:
|
||||||
basis = AS.holomorphic_differentials_basis(threshold=threshold)
|
basis = AS.holomorphic_differentials_basis(threshold=threshold)
|
||||||
return group_action_matrices(basis, generators, basis = basis)
|
F = AS.base_ring
|
||||||
|
return group_action_matrices(F, basis, generators, basis = basis)
|
||||||
|
|
||||||
def group_action_matrices_dR(AS, threshold=8):
|
def group_action_matrices_dR(AS, threshold=8):
|
||||||
n = AS.height
|
n = AS.height
|
||||||
@ -30,35 +31,9 @@ def group_action_matrices_dR(AS, threshold=8):
|
|||||||
holo_basis = AS.holomorphic_differentials_basis(threshold = threshold)
|
holo_basis = AS.holomorphic_differentials_basis(threshold = threshold)
|
||||||
str_basis = AS.cohomology_of_structure_sheaf_basis(holo_basis = holo_basis, threshold = threshold)
|
str_basis = AS.cohomology_of_structure_sheaf_basis(holo_basis = holo_basis, threshold = threshold)
|
||||||
dr_basis = AS.de_rham_basis(holo_basis = holo_basis, cohomology_basis = str_basis, threshold=threshold)
|
dr_basis = AS.de_rham_basis(holo_basis = holo_basis, cohomology_basis = str_basis, threshold=threshold)
|
||||||
|
F = AS.base_ring
|
||||||
basis = [holo_basis, str_basis, dr_basis]
|
basis = [holo_basis, str_basis, dr_basis]
|
||||||
return group_action_matrices(basis[2], generators, basis = basis)
|
return group_action_matrices(F, basis[2], generators, basis = basis)
|
||||||
|
|
||||||
def group_action_matrices_old(C_AS):
|
|
||||||
F = C_AS.base_ring
|
|
||||||
n = C_AS.height
|
|
||||||
holo = C_AS.holomorphic_differentials_basis()
|
|
||||||
holo_forms = [omega.form for omega in holo]
|
|
||||||
denom = LCM([denominator(omega) for omega in holo_forms])
|
|
||||||
variable_names = 'x, y'
|
|
||||||
for j in range(n):
|
|
||||||
variable_names += ', z' + str(j)
|
|
||||||
Rxyz = PolynomialRing(F, n+2, variable_names)
|
|
||||||
x, y = Rxyz.gens()[:2]
|
|
||||||
z = Rxyz.gens()[2:]
|
|
||||||
holo_forms = [Rxyz(omega*denom) for omega in holo_forms]
|
|
||||||
A = [[] for i in range(n)]
|
|
||||||
for omega in holo:
|
|
||||||
for i in range(n):
|
|
||||||
ei = n*[0]
|
|
||||||
ei[i] = 1
|
|
||||||
omega1 = omega.group_action(ei)
|
|
||||||
omega1 = denom * omega1
|
|
||||||
v1 = omega1.coordinates(holo_forms)
|
|
||||||
A[i] += [v1]
|
|
||||||
for i in range(n):
|
|
||||||
A[i] = matrix(F, A[i])
|
|
||||||
A[i] = A[i].transpose()
|
|
||||||
return A
|
|
||||||
|
|
||||||
def group_action_matrices_log(AS):
|
def group_action_matrices_log(AS):
|
||||||
n = AS.height
|
n = AS.height
|
||||||
@ -67,31 +42,5 @@ def group_action_matrices_log(AS):
|
|||||||
ei = n*[0]
|
ei = n*[0]
|
||||||
ei[i] = 1
|
ei[i] = 1
|
||||||
generators += [ei]
|
generators += [ei]
|
||||||
return group_action_matrices(AS.at_most_poles_forms(1), generators, basis = AS.at_most_poles_forms(1))
|
F = AS.base_ring
|
||||||
|
return group_action_matrices(F, AS.at_most_poles_forms(1), generators, basis = AS.at_most_poles_forms(1))
|
||||||
def group_action_matrices_log_old(C_AS):
|
|
||||||
F = C_AS.base_ring
|
|
||||||
n = C_AS.height
|
|
||||||
holo = C_AS.at_most_poles_forms(1)
|
|
||||||
holo_forms = [omega for omega in holo]
|
|
||||||
denom = LCM([denominator(omega) for omega in holo_forms])
|
|
||||||
variable_names = 'x, y'
|
|
||||||
for j in range(n):
|
|
||||||
variable_names += ', z' + str(j)
|
|
||||||
Rxyz = PolynomialRing(F, n+2, variable_names)
|
|
||||||
x, y = Rxyz.gens()[:2]
|
|
||||||
z = Rxyz.gens()[2:]
|
|
||||||
holo_forms = [Rxyz(omega*denom) for omega in holo_forms]
|
|
||||||
A = [[] for i in range(n)]
|
|
||||||
for omega in holo:
|
|
||||||
for i in range(n):
|
|
||||||
ei = n*[0]
|
|
||||||
ei[i] = 1
|
|
||||||
omega1 = omega.group_action(ei)
|
|
||||||
omega1 = denom * omega1
|
|
||||||
v1 = omega1.coordinates(holo_forms)
|
|
||||||
A[i] += [v1]
|
|
||||||
for i in range(n):
|
|
||||||
A[i] = matrix(F, A[i])
|
|
||||||
A[i] = A[i].transpose()
|
|
||||||
return A
|
|
@ -81,13 +81,29 @@ class quaternion_form:
|
|||||||
omega = self.form
|
omega = self.form
|
||||||
return quaternion_form(C, constant*omega)
|
return quaternion_form(C, constant*omega)
|
||||||
|
|
||||||
def group_action(self, ZN_tuple):
|
def group_action(self, elt):
|
||||||
C = self.curve
|
Q8 = QuaternionGroup()
|
||||||
n = C.height
|
Qi, Qj = Q8.gens()
|
||||||
RxyzQ, Rxyz, x, y, z = C.fct_field
|
AS = self.curve
|
||||||
sub_list = {x : x, y : y} | {z[j] : z[j]+ZN_tuple[j] for j in range(n)}
|
RxyzQ, Rxyz, x, y, z = AS.fct_field
|
||||||
|
if elt == Qi^4:
|
||||||
|
sub_list = {x : x, y : y} | {z[0] : z[0], z[1] : z[1], z[2]: z[2]}
|
||||||
|
if elt == Qi:
|
||||||
|
sub_list = {x : x, y : y} | {z[0] : z[0]+1, z[1] : z[1], z[2]: z[2] + z[0]}
|
||||||
|
if elt == Qj:
|
||||||
|
sub_list = {x : x, y : y} | {z[0] : z[0], z[1] : z[1] + 1, z[2]: z[2] + z[1] + z[0]}
|
||||||
|
if elt == Qi^2:
|
||||||
|
sub_list = {x : x, y : y} | {z[0] : z[0], z[1] : z[1], z[2]: z[2] + 1}
|
||||||
|
if elt == Qi * Qj:
|
||||||
|
sub_list = {x : x, y : y} | {z[0] : z[0] + 1, z[1] : z[1] + 1, z[2]: z[2] + z[1] + 1}
|
||||||
|
if elt == Qj * Qi:
|
||||||
|
sub_list = {x : x, y : y} | {z[0] : z[0] + 1, z[1] : z[1] + 1, z[2]: z[2] + z[1]}
|
||||||
|
if elt == Qi^3:
|
||||||
|
sub_list = {x : x, y : y} | {z[0] : z[0]+1, z[1] : z[1], z[2]: z[2] + z[0] + 1}
|
||||||
|
if elt == Qj^3:
|
||||||
|
sub_list = {x : x, y : y} | {z[0] : z[0], z[1] : z[1] + 1, z[2]: z[2] + z[1] + z[0] + 1}
|
||||||
g = self.form
|
g = self.form
|
||||||
return quaternion_form(C, g.substitute(sub_list))
|
return quaternion_form(AS, g.substitute(sub_list))
|
||||||
|
|
||||||
def coordinates(self, basis = 0):
|
def coordinates(self, basis = 0):
|
||||||
"""Find coordinates of the given holomorphic form self in terms of the basis forms in a list holo."""
|
"""Find coordinates of the given holomorphic form self in terms of the basis forms in a list holo."""
|
||||||
@ -97,6 +113,9 @@ class quaternion_form:
|
|||||||
RxyzQ, Rxyz, x, y, z = C.fct_field
|
RxyzQ, Rxyz, x, y, z = C.fct_field
|
||||||
# We need to have only polynomials to use monomial_coefficients in linear_representation_polynomials,
|
# We need to have only polynomials to use monomial_coefficients in linear_representation_polynomials,
|
||||||
# and sometimes basis elements have denominators. Thus we multiply by them.
|
# and sometimes basis elements have denominators. Thus we multiply by them.
|
||||||
|
fct = quaternion_function(C, self.form)
|
||||||
|
fct = quaternion_reduction(C, fct)
|
||||||
|
self = quaternion_form(C, fct)
|
||||||
denom = LCM([denominator(omega.form) for omega in basis])
|
denom = LCM([denominator(omega.form) for omega in basis])
|
||||||
basis = [denom*omega for omega in basis]
|
basis = [denom*omega for omega in basis]
|
||||||
self_with_no_denominator = denom*self
|
self_with_no_denominator = denom*self
|
||||||
|
@ -24,7 +24,7 @@ def quaternion_reduction(AS, fct):
|
|||||||
if d_div != n*[0]:
|
if d_div != n*[0]:
|
||||||
change = 1
|
change = 1
|
||||||
d_rem = [a.degree(z[i])%p for i in range(n)]
|
d_rem = [a.degree(z[i])%p for i in range(n)]
|
||||||
monomial = fct1.monomial_coefficient(a)*x^(a.degree(x))*y^(a.degree(y))*prod(z[i]^(d_rem[i]) for i in range(n))*prod((z[i] + ff[i])^(d_div[i]) for i in range(n))
|
monomial = fct1.monomial_coefficient(a)*x^(a.degree(x))*y^(a.degree(y))*prod(z[i]^(d_rem[i]) for i in range(n))*prod((z[i] + ff[i])^(d_div[i]) for i in range(n-1))*(z[2] + ff[2] + z[0]*ff[0] + z[1] * (ff[0] + ff[1]))^(d_div[2])
|
||||||
result += RxyzQ(monomial)
|
result += RxyzQ(monomial)
|
||||||
|
|
||||||
if change == 0:
|
if change == 0:
|
||||||
|
Loading…
Reference in New Issue
Block a user