carl  24.04
Computer ARithmetic Library
carl::Reductor< InputPolynomial, PolynomialInIdeal, Datastructure, Configuration > Class Template Reference

A dedicated algorithm for calculating the remainder of a polynomial modulo a set of other polynomials. More...

#include <Reductor.h>

Collaboration diagram for carl::Reductor< InputPolynomial, PolynomialInIdeal, Datastructure, Configuration >:

Public Member Functions

 Reductor (const Ideal< PolynomialInIdeal > &ideal, const InputPolynomial &f)
 
 Reductor (const Ideal< PolynomialInIdeal > &ideal, const Term< Coeff > &f)
 
virtual ~Reductor ()=default
 
bool reduce ()
 The basic reduce routine on a priority queue. More...
 
bool reductionOccured ()
 Gets the flag which indicates that a reduction has occurred (p -> p' with p' != p) More...
 
InputPolynomial fullReduce ()
 Uses the ideal to reduce a polynomial as far as possible. More...
 

Protected Types

using Order = typename InputPolynomial::OrderedBy
 
using EntryType = typename Configuration< InputPolynomial >::EntryType
 
using Coeff = typename InputPolynomial::CoeffType
 

Private Member Functions

bool updateDatastruct (EntryType *entry)
 A small routine which updates the underlying data structure for the polynomial which is reduced. More...
 
void insert (const InputPolynomial &g, const Term< Coeff > &fact)
 
void insert (const Term< Coeff > &g)
 

Private Attributes

const Ideal< PolynomialInIdeal > & mIdeal
 
Datastructure< Configuration< InputPolynomial > > mDatastruct
 
std::vector< Term< Coeff > > mRemainder
 
bool mReductionOccured
 
BitVector mReasons
 

Detailed Description

template<typename InputPolynomial, typename PolynomialInIdeal, template< class > class Datastructure = carl::Heap, template< typename Polynomial > class Configuration = ReductorConfiguration>
class carl::Reductor< InputPolynomial, PolynomialInIdeal, Datastructure, Configuration >

A dedicated algorithm for calculating the remainder of a polynomial modulo a set of other polynomials.

Definition at line 68 of file Reductor.h.

Member Typedef Documentation

◆ Coeff

template<typename InputPolynomial , typename PolynomialInIdeal , template< class > class Datastructure = carl::Heap, template< typename Polynomial > class Configuration = ReductorConfiguration>
using carl::Reductor< InputPolynomial, PolynomialInIdeal, Datastructure, Configuration >::Coeff = typename InputPolynomial::CoeffType
protected

Definition at line 74 of file Reductor.h.

◆ EntryType

template<typename InputPolynomial , typename PolynomialInIdeal , template< class > class Datastructure = carl::Heap, template< typename Polynomial > class Configuration = ReductorConfiguration>
using carl::Reductor< InputPolynomial, PolynomialInIdeal, Datastructure, Configuration >::EntryType = typename Configuration<InputPolynomial>::EntryType
protected

Definition at line 73 of file Reductor.h.

◆ Order

template<typename InputPolynomial , typename PolynomialInIdeal , template< class > class Datastructure = carl::Heap, template< typename Polynomial > class Configuration = ReductorConfiguration>
using carl::Reductor< InputPolynomial, PolynomialInIdeal, Datastructure, Configuration >::Order = typename InputPolynomial::OrderedBy
protected

Definition at line 72 of file Reductor.h.

Constructor & Destructor Documentation

◆ Reductor() [1/2]

template<typename InputPolynomial , typename PolynomialInIdeal , template< class > class Datastructure = carl::Heap, template< typename Polynomial > class Configuration = ReductorConfiguration>
carl::Reductor< InputPolynomial, PolynomialInIdeal, Datastructure, Configuration >::Reductor ( const Ideal< PolynomialInIdeal > &  ideal,
const InputPolynomial &  f 
)
inline

Definition at line 82 of file Reductor.h.

Here is the call graph for this function:

◆ Reductor() [2/2]

template<typename InputPolynomial , typename PolynomialInIdeal , template< class > class Datastructure = carl::Heap, template< typename Polynomial > class Configuration = ReductorConfiguration>
carl::Reductor< InputPolynomial, PolynomialInIdeal, Datastructure, Configuration >::Reductor ( const Ideal< PolynomialInIdeal > &  ideal,
const Term< Coeff > &  f 
)
inline

Definition at line 93 of file Reductor.h.

Here is the call graph for this function:

◆ ~Reductor()

template<typename InputPolynomial , typename PolynomialInIdeal , template< class > class Datastructure = carl::Heap, template< typename Polynomial > class Configuration = ReductorConfiguration>
virtual carl::Reductor< InputPolynomial, PolynomialInIdeal, Datastructure, Configuration >::~Reductor ( )
virtualdefault

