Basic Polynomial Algebra Subprograms (BPAS)  v. 1.652
SmallPrimeFieldDistributedDenseMultivariateModularPolynomial Class Reference

A multivariate polynomial with coefficients in a small prime field using a dense representation. More...

`#include <sdmpolynomial.h>`

Simplified semantic inheritance diagram for SmallPrimeFieldDistributedDenseMultivariateModularPolynomial:
Full inheritance diagram for SmallPrimeFieldDistributedDenseMultivariateModularPolynomial:
[legend]

## Public Member Functions

SmallPrimeFieldDistributedDenseMultivariateModularPolynomial ()
Constructor using a default prime.

SmallPrimeFieldDistributedDenseMultivariateModularPolynomial (sfixn m)
Constructor with the field. More...

SmallPrimeFieldDistributedDenseMultivariateModularPolynomial (int v, int *ds, sfixn m)
Constructor with number of variables and terms. More...

SmallPrimeFieldDistributedDenseMultivariateModularPolynomial (Symbol x, sfixn m)
Construct with a variable name such that f(x) = x;. More...

SmallPrimeFieldDistributedDenseMultivariateModularPolynomial (const SmallPrimeFieldDistributedDenseMultivariateModularPolynomial &b)
Copy constructor. More...

~SmallPrimeFieldDistributedDenseMultivariateModularPolynomial ()
Deconstructor. More...

SmallPrimeFieldDistributedDenseMultivariateModularPolynomialoperator= (const SmallPrimeFieldDistributedDenseMultivariateModularPolynomial &b)

SmallPrimeFieldDistributedDenseMultivariateModularPolynomialoperator= (const sfixn &b)

bool isZero () const
Is a zero polynomial. More...

void zero ()
Zero polynomial. More...

bool isOne () const
Is polynomial 1. More...

void one ()
Set polynomial to 1. More...

bool isNegativeOne () const
Is polynomial -1. More...

void negativeOne ()
Set polynomial to -1. More...

int isConstant () const
Is a constant. More...

SmallPrimeFieldDistributedDenseMultivariateModularPolynomial unitCanonical (SmallPrimeFieldDistributedDenseMultivariateModularPolynomial *u=NULL, SmallPrimeFieldDistributedDenseMultivariateModularPolynomial *v=NULL) const
Obtain the unit normal (a.k.a canonical associate) of an element. More...

int numberOfVariables () const
Get the number of variables. More...

int numberOfRingVariables () const
Get the number of variables in this polynomial ring.

Integer numberOfTerms () const
Get the number of non-zero terms. More...

int size () const
Get the size of the polynomial. More...

Integer degree () const
Total degree.

Integer degree (const Symbol &x) const
Get a partial degree of variable x. More...

sfixn trailingCoefficient () const

bool isConstantTermZero () const

sfixn coefficient (int v, const int *d) const
Get a coefficient. More...

sfixn coefficient (const std::vector< int > &v) const

void setCoefficient (int v, const int *d, const sfixn &val)
Set a coefficient. More...

void setCoefficient (const std::vector< int > &v, const sfixn &val)

void setCoefficient (int k, const sfixn &val)
Set a coefficient. More...

std::vector< SymbolringVariables () const
Get variable names. More...

void setRingVariables (const std::vector< Symbol > &xs)
Set variable names. More...

std::vector< Symbolvariables () const

void differentiate (const Symbol &s, int k)
Convert current object to its k-th derivative. More...

void differentiate (const Symbol &s)
Convert current object to its derivative. More...

SmallPrimeFieldDistributedDenseMultivariateModularPolynomial derivative (const Symbol &s, int k) const
Return k-th derivative. More...

SmallPrimeFieldDistributedDenseMultivariateModularPolynomial derivative (const Symbol &s) const
Compute derivative. More...

SmallPrimeFieldDistributedDenseMultivariateModularPolynomial evaluate (int, const Symbol *syms, const sfixn *xs) const
Evaluate f(x) More...

SmallPrimeFieldDistributedDenseMultivariateModularPolynomial evaluate (const std::vector< Symbol > &syms, const std::vector< sfixn > &xs) const
Evaluate f(x) More...

bool operator== (const SmallPrimeFieldDistributedDenseMultivariateModularPolynomial &b) const

bool operator!= (const SmallPrimeFieldDistributedDenseMultivariateModularPolynomial &b) const

SmallPrimeFieldDistributedDenseMultivariateModularPolynomial operator+ (const SmallPrimeFieldDistributedDenseMultivariateModularPolynomial &b) const

SmallPrimeFieldDistributedDenseMultivariateModularPolynomialoperator+= (const SmallPrimeFieldDistributedDenseMultivariateModularPolynomial &b)

