class POLYM_INTI < $IS_LT{POLYM_INTI},$STR


Ancestors
$STR $IS_LT{_} $IS_EQ



Public


Readable Attributes
attr monomials:ARRAY{MONOMIAL{R}}; .. Included as monomials
**** Polynomial is sequence of Monomials.

Writable Attributes
attr monomials:ARRAY{MONOMIAL{R}}; .. Included as monomials
**** Polynomial is sequence of Monomials.

Readonly Shareds
shared divmodForce:BOOL; .. Included as divmodForce
shared r_0:R; .. Included as r_0
shared r_1:R; .. Included as r_1

Writable Shareds
shared divmodForce:BOOL; .. Included as divmodForce
shared r_0:R; .. Included as r_0
shared r_1:R; .. Included as r_1

Features
S_poly(g:SAME):SAME .. Included as S_poly
**** coefficient is field
S_poly_PID(g:SAME):SAME
S_poly_Zp(prime:INTI, g:SAME):SAME
coeff(varId:INT, deg:INT):SAME .. Included as coeff
**** coefficient of degree "deg" as a "var" variable polynomial.
coeff(varName:STR, deg:INT):SAME .. Included as coeff
**** coefficient of degree "deg" as a "var" variable polynomial.
copy:SAME .. Included as copy
create(a:ARRAY{MONOMIAL{R}}):SAME .. Included as create
create(c:R): SAME .. Included as create
create(c:R,x:STR,d:INT):SAME .. Included as create
**** c*x^d
create(m:MONOMIAL{R}):SAME .. Included as create
create(p:SAME):SAME .. Included as create
create(x:STR):SAME .. Included as create
**** 1x^1. assume "x" is var_name
create: SAME .. Included as create
**** 0
derivative(vars:ARRAY{INT}):SAME .. Included as derivative
**** vars is Array of var id
div(other:ARRAY{SAME}):ARRAY{SAME} .. Included as div
div(other:R):SAME .. Included as div
div(other:SAME):SAME .. Included as div
divmod(divisors:ARRAY{SAME}, out q:ARRAY{SAME}, out r:SAME) .. Included as divmod
**** Multiple division.
divmod(divisor:R, out q:SAME, out r:SAME) .. Included as divmod
divmod(divisor:SAME, out q:SAME, out r:SAME) .. Included as divmod
divmod_Zp(prime:INTI,divisors:ARRAY{SAME},out q:ARRAY{SAME},out r:SAME)
**** Do mod(prime) before use this. Multiple division.
divmod_Zp_lt(prime:INTI,divisors:ARRAY{SAME},out q:ARRAY{SAME},out r:SAME)
**** Do mod(prime) before use this. Multiple division.
divmod_lt(divisors:ARRAY{SAME}, out q:ARRAY{SAME}, out r:SAME) .. Included as divmod_lt
**** Multiple division for leading term.
gcd_coeff_num:INTI
**** gcd of numerator of coefficients as Rational
gcd_term:MONOMIAL{R} .. Included as gcd_term
**** gcd of power product of terms
init
integral(vars:ARRAY{INT}):SAME .. Included as integral
**** vars is Array of var id
is_eq(o:SAME):BOOL .. Included as is_eq
.. Included as is_eq
is_lt(o:SAME):BOOL .. Included as is_lt
is_one:BOOL .. Included as is_one
is_unit:BOOL .. Included as is_unit
is_zero:BOOL .. Included as is_zero
lc:R .. Included as lc
**** leading coefficient
lcm_term:MONOMIAL{R} .. Included as lcm_term
**** lcm of power product of terms
lp:MONOMIAL{R} .. Included as lp
**** leading power product
lt:MONOMIAL{R} .. Included as lt
**** leading term
maxdeg(varId:INT):INT .. Included as maxdeg
maxdeg(name:STR):INT .. Included as maxdeg
mindeg(varId:INT):INT .. Included as mindeg
mindeg(name:STR):INT .. Included as mindeg
minus(n:INT):SAME .. Included as minus
minus(other:R):SAME .. Included as minus
minus(other:SAME):SAME .. Included as minus
mod(other:ARRAY{SAME}):SAME .. Included as mod
mod(n:INTI):SAME
mod(other:SAME):SAME .. Included as mod
monomial_sort_func(m1,m2:MONOMIAL{R}):BOOL .. Included as monomial_sort_func
negate:SAME .. Included as negate
normalize:SAME .. Included as normalize
**** remove 0 coefficient and normalize each term
one: SAME .. Included as one
plus(n:INT):SAME .. Included as plus
plus(other:R):SAME .. Included as plus
plus(other:SAME):SAME .. Included as plus
polym_rat:POLYM_RAT
pow(power:INT):SAME .. Included as pow
pow(power:INTI):SAME .. Included as pow
**** calculate expr1^expr2 following to binary notation of "power".
sort .. Included as sort
**** sort decerasing order ">". i.e. higher term is top.sf::=bind(monomial_sort_func(_,_)); monomials.insertion_sort_by(sf);
str(format:STR):STR .. Included as str
str:STR .. Included as str
substitute(list:MAP{INT,SAME}):SAME .. Included as substitute
**** list is Hash of "var id" => val
substitute(nlist:MAP{STR,SAME}):SAME .. Included as substitute
times(n:INT):SAME .. Included as times
times(other:R):SAME .. Included as times
times(other:SAME):SAME .. Included as times
vars:ARRAY{STR} .. Included as vars
**** return var names in the polynomial.
zero: SAME .. Included as zero


Private

plus_merge(other:SAME):SAME .. Included as plus_merge
**** plus Assume self and other are sorted by ">".

The Sather Home Page