[BACK]Return to contiguity CVS log [TXT][DIR] Up to [local] / OpenXM / src / asir-contrib / packages / sample

Annotation of OpenXM/src/asir-contrib/packages/sample/contiguity, Revision 1.3

1.3     ! takayama    1: /* $OpenXM: OpenXM/src/asir-contrib/packages/sample/contiguity,v 1.2 2000/01/22 11:20:00 takayama Exp $ */
1.1       takayama    2:
                      3: /* contiguity */
                      4:
                      5: def contiguity_param_only(F) {
                      6:    if (deg(F,x) != 0) return(0);
                      7:    if (deg(F,y) != 0) return(0);
                      8:    if (deg(F,dx) != 0) return(0);
                      9:    if (deg(F,dy) != 0) return(0);
                     10:    return(F);
                     11: }
                     12:
                     13: def contiguity_eliminated(G) {
                     14:    A = map(contiguity_param_only,G);
                     15:    C = [];
                     16:    for (I=0; I<length(A); I++) {
                     17:      if (A[I] != 0) {
                     18:          C = append(C,[A[I]]);
                     19:      }
                     20:    }
                     21:    return(C);
                     22: }
                     23: def contiguity_f4_a_bf() {
                     24:    V = [x,y,a,b,c,cp];
                     25:    W = [[dx,1,dy,1,x,1,y,1]];
1.3     ! takayama   26:    F = [x*dx+y*dy+a,
        !            27:         sm1_mul(dx,x*dx+c-1,V)-sm1_mul(x*dx+y*dy+a,x*dx+y*dy+b,V),
        !            28:         sm1_mul(dy,y*dy+cp-1,V)-sm1_mul(x*dx+y*dy+a,x*dx+y*dy+b,V)];
        !            29:    G = sm1_gb([F,V,W]);
1.1       takayama   30:    G = G[0];
                     31:    B = contiguity_eliminated(G);
                     32:    print("b-function for HG is ",0);
                     33:    print(map(fctr,B));
                     34:    return(map(fctr,B));
                     35: }
                     36:
                     37: def contiguity_f4_a() {
                     38:    V = [x,y,a,b,c,cp];
                     39:    W = [[dx,1,dy,1,x,1,y,1]];
1.3     ! takayama   40:    F = [x*dx+y*dy+a,
        !            41:         sm1_mul(dx,x*dx+c-1,V)-sm1_mul(x*dx+y*dy+a,x*dx+y*dy+b,V),
        !            42:         sm1_mul(dy,y*dy+cp-1,V)-sm1_mul(x*dx+y*dy+a,x*dx+y*dy+b,V)];
1.1       takayama   43:    G = sm1_syz([F,V,W]);
                     44:
                     45:    Gb = map(first,G[1][0]);
                     46:    C  = G[1][1];
                     47:    Ans = [ ];
                     48:    for (I=0; I<length(Gb); I++) {
                     49:      if (contiguity_param_only(Gb[I]) != 0) {
                     50:         Ans = append(Ans,[ [Gb[I],C[I][0]] ]);
1.3     ! takayama   51:         /* print(sm1_mul(C[I],F,[x,y,a,b,c,cp])); */ /* check ! */
1.1       takayama   52:      }
                     53:    }
                     54:    return(Ans);
                     55: }
                     56:
                     57:
                     58:
                     59: end$
                     60:
                     61:

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