source: git/Singular/LIB/gmspoly.lib @ 1e1ec4

spielwiese
Last change on this file since 1e1ec4 was 1e1ec4, checked in by Oleksandr Motsak <motsak@…>, 11 years ago
Updated LIBs according to master add: new LIBs from master fix: updated LIBs due to minpoly/(de)numerator changes fix: -> $Id$ fix: Fixing wrong rebase of SW on master (LIBs)
  • Property mode set to 100644
File size: 12.4 KB
Line 
1///////////////////////////////////////////////////////////////////////////////
2version="$Id$";
3category="Singularities";
4
5info="
6LIBRARY:  gmspoly.lib  Gauss-Manin System of Tame Polynomials
7
8AUTHOR:   Mathias Schulze, mschulze at mathematik.uni-kl.de
9
10OVERVIEW:
11A library for computing the Gauss-Manin system of a cohomologically tame
12polynomial f. Schulze's algorithm [Sch05], based on Sabbah's theory [Sab98],
13is used to compute a good basis of (the Brieskorn lattice of) the Gauss-Manin system and the differential operation of f in terms of this basis.
14In addition, there is a test for tameness in the sense of Broughton.
15Tame polynomials can be considered as an affine algebraic analogue of local
16analytic isolated hypersurface singularities. They have only finitely many
17citical points, and those at infinity do not give rise to atypical values
18in a sense depending on the precise notion of tameness considered. Well-known
19notions of tameness like tameness, M-tameness, Malgrange-tameness, and
20cohomological tameness, and their relations, are reviewed in [Sab98,8].
21For ordinary tameness, see Broughton [Bro88,3].
22Sabbah [Sab98] showed that the Gauss-Manin system, the D-module direct image
23of the structure sheaf, of a cohomologically tame polynomial carries a
24similar structure as in the isolated singularity case, coming from a Mixed
25Hodge structure on the cohomology of the Milnor (typical) fibre (see
26gmssing.lib). The data computed by this library encodes the differential structure of the Gauss-Manin system, and the Mixed Hodge structure of the Milnor fibre over the complex numbers. As a consequence, it yields the Hodge numbers, spectral pairs, and monodromy at infinity.
27
28REFERENCES:
29[Bro88] S. Broughton: Milnor numbers and the topology of polynomial
30        hypersurfaces. Inv. Math. 92 (1988) 217-241.
31[Sab98] C. Sabbah: Hypergeometric periods for a tame polynomial.
32        arXiv.org math.AG/9805077.
33[Sch05] M. Schulze: Good bases for tame polynomials.
34        J. Symb. Comp. 39,1 (2005), 103-126.
35
36PROCEDURES:
37  isTame(f);     test whether the polynomial f is tame
38  goodBasis(f);  good basis of Brieskorn lattice of cohom. tame polynomial f
39
40SEE ALSO: gmssing_lib
41
42KEYWORDS: tame polynomial; Gauss-Manin system; Brieskorn lattice;
43          mixed Hodge structure; V-filtration; weight filtration;
44          monodromy; spectrum; spectral pairs; good basis
45";
46
47LIB "linalg.lib";
48LIB "ring.lib";
49
50///////////////////////////////////////////////////////////////////////////////
51
52static proc mindegree(matrix A)
53{
54  int d=0;
55
56  while(A/var(1)^(d+1)*var(1)^(d+1)==A)
57  {
58    d++;
59  }
60
61  return(d);
62}
63///////////////////////////////////////////////////////////////////////////////
64
65static proc maxdegree(matrix A)
66{
67  int d=0;
68  matrix N[nrows(A)][ncols(A)];
69
70  while(A/var(1)^(d+1)!=N)
71  {
72    d++;
73  }
74
75  return(d);
76}
77///////////////////////////////////////////////////////////////////////////////
78
79proc isTame(poly f)
80"USAGE:    isTame(f); poly f
81ASSUME:   basering has no variables named w(1),w(2),...
82RETURN:
83@format
84int k=
85  1;  if f is tame in the sense of Broughton [Bro88,3]
86  0;  if f is not tame
87@end format
88REMARKS:  procedure implements Proposition 3.1 in [Bro88]
89KEYWORDS: tame polynomial
90EXAMPLE:  example isTame; shows examples
91"
92{
93  int d=vdim(std(jacob(f)));
94  def @X=basering;
95  int n=nvars(@X);
96  ring ext_ring=0,(w(1..n)),dp;
97  setring @X;
98  def @WX=changechar(ringlist(ext_ring));
99  setring @WX;
100  kill ext_ring;
101  ideal J=jacob(imap(@X,f));
102  int i;
103  for(i=1;i<=n;i++)
104  {
105    J[i]=J[i]+w(i);
106  }
107  int D=vdim(std(J));
108
109  setring(@X);
110  kill @WX;
111
112  return(d>0&&d==D);
113}
114example
115{ "EXAMPLE:"; echo=2;
116  ring R=0,(x,y),dp;
117  isTame(x2y+x);
118  isTame(x3+y3+xy);
119}
120///////////////////////////////////////////////////////////////////////////////
121
122static proc chart(matrix A)
123{
124  A=ideal(homog(transpose(ideal(A)),var(2)));
125  def r=basering;
126  map h=r,1,var(1);
127  return(h(A));
128}
129///////////////////////////////////////////////////////////////////////////////
130
131static proc pidbasis(module M0,module M)
132{
133  int m=nrows(M);
134  int n=ncols(M);
135
136  module L,N;
137  module T=freemodule(m);
138  while(matrix(L)!=matrix(M))
139  {
140    L=M;
141
142    M=T,M;
143    N=transpose(std(transpose(M)));
144    T=N[1..m];
145    M=N[m+1..ncols(N)];
146
147    M=freemodule(n),transpose(M);
148    N=std(transpose(M));
149    N=transpose(simplify(N,1));
150    M=N[n+1..ncols(N)];
151    M=transpose(M);
152  }
153
154  if(maxdegree(M)>0)
155  {
156    print("   ? module not free");
157    return(module());
158  }
159
160  attrib(M,"isSB",1);
161  N=lift(T,simplify(reduce(M0,M),2));
162
163  return(N);
164}
165///////////////////////////////////////////////////////////////////////////////
166
167static proc vfiltmat(matrix B,int d)
168{
169  int mu=ncols(B);
170
171  module V=freemodule(mu);
172  module V0=var(1)^(d-1)*freemodule(mu);
173  attrib(V0,"isSB",1);
174  module V1=B;
175  option(redSB);
176  while(size(reduce(V1,V0))>0)
177  {
178    V=std(V0+V1);
179    V0=var(1)^(d-1)*V;
180    attrib(V0,"isSB",1);
181    V1=B*matrix(V1)-var(1)^d*diff(matrix(V1),var(1));
182  }
183  option("noredSB");
184
185  B=lift(V0,B*matrix(V)-var(1)^d*diff(matrix(V),var(1)));
186  list l=eigenvals(B);
187  def e0,s0=l[1..2];
188
189  module U;
190  int i,j,i0,j0,i1,j1,k;
191  for(k=int(e0[ncols(e0)]-e0[1]);k>=1;k--)
192  {
193    U=0;
194    for(i=1;i<=ncols(e0);i++)
195    {
196      U=U+syz(power(jet(B,0)-e0[i],s0[i]));
197    }
198    B=lift(U,B*U);
199    V=V*U;
200
201    for(i0,i=1,1;i0<=ncols(e0);i0++)
202    {
203      for(i1=1;i1<=s0[i0];i1,i=i1+1,i+1)
204      {
205        for(j0,j=1,1;j0<=ncols(e0);j0++)
206        {
207          for(j1=1;j1<=s0[j0];j1,j=j1+1,j+1)
208          {
209            if(leadcoef(e0[i0]-e0[1])>=1&&leadcoef(e0[j0]-e0[1])<1)
210            {
211              B[i,j]=B[i,j]/var(1);
212            }
213            if(leadcoef(e0[i0]-e0[1])<1&&leadcoef(e0[j0]-e0[1])>=1)
214            {
215              B[i,j]=B[i,j]*var(1);
216            }
217          }
218        }
219      }
220    }
221
222    for(i0,i=1,1;i0<=ncols(e0);i0++)
223    {
224      if(leadcoef(e0[i0]-e0[1])>=1)
225      {
226        for(i1=1;i1<=s0[i0];i1,i=i1+1,i+1)
227        {
228          B[i,i]=B[i,i]-1;
229          V[i]=V[i]*var(1);
230        }
231        e0[i0]=e0[i0]-1;
232      }
233      else
234      {
235        i=i+s0[i0];
236      }
237    }
238
239    l=spnf(list(e0,s0));
240    e0,s0=l[1..2];
241  }
242
243  U=0;
244  for(i=1;i<=ncols(e0);i++)
245  {
246    U=U+syz(power(jet(B,0)-e0[i],s0[i]));
247  }
248  B=lift(U,B*U);
249  V=V*U;
250
251  d=mindegree(V);
252  V=V/var(1)^d;
253  B=B+d*matrix(freemodule(mu));
254  for(i=ncols(e0);i>=1;i--)
255  {
256    e0[i]=e0[i]+d;
257  }
258
259  return(e0,s0,V,B);
260}
261///////////////////////////////////////////////////////////////////////////////
262
263static proc spec(ideal e0,intvec s0,module V,matrix B)
264{
265  int mu=ncols(B);
266
267  int i,j,k;
268
269  int d=maxdegree(V);
270  int d0=d;
271  V=chart(V);
272  module U=std(V);
273  while(size(reduce(var(1)^d*freemodule(mu),U))>0)
274  {
275    d++;
276  }
277  if(d>d0)
278  {
279    k=d-d0;
280    B=B-k*freemodule(mu);
281    for(i=1;i<=ncols(e0);i++)
282    {
283      e0[i]=e0[i]-k;
284    }
285  }
286  module G=lift(V,var(1)^d*freemodule(mu));
287  G=std(G);
288  G=simplify(G,1);
289
290  ideal e;
291  intvec s;
292  e[mu]=0;
293  for(j,k=1,1;j<=ncols(e0);j++)
294  {
295    for(i=s0[j];i>=1;i,k=i-1,k+1)
296    {
297      e[k]=e0[j];
298      s[k]=j;
299    }
300  }
301
302  ideal a;
303  a[mu]=0;
304  for(i=1;i<=mu;i++)
305  {
306    a[i]=leadcoef(e[leadexp(G[i])[nvars(basering)+1]])+leadexp(G[i])[1];
307  }
308
309  return(a,e0,e,s,V,B,G);
310}
311///////////////////////////////////////////////////////////////////////////////
312
313static proc fsplit(ideal e0,ideal e,intvec s,module V,matrix B,module G)
314{
315  int mu=ncols(e);
316
317  int i,j,k;
318
319  number n,n0;
320  vector v,v0;
321  list F;
322  for(i=ncols(e0);i>=1;i--)
323  {
324    F[i]=module(matrix(0,mu,1));
325  }
326  for(i=mu;i>=1;i--)
327  {
328    v=G[i];
329    v0=lead(v);
330    n0=leadcoef(e[leadexp(v0)[nvars(basering)+1]])+leadexp(v0)[1];
331    v=v-lead(v);
332    while(v!=0)
333    {
334      n=leadcoef(e[leadexp(v)[nvars(basering)+1]])+leadexp(v)[1];
335      if(n==n0)
336      {
337        v0=v0+lead(v);
338        v=v-lead(v);
339      }
340      else
341      {
342        v=0;
343      }
344    }
345    j=s[leadexp(v0)[nvars(basering)+1]];
346    F[j]=F[j]+v0;
347  }
348
349  matrix B0=jet(B,0);
350  module U,U0,U1,U2;
351  matrix N;
352  for(i=size(F);i>=1;i--)
353  {
354    N=B0-e0[i];
355    U0=0;
356    while(size(F[i])>0)
357    {
358      k=0;
359      U1=jet(F[i],0);
360      while(size(U1)>0)
361      {
362        for(j=ncols(U1);j>=1;j--)
363        {
364          if(size(reduce(U1[j],std(U0)))>0)
365          {
366            U0=U1[j]+U0;
367          }
368        }
369        U1=N*U1;
370        k++;
371      }
372      F[i]=module(F[i]/var(1));
373    }
374    U=U0+U;
375  }
376
377  V=V*U;
378  G=lift(U,G);
379  B=lift(U,B*U);
380
381  return(e,V,B,G);
382}
383///////////////////////////////////////////////////////////////////////////////
384
385static proc glift(ideal e,module V,matrix B,module G)
386{
387  int mu=ncols(e);
388
389  int d=maxdegree(B);
390  B=chart(B);
391  G=std(G);
392  G=simplify(G,1);
393
394  int i,j,k;
395
396  ideal v;
397  for(i=mu;i>=1;i--)
398  {
399    v[i]=e[leadexp(G[i])[nvars(basering)+1]]+leadexp(G[i])[1];
400  }
401
402  number c;
403  matrix g[mu][1];
404  matrix m[mu][1];
405  matrix a[mu][1];
406  matrix A[mu][mu];
407  module M=var(1)^d*G;
408  module N=var(1)*B*matrix(G)+var(1)^(d+2)*diff(matrix(G),var(1));
409  while(size(N)>0)
410  {
411    j=mu;
412    for(k=mu-1;k>=1;k--)
413    {
414      if(N[k]>N[j])
415      {
416        j=k;
417      }
418    }
419
420    i=mu;
421    while(leadexp(M[i])[nvars(basering)+1]!=leadexp(N[j])[nvars(basering)+1])
422    {
423      i--;
424    }
425
426    k=leadexp(N[j])[1]-leadexp(M[i])[1];
427    if(k==0||i==j)
428    {
429      c=leadcoef(N[j])/leadcoef(M[i]);
430      A[i,j]=A[i,j]+c*var(1)^k;
431      N[j]=N[j]-c*var(1)^k*M[i];
432    }
433    else
434    {
435      c=leadcoef(N[j])/leadcoef(M[i])/(1-k-leadcoef(v[i])+leadcoef(v[j]));
436      G[j]=G[j]+c*var(1)^(k-1)*G[i];
437      M[j]=M[j]+c*var(1)^(k-1)*M[i];
438      g=c*var(1)^(k-1)*G[i];
439      N[j]=N[j]+(var(1)*B*g+var(1)^(d+2)*diff(g,var(1)))[1];
440      m=M[i];
441      a=transpose(A)[j];
442      N=N-c*var(1)^(k-1)*m*transpose(a);
443    }
444  }
445
446  G=V*G;
447  G=G/var(1)^mindegree(G);
448
449  return(G,A);
450}
451///////////////////////////////////////////////////////////////////////////////
452
453proc goodBasis(poly f)
454"USAGE:    goodBasis(f); poly f
455ASSUME:   f is cohomologically tame in the sense of Sabbah [Sab98,8]
456RETURN:
457@format
458ring R;  basering with new variable s
459  ideal b;  [matrix(b)] is a good basis of the Brieskorn lattice
460  matrix A;  A(s)=A0+s*A1 and t[matrix(b)]=[matrix(b)](A(s)+s^2*(d/ds))
461@end format
462REMARKS:  procedure implements Algorithm 6 in [Sch05]
463KEYWORDS: tame polynomial; Gauss-Manin system; Brieskorn lattice;
464          mixed Hodge structure; V-filtration; weight filtration;
465          monodromy; spectrum; spectral pairs; good basis
466SEE ALSO: gmssing_lib
467EXAMPLE:  example goodBasis; shows examples
468"
469{
470  def @X=basering;
471  int n=nvars(@X);
472  ideal J=jacob(f);
473
474  if(vdim(std(J))<=0)
475  {
476    ERROR("input is not cohomologically tame");
477  }
478
479  int i,j,k,l;
480
481  ideal X=maxideal(1);
482  string c="ring @XS=0,(s,"+varstr(@X)+"),(C,dp(1),dp(n));";
483  execute(c);
484  poly f=imap(@X,f);
485  ideal J=imap(@X,J);
486  ideal JS=std(J+var(1));
487  ideal b0=kbase(JS);
488  int mu=ncols(b0);
489  ideal X=imap(@X,X);
490
491  ideal b;
492  matrix A;
493  module B,B0;
494  ideal K,L,M=1,J,1;
495  ideal K0,L0,M0=X,X,X;
496  module K1,L1,K2,L2;
497  module LL1;
498  for(i=1;i<=deg(f)-1;i++)
499  {
500    M=M,M0;
501    M0=M0*X;
502  }
503
504  ring @S=0,(s,t),(dp,C);
505  number a0;
506  ideal a;
507  int d;
508  ideal e,e0;
509  intvec s,s0;
510  matrix A,B;
511  module V,G;
512
513  while(2*a0!=mu*n)
514  {
515    setring(@XS);
516
517    B=0;
518    while(size(B)<mu||size(B0)<mu||maxdegree(b)+deg(f)>k)
519    {
520      k++;
521      K=K,K0;
522      K0=K0*X;
523
524      B=0;
525      while(size(B)==0||size(B)>mu)
526      {
527        l++;
528        for(i=1;i<=size(L0);i++)
529        {
530          for(j=1;j<=n;j++)
531          {
532            L=L,J[j]*L0[i]-var(1)*diff(L0[i],var(j+1));
533          }
534        }
535        L0=L0*X;
536        M=M,M0;
537        M0=M0*X;
538
539        K1=coeffs(K,K,product(X));
540        L1=std(coeffs(L,M,product(X)));
541        LL1=jet(lead(L1),0);
542        attrib(LL1,"isSB",1);
543        K2=simplify(reduce(K1,LL1),2);
544        L2=intersect(K2,L1);
545
546        B=pidbasis(K2,L2);
547      }
548
549      B0=std(coeffs(reduce(matrix(K,nrows(K),nrows(B))*B,JS),b0));
550      b=matrix(K,nrows(K),nrows(B))*B;
551    }
552
553    A=lift(B,reduce(coeffs(f*b+var(1)^2*diff(b,var(1)),M,product(X)),L1));
554    d=maxdegree(A);
555    A=chart(A);
556
557    setring(@S);
558
559    e0,s0,V,B=vfiltmat(imap(@XS,A),d);
560    a,e0,e,s,V,B,G=spec(e0,s0,V,B);
561
562    a0=leadcoef(a[1]);
563    for(i=2;i<=mu;i++)
564    {
565      a0=a0+leadcoef(a[i]);
566    }
567  }
568
569  G,A=glift(fsplit(e0,e,s,V,B,G));
570
571  setring(@XS);
572  b=matrix(b)*imap(@S,G);
573  A=imap(@S,A);
574  export(b,A);
575  kill @S;
576
577  setring(@X);
578  return(@XS);
579}
580example
581{ "EXAMPLE:"; echo=2;
582  ring R=0,(x,y,z),dp;
583  poly f=x+y+z+x2y2z2;
584  def Rs=goodBasis(f);
585  setring(Rs);
586  b;
587  print(jet(A,0));
588  print(jet(A/var(1),0));
589}
590///////////////////////////////////////////////////////////////////////////////
Note: See TracBrowser for help on using the repository browser.