Changeset 713bdb in git


Ignore:
Timestamp:
Sep 12, 2008, 12:43:58 PM (15 years ago)
Author:
Hans Schönemann <hannes@…>
Branches:
(u'spielwiese', '0d6b7fcd9813a1ca1ed4220cfa2b104b97a0a003')
Children:
fb0d9aac10ed984cf41f9bd1c5e18752cecc013b
Parents:
cab83807bb068e131a3c656b02a316119e75729c
Message:
*hannes: QGCD


git-svn-id: file:///usr/local/Singular/svn/trunk@11045 2c84dea3-7e68-4137-9b89-c4e89433aadc
Location:
factory
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • factory/algext.cc

    rcab838 r713bdb  
    490490  int *bound, *other; // degree vectors
    491491  bool fail;
     492  bool off_rational=!isOn(SW_RATIONAL);
    492493  On( SW_RATIONAL ); // needed by bCommonDen
    493494  f = F * bCommonDen(F);
     
    510511      tmp = gcd( F, G );
    511512      On( SW_USE_QGCD );
     513      if (off_rational) Off(SW_RATIONAL);
    512514      return tmp;
    513515    }
     
    560562        continue;
    561563      setReduce(a,true);
     564      if (off_rational) Off(SW_RATIONAL); else On(SW_RATIONAL);
    562565      return CanonicalForm(1);
    563566    }
     
    584587        Off( SW_RATIONAL );
    585588        setReduce(a,true);
     589        if (off_rational) Off(SW_RATIONAL); else On(SW_RATIONAL);
    586590        return tmp;
    587591      }
     
    603607  D = gcd( f, g );
    604608  On( SW_USE_QGCD );
     609  if (off_rational) Off(SW_RATIONAL); else On(SW_RATIONAL);
    605610  return D;
    606611}
  • factory/cf_gcd.cc

    rcab838 r713bdb  
    11/* emacs edit mode for this file is -*- C++ -*- */
    2 /* $Id: cf_gcd.cc,v 1.65 2008-08-06 13:53:15 Singular Exp $ */
     2/* $Id: cf_gcd.cc,v 1.66 2008-09-12 10:43:58 Singular Exp $ */
    33
    44#include <config.h>
     
    782782            //  return univarQGCD(f,g);
    783783            //else
    784               return QGCD(f,g);
     784              //return QGCD(f,g);
     785            bool on_rational = isOn(SW_RATIONAL);
     786            On(SW_RATIONAL);
     787            CanonicalForm r=QGCD(f,g);
     788            CanonicalForm cdF = bCommonDen( r );
     789            if (!on_rational) Off(SW_RATIONAL);
     790            return cdF*r;
    785791          }
    786792        }
    787            
     793
    788794        if ( f.inExtension() && getReduce( f.mvar() ) )
    789795            return CanonicalForm(1);
  • factory/cf_switches.cc

    rcab838 r713bdb  
    11/* emacs edit mode for this file is -*- C++ -*- */
    2 /* $Id: cf_switches.cc,v 1.12 2008-06-24 12:54:31 Singular Exp $ */
     2/* $Id: cf_switches.cc,v 1.13 2008-09-12 10:43:58 Singular Exp $ */
    33
    44//{{{ docu
     
    3737  On(SW_USE_EZGCD);
    3838  //On(SW_USE_EZGCD_P); // still testing
    39   //On(SW_USE_QGCD);
     39  On(SW_USE_QGCD);
    4040  //On(SW_USE_fieldGCD);
    4141}
Note: See TracChangeset for help on using the changeset viewer.