=================================================================== RCS file: /home/cvs/OpenXM/src/kan96xx/Kan/Kclass/indeterminate.c,v retrieving revision 1.1.1.1 retrieving revision 1.5 diff -u -p -r1.1.1.1 -r1.5 --- OpenXM/src/kan96xx/Kan/Kclass/indeterminate.c 1999/10/08 02:12:02 1.1.1.1 +++ OpenXM/src/kan96xx/Kan/Kclass/indeterminate.c 2001/05/04 01:06:29 1.5 @@ -1,3 +1,4 @@ +/* $OpenXM: OpenXM/src/kan96xx/Kan/Kclass/indeterminate.c,v 1.4 2001/04/12 06:48:27 takayama Exp $ */ /* Kclass/indeterminate.c */ /* This file handles indeterminate, tree, recursivePolynomial, polynomialInOneVariable @@ -138,7 +139,7 @@ struct object addTree(struct object ob1, struct object } rob = newObjectArray(3); putoa(rob,0,KpoString("add")); - putoa(rob,1,KpoString("Basic")); + putoa(rob,1,KpoString("basic")); putoa(rob,2,aob); return(KpoTree(rob)); } @@ -162,7 +163,7 @@ struct object KpoRecursivePolynomial(struct object ob) } static void printBodyOfRecursivePolynomial(struct object body, - struct object vlist, FILE *fp) + struct object vlist, FILE *fp) { int i,j; int k; @@ -181,12 +182,18 @@ static void printBodyOfRecursivePolynomial(struct obj for (j=1; j 1) { - fprintf(fp,"^%d ",k); + fprintf(fp,"^%d ",k); }else if (k == 1) { }else{ - fprintf(fp,"^(%d) ",k); + fprintf(fp,"^(%d) ",k); } fprintf(fp," * "); } @@ -203,7 +210,7 @@ static void printBodyOfRecursivePolynomial(struct obj void fprintRecursivePolynomial(FILE *fp,struct object op) { /* old code - printObject(KopRecursivePolynomial(op),0,fp); return; + printObject(KopRecursivePolynomial(op),0,fp); return; */ struct object ob; struct object vlist; @@ -297,11 +304,11 @@ struct object polyToRecursivePoly(struct object p) { putoa(rob,0,vlist2); putoa(rob,1,ob1); /* format of rob [ list of variables, poly or universalNumber or yyy to express - a recursive polynomial. ] - format of yyy = CLASSNAME_polynomialInOneVariable + a recursive polynomial. ] + format of yyy = CLASSNAME_polynomialInOneVariable [Sinteger, Sinteger, coeff obj, Sinteger, coeff obj, .....] - name of var, exp, coeff, exp, coeff - This format is checked by isRecursivePolynomial2(). + name of var, exp, coeff, exp, coeff + This format is checked by isRecursivePolynomial2(). */ rob = KpoRecursivePolynomial(rob); if (isRecursivePolynomial2(rob)) { @@ -398,9 +405,9 @@ static int isRecursivePolynomial2a(struct object ob2, if (ectag(tmp) == CLASSNAME_polynomialInOneVariable) { if (isRecursivePolynomial2a(tmp,n)) { }else{ - fprintf(stderr,"isRecursivePolynomial2a: entry is not a polynomial in one variable.\n"); - printObject(tmp,0,stderr); fprintf(stderr,"\n"); - return(0); + fprintf(stderr,"isRecursivePolynomial2a: entry is not a polynomial in one variable.\n"); + printObject(tmp,0,stderr); fprintf(stderr,"\n"); + return(0); } } } @@ -434,8 +441,10 @@ int isRecursivePolynomial2(struct object ob) { n = getoaSize(ob1); for (i=0; i