[BACK]Return to demo.k CVS log [TXT][DIR] Up to [local] / OpenXM / src / k097 / lib / restriction

Diff for /OpenXM/src/k097/lib/restriction/demo.k between version 1.2 and 1.4

version 1.2, 2000/12/15 02:44:32 version 1.4, 2000/12/27 10:16:13
Line 1 
Line 1 
 /* $OpenXM: OpenXM/src/k097/lib/restriction/demo.k,v 1.1 2000/12/14 13:18:41 takayama Exp $  */  /* $OpenXM: OpenXM/src/k097/lib/restriction/demo.k,v 1.3 2000/12/27 08:09:27 takayama Exp $  */
   
 load["restriction.k"];;  load["restriction.k"];;
 load("../ox/ox.k");;  load("../ox/ox.k");;
Line 8  def demoSendAsirCommand(a) {
Line 8  def demoSendAsirCommand(a) {
   a.executeString(" def myann(F) { B=ann(eval_str(F)); print(B); return(map(dp_ptod,B,[hoge,x,y,z,s,hh,ee,dx,dy,dz,ds,dhh])); }; ");    a.executeString(" def myann(F) { B=ann(eval_str(F)); print(B); return(map(dp_ptod,B,[hoge,x,y,z,s,hh,ee,dx,dy,dz,ds,dhh])); }; ");
   a.executeString(" def myann0(F) { B=ann0(eval_str(F)); print(B); return(map(dp_ptod,B[1],[hoge,x,y,z,s,hh,ee,dx,dy,dz,ds,dhh])); }; ");    a.executeString(" def myann0(F) { B=ann0(eval_str(F)); print(B); return(map(dp_ptod,B[1],[hoge,x,y,z,s,hh,ee,dx,dy,dz,ds,dhh])); }; ");
   a.executeString(" def mybfct(F) { return(rtostr(bfct(eval_str(F)))); }; ");    a.executeString(" def mybfct(F) { return(rtostr(bfct(eval_str(F)))); }; ");
     a.executeString(" def mygeneric_bfct(F,VV,DD,WW) { print([F,VV,DD,WW]); return(generic_bfct(F,VV,DD,WW));}; ");
 }  }
   
 as = startAsir();  as = startAsir();
Line 32  def asirAnnfsXYZ(a,f) {
Line 33  def asirAnnfsXYZ(a,f) {
   return(b);    return(b);
 }  }
   
   
   def asir_generic_bfct(a,ii,vv,dd,ww) {
      local ans;
      ans = a.rpc_str("mygeneric_bfct",[ii,vv,dd,ww]);
      return(ans);
   }
   /* a=startAsir();
      asir_generic_bfct(a,[Dx^2+Dy^2-1,Dx*Dy-4],[x,y],[Dx,Dy],[1,1]): */
   
   /* usage: misc/tmp/complex-ja.texi */
   def changeRing(F) {
     local n,i,f;
     if (IsArray(F)) {
       n = Length(F);
       for (i=0; i<n; i++) {
         if (IsArray(F[i])) {
            if (changeRing(F)) return(true);
         }else if (IsPolynomial(F[i])) {
            if (F[i] != Poly("0")) {
               f = F[i];
               sm1(" f (ring) dc ring_def ");
               return(true);
            }
         }
       }
     }else if (IsPolynomial(F)) {
        if (F != Poly("0")) {
           sm1(" F (ring) dc ring_def ");
           return(true);
        }
     }
     return(false);
   }
   
   def asir_BfRoots2(G) {
      local bb,ans,ss;
      sm1(" G flatten {dehomogenize} map /G set ");
      changeRing(G);
      ss = asir_generic_bfct(asssssir,G,[x,y],[Dx,Dy],[1,1]);
      bb = [ss];
      sm1(" bb 0 get findIntegralRoots { (universalNumber) dc } map /ans set ");
      return([ans, bb]);
   }
   def asir_BfRoots3(G) {
      local bb,ans,ss;
      sm1(" G flatten {dehomogenize} map /G set ");
      changeRing(G);
      ss = asir_generic_bfct(asssssir,G,[x,y,z],[Dx,Dy,Dz],[1,1,1]);
      bb = [ss];
      sm1(" bb 0 get findIntegralRoots { (universalNumber) dc } map /ans set ");
      return([ans, bb]);
   }
   
 def findMinSol(f) {  def findMinSol(f) {
   sm1(" f (string) dc findIntegralRoots 0 get (universalNumber) dc /FunctionValue set ");    sm1(" f (string) dc findIntegralRoots 0 get (universalNumber) dc /FunctionValue set ");
 }  }
Line 67  def nonquasi2(p,q) {
Line 121  def nonquasi2(p,q) {
   Res = Sminimal(pp);    Res = Sminimal(pp);
   Res0 = Res[0];    Res0 = Res[0];
   Println("Step2: (-1,1)-minimal resolution (Res0) "); sm1_pmat(Res0);    Println("Step2: (-1,1)-minimal resolution (Res0) "); sm1_pmat(Res0);
   R = BfRoots1(Res0[0],"x,y");  /*  R = BfRoots1(Res0[0],"x,y"); */
     R = asir_BfRoots2(Res0[0]);
   Println("Step3: computing the cohomology of the truncated complex.");    Println("Step3: computing the cohomology of the truncated complex.");
   Print("Roots and b-function are "); Println(R);    Print("Roots and b-function are "); Println(R);
   R0 = R[0];    R0 = R[0];
Line 96  def DeRham2WithAsir(f) {
Line 151  def DeRham2WithAsir(f) {
   Res = Sminimal(pp);    Res = Sminimal(pp);
   Res0 = Res[0];    Res0 = Res[0];
   Print("Step2: (-1,1)-minimal resolution (Res0) "); sm1_pmat(Res0);    Print("Step2: (-1,1)-minimal resolution (Res0) "); sm1_pmat(Res0);
   R = BfRoots1(Res0[0],"x,y");    /* R = BfRoots1(Res0[0],"x,y"); */
     R = asir_BfRoots2(Res0[0]);
   Println("Step3: computing the cohomology of the truncated complex.");    Println("Step3: computing the cohomology of the truncated complex.");
   Print("Roots and b-function are "); Println(R);    Print("Roots and b-function are "); Println(R);
   R0 = R[0];    R0 = R[0];
Line 115  def DeRham3WithAsir(f) {
Line 171  def DeRham3WithAsir(f) {
   Res = Sminimal(pp);    Res = Sminimal(pp);
   Res0 = Res[0];    Res0 = Res[0];
   Print("Step2: (-1,1)-minimal resolution (Res0) "); sm1_pmat(Res0);    Print("Step2: (-1,1)-minimal resolution (Res0) "); sm1_pmat(Res0);
   R = BfRoots1(Res0[0],"x,y,z");    /* R = BfRoots1(Res0[0],"x,y,z");  */
     R = asir_BfRoots3(Res0[0]);
   Println("Step3: computing the cohomology of the truncated complex.");    Println("Step3: computing the cohomology of the truncated complex.");
   Print("Roots and b-function are "); Println(R);    Print("Roots and b-function are "); Println(R);
   R0 = R[0];    R0 = R[0];

Legend:
Removed from v.1.2  
changed lines
  Added in v.1.4

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>