cisst-saw
Loading...
Searching...
No Matches
nmrDynAllocPolynomialContainer Class Referenceabstract

#include <nmrDynAllocPolynomialContainer.h>

Inheritance diagram for nmrDynAllocPolynomialContainer:
nmrPolynomialContainer< void * > nmrPolynomialBase nmrStandardPolynomial

Public Types

typedef nmrPolynomialContainer< void * > BaseType
Public Types inherited from nmrPolynomialContainer< void * >
typedef nmrPolynomialBase BaseType
typedef void * TermInfoType
typedef std::pair< nmrPolynomialTermPowerIndex, TermInfoTypeContainerElementType
typedef std::list< ContainerElementTypeTermContainerType
typedef TermContainerType::value_type TermType
typedef TermContainerType::iterator TermIteratorType
typedef TermContainerType::const_iterator TermConstIteratorType
Public Types inherited from nmrPolynomialBase
enum  InsertStatus { INSERT_FAIL = -1 , INSERT_NEW = 0 , INSERT_REPLACE = 1 }
typedef double ValueType
typedef double VariableType
typedef double CoefficientType
typedef nmrPolynomialTermPowerIndex::VariableIndexType VariableIndexType
typedef nmrPolynomialTermPowerIndex::PowerType PowerType
typedef nmrPolynomialTermPowerIndex::MultinomialCoefficientType TermCounterType

Public Member Functions

 nmrDynAllocPolynomialContainer (unsigned int numVariables, unsigned int minDegree, unsigned int maxDegree)
virtual void SerializeTermInfo (std::ostream &output, const TermConstIteratorType &termIterator) const =0
virtual void DeserializeTermInfo (std::istream &input, TermIteratorType &termIterator)=0
Public Member Functions inherited from nmrPolynomialContainer< void * >
 nmrPolynomialContainer (VariableIndexType numVariables, PowerType minDegree, PowerType maxDegree)