SmallPrimeFieldDistributedDenseMultivariateModularPolynomial operator+ (const sfixn &e) const

SmallPrimeFieldDistributedDenseMultivariateModularPolynomialoperator+= (const sfixn &e)

SmallPrimeFieldDistributedDenseMultivariateModularPolynomial operator- (const SmallPrimeFieldDistributedDenseMultivariateModularPolynomial &b) const

SmallPrimeFieldDistributedDenseMultivariateModularPolynomialoperator-= (const SmallPrimeFieldDistributedDenseMultivariateModularPolynomial &b)

SmallPrimeFieldDistributedDenseMultivariateModularPolynomial operator- (const sfixn &e) const

SmallPrimeFieldDistributedDenseMultivariateModularPolynomialoperator-= (const sfixn &e)

SmallPrimeFieldDistributedDenseMultivariateModularPolynomial operator- () const

void negate ()
Negate, f(-x) More...

SmallPrimeFieldDistributedDenseMultivariateModularPolynomial operator* (const SmallPrimeFieldDistributedDenseMultivariateModularPolynomial &b) const

SmallPrimeFieldDistributedDenseMultivariateModularPolynomialoperator*= (const SmallPrimeFieldDistributedDenseMultivariateModularPolynomial &b)

SmallPrimeFieldDistributedDenseMultivariateModularPolynomial operator* (const sfixn &e) const

SmallPrimeFieldDistributedDenseMultivariateModularPolynomialoperator*= (const sfixn &e)

SmallPrimeFieldDistributedDenseMultivariateModularPolynomial operator^ (long long int e) const

SmallPrimeFieldDistributedDenseMultivariateModularPolynomialoperator^= (long long int e)

SmallPrimeFieldDistributedDenseMultivariateModularPolynomial operator/ (const sfixn &e) const

SmallPrimeFieldDistributedDenseMultivariateModularPolynomialoperator/= (const sfixn &e)

sfixn content () const

SmallPrimeFieldDistributedDenseMultivariateModularPolynomial primitivePart () const

void print (std::ostream &out) const
Print the Ring element. More...

ExpressionTree convertToExpressionTree () const
Convert *this to an expression tree. More...

SmallPrimeFieldDistributedDenseMultivariateModularPolynomial operator/ (const SmallPrimeFieldDistributedDenseMultivariateModularPolynomial &p) const
Exact division.

SmallPrimeFieldDistributedDenseMultivariateModularPolynomialoperator/= (const SmallPrimeFieldDistributedDenseMultivariateModularPolynomial &p)
Exact division assignment.

SmallPrimeFieldDistributedDenseMultivariateModularPolynomial gcd (const SmallPrimeFieldDistributedDenseMultivariateModularPolynomial &p) const
Get GCD of *this and other.

Factors< SmallPrimeFieldDistributedDenseMultivariateModularPolynomialsquareFree () const
Compute squarefree factorization of *this.

## Static Public Attributes

static mpz_class characteristic

static RingProperties properties

## Friends

SmallPrimeFieldDistributedDenseMultivariateModularPolynomial operator+ (const sfixn &e, const SmallPrimeFieldDistributedDenseMultivariateModularPolynomial &f)

SmallPrimeFieldDistributedDenseMultivariateModularPolynomial operator- (const sfixn &e, const SmallPrimeFieldDistributedDenseMultivariateModularPolynomial &r)

SmallPrimeFieldDistributedDenseMultivariateModularPolynomial operator* (const sfixn &e, const SmallPrimeFieldDistributedDenseMultivariateModularPolynomial &f)

## Detailed Description

A multivariate polynomial with coefficients in a small prime field using a dense representation.

## ◆ SmallPrimeFieldDistributedDenseMultivariateModularPolynomial() [1/4]

 SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::SmallPrimeFieldDistributedDenseMultivariateModularPolynomial ( sfixn m )
inline

Constructor with the field.

Parameters
 m The prime

## ◆ SmallPrimeFieldDistributedDenseMultivariateModularPolynomial() [2/4]

 SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::SmallPrimeFieldDistributedDenseMultivariateModularPolynomial ( int v, int * ds, sfixn m )
inline

Constructor with number of variables and terms.

Parameters
 v Number of variables ds Partial degrees m The prime

## ◆ SmallPrimeFieldDistributedDenseMultivariateModularPolynomial() [3/4]

 SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::SmallPrimeFieldDistributedDenseMultivariateModularPolynomial ( Symbol x, sfixn m )
inline

Construct with a variable name such that f(x) = x;.

Parameters
 x The variable name m The prime

## ◆ SmallPrimeFieldDistributedDenseMultivariateModularPolynomial() [4/4]

 SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::SmallPrimeFieldDistributedDenseMultivariateModularPolynomial ( const SmallPrimeFieldDistributedDenseMultivariateModularPolynomial & b )
