Changeset 8f8b75 in git


Ignore:
Timestamp:
May 11, 2010, 1:53:49 PM (14 years ago)
Author:
Hans Schoenemann <hannes@…>
Branches:
(u'spielwiese', 'fe61d9c35bf7c61f2b6cbf1b56e25e2f08d536cc')
Children:
7a95e9169a993d42f4a8184742b7ffbc5725a115
Parents:
f945d2b0105e7e765829a443b2044990186c9f2e
git-author:
Hans Schoenemann <hannes@mathematik.uni-kl.de>2010-05-11 13:53:49+02:00
git-committer:
Mohamed Barakat <mohamed.barakat@rwth-aachen.de>2011-11-09 11:52:54+01:00
Message:
register new coeffs
Location:
coeffs
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • coeffs/coeffs.h

    rf945d2b r8f8b75  
    4646   coeffs next;
    4747   unsigned int  ringtype;  /* 0 => coefficient field, 1 => coeffs from Z/2^m */
     48
     49   // general properties:
     50   BOOLEAN has_simple_Alloc; /* TRUE, if nNew/nDelete are dummies */
     51   BOOLEAN has_simple_Inverse; /* TRUE, if nInvers is cheap */
     52
     53   // tests for numbers.cc:
     54   BOOLEAN (*nCoeffIsEqual)(const coeffs r, n_coeffType n, int parameter);
    4855
    4956   // the union stuff
  • coeffs/numbers.h

    rf945d2b r8f8b75  
    5252
    5353#define n_New(n, r)           nNew(n)
    54 
    55 /* variables */
    56 extern unsigned short fftable[];
    5754
    5855/* prototypes */
     
    162159
    163160static inline BOOLEAN nField_has_simple_inverse(const coeffs r)
    164 /* { return (r->ch>1) || (r->ch== -1); } *//* Z/p, GF(p,n), R, long_R, long_C*/
    165 #ifdef HAVE_RINGS
    166 { return (r->ringtype > 0) || (r->ch>1) || ((r->ch== -1) && (r->float_len < 10)); } /* Z/2^n, Z/p, GF(p,n), R, long_R, long_C*/
    167 #else
    168 { return (r->ch>1) || ((r->ch== -1) && (r->float_len < 10)); } /* Z/p, GF(p,n), R, long_R, long_C*/
    169 #endif
     161{ return r->has_simple_Inverse; }
     162/* Z/2^n, Z/p, GF(p,n), R, long_R, long_C*/
    170163
    171164static inline BOOLEAN nField_has_simple_Alloc(const coeffs r)
    172 { return (nField_is_Zp(r)
    173        || nField_is_GF(r)
    174 #ifdef HAVE_RINGS
    175        || nField_is_Ring_2toM(r)
    176 #endif
    177        || nField_is_R(r));
    178 }
    179 /* Z/p, GF(p,n), R: nCopy, nNew, nDelete are dummies*/
     165{ return r->has_simple_Alloc; }
     166/* Z/p, GF(p,n), R, Ring_2toM: nCopy, nNew, nDelete are dummies*/
    180167
    181168static inline BOOLEAN nField_is_Extension(const coeffs r)
    182169{ return (nField_is_Q_a(r)) || (nField_is_Zp_a(r)); } /* Z/p(a) and Q(a)*/
    183170
    184 
     171typedef void (*cfInitCharProc)(coeffs, int);
     172n_coeffType nRegister(n_coeffType n, cfInitCharProc p);
    185173
    186174
Note: See TracChangeset for help on using the changeset viewer.