Changeset da5d77 in git


Ignore:
Timestamp:
Mar 16, 2012, 9:31:18 PM (12 years ago)
Author:
Oleksandr Motsak <motsak@…>
Branches:
(u'spielwiese', '5b153614cbc72bfa198d75b1e9e33dab2645d9fe')
Children:
bbe9548df00466bc1a7e2d22f1e5662d1f4614fa
Parents:
66b9679c3d696e061e7f06abdc3f5ddf7c9f2991
git-author:
Oleksandr Motsak <motsak@mathematik.uni-kl.de>2012-03-16 21:31:18+01:00
git-committer:
Oleksandr Motsak <motsak@mathematik.uni-kl.de>2012-03-17 18:45:31+01:00
Message:
minor changes to ParDeg

chg: ndParDeg is a static function
add: nfParDef in ffields.cc (GF!)
add: n_ParDeg(ring) wrapper
add: added standard assumes to wrappers for ChineseRemainder, Farey, ParDeg
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • Singular/iparith.cc

    r66b967 rda5d77  
    44464446{
    44474447  number nn=(number)v->Data();
    4448   res->data = (char *)(long)n_ParDeg(nn,currRing->cf);
     4448  res->data = (char *)(long)n_ParDeg(nn, currRing);
    44494449  return FALSE;
    44504450}
  • libpolys/coeffs/coeffs.h

    r66b967 rda5d77  
    630630static inline number n_ChineseRemainder(number *a, number *b, int rl, const coeffs r)
    631631{
    632   assume(r != NULL);
    633   return r->cfChineseRemainder(a,b,rl,r);
     632  assume(r != NULL); assume(r->cfChineseRemainder != NULL); return r->cfChineseRemainder(a,b,rl,r);
    634633}
    635634
    636635static inline number n_Farey(number a, number b, const coeffs r)
    637636{
    638   assume(r != NULL);
    639   return r->cfFarey(a,b,r);
     637  assume(r != NULL); assume(r->cfFarey != NULL); return r->cfFarey(a,b,r);
    640638}
    641639
    642640static inline int n_ParDeg(number n, const coeffs r)
    643641{
    644   assume(r != NULL);
    645   return r->cfParDeg(n,r);
     642  assume(r != NULL); assume(r->cfParDeg != NULL); return r->cfParDeg(n,r);
    646643}
    647644
  • libpolys/coeffs/ffields.cc

    r66b967 rda5d77  
    2828number  nfInit        (long i, const coeffs r);
    2929number  nfParameter   (int i, const coeffs r);
    30 int     nfParDeg      (number n, const coeffs r);
    3130int     nfInt         (number &n, const coeffs r);
    3231number  nfAdd         (number a, number b, const coeffs r);
     
    237236* the degree of the "alg. number"
    238237*/
    239 int nfParDeg(number n, const coeffs r)
     238static int nfParDeg(number n, const coeffs r)
    240239{
    241240#ifdef LDEBUG
     
    884883  // debug stuff
    885884  r->cfCoeffWrite=nfCoeffWrite;
     885   
     886  r->cfParDeg = nfParDeg;
    886887
    887888#ifdef LDEBUG
  • libpolys/coeffs/numbers.cc

    r66b967 rda5d77  
    8787}
    8888
    89 int ndParDeg(number n, const coeffs r)
     89static int ndParDeg(number n, const coeffs r)
    9090{
    9191  return (-n_IsZero(n,r));
  • libpolys/polys/OBSOLETE_pInitContent.cc

    r66b967 rda5d77  
    168168}
    169169
    170 void pSimpleContent(poly ph,int smax)
     170void pSimpleContent(poly ph,int smax) // in currRing!
    171171{
    172172  //if(TEST_OPT_CONTENTSB) return;
     
    228228}
    229229
    230 number pInitContent(poly ph)
     230number pInitContent(poly ph)  // in currRing!
    231231// only for coefficients in Q
    232232#if 0
     
    313313#endif
    314314
    315 number pInitContent_a(poly ph)
     315number pInitContent_a(poly ph) // in currRing!
    316316// only for coefficients in K(a) anf K(a,...)
    317317{
    318318  number d=pGetCoeff(ph);
    319   int s=naParDeg(d);
    320   if (s /* naParDeg(d)*/ <=1) return naCopy(d);
     319  int s=n_ParDeg(d, currRing);
     320  if (s /* n_ParDeg(d, currRing)*/ <=1) return naCopy(d);
    321321  int s2=-1;
    322322  number d2;
     
    330330      break;
    331331    }
    332     if ((ss=naParDeg(pGetCoeff(ph)))<s)
     332    if ((ss=n_ParDeg(pGetCoeff(ph), currRing))<s)
    333333    {
    334334      s2=s;
  • libpolys/polys/coeffrings.h

    r66b967 rda5d77  
    4747#endif
    4848
    49 
     49static inline int n_ParDeg(number n, const ring r){ assume(r != NULL); assume(r->cf != NULL); return n_ParDeg(n,r->cf); }
    5050
    5151#endif /* COEFFRINGS_H */
  • libpolys/polys/ext_fields/algext.cc

    r66b967 rda5d77  
    781781}
    782782
    783 int naParDeg(number a, const coeffs cf)
     783static int naParDeg(number a, const coeffs cf)
    784784{
    785785  if (a == NULL) return -1;
  • libpolys/polys/ext_fields/transext.cc

    r66b967 rda5d77  
    13501350#endif
    13511351
    1352 int ntParDeg(number a, const coeffs cf)
     1352static int ntParDeg(number a, const coeffs cf)
    13531353{
    13541354  if (IS0(a)) return -1;
Note: See TracChangeset for help on using the changeset viewer.