My Project
Loading...
Searching...
No Matches
Public Member Functions | Protected Attributes
Evaluation Class Reference

class to evaluate a polynomial at points More...

#include <cf_eval.h>

Public Member Functions

 Evaluation ()
 
 Evaluation (int min0, int max0)
 
 Evaluation (const Evaluation &e)
 
virtual ~Evaluation ()
 
Evaluationoperator= (const Evaluation &e)
 
int min () const
 
int max () const
 
CanonicalForm operator[] (int i) const
 
CanonicalForm operator[] (const Variable &v) const
 
CanonicalForm operator() (const CanonicalForm &f) const
 
CanonicalForm operator() (const CanonicalForm &f, int i, int j) const
 
void setValue (int i, const CanonicalForm &f)
 
virtual void nextpoint ()
 

Protected Attributes

CFArray values
 

Detailed Description

class to evaluate a polynomial at points

Definition at line 31 of file cf_eval.h.

Constructor & Destructor Documentation

◆ Evaluation() [1/3]

Evaluation::Evaluation ( )
inline

Definition at line 36 of file cf_eval.h.

36: values() {}
CFArray values
Definition: cf_eval.h:34

◆ Evaluation() [2/3]

Evaluation::Evaluation ( int  min0,
int  max0 
)
inline

Definition at line 37 of file cf_eval.h.

37: values( min0, max0 ) {}

◆ Evaluation() [3/3]

Evaluation::Evaluation ( const Evaluation e)
inline

Definition at line 38 of file cf_eval.h.

38: values( e.values ) {}

◆ ~Evaluation()

virtual Evaluation::~Evaluation ( )
inlinevirtual

Definition at line 39 of file cf_eval.h.

39{}

Member Function Documentation

◆ max()

int Evaluation::max ( ) const
inline

Definition at line 42 of file cf_eval.h.

42{ return values.max(); }
int max() const
Definition: ftmpl_array.cc:104

◆ min()

int Evaluation::min ( ) const
inline

Definition at line 41 of file cf_eval.h.

41{ return values.min(); }
int min() const
Definition: ftmpl_array.cc:98

◆ nextpoint()

void Evaluation::nextpoint ( )
virtual

Reimplemented in REvaluation.

Definition at line 43 of file cf_eval.cc.

44{
45 int n = values.max();
46 for ( int i = values.min(); i <= n; i++ )
47 values[i] += 1;
48}
int i
Definition: cfEzgcd.cc:132

◆ operator()() [1/2]

CanonicalForm Evaluation::operator() ( const CanonicalForm f) const

Definition at line 24 of file cf_eval.cc.

25{
26 if ( f.inCoeffDomain() || f.level() < values.min() )
27 return f;
28 else if ( f.level() < values.max() )
29 return evalCF( f, values, values.min(), f.level() );
30 else
31 return evalCF( f, values, values.min(), values.max() );
32}
static CanonicalForm evalCF(const CanonicalForm &f, const CFArray &a, int m, int n)
Definition: cf_eval.cc:68
FILE * f
Definition: checklibs.c:9

◆ operator()() [2/2]

CanonicalForm Evaluation::operator() ( const CanonicalForm f,
int  i,
int  j 
) const

Definition at line 35 of file cf_eval.cc.

36{
37 if ( i > j )
38 return f;
39 return evalCF( f, values, i, j );
40}
int j
Definition: facHensel.cc:110

◆ operator=()

Evaluation & Evaluation::operator= ( const Evaluation e)

Definition at line 15 of file cf_eval.cc.

16{
17 if ( this != &e ) {
18 values = e.values;
19 }
20 return *this;
21}

◆ operator[]() [1/2]

CanonicalForm Evaluation::operator[] ( const Variable v) const
inline

Definition at line 44 of file cf_eval.h.

44{ return operator[](v.level()); }
CanonicalForm operator[](int i) const
Definition: cf_eval.h:43
int level() const
Definition: variable.h:49
const Variable & v
< [in] a sqrfree bivariate poly
Definition: facBivar.h:39

◆ operator[]() [2/2]

CanonicalForm Evaluation::operator[] ( int  i) const
inline

Definition at line 43 of file cf_eval.h.

43{ return values[i]; }

◆ setValue()

void Evaluation::setValue ( int  i,
const CanonicalForm f 
)

Definition at line 51 of file cf_eval.cc.

52{
53 if (i < values.min() || i > values.max())
54 return;
55 values[i]= f;
56}

Field Documentation

◆ values

CFArray Evaluation::values
protected

Definition at line 34 of file cf_eval.h.


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