[SCM] an open source computer algebra system branch, cleanedupstream, updated. 6125e540ca6d66c307958938a9d53b245507c323
Bernhard R. Link
brlink at debian.org
Tue Apr 24 15:54:53 UTC 2012
The following commit has been merged in the cleanedupstream branch:
commit 07948421a538efed6693e5f81ace9b1b04a002ca
Author: Martin Lee <martinlee84 at web.de>
Date: Thu Feb 16 15:43:29 2012 +0100
chg: added coeff bounds to Hensel lifting routines
added coeff bounds to henselLiftAndEarly
diff --git a/factory/facFqBivar.cc b/factory/facFqBivar.cc
index 543c475..ed36b72 100644
--- a/factory/facFqBivar.cc
+++ b/factory/facFqBivar.cc
@@ -448,7 +448,7 @@ extFactorRecombination (CFList& factors, CanonicalForm& F,
CFList
factorRecombination (CFList& factors, CanonicalForm& F,
const CanonicalForm& N, DegreePattern& degs, int s,
- int thres
+ int thres, const modpk& b
)
{
if (factors.length() == 0)
@@ -637,7 +637,8 @@ Variable chooseExtension (const Variable & alpha, const Variable& beta, int k)
void
earlyFactorDetection (CFList& reconstructedFactors, CanonicalForm& F, CFList&
factors, int& adaptedLiftBound, int*& factorsFoundIndex,
- DegreePattern& degs, bool& success, int deg)
+ DegreePattern& degs, bool& success, int deg,
+ const modpk& b)
{
DegreePattern bufDegs1= degs;
DegreePattern bufDegs2;
@@ -858,7 +859,7 @@ CFList
henselLiftAndEarly (CanonicalForm& A, bool& earlySuccess, CFList&
earlyFactors, DegreePattern& degs, int& liftBound,
const CFList& uniFactors, const ExtensionInfo& info,
- const CanonicalForm& eval)
+ const CanonicalForm& eval, const modpk& b)
{
Variable alpha= info.getAlpha();
Variable beta= info.getBeta();
diff --git a/factory/facFqBivar.h b/factory/facFqBivar.h
index 741b5c6..46ec50f 100644
--- a/factory/facFqBivar.h
+++ b/factory/facFqBivar.h
@@ -645,10 +645,11 @@ factorRecombination (
DegreePattern& degs, ///< [in] degree pattern
int s, ///< [in] algorithm starts checking
///< subsets of size s
- int thres ///< [in] threshold for the size of
+ int thres, ///< [in] threshold for the size of
///< subsets which are checked, for a
///< full factor recombination choose
///< thres= factors.length()/2
+ const modpk& b=modpk() ///< [in] coeff bound
);
/// chooses a field extension.
@@ -693,7 +694,8 @@ earlyFactorDetection (
DegreePattern& degs, ///< [in,out] degree pattern, is updated
///< whenever we find a factor
bool& success, ///< [in,out] indicating success
- int deg ///< [in] stage of Hensel lifting
+ int deg, ///< [in] stage of Hensel lifting
+ const modpk& b= modpk() ///< [in] coeff bound
);
/// detects factors of @a F at stage @a deg of Hensel lifting.
@@ -740,7 +742,8 @@ henselLiftAndEarly (
int& liftBound, ///< [in,out] (adapted) lift bound
const CFList& uniFactors, ///< [in] univariate factors
const ExtensionInfo& info, ///< [in] information about extension
- const CanonicalForm& eval ///< [in] evaluation point
+ const CanonicalForm& eval, ///< [in] evaluation point
+ const modpk& b= modpk() ///< [in] coeff bound
);
/// Factorization over an extension of initial field
diff --git a/factory/facHensel.cc b/factory/facHensel.cc
index 974cd55..46578f1 100644
--- a/factory/facHensel.cc
+++ b/factory/facHensel.cc
@@ -602,7 +602,7 @@ henselStep12 (const CanonicalForm& F, const CFList& factors,
void
henselLift12 (const CanonicalForm& F, CFList& factors, int l, CFArray& Pi,
- CFList& diophant, CFMatrix& M, bool sort)
+ CFList& diophant, CFMatrix& M, bool sort, const modpk& b)
{
if (sort)
sortList (factors, Variable (1));
@@ -642,7 +642,8 @@ henselLift12 (const CanonicalForm& F, CFList& factors, int l, CFArray& Pi,
void
henselLiftResume12 (const CanonicalForm& F, CFList& factors, int start, int
- end, CFArray& Pi, const CFList& diophant, CFMatrix& M)
+ end, CFArray& Pi, const CFList& diophant, CFMatrix& M,
+ const modpk& b)
{
CFArray bufFactors= CFArray (factors.length());
int i= 0;
diff --git a/factory/facHensel.h b/factory/facHensel.h
index 7cf857c..0095649 100644
--- a/factory/facHensel.h
+++ b/factory/facHensel.h
@@ -22,6 +22,7 @@
#include "timing.h"
#include "canonicalform.h"
+#include "fac_util.h"
/// sort a list of polynomials by their degree in @a x.
///
@@ -43,8 +44,9 @@ henselLift12 (const CanonicalForm& F, ///< [in] compressed, bivariate poly
CFArray& Pi, ///< [in,out] stores intermediate results
CFList& diophant, ///< [in,out] result of diophantine()
CFMatrix& M, ///< [in,out] stores intermediate results
- bool sort= true ///< [in] sort factors by degree in
+ bool sort= true, ///< [in] sort factors by degree in
///< Variable(1)
+ const modpk& b= modpk ()///< [in] coeff bound
);
/// resume Hensel lift from univariate to bivariate. Assumes factors are lifted
@@ -64,8 +66,9 @@ henselLiftResume12 (const CanonicalForm& F, ///< [in] compressed, bivariate poly
CFArray& Pi, ///< [in,out] stores intermediate
///< results
const CFList& diophant, ///< [in] result of diophantine
- CFMatrix& M ///< [in,out] stores intermediate
+ CFMatrix& M, ///< [in,out] stores intermediate
///< results
+ const modpk& b= modpk() ///< [in] coeff bound
);
/// Hensel lifting from bivariate to trivariate.
--
an open source computer algebra system
More information about the debian-science-commits
mailing list