inline

Copy constructor.

Parameters
 b A multivariate modular polynomial

## ◆ ~SmallPrimeFieldDistributedDenseMultivariateModularPolynomial()

 SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::~SmallPrimeFieldDistributedDenseMultivariateModularPolynomial ( )
inline

Deconstructor.

Parameters

## ◆ coefficient()

 sfixn SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::coefficient ( int v, const int * d ) const
inlinevirtual

Get a coefficient.

Parameters
 v Number of variables d The exponent of each variable

## ◆ convertToExpressionTree()

 ExpressionTree SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::convertToExpressionTree ( ) const
virtual

Convert *this to an expression tree.

Implements ExpressionTreeConvert.

## ◆ degree()

 Integer SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::degree ( const Symbol & x ) const
inlinevirtual

Get a partial degree of variable x.

Parameters
 x The variable name

## ◆ derivative() [1/2]

 SmallPrimeFieldDistributedDenseMultivariateModularPolynomial SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::derivative ( const Symbol & s, int k ) const
inlinevirtual

Return k-th derivative.

Parameters
 s Symbol to differentiate with respect to k Order of the k-th derivative, k > 0

## ◆ derivative() [2/2]

 SmallPrimeFieldDistributedDenseMultivariateModularPolynomial SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::derivative ( const Symbol & s ) const
inlinevirtual

Compute derivative.

Parameters
 s Symbol to differentiate with respect to

## ◆ differentiate() [1/2]

 void SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::differentiate ( const Symbol & s, int k )
inlinevirtual

Convert current object to its k-th derivative.

Parameters
 s Symbol to differentiate with respect to k Order of the derivative, k > 0

## ◆ differentiate() [2/2]

 void SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::differentiate ( const Symbol & s )
inlinevirtual

Convert current object to its derivative.

Parameters
 s Symbol to differentiate with respect to

## ◆ evaluate() [1/2]

 SmallPrimeFieldDistributedDenseMultivariateModularPolynomial SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::evaluate ( int , const Symbol * syms, const sfixn * xs ) const
inlinevirtual

Evaluate f(x)

Parameters
 syms Array of Symbols to evaluate at corresponding xs xs Evaluation points

## ◆ evaluate() [2/2]

 SmallPrimeFieldDistributedDenseMultivariateModularPolynomial SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::evaluate ( const std::vector< Symbol > & syms, const std::vector< sfixn > & xs ) const
inlinevirtual

Evaluate f(x)

Parameters
 syms Vector of Symbols to evaluate at corresponding xs xs Corresponding evaluation points

## ◆ isConstant()

 int SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::isConstant ( ) const
inline

Is a constant.

Parameters

## ◆ isNegativeOne()

 bool SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::isNegativeOne ( ) const
inline

Is polynomial -1.

Parameters

## ◆ isOne()

 bool SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::isOne ( ) const
inlinevirtual

Is polynomial 1.

Parameters

## ◆ isZero()

 bool SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::isZero ( ) const
inlinevirtual

Is a zero polynomial.

Parameters

inline

Parameters

## ◆ negate()

 void SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::negate ( )

Negate, f(-x)

Parameters

## ◆ negativeOne()

 void SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::negativeOne ( )
inline

Set polynomial to -1.

Parameters

## ◆ numberOfTerms()

 Integer SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::numberOfTerms ( ) const
inline

Get the number of non-zero terms.

Parameters

## ◆ numberOfVariables()

 int SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::numberOfVariables ( ) const
inlinevirtual

Get the number of variables.

Parameters

## ◆ one()

 void SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::one ( )
inlinevirtual

Set polynomial to 1.

Parameters

## ◆ operator!=()

 bool SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::operator!= ( const SmallPrimeFieldDistributedDenseMultivariateModularPolynomial & b ) const
inlinevirtual

Parameters
 b A multivariate modular polynomial

## ◆ operator*() [1/2]

 SmallPrimeFieldDistributedDenseMultivariateModularPolynomial SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::operator* ( const SmallPrimeFieldDistributedDenseMultivariateModularPolynomial & b ) const
virtual

Parameters
 b A multivariate modular polynomial

## ◆ operator*() [2/2]

 SmallPrimeFieldDistributedDenseMultivariateModularPolynomial SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::operator* ( const sfixn & e ) const
inline

Parameters
 e A constant

## ◆ operator*=() [1/2]

 SmallPrimeFieldDistributedDenseMultivariateModularPolynomial& SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::operator*= ( const SmallPrimeFieldDistributedDenseMultivariateModularPolynomial & b )
inlinevirtual

Parameters
 b A multivariate modular polynomial

