Changeset 098f98f in git
- Timestamp:
- Jan 6, 2010, 3:55:03 PM (13 years ago)
- Branches:
- (u'spielwiese', '828514cf6e480e4bafc26df99217bf2a1ed1ef45')
- Children:
- eaf66fe9969d8b8c2cf369ea94e7616f379a3229
- Parents:
- b46774f2ffde4294abff59d9fdb51d1914924c72
- Location:
- kernel
- Files:
-
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/fglm.h
rb46774 r098f98f 82 82 // if deleteIdeal==FALSE, then nothing happens to sourceIdeal 83 83 BOOLEAN 84 fglmzero( idhdl sourceRingHdl, ideal & sourceIdeal, idhdl destRingHdl, ideal & destideal, BOOLEAN switchBack = TRUE, BOOLEAN deleteIdeal = FALSE );84 fglmzero( ring sourceRing, ideal & sourceIdeal, idhdl destRingHdl, ideal & destideal, BOOLEAN switchBack = TRUE, BOOLEAN deleteIdeal = FALSE ); 85 85 86 86 BOOLEAN -
kernel/fglmzero.cc
rb46774 r098f98f 30 30 #include "omalloc.h" 31 31 #include "kstd1.h" // for kNF (see fglmquot) 32 #include "intvec.h" 32 #include "intvec.h" 33 33 #include "fglm.h" 34 34 #include "fglmvec.h" … … 593 593 void 594 594 internalCalculateFunctionals( const ideal & theIdeal, idealFunctionals & l, 595 595 fglmSdata & data ) 596 596 { 597 597 … … 663 663 static BOOLEAN 664 664 CalculateFunctionals( const ideal & theIdeal, idealFunctionals & l, 665 665 poly & p, fglmVector & v ) 666 666 { 667 667 fglmSdata data( theIdeal ); … … 669 669 // STICKYPROT("Calculating vector rep\n"); 670 670 v = data.getVectorRep( p ); 671 // if ( v.isZero() ) 671 // if ( v.isZero() ) 672 672 // STICKYPROT("vectorrep is 0\n"); 673 673 return ( data.state() ); … … 1019 1019 static ideal 1020 1020 GroebnerViaFunctionals( const idealFunctionals & l, 1021 1021 fglmVector iv = fglmVector() ) 1022 1022 // If iv is zero, calculates the groebnerBasis for the ideal which is 1023 1023 // defined by l. … … 1039 1039 initv = iv; 1040 1040 } 1041 1041 1042 1042 poly one = pOne(); 1043 1043 data.updateCandidates( one, initv ); … … 1104 1104 for(i = pVariables; i > 0; i--) varpermutation[pVariables+1-i] = (*iv)[i-1]; 1105 1105 delete iv; 1106 1106 1107 1107 for (i= 1; i <= pVariables; i++ ) 1108 1108 { … … 1157 1157 // for a descritption of the parameters see fglm.h 1158 1158 BOOLEAN 1159 fglmzero( idhdl sourceRingHdl, ideal & sourceIdeal, idhdl destRingHdl, ideal & destIdeal, BOOLEAN switchBack, BOOLEAN deleteIdeal )1159 fglmzero( ring sourceRing, ideal & sourceIdeal, idhdl destRingHdl, ideal & destIdeal, BOOLEAN switchBack, BOOLEAN deleteIdeal ) 1160 1160 { 1161 1161 idhdl initialRingHdl = currRingHdl; 1162 1162 BOOLEAN fglmok; 1163 1163 1164 if ( currRingHdl != sourceRingHdl ) 1165 rSetHdl( sourceRingHdl ); 1164 if ( currRing != sourceRing ) 1165 { 1166 rChangeCurrRing( sourceRing ); 1167 currRingHdl=NULL; 1168 } 1166 1169 idealFunctionals L( 100, pVariables ); 1167 1170 fglmok = CalculateFunctionals( sourceIdeal, L ); … … 1169 1172 idDelete( & sourceIdeal ); 1170 1173 rSetHdl( destRingHdl ); 1171 if ( fglmok == TRUE ) { 1172 L.map( IDRING( sourceRingHdl ) ); 1174 if ( fglmok == TRUE ) 1175 { 1176 L.map( sourceRing ); 1173 1177 destIdeal= GroebnerViaFunctionals( L ); 1174 1178 } -
kernel/misc.cc
rb46774 r098f98f 57 57 omBin sip_smap_bin = omGetSpecBin(sizeof(sip_smap)); 58 58 omBin sip_sring_bin = omGetSpecBin(sizeof(sip_sring)); 59 omBin ip_sideal_bin = omGetSpecBin(sizeof(ip_sideal));60 omBin ip_sring_bin = omGetSpecBin(sizeof(ip_sring));61 59 62 60 /*0 implementation*/ -
kernel/ring.cc
rb46774 r098f98f 558 558 } 559 559 #endif 560 omFreeBin(r, ip_sring_bin);560 omFreeBin(r, sip_sring_bin); 561 561 } 562 562 … … 1311 1311 } 1312 1312 } 1313 sum=(ring)omAllocBin( ip_sring_bin);1313 sum=(ring)omAllocBin(sip_sring_bin); 1314 1314 memcpy(sum,&tmpR,sizeof(ip_sring)); 1315 1315 rComplete(sum); … … 1538 1538 if (r == NULL) return NULL; 1539 1539 int i,j; 1540 ring res=(ring)omAllocBin( ip_sring_bin);1540 ring res=(ring)omAllocBin(sip_sring_bin); 1541 1541 memset(res,0,sizeof(ip_sring)); 1542 1542 //memcpy4(res,r,sizeof(ip_sring)); … … 2842 2842 return r; 2843 2843 } 2844 ring res=(ring)omAlloc0Bin( ip_sring_bin);2844 ring res=(ring)omAlloc0Bin(sip_sring_bin); 2845 2845 *res = *r; 2846 2846 … … 2945 2945 ring rModifyRing_Wp(ring r, int* weights) 2946 2946 { 2947 ring res=(ring)omAlloc0Bin( ip_sring_bin);2947 ring res=(ring)omAlloc0Bin(sip_sring_bin); 2948 2948 *res = *r; 2949 2949 #ifdef HAVE_PLURAL … … 3019 3019 order[1]=ringorder_C; 3020 3020 } 3021 ring res=(ring)omAlloc0Bin( ip_sring_bin);3021 ring res=(ring)omAlloc0Bin(sip_sring_bin); 3022 3022 *res = *r; 3023 3023 #ifdef HAVE_PLURAL … … 3072 3072 omFree(r->block1); 3073 3073 omFree(r->wvhdl); 3074 omFreeBin(r, ip_sring_bin);3074 omFreeBin(r,sip_sring_bin); 3075 3075 } 3076 3076 … … 3083 3083 omFree(r->wvhdl[0]); 3084 3084 omFree(r->wvhdl); 3085 omFreeBin(r, ip_sring_bin);3085 omFreeBin(r,sip_sring_bin); 3086 3086 } 3087 3087 -
kernel/structs.h
rb46774 r098f98f 899 899 extern struct omBin_s* sip_smap_bin; 900 900 extern struct omBin_s* sip_sring_bin; 901 extern struct omBin_s* ip_sideal_bin;902 extern struct omBin_s* ip_sring_bin;903 901 extern struct omBin_s* sleftv_bin; 904 902 … … 936 934 int id_i; 937 935 938 #define IDNEXT(a) ((a)->next)939 #define IDTYP(a) ((a)->typ)940 #define IDFLAG(a) ((a)->flag)941 #define IDLEV(a) ((a)->lev)942 #define IDID(a) ((a)->id)943 #define IDATTR(a) ((a)->attribute)944 945 #define IDINT(a) ((int)(long)((a)->data.ustring))946 #define IDDATA(a) ((a)->data.ustring)947 #define IDRING(a) ((a)->data.uring)948 #define IDINTVEC(a) ((a)->data.iv)949 #define IDPOLY(a) ((a)->data.p)950 #define IDBIGINT(a) ((a)->data.n)951 #define IDNUMBER(a) ((a)->data.n)952 #define IDIDEAL(a) (((a)->data).uideal)953 #define IDMATRIX(a) (((a)->data).umatrix)954 #define IDMAP(a) (((a)->data).umap)955 #define IDSTRING(a) ((a)->data.ustring)956 #define IDLIST(a) ((a)->data.l)957 #define IDLINK(a) ((a)->data.li)958 #define IDPACKAGE(a) ((a)->data.pack)959 #define IDPROC(a) ((a)->data.pinf)960 961 936 idrec() { memset(this,0,sizeof(*this)); } 962 937 idhdl get(const char * s, int lev); -
kernel/walkProc.cc
rb46774 r098f98f 54 54 55 55 WalkState 56 walkConsistency( idhdl sringHdl, idhdl dringHdl, int * vperm )56 walkConsistency( ring sring, ring dring, int * vperm ) 57 57 { 58 58 int k; 59 59 WalkState state= WalkOk; 60 ring dring = IDRING( dringHdl );61 ring sring = IDRING( sringHdl );62 60 63 61 if ( rChar(sring) != rChar(dring) ) … … 212 210 213 211 WalkState 214 fractalWalkConsistency( idhdl sringHdl, idhdl dringHdl, int * vperm )212 fractalWalkConsistency( ring sring, ring dring, int * vperm ) 215 213 { 216 214 int k; 217 215 WalkState state= WalkOk; 218 ring dring = IDRING( dringHdl );219 ring sring = IDRING( sringHdl );220 216 221 217 if ( rChar(sring) != rChar(dring) ) -
kernel/walkProc.h
rb46774 r098f98f 4 4 ideal walkProc(leftv first, leftv second); 5 5 ideal fractalWalkProc(leftv first, leftv second); 6 WalkState walkConsistency( idhdl sringHdl, idhdl dringHdl, int * vperm );7 WalkState fractalWalkConsistency( idhdl sringHdl, idhdl dringHdl, int * vperm );6 WalkState walkConsistency( ring sring, ring dring, int * vperm ); 7 WalkState fractalWalkConsistency( ring sring, ring dring, int * vperm ); 8 8 #endif 9 9 -
kernel/walkSupport.cc
rb46774 r098f98f 1025 1025 if (r == NULL) return NULL; 1026 1026 int i,j; 1027 ring res=(ring)omAllocBin( ip_sring_bin);1027 ring res=(ring)omAllocBin(sip_sring_bin); 1028 1028 1029 1029 memcpy4(res,r,sizeof(ip_sring));
Note: See TracChangeset
for help on using the changeset viewer.