Changeset c92097b in git
- Timestamp:
- Jan 4, 2012, 7:48:21 PM (11 years ago)
- Branches:
- (u'spielwiese', '0d6b7fcd9813a1ca1ed4220cfa2b104b97a0a003')
- Children:
- 4d0cbc73d042b4eff26b590ee72477709df171a3
- Parents:
- 0fc4c8bd0177d4673beebe5a386cd69e4161f080
- git-author:
- Martin Lee <martinlee84@web.de>2012-01-04 19:48:21+01:00
- git-committer:
- Martin Lee <martinlee84@web.de>2012-01-05 12:26:44+01:00
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
Singular/iparith.cc
r0fc4c8 rc92097b 3152 3152 int sw=(int)(long)dummy->Data(); 3153 3153 int fac_sw=sw; 3154 if ( (sw<0)||(sw>2)) fac_sw=1;3154 if (sw<0) fac_sw=1; 3155 3155 singclap_factorize_retry=0; 3156 3156 ideal f=singclap_sqrfree((poly)(u->CopyD()), &v, fac_sw, currRing); -
libpolys/polys/clapsing.cc
r0fc4c8 rc92097b 969 969 { 970 970 res=idInit(1,1); 971 if (with_exps!=1 )971 if (with_exps!=1 && with_exps!=3) 972 972 { 973 973 (*v)=new intvec(1); … … 983 983 int e; 984 984 for(i=rVar(r);i>0;i--) if(p_GetExp(f,i,r)!=0) n++; 985 if (with_exps==0 ) n++; // with coeff985 if (with_exps==0 || with_exps==3) n++; // with coeff 986 986 res=idInit(si_max(n,1),1); 987 987 switch(with_exps) 988 988 { 989 989 case 0: // with coef & exp. 990 res->m[0]=p_NSet(n_Copy(pGetCoeff(f),r->cf),r); 991 // no break 992 case 3: // with coef & exp. 990 993 res->m[0]=p_NSet(n_Copy(pGetCoeff(f),r->cf),r); 991 994 // no break … … 1041 1044 //if (f!=NULL) // already tested at start of routine 1042 1045 number n0=n_Copy(pGetCoeff(f),r->cf); 1043 if (with_exps==0 )1046 if (with_exps==0 || with_exps==3) 1044 1047 N=n_Copy(n0,r->cf); 1045 1048 p_Cleardenom(f, r); … … 1048 1051 NN=n_Div(n0,pGetCoeff(f),r->cf); 1049 1052 n_Delete(&n0,r->cf); 1050 if (with_exps==0 )1053 if (with_exps==0 || with_exps==3) 1051 1054 { 1052 1055 n_Delete(&N,r->cf); … … 1060 1063 { 1061 1064 number n0=n_Copy(pGetCoeff(f),r->cf); 1062 if (with_exps==0 )1065 if (with_exps==0 || with_exps==3) 1063 1066 N=n_Copy(n0,r->cf); 1064 1067 p_Norm(f,r); … … 1066 1069 NN=n_Div(n0,pGetCoeff(f),r->cf); 1067 1070 n_Delete(&n0,r->cf); 1068 if (with_exps==0 )1071 if (with_exps==0 || with_exps==3) 1069 1072 { 1070 1073 n_Delete(&N,r->cf); … … 1132 1135 *v = new intvec( n ); 1133 1136 } 1134 else if (L.getFirst().factor().inCoeffDomain() )1137 else if (L.getFirst().factor().inCoeffDomain() && with_exps!=3) 1135 1138 { 1136 1139 n--; … … 1140 1143 for ( ; J.hasItem(); J++, j++ ) 1141 1144 { 1142 if (with_exps!=1 ) (**v)[j] = J.getItem().exp();1145 if (with_exps!=1 && with_exps!=3) (**v)[j] = J.getItem().exp(); 1143 1146 if (rField_is_Zp(r) || rField_is_Q(r)) 1144 1147 res->m[j] = convFactoryPSingP( J.getItem().factor(),r ); … … 1166 1169 int i=IDELEMS(res)-1; 1167 1170 int stop=1; 1168 if (with_exps!=0 ) stop=0;1171 if (with_exps!=0 || with_exps==3) stop=0; 1169 1172 for(;i>=stop;i--) 1170 1173 { 1171 1174 p_Norm(res->m[i],r); 1172 1175 } 1173 if (with_exps==0 ) p_SetCoeff(res->m[0],old_lead_coeff,r);1176 if (with_exps==0 || with_exps==3) p_SetCoeff(res->m[0],old_lead_coeff,r); 1174 1177 else n_Delete(&old_lead_coeff,r->cf); 1175 1178 }
Note: See TracChangeset
for help on using the changeset viewer.