Member Function Documentation

◆ fullReduce()

template<typename InputPolynomial , typename PolynomialInIdeal , template< class > class Datastructure = carl::Heap, template< typename Polynomial > class Configuration = ReductorConfiguration>
InputPolynomial carl::Reductor< InputPolynomial, PolynomialInIdeal, Datastructure, Configuration >::fullReduce ( )
inline

Uses the ideal to reduce a polynomial as far as possible.

Returns

Definition at line 181 of file Reductor.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ insert() [1/2]

template<typename InputPolynomial , typename PolynomialInIdeal , template< class > class Datastructure = carl::Heap, template< typename Polynomial > class Configuration = ReductorConfiguration>
void carl::Reductor< InputPolynomial, PolynomialInIdeal, Datastructure, Configuration >::insert ( const InputPolynomial &  g,
const Term< Coeff > &  fact 
)
inlineprivate

Definition at line 232 of file Reductor.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ insert() [2/2]

template<typename InputPolynomial , typename PolynomialInIdeal , template< class > class Datastructure = carl::Heap, template< typename Polynomial > class Configuration = ReductorConfiguration>
void carl::Reductor< InputPolynomial, PolynomialInIdeal, Datastructure, Configuration >::insert ( const Term< Coeff > &  g)
inlineprivate

Definition at line 241 of file Reductor.h.

◆ reduce()

template<typename InputPolynomial , typename PolynomialInIdeal , template< class > class Datastructure = carl::Heap, template< typename Polynomial > class Configuration = ReductorConfiguration>
bool carl::Reductor< InputPolynomial, PolynomialInIdeal, Datastructure, Configuration >::reduce ( )
inline

The basic reduce routine on a priority queue.

Returns

Definition at line 105 of file Reductor.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ reductionOccured()

template<typename InputPolynomial , typename PolynomialInIdeal , template< class > class Datastructure = carl::Heap, template< typename Polynomial > class Configuration = ReductorConfiguration>
bool carl::Reductor< InputPolynomial, PolynomialInIdeal, Datastructure, Configuration >::reductionOccured ( )
inline

Gets the flag which indicates that a reduction has occurred (p -> p' with p' != p)

Returns
the value of the flag

Definition at line 172 of file Reductor.h.

◆ updateDatastruct()

template<typename InputPolynomial , typename PolynomialInIdeal , template< class > class Datastructure = carl::Heap, template< typename Polynomial > class Configuration = ReductorConfiguration>
bool carl::Reductor< InputPolynomial, PolynomialInIdeal, Datastructure, Configuration >::updateDatastruct ( EntryType entry)
inlineprivate

A small routine which updates the underlying data structure for the polynomial which is reduced.

Parameters
entry
Returns

Definition at line 214 of file Reductor.h.

Here is the call graph for this function:
Here is the caller graph for this function:

Field Documentation

◆ mDatastruct

template<typename InputPolynomial , typename PolynomialInIdeal , template< class > class Datastructure = carl::Heap, template< typename Polynomial > class Configuration = ReductorConfiguration>
Datastructure<Configuration<InputPolynomial> > carl::Reductor< InputPolynomial, PolynomialInIdeal, Datastructure, Configuration >::mDatastruct
private

Definition at line 77 of file Reductor.h.

◆ mIdeal

template<typename InputPolynomial , typename PolynomialInIdeal , template< class > class Datastructure = carl::Heap, template< typename Polynomial > class Configuration = ReductorConfiguration>
const Ideal<PolynomialInIdeal>& carl::Reductor< InputPolynomial, PolynomialInIdeal, Datastructure, Configuration >::mIdeal
private

Definition at line 76 of file Reductor.h.

◆ mReasons

template<typename InputPolynomial , typename PolynomialInIdeal , template< class > class Datastructure = carl::Heap, template< typename Polynomial > class Configuration = ReductorConfiguration>
BitVector carl::Reductor< InputPolynomial, PolynomialInIdeal, Datastructure, Configuration >::mReasons
private

Definition at line 80 of file Reductor.h.

◆ mReductionOccured

template<typename InputPolynomial , typename PolynomialInIdeal , template< class > class Datastructure = carl::Heap, template< typename Polynomial > class Configuration = ReductorConfiguration>
bool carl::Reductor< InputPolynomial, PolynomialInIdeal, Datastructure, Configuration >::mReductionOccured
private

Definition at line 79 of file Reductor.h.

◆ mRemainder

template<typename InputPolynomial , typename PolynomialInIdeal , template< class > class Datastructure = carl::Heap, template< typename Polynomial > class Configuration = ReductorConfiguration>
std::vector<Term<Coeff> > carl::Reductor< InputPolynomial, PolynomialInIdeal, Datastructure, Configuration >::mRemainder
private

Definition at line 78 of file Reductor.h.


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