Changeset 227efd in git
- Timestamp:
- Jun 16, 2010, 5:58:04 PM (13 years ago)
- Branches:
- (u'spielwiese', '0d6b7fcd9813a1ca1ed4220cfa2b104b97a0a003')
- Children:
- 0eb229de7f102c905e5f2b8497a9a524f8ede977
- Parents:
- 584cbc74b85aa9f5b4e31e70416327028b017132
- git-author:
- Hans Schoenemann <hannes@mathematik.uni-kl.de>2010-06-16 17:58:04+02:00
- git-committer:
- Mohamed Barakat <mohamed.barakat@rwth-aachen.de>2011-11-09 11:55:11+01:00
- Location:
- coeffs
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
coeffs/Makefile.in
r584cbc r227efd 35 35 CXXTEMPLFLAGS = -fno-implicit-templates --no-exceptions 36 36 CPPFLAGS = -I${srcdir} -I${includedir} -I${srcdir}/../misc/ -I${srcdir}/../resource/ -I${srcdir}/../reporter/ -L${srcdir}/../reporter/ -L${libdir} -lgmp 37 DEFS = -D ix86_Linux -DHAVE_CONFIG_H -DLDEBUG -DDEBUG -DOM_DEBUG -DHAVE_ASSUME37 DEFS = -DNDEBUG -DOM_NDEBUG @DEFS@ 38 38 39 39 #-DHAVE_RINGS … … 75 75 ar cr $@ $^ 76 76 77 ## ---------------------------------------------------------------------------- 78 ## debug version: 79 FLAGSG = -g ${PIPE} 80 CXXFLAGSG = -g ${PIPE} 81 DEFSG = @DEFS@ 82 83 CCG = ${CC} 84 CXXG = ${CXX} 85 OBJSG1 := $(CXXSOURCES:.cc=.og) 86 87 libcoeffs_g.a: ${OBJSG1} 88 -rm -f libcoeffs_g.a 89 ar cr $@ $^ 90 91 %.og: %.cc 92 $(CXXG) ${CXXFLAGSG} ${CXXTEMPLFLAGS} ${CPPFLAGS} ${DEFSG} -c $< -o $@ 93 77 94 ## 78 95 ## clean targest … … 90 107 ctags *.c *.h *.cc *.inc 91 108 92 all: libcoeffs.a 109 all: libcoeffs.a libcoeffs_g.a 93 110 94 111 install: all … … 96 113 ${MKINSTALLDIRS} ${libdir} 97 114 ${INSTALL_DATA} libcoeffs.a ${libdir}/libcoeffs.a 115 ${INSTALL_DATA} libcoeffs_g.a ${libdir}/libcoeffs_g.a 98 116 $(INSTALL_DATA) coeffs.h $(includedir)/coeffs.h 99 117 -
coeffs/coeffs.h
r584cbc r227efd 10 10 11 11 #include <auxiliary.h> 12 /* for assume: */ 13 #include <reporter.h> 12 14 #include <si_gmp.h> 13 15 … … 39 41 #endif 40 42 41 // and the routines w.r.t. currRing: 43 // the access methods (part 1) (see also part2 below): 44 // 45 // the routines w.r.t. currRing: 42 46 // (should only be used in the context of currRing, i.e. in the interpreter) 43 47 #define nCopy(n) n_Copy(n, currRing->cf) … … 218 222 inline void nSetChar(coeffs r) 219 223 { 220 if ((r!=NULL) && (r->cfSetChar!=NULL)) r->cfSetChar(r); 224 assume(r!=NULL); // r==NULL is an error 225 if (r->cfSetChar!=NULL) r->cfSetChar(r); 221 226 } 222 227 … … 226 231 227 232 228 // the access methods :233 // the access methods (part 2): 229 234 230 235 /// return a copy of a … … 232 237 static inline void n_Delete(number* p, const coeffs r){ return (r)->cfDelete(p, r); } 233 238 234 static inline BOOLEAN n_ AreEqual(number a, number b, const coeffs r){ return (r)->cfEqual(a, b, r); }239 static inline BOOLEAN n_Equal(number a, number b, const coeffs r){ return (r)->cfEqual(a, b, r); } 235 240 static inline BOOLEAN n_IsZero(number n, const coeffs r){ return (r)->cfIsZero(n,r); } 236 241 static inline BOOLEAN n_IsOne(number n, const coeffs r){ return (r)->cfIsOne(n,r); } 237 242 static inline BOOLEAN n_IsMOne(number n, const coeffs r){ return (r)->cfIsMOne(n,r); } 238 static inline BOOLEAN n_ IsGreaterZero(number n, const coeffs r){ return (r)->cfGreaterZero(n,r); }243 static inline BOOLEAN n_GreaterZero(number n, const coeffs r){ return (r)->cfGreaterZero(n,r); } 239 244 // cfGreater? 240 245 … … 248 253 static inline number n_Invers(number a, const coeffs r){ return (r)->cfInvers(a,r); } 249 254 250 /// how complicated, (0) => 0, otherwise positive255 /// use for pivot strategies, (0) => 0, otherwise positive 251 256 static inline int n_Size(number n, const coeffs r){ return (r)->cfSize(n,r); } 252 257 … … 254 259 static inline void n_Normalize(number& n, const coeffs r){ return (r)->cfNormalize(n,r); } 255 260 256 /// Normalize and Write 261 /// Normalize and Write to the output buffer of reporter 257 262 static inline void n_Write(number& n, const coeffs r){ return (r)->cfWrite(n,r); } 258 263 … … 267 272 268 273 static inline number n_Mult(number a, number b, const coeffs r){ return (r)->cfMult(a, b, r); } 274 269 275 /// Inplace multiplication: a := a * b 270 276 static inline void n_InpMult(number &a, number b, const coeffs r){ return (r)->cfInpMult(a,b,r); } … … 279 285 static inline number n_Gcd(number a, number b, const coeffs r){ return (r)->cfGcd(a,b,r); } 280 286 281 /// Tests whether n is a correct number. 287 #ifdef LDEBUG 288 /// Tests whether n is a correct number: only used if LDEBUG is defined 282 289 static inline BOOLEAN n_DBTest(number n, const char *filename, const int linenumber, const coeffs r) 283 290 { 284 #ifdef LDEBUG285 291 return (r)->cfDBTest(n, filename, linenumber, r); 286 #else287 return TRUE;288 #endif289 292 } 290 293 /// BOOLEAN n_Test(number a, const coeffs r) 291 294 #define n_Test(a,r) n_DBTest(a, __FILE__, __LINE__, r) 295 #else 296 #define n_Test(a,r) (1) 297 #endif 292 298 293 299 // Missing wrappers for: … … 297 303 298 304 // Deprecated: 299 static inline BOOLEAN n_GreaterZero(number n, const coeffs r){ return n_IsGreaterZero(n,r); }300 static inline BOOLEAN n_Equal(number a, number b, const coeffs r){ return n_AreEqual(a, b, r); }301 302 // Deprecated:303 305 static inline int n_GetChar(const coeffs r){ return nInternalChar(r); } 304 306
Note: See TracChangeset
for help on using the changeset viewer.