Changeset 23f3c87 in git


Ignore:
Timestamp:
Jun 2, 2014, 12:18:15 PM (10 years ago)
Author:
Martin Lee <martinlee84@…>
Branches:
(u'spielwiese', 'fe61d9c35bf7c61f2b6cbf1b56e25e2f08d536cc')
Children:
6e4bb02f0a7a82f90f9ed86e463736bad0637b46
Parents:
3056723f8ded0bf113146118e3fddcb035d965b2
git-author:
Martin Lee <martinlee84@web.de>2014-06-02 12:18:15+02:00
git-committer:
Martin Lee <martinlee84@web.de>2014-06-04 11:54:57+02:00
Message:
chg: refactor SteelTrager
File:
1 edited

Legend:

Unmodified
Added
Removed
  • factory/facAlgFunc.cc

    r305672 r23f3c87  
    599599}
    600600
    601 /// algorithm of A. Steel described in "Conquering Inseparability: Primary
    602 /// decomposition and multivariate factorization over algebraic function fields
    603 /// of positive characteristic" with the following modifications: we use
    604 /// characteristic sets in IdealOverSubfield and Trager's primitive element
    605 /// algorithm instead of FGLM
    606 CFFList
    607 SteelTrager (const CanonicalForm & f, const CFList & AS)
     601
     602/// map elements in AS into a PIE L and record where the variables are mapped to
     603/// in varsMapLevel, i.e varsMapLevel contains a list of pairs of variables
     604/// $v_i$ and integers $e_i$ such that
     605/// $L=K(\sqrt[p^{e_1}]{v_1}, \ldots, \sqrt[p^{e_n}]{v_n})$
     606CFList
     607mapIntoPIE (CFFList& varsMapLevel, CanonicalForm& lcmVars, const CFList & AS)
    608608{
    609   CanonicalForm F= f, lcmVars= 1;
     609  CanonicalForm varsG;
     610  int j, exp= 0, tmpExp;
     611  bool recurse= false;
    610612  CFList asnew, as= AS;
    611   CFListIterator i, ii;
    612 
    613   bool derivZeroF= false;
    614   int j, exp=0, expF= 0, tmpExp;
    615   CFFList varsMapLevel;
     613  CFListIterator i= as, ii;
     614  CFFList varsGMapLevel, tmp;
    616615  CFFListIterator iter;
    617 
    618   // check if F is separable
    619   if (F.deriv().isZero())
    620   {
    621     derivZeroF= true;
    622     deflateDegree (F, expF, F.level());
    623   }
    624 
    625   CanonicalForm varsF= getVars (F);
    626   varsF /= F.mvar();
    627 
    628   lcmVars= lcm (varsF, lcmVars);
    629 
    630   if (derivZeroF)
    631     as.append (F);
    632 
    633   CFFList varsGMapLevel;
    634   CFFList tmp;
    635616  CFFList * varsGMap= new CFFList [as.length()];
    636617  for (j= 0; j < as.length(); j++)
    637618    varsGMap[j]= CFFList();
    638 
    639   CanonicalForm varsG;
    640619  j= 0;
    641   bool recurse= false;
    642   i= as;
    643   // make minimal polys and F separable
    644620  while (i.hasItem())
    645621  {
     
    648624      deflateDegree (i.getItem(), exp, i.getItem().level());
    649625      i.getItem()= deflatePoly (i.getItem(), exp, i.getItem().level());
    650      
     626
    651627      varsG= getVars (i.getItem());
    652628      varsG /= i.getItem().mvar();
     
    750726  }
    751727
    752   // compute how to map variables in F
    753728  for (j= 0; j < as.length(); j++)
    754729  {
     
    771746  delete [] varsGMap;
    772747
     748  return asnew;
     749}
     750
     751/// algorithm of A. Steel described in "Conquering Inseparability: Primary
     752/// decomposition and multivariate factorization over algebraic function fields
     753/// of positive characteristic" with the following modifications: we use
     754/// characteristic sets in IdealOverSubfield and Trager's primitive element
     755/// algorithm instead of FGLM
     756CFFList
     757SteelTrager (const CanonicalForm & f, const CFList & AS)
     758{
     759  CanonicalForm F= f, lcmVars= 1;
     760  CFList asnew, as= AS;
     761  CFListIterator i, ii;
     762
     763  bool derivZeroF= false;
     764  int j, expF= 0, tmpExp;
     765  CFFList varsMapLevel, tmp;
     766  CFFListIterator iter;
     767
     768  // check if F is separable
     769  if (F.deriv().isZero())
     770  {
     771    derivZeroF= true;
     772    deflateDegree (F, expF, F.level());
     773  }
     774
     775  CanonicalForm varsF= getVars (F);
     776  varsF /= F.mvar();
     777
     778  lcmVars= lcm (varsF, lcmVars);
     779
    773780  if (derivZeroF)
    774   {
    775     as.removeLast();
     781    as.append (F);
     782
     783  asnew= mapIntoPIE (varsMapLevel, lcmVars, as);
     784
     785  if (derivZeroF)
     786  {
    776787    asnew.removeLast();
    777788    F= deflatePoly (F, expF, F.level());
Note: See TracChangeset for help on using the changeset viewer.