=================================================================== RCS file: /home/cvs/OpenXM_contrib2/asir2000/builtin/array.c,v retrieving revision 1.10 retrieving revision 1.14 diff -u -p -r1.10 -r1.14 --- OpenXM_contrib2/asir2000/builtin/array.c 2000/11/13 01:48:12 1.10 +++ OpenXM_contrib2/asir2000/builtin/array.c 2001/09/04 05:14:03 1.14 @@ -45,7 +45,7 @@ * DEVELOPER SHALL HAVE NO LIABILITY IN CONNECTION WITH THE USE, * PERFORMANCE OR NON-PERFORMANCE OF THE SOFTWARE. * - * $OpenXM: OpenXM_contrib2/asir2000/builtin/array.c,v 1.9 2000/11/08 08:02:49 noro Exp $ + * $OpenXM: OpenXM_contrib2/asir2000/builtin/array.c,v 1.13 2001/06/07 05:14:48 noro Exp $ */ #include "ca.h" #include "base.h" @@ -57,7 +57,7 @@ #define DMAR(a1,a2,a3,d,r) (r)=dmar(a1,a2,a3,d); #endif -extern int Print; /* XXX */ +extern int DP_Print; /* XXX */ void inner_product_mat_int_mod(Q **,int **,int,int,int,Q *); void solve_by_lu_mod(int **,int,int,int **,int); @@ -90,6 +90,7 @@ void Px962_irredpoly_up2(); void Pirredpoly_up2(); void Pnbpoly_up2(); void Pqsort(); +void Pexponent_vector(); struct ftab array_tab[] = { {"solve_by_lu_gfmmat",Psolve_by_lu_gfmmat,4}, @@ -97,7 +98,10 @@ struct ftab array_tab[] = { {"mat_to_gfmmat",Pmat_to_gfmmat,2}, {"generic_gauss_elim_mod",Pgeneric_gauss_elim_mod,2}, {"newvect",Pnewvect,-2}, + {"vector",Pnewvect,-2}, + {"exponent_vector",Pexponent_vector,-99999999}, {"newmat",Pnewmat,-3}, + {"matrix",Pnewmat,-3}, {"newbytearray",Pnewbytearray,-2}, {"sepmat_destructive",Psepmat_destructive,2}, {"sepvect",Psepvect,2}, @@ -376,6 +380,13 @@ VECT *rp; *rp = vect; } +void Pexponent_vector(arg,rp) +NODE arg; +DP *rp; +{ + nodetod(arg,rp); +} + void Pnewbytearray(arg,rp) NODE arg; BYTEARRAY *rp; @@ -805,10 +816,10 @@ int **rindp,**cindp; colstat = (int *)MALLOC_ATOMIC(col*sizeof(int)); wcolstat = (int *)MALLOC_ATOMIC(col*sizeof(int)); for ( ind = 0; ; ind++ ) { - if ( Print ) { + if ( DP_Print ) { fprintf(asir_out,"."); fflush(asir_out); } - md = lprime[ind]; + md = get_lprime(ind); get_eg(&tmp0); for ( i = 0; i < row; i++ ) for ( j = 0, bmi = bmat[i], wmi = wmat[i]; j < col; j++ ) @@ -842,13 +853,13 @@ RESET: } } else { if ( rank < rank0 ) { - if ( Print ) { + if ( DP_Print ) { fprintf(asir_out,"lower rank matrix; continuing...\n"); fflush(asir_out); } continue; } else if ( rank > rank0 ) { - if ( Print ) { + if ( DP_Print ) { fprintf(asir_out,"higher rank matrix; resetting...\n"); fflush(asir_out); } @@ -856,7 +867,7 @@ RESET: } else { for ( j = 0; (j