## ◆ operator*=() [2/2]

 SmallPrimeFieldDistributedDenseMultivariateModularPolynomial& SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::operator*= ( const sfixn & e )

Parameters
 e A constant

## ◆ operator+() [1/2]

 SmallPrimeFieldDistributedDenseMultivariateModularPolynomial SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::operator+ ( const SmallPrimeFieldDistributedDenseMultivariateModularPolynomial & b ) const
virtual

Parameters
 b A multivariate modular polynomial

## ◆ operator+() [2/2]

 SmallPrimeFieldDistributedDenseMultivariateModularPolynomial SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::operator+ ( const sfixn & e ) const
inline

Parameters
 e A constant

## ◆ operator+=() [1/2]

 SmallPrimeFieldDistributedDenseMultivariateModularPolynomial& SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::operator+= ( const SmallPrimeFieldDistributedDenseMultivariateModularPolynomial & b )
inlinevirtual

Parameters
 b A multivariate modular polynomial

## ◆ operator+=() [2/2]

 SmallPrimeFieldDistributedDenseMultivariateModularPolynomial& SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::operator+= ( const sfixn & e )

Parameters
 e A constant

## ◆ operator-() [1/3]

 SmallPrimeFieldDistributedDenseMultivariateModularPolynomial SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::operator- ( const SmallPrimeFieldDistributedDenseMultivariateModularPolynomial & b ) const
virtual

Parameters
 b A multivariate modular polynomial

## ◆ operator-() [2/3]

 SmallPrimeFieldDistributedDenseMultivariateModularPolynomial SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::operator- ( const sfixn & e ) const
inline

Parameters
 e A constant

## ◆ operator-() [3/3]

 SmallPrimeFieldDistributedDenseMultivariateModularPolynomial SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::operator- ( ) const
virtual

Parameters

## ◆ operator-=() [1/2]

 SmallPrimeFieldDistributedDenseMultivariateModularPolynomial& SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::operator-= ( const SmallPrimeFieldDistributedDenseMultivariateModularPolynomial & b )
inlinevirtual

Parameters
 b A multivariate modular polynomial

## ◆ operator-=() [2/2]

 SmallPrimeFieldDistributedDenseMultivariateModularPolynomial& SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::operator-= ( const sfixn & e )

Parameters
 e A constant

## ◆ operator=()

 SmallPrimeFieldDistributedDenseMultivariateModularPolynomial& SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::operator= ( const SmallPrimeFieldDistributedDenseMultivariateModularPolynomial & b )
inlinevirtual

Parameters
 b A multivariate modular polynomial

## ◆ operator==()

 bool SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::operator== ( const SmallPrimeFieldDistributedDenseMultivariateModularPolynomial & b ) const
virtual

Parameters
 b A multivariate modular polynomial

## ◆ print()

 void SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::print ( std::ostream & ostream ) const
virtual

Print the Ring element.

Derived classes may override this to get custom printing that may be more expressive (and prettier) than expression tree printing.

Reimplemented from BPASRing< SmallPrimeFieldDistributedDenseMultivariateModularPolynomial >.

## ◆ ringVariables()

 std::vector SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::ringVariables ( ) const
inlinevirtual

Get variable names.

Parameters

## ◆ setCoefficient() [1/2]

 void SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::setCoefficient ( int v, const int * d, const sfixn & val )
inlinevirtual

Set a coefficient.

Parameters
 v Number of variables d The exponent of each variable val Value of the coefficient

## ◆ setCoefficient() [2/2]

 void SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::setCoefficient ( int k, const sfixn & val )
inline

Set a coefficient.

Parameters
 k The offset in the coefficient array val Value of the coefficient

## ◆ setRingVariables()

 void SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::setRingVariables ( const std::vector< Symbol > & xs )
inlinevirtual

Set variable names.

Parameters
 xs Variable names

## ◆ size()

 int SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::size ( ) const
inline

Get the size of the polynomial.

Parameters

## ◆ unitCanonical()

 SmallPrimeFieldDistributedDenseMultivariateModularPolynomial SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::unitCanonical ( SmallPrimeFieldDistributedDenseMultivariateModularPolynomial * u = `NULL`, SmallPrimeFieldDistributedDenseMultivariateModularPolynomial * v = `NULL` ) const
inlinevirtual

Obtain the unit normal (a.k.a canonical associate) of an element.

If either parameters u, v, are non-NULL then the units are returned such that b = ua, v = u^-1. Where b is the unit normal of a, and is the returned value.

## ◆ zero()

 void SmallPrimeFieldDistributedDenseMultivariateModularPolynomial::zero ( )
inlinevirtual

Zero polynomial.

Parameters

The documentation for this class was generated from the following file: