44 ASSERT(
x.
level() > 0,
"cannot calculate subresultant sequence with respect to algebraic variables" );
51 if (
f.isZero() ||
g.isZero() ) {
57 if (
f.mvar() >
x ||
g.mvar() >
x ) {
58 if (
f.mvar() >
g.mvar() )
78 int j = (
m <= n) ? n :
m-1;
86 if (
m == n &&
j > 0 ) {
90 S[
j-1] =
LC( S[
j],
X ) *
LC( S[
j],
X ) * S[
j+1];
92 }
else if (
m > n &&
j > 0 ) {
98 if (
j > r && r >= 0 )
114 if (
j > r && r >= 0 )
125 for (
j = 0;
j <= S.
max();
j++ ) {
175 ASSERT(
x.
level() > 0,
"cannot calculate resultant with respect to algebraic variables" );
179 if (
f.isZero() ||
g.isZero() )
189 if (
f.mvar() >
x ||
g.mvar() >
x ) {
190 if (
f.mvar() >
g.mvar() )
209 if (
m+n <= 2 ||
m == 0 || n == 0 )
219 if (
m & 1 && n & 1 )
CanonicalForm psr(const CanonicalForm &rr, const CanonicalForm &vv, const Variable &x)
CanonicalForm psr ( const CanonicalForm & f, const CanonicalForm & g, const Variable & x )
declarations of higher level algorithms.
#define ASSERT(expression, message)
CFArray subResChain(const CanonicalForm &f, const CanonicalForm &g, const Variable &x)
CFArray subResChain ( const CanonicalForm & f, const CanonicalForm & g, const Variable & x )
CanonicalForm resultant(const CanonicalForm &f, const CanonicalForm &g, const Variable &x)
CanonicalForm resultant ( const CanonicalForm & f, const CanonicalForm & g, const Variable & x )
static CanonicalForm trivialResultant(const CanonicalForm &f, const CanonicalForm &g, const Variable &x)
static CanonicalForm trivialResultant ( const CanonicalForm & f, const CanonicalForm & g,...
factory's class for variables