Changeset dc4782 in git for Singular/iparith.cc


Ignore:
Timestamp:
Nov 25, 2013, 4:49:42 PM (10 years ago)
Author:
Hans Schoenemann <hannes@…>
Branches:
(u'spielwiese', 'fe61d9c35bf7c61f2b6cbf1b56e25e2f08d536cc')
Children:
98e588265496a69b639a1e37bf39d39134a6df5f
Parents:
7bb7da5db82ebe13b1923654fb861e84c6c3ec65
Message:
chg: factory/libfac is not optional, removing HAVE_FACTORY/HAVE_LIBFAC
File:
1 edited

Legend:

Unmodified
Added
Removed
  • Singular/iparith.cc

    r7bb7da5 rdc4782  
    6868#include <Singular/linearAlgebra_ip.h>
    6969
    70 #ifdef HAVE_FACTORY
    7170#  include <factory/factory.h>
    7271#  include <polys/clapsing.h>
     
    7473#  include <kernel/fglm.h>
    7574#  include <Singular/fglm.h>
    76 #endif /* HAVE_FACTORY */
    7775
    7876#include <Singular/interpolation.h>
     
    12151213  { /* This means that q != 0 consists of at least two terms.
    12161214       Moreover, currRing is over a field. */
    1217 #ifdef HAVE_FACTORY
    12181215    if(pGetComp(p)==0)
    12191216    {
     
    12531250      res->data=(void *)p;
    12541251    }
    1255 #else /* HAVE_FACTORY */
    1256     WerrorS("division only by a monomial");
    1257     return TRUE;
    1258 #endif /* HAVE_FACTORY */
    12591252  }
    12601253  else
     
    12971290      if (pNext(q)!=NULL)
    12981291      {
    1299       #ifdef HAVE_FACTORY
    13001292        MATELEM(mm,i,j) = singclap_pdivide( MATELEM(m,i,j) ,
    13011293                                           q /*(poly)(v->Data())*/, currRing );
    1302 #else /* HAVE_FACTORY */
    1303         WerrorS("division only by a monomial");
    1304         return TRUE;
    1305 #endif /* HAVE_FACTORY */
    13061294      }
    13071295      else
     
    16451633  return FALSE;
    16461634}
    1647 #ifdef HAVE_FACTORY
    16481635static BOOLEAN jjCHINREM_BI(leftv res, leftv u, leftv v)
    16491636{
     
    16691656  return FALSE;
    16701657}
    1671 #endif
    16721658#if 0
    16731659static BOOLEAN jjCHINREM_P(leftv res, leftv u, leftv v)
     
    17331719}
    17341720#endif
    1735 #ifdef HAVE_FACTORY
    17361721static BOOLEAN jjCHINREM_ID(leftv res, leftv u, leftv v)
    17371722{
     
    18671852  return FALSE;
    18681853}
    1869 #endif
    18701854static BOOLEAN jjCOEF(leftv res, leftv u, leftv v)
    18711855{
     
    21182102  return FALSE;
    21192103}
    2120 #ifdef HAVE_FACTORY
    21212104static BOOLEAN jjEXTGCD_P(leftv res, leftv u, leftv v)
    21222105{
     
    22052188  return FALSE;
    22062189}
    2207 #endif /* HAVE_FACTORY */
    22082190static BOOLEAN jjFAREY_BI(leftv res, leftv u, leftv v)
    22092191{
     
    23672349static BOOLEAN jjGCD_BI(leftv res, leftv u, leftv v)
    23682350{
    2369 #ifdef HAVE_FACTORY
    23702351  number n1 = (number) u->CopyD();
    23712352  number n2 = (number) v->CopyD();
     
    23772358  res->data = g;
    23782359  return FALSE;
    2379 #else
    2380   number a=(number) u->Data();
    2381   number b=(number) v->Data();
    2382   if (n_IsZero(a,coeffs_BIGINT))
    2383   {
    2384     if (n_IsZero(b,coeffs_BIGINT)) res->data=(char *)n_Init(1,coeffs_BIGINT);
    2385     else                           res->data=(char *)n_Copy(b,coeffs_BIGINT);
    2386   }
    2387   else
    2388   {
    2389     if (n_IsZero(b,coeffs_BIGINT))  res->data=(char *)n_Copy(a,coeffs_BIGINT);
    2390     else res->data=(char *)n_Gcd(a, b, coeffs_BIGINT);
    2391   }
    2392   return FALSE;
    2393 #endif
    23942360}
    23952361static BOOLEAN jjGCD_N(leftv res, leftv u, leftv v)
     
    24092375  return FALSE;
    24102376}
    2411 #ifdef HAVE_FACTORY
    24122377static BOOLEAN jjGCD_P(leftv res, leftv u, leftv v)
    24132378{
     
    24162381  return FALSE;
    24172382}
    2418 #endif /* HAVE_FACTORY */
    24192383static BOOLEAN jjHILBERT2(leftv res, leftv u, leftv v)
    24202384{
     
    33303294  return FALSE;
    33313295}
    3332 #ifdef HAVE_FACTORY
    33333296extern int singclap_factorize_retry;
    33343297static BOOLEAN jjSQR_FREE2(leftv res, leftv u, leftv dummy)
     
    33793342  return FALSE;
    33803343}
    3381 #endif
    33823344static BOOLEAN jjSTATUS2(leftv res, leftv u, leftv v)
    33833345{
     
    38243786  else if (rField_is_Zp_a(r) && (r->cf->type==n_algExt))
    38253787  {
    3826 #ifdef HAVE_FACTORY
    38273788    extern int ipower ( int b, int n ); /* factory/cf_util */
    38283789    elems=ipower(r->cf->ch,r->cf->extRing->pFDeg(r->cf->extRing->qideal->m[0],r->cf->extRing));
    3829 #else
    3830     elems=(int)pow((double) r->cf->ch,(double)r->cf->extRing->pFDeg(r->cf->extRing->qideal->m[0],r->cf->extRing));
    3831 #endif
    38323790  }
    38333791  res->data = (char *)(long)elems;
     
    39203878}
    39213879
    3922 
    3923 
    3924 
    3925 #ifdef HAVE_FACTORY
    39263880static BOOLEAN jjDET(leftv res, leftv v)
    39273881{
     
    39833937  return FALSE;
    39843938}
    3985 #endif
    39863939static BOOLEAN jjDIM(leftv res, leftv v)
    39873940{
     
    40554008  return yyparse();
    40564009}
    4057 #ifdef HAVE_FACTORY
    40584010static BOOLEAN jjFACSTD(leftv res, leftv v)
    40594011{
     
    41124064  return FALSE;
    41134065}
    4114 #endif
    41154066static BOOLEAN jjGETDUMP(leftv, leftv v)
    41164067{
     
    50104961  return FALSE;
    50114962}
    5012 #ifdef HAVE_FACTORY
    50134963static BOOLEAN jjSQR_FREE(leftv res, leftv u)
    50144964{
     
    50274977  return FALSE;
    50284978}
    5029 #endif
    50304979#if 1
    50314980static BOOLEAN jjSYZYGY(leftv res, leftv v)
     
    53575306        case (int)jjidElem:       dArith1[i].p=(proc1)idElem; break;
    53585307        case (int)jjidVec2Ideal:  dArith1[i].p=(proc1)idVec2Ideal; break;
    5359 #ifndef HAVE_FACTORY
    53605308        case (int)jjmpDetBareiss: dArith1[i].p=(proc1)mpDetBareiss; break;
    5361 #endif
    53625309        case (int)jjidFreeModule: dArith1[i].p=(proc1)idFreeModule; break;
    53635310        case (int)jjrCharStr:     dArith1[i].p=(proc1)rCharStr; break;
     
    75367483                                                optional: all 4 optional args
    75377484     (The defaults are xIndex = 1, yIndex = 2, f0 and g0 polynomials as found
    7538       by singclap_factorize in the case that HAVE_FACTORY is defined and h(0, y)
     7485      by singclap_factorize and h(0, y)
    75397486      has exactly two distinct monic factors [possibly with exponent > 1].)
    75407487     result:
     
    76257572  if (factorsGiven == 0)
    76267573  {
    7627 #ifdef HAVE_FACTORY
    76287574    poly h0 = pSubst(pCopy(h), xIndex, NULL);
    76297575    intvec* v = NULL;
     
    76447590    g0 = pPower(pCopy(i->m[2]), (*v)[2]);
    76457591    idDelete(&i);
    7646 #else
    7647     WerrorS("cannot factorize h(0,y) due to missing module 'factory'");
    7648     return TRUE;
    7649 #endif
    76507592  }
    76517593
Note: See TracChangeset for help on using the changeset viewer.