MCPcopy Create free account
hub / github.com/Singular/Singular / extEarlyFactorDetection

Function extEarlyFactorDetection

factory/facFqBivar.cc:984–1081  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

982}
983
984void
985extEarlyFactorDetection (CFList& reconstructedFactors, CanonicalForm& F, CFList&
986 factors,int& adaptedLiftBound, int*& factorsFoundIndex,
987 DegreePattern& degs, bool& success, const
988 ExtensionInfo& info, const CanonicalForm& eval, int deg
989 )
990{
991 Variable alpha= info.getAlpha();
992 Variable beta= info.getBeta();
993 CanonicalForm gamma= info.getGamma();
994 CanonicalForm delta= info.getDelta();
995 int k= info.getGFDegree();
996 DegreePattern bufDegs1= degs, bufDegs2;
997 CFList result;
998 CFList T= factors;
999 Variable y= F.mvar();
1000 Variable x= Variable (1);
1001 CanonicalForm buf= F, LCBuf= LC (buf, x), g, buf2;
1002 CanonicalForm M= power (y, deg);
1003 adaptedLiftBound= 0;
1004 bool trueFactor= false;
1005 int d= degree (F), l= 0;
1006 CFList source, dest;
1007 int degMipoBeta= 1;
1008 if (!k && beta.level() != 1)
1009 degMipoBeta= degree (getMipo (beta));
1010 CanonicalForm quot;
1011 for (CFListIterator i= factors; i.hasItem(); i++, l++)
1012 {
1013 if (!bufDegs1.find (degree (i.getItem(), 1)) || factorsFoundIndex[l] == 1)
1014 continue;
1015 else
1016 {
1017 g= mulMod2 (i.getItem(), LCBuf, M);
1018 g /= content (g, x);
1019 if (fdivides (g, buf, quot))
1020 {
1021 buf2= g (y - eval, y);
1022 buf2 /= Lc (buf2);
1023
1024 if (!k && beta == x)
1025 {
1026 if (degree (buf2, alpha) < degMipoBeta)
1027 {
1028 appendTestMapDown (reconstructedFactors, buf2, info, source, dest);
1029 factorsFoundIndex[l]= 1;
1030 buf= quot;
1031 d -= degree (g);
1032 LCBuf= LC (buf, x);
1033 trueFactor= true;
1034 }
1035 }
1036 else
1037 {
1038 if (!isInExtension (buf2, gamma, k, delta, source, dest))
1039 {
1040 appendTestMapDown (reconstructedFactors, buf2, info, source, dest);
1041 factorsFoundIndex[l]= 1;

Callers 2

henselLiftAndEarlyFunction · 0.85
extSieveSmallFactorsFunction · 0.85

Calls 15

VariableFunction · 0.85
LCFunction · 0.85
powerFunction · 0.85
degreeFunction · 0.85
getMipoFunction · 0.85
mulMod2Function · 0.85
contentFunction · 0.85
fdividesFunction · 0.85
LcFunction · 0.85
appendTestMapDownFunction · 0.85
isInExtensionFunction · 0.85
DifferenceFunction · 0.85

Tested by

no test coverage detected