virtual ~nmrPolynomialContainer ()
virtual TermCounterType GetNumberOfTerms () const
virtual bool IsEmpty () const
virtual void SetMinDegree (PowerType newMin) CISST_THROW(std
virtual void SetMaxDegree (PowerType newMax) CISST_THROW(std
virtual void FillAllTerms ()
virtual bool IncludesIndex (const nmrPolynomialTermPowerIndex &target) const
virtual TermCounterType GetIndexPosition (const nmrPolynomialTermPowerIndex &term) const
TermIteratorType GetTermIteratorForPosition (TermCounterType position)
TermIteratorType FirstTermIterator ()
TermConstIteratorType FirstTermIterator () const
TermIteratorType EndTermIterator ()
TermConstIteratorType EndTermIterator () const
TermIteratorType FindTerm (const nmrPolynomialTermPowerIndex &target)
TermConstIteratorType FindTerm (const nmrPolynomialTermPowerIndex &target) const
virtual void RemoveTerm (const nmrPolynomialTermPowerIndex &where)
virtual void RemoveTerm (TermIteratorType &where)
virtual void Clear ()
virtual InsertStatus SetCoefficient (const nmrPolynomialTermPowerIndex &where, CoefficientType coefficient)=0
virtual InsertStatus SetCoefficient (TermIteratorType &where, CoefficientType coefficient)=0
virtual CoefficientType GetCoefficient (const TermConstIteratorType &where) const=0
virtual CoefficientType GetCoefficient (const TermIteratorType &where) const=0
virtual void CollectCoefficients (CoefficientType target[]) const
virtual void RestoreCoefficients (const CoefficientType source[])
const nmrPolynomialTermPowerIndexGetTermPowerIndex (const TermConstIteratorType &where) const
const nmrPolynomialTermPowerIndexGetTermPowerIndex (const TermIteratorType &where) const
virtual ValueType EvaluateBasis (const TermConstIteratorType &where, const nmrMultiVariablePowerBasis &variables) const=0
virtual ValueType EvaluateBasis (const TermIteratorType &where, const nmrMultiVariablePowerBasis &variables) const=0
ValueType EvaluateTerm (const TermConstIteratorType &where) const
ValueType EvaluateTerm (const TermIteratorType &where) const
ValueType EvaluateTerm (const TermConstIteratorType &where, const nmrMultiVariablePowerBasis &variables) const
ValueType EvaluateTerm (const TermIteratorType &where, const nmrMultiVariablePowerBasis &variables) const
virtual ValueType Evaluate (const nmrMultiVariablePowerBasis &variables) const
virtual void EvaluateBasisVector (const nmrMultiVariablePowerBasis &variables, ValueType termBaseValues[]) const
virtual ValueType EvaluateForCoefficients (const nmrMultiVariablePowerBasis &variables, const CoefficientType coefficients[]) const
virtual void Scale (CoefficientType scaleFactor)
virtual void AddConstant (CoefficientType shiftAmount)=0
virtual void AddConstantToCoefficients (CoefficientType coefficients[], CoefficientType shiftAmount) const=0
virtual void SerializeRaw (std::ostream &output) const
virtual void DeserializeRaw (std::istream &input)
Public Member Functions inherited from nmrPolynomialBase
 nmrPolynomialBase (VariableIndexType numVariables, PowerType minDegree, PowerType maxDegree)
virtual ~nmrPolynomialBase ()
VariableIndexType GetNumVariables () const
PowerType GetMinDegree () const
PowerType GetMaxDegree () const
TermCounterType GetMaxNumberOfTerms () const
bool CanIncludeIndex (const nmrPolynomialTermPowerIndex &term) const
virtual CoefficientType GetCoefficient (const nmrPolynomialTermPowerIndex &CMN_UNUSED(where)) const
virtual ValueType EvaluateBasis (const nmrPolynomialTermPowerIndex &where, const nmrMultiVariablePowerBasis &variables) const =0
void CISST_DEPRECATED ScaleCoefficients (CoefficientType coefficients[], CoefficientType scaleFactor) const

Additional Inherited Members

Protected Member Functions inherited from nmrPolynomialContainer< void * >
const TermInfoTypeGetTermInfo (const TermConstIteratorType &termIterator) const
TermInfoTypeGetTermInfo (const TermConstIteratorType &termIterator)
Protected Attributes inherited from nmrPolynomialContainer< void * >
TermContainerType Terms
Protected Attributes inherited from nmrPolynomialBase
VariableIndexType NumVariables
PowerType MinDegree
PowerType MaxDegree

Member Typedef Documentation

◆ BaseType

Constructor & Destructor Documentation

◆ nmrDynAllocPolynomialContainer()

nmrDynAllocPolynomialContainer::nmrDynAllocPolynomialContainer ( unsigned int numVariables,
unsigned int minDegree,
unsigned int maxDegree )
inline

Member Function Documentation

◆ DeserializeTermInfo()

virtual void nmrDynAllocPolynomialContainer::DeserializeTermInfo ( std::istream & input,
TermIteratorType & termIterator )
pure virtual

Deserialize and do other necessary initializations for the TermInfoMember associated with the power index of a term. This function should be complementart to SerializeTermInfo.

Parameters
inputthe input deserialization stream
termIteratoran iterator referreing to the term whose contents are being deserialized.

Implements nmrPolynomialContainer< void * >.

Implemented in nmrStandardPolynomial.

◆ SerializeTermInfo()

virtual void nmrDynAllocPolynomialContainer::SerializeTermInfo ( std::ostream & output,
const TermConstIteratorType & termIterator ) const
pure virtual

Serialize the TermInfo member associated with the power index of a term. The implementation of this function is to be specific per TermInfo concrete type, and so it should be overridden in the derived classes. This function is called from SerializeRaw().

Parameters
outputthe output serializetion stream
termIteratoran iterator referring to the term whose contents are being serialized.

Implements nmrPolynomialContainer< void * >.

Implemented in nmrStandardPolynomial.


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