CoCalc Public Fileswww / tables / magma_src / ModFrm / qexp_mappings.mOpen with one click!
Author: William A. Stein
1
freeze;
2
3
/****-*-magma-* EXPORT DATE: 2004-03-08 ************************************
4
5
MODFORM: Modular Forms in MAGMA
6
7
William A. Stein
8
9
FILE: qexp_mappings.m
10
11
$Header: /home/was/magma/packages/modform/code/RCS/qexp_mappings.m,v 1.2 2001/11/10 18:49:06 was Exp $
12
13
$Log: qexp_mappings.m,v $
14
Revision 1.2 2001/11/10 18:49:06 was
15
Changed from SeqEnum to List in orbits of maps, because Magma V2.8-3 now
16
pronounces my use of SeqEnum in this case an error (it didn't used to). -- WAS
17
18
Revision 1.1 2001/05/30 18:56:50 was
19
Initial revision
20
21
22
23
***************************************************************************/
24
25
26
import "misc.m" : ToLowerCaseLetter;
27
28
29
function MapFromNumberField(K, root)
30
R := PolynomialRing(Rationals());
31
L := Parent(root);
32
phi := hom< K -> R | x :-> R!Eltseq(x) >;
33
psi := hom< R -> L | root>;
34
return hom< K -> L | x :-> psi(phi(x))>;
35
end function;
36
37
38
function ComputeComplexMaps(f)
39
R := BaseRing(Parent(PowerSeries(f,2)));
40
L := ComplexField();
41
42
if Type(R) in {FldRat, RngInt} then
43
return [* [hom<R -> L | x :-> L!x>] *];
44
end if;
45
46
assert Type(R) in {FldNum, FldCyc};
47
48
h := PolynomialRing(L)!DefiningPolynomial(R);
49
50
orb := [];
51
for root in Roots(h) do
52
// for i in [1..root[2]] do
53
Append(~orb, MapFromNumberField(R, root[1]));
54
// end for;
55
end for;
56
return [* orb *];
57
58
end function;
59
60
function ComputepAdicMaps(f, p)
61
assert Type(f) eq ModFrmElt;
62
R := BaseRing(Parent(PowerSeries(f,2)));
63
L := pAdicField(p);
64
65
if Type(R) in {FldRat, RngInt} then
66
return [* [hom<R -> L | x :-> L!x>] *];
67
end if;
68
69
assert Type(R) in {FldNum, FldCyc};
70
71
h := PolynomialRing(L)!DefiningPolynomial(R);
72
73
// Now we distribute the corresponding maps to the conjugates in the orb.
74
ans := [* *];
75
j := 1;
76
for F in Factorization(h) do
77
orb := [* *];
78
// for n in [1..F[2]] do
79
if Degree(F[1]) eq 1 then
80
Append(~orb, MapFromNumberField(R, -Evaluate(F[1],0)));
81
else
82
S := PolynomialRing(L);
83
for i in [1..Degree(F[1])] do
84
T := quo<S|F[1]>;
85
AssignNames(~T,[ToLowerCaseLetter(j)]);
86
j +:= 1;
87
phi := MapFromNumberField(R, T.1);
88
Append(~orb, phi);
89
end for;
90
end if;
91
// end for;
92
Append(~ans,orb);
93
end for;
94
return ans;
95
end function;
96
97
function ComputeModpMapsUsingMaximalOrder(f, p)
98
assert Type(p) eq RngIntElt;
99
assert IsPrime(p) and p gt 0;
100
assert Type(f) eq ModFrmElt;
101
102
R := BaseRing(Parent(PowerSeries(f)));
103
assert Type(R) in {FldNum, FldCyc};
104
L := GF(p) ;
105
106
vprint ModularForms :
107
"Ramification in a degree "*IntegerToString(Degree(R))*
108
" extension, so we use slower method to compute mod-"*IntegerToString(p)*" reductions.";
109
110
O := MaximalOrder(R);
111
I := ideal<O|p>;
112
ans := [* *];
113
which := 1;
114
for F in Factorization(I) do
115
orb := [ ];
116
k, phi := ResidueClassField(O, F[1]);
117
ord_embed := hom<R -> Domain(phi) | x :-> Domain(phi)!x>;
118
kk := GF(#k);
119
if not IsCoercible(kk,k.1) then // first time to choose an embedding.
120
Embed(k,kk);
121
end if;
122
embed := hom<k->kk | x :-> kk!x>;
123
for i in [0..Degree(k)-1] do
124
frob_i := hom<kk -> kk | x :-> x^(p^i)>;
125
comp := ord_embed*phi*embed*frob_i;
126
Append(~orb, comp);
127
end for;
128
Append(~ans,orb);
129
end for;
130
return ans;
131
end function;
132
133
134
function ComputeModpMaps(f, p)
135
R := BaseRing(Parent(PowerSeries(f,2)));
136
L := GF(p);
137
138
if Type(R) in {FldRat, RngInt} then
139
return [* [hom<R -> L | x :-> L!x>] *];
140
end if;
141
142
assert Type(R) in {FldNum, FldCyc};
143
144
h := DefiningPolynomial(R);
145
if not IsEisensteinSeries(f) then // use maximal order if Z[x]/(h) is not p-maximal in O_R.
146
disc_h := Discriminant(h);
147
if (Integers()!disc_h) mod p eq 0 and
148
(Integers()!(disc_h/Discriminant(MaximalOrder(R))) mod p eq 0) then
149
return ComputeModpMapsUsingMaximalOrder(f, p);
150
end if;
151
end if;
152
153
ans := [* *];
154
for F in Factorization(PolynomialRing(L)!h) do
155
orb := [];
156
k := GF(p^Degree(F[1]));
157
for linear in Factorization(PolynomialRing(k)!F[1]) do
158
// for i in [1..F[2]] do // count with multiplicities.
159
assert Degree(linear[1]) eq 1;
160
root := -Evaluate(linear[1],0);
161
Append(~orb, MapFromNumberField(R, root));
162
// end for;
163
end for;
164
Append(~ans, orb);
165
end for;
166
return ans;
167
end function;
168
169
function ModpReductionMaps(f, p)
170
assert Type(f) eq ModFrmElt;
171
assert Type(p) eq RngIntElt;
172
assert p gt 0 and IsPrime(p);
173
return ComputeModpMaps(f,p);
174
end function;
175
176
177
function pAdicEmbeddingMaps(f, p)
178
assert Type(f) eq ModFrmElt;
179
assert Type(p) eq RngIntElt;
180
assert p gt 0 and IsPrime(p);
181
return ComputepAdicMaps(f,p);
182
end function;
183
184
function ComplexEmbeddingMaps(f)
185
assert Type(f) eq ModFrmElt;
186
return ComputeComplexMaps(f);
187
end function;
188