polynomXY< TNum, TIndex > Class Template Reference
[Algebra objectsPolynoms]

class used to store the coefficients of a polynom in (x,y) More...

#include <polynom.h>

Collaboration diagram for polynomXY< TNum, TIndex >:
Collaboration graph
[legend]

List of all members.

Public Types

typedef TNum CoefficientType
 object name

Public Member Functions

Contsructors / Destructors

 polynomXY ()
 polynomXY (const short _maxDegree)
 create a polynom in (x,y). with maximal monom degree = _maxDegree
 polynomXY (string _name, const short _maxDegree)
 create a polynom in (x,y). with maximal monom degree= _maxDegree
 polynomXY (const polynomXY &)
 copy constructor
 ~polynomXY ()
Initialization

void setDegree (short maxDegree)
 reset max possible degree of a contained (x,y)-monom. All data is erased !
void clear (short maxDegree)
void clear ()
Data access

void setCoeff (const short x_exp, const short y_exp, const TNum value)
TNum getCoeff (const short x_exp, const short y_exp) const
TNum const getCoeffConst (const short x_exp, const short y_exp) const
const TNum & getCoeffConstRef (const int x_exp, const int y_exp) const
TNum & getCoeffRef (const short x_exp, const short y_exp)
TNum const * getCoeffConstAddr (const short x_exp, const short y_exp) const
TNum * getCoeffAddr (const short x_exp, const short y_exp)
Properties

short getDegree () const
string getName () const
short getMaxDegree () const
 return max monom degree capacity
Safety

void testBounds (const short x_exp, const short y_exp) const
 Test, if x_exp and y_exp have legal values due do maxDegree !
operators

polynomXYoperator= (const polynomXY &)
 assignment operator
bool operator== (const polynomXY &) const
IO

void OutputPureCoefficients (ostream &datei, int maxDegree, bool mitKomma) const
 output coefficients in monomgroups with equal degree
void output (std::ostream &os) const
void printInMacaulayStyle (std::ostream &os) const
void outputMatrix () const
 print object ( debug)
void print (std::ostream &os) const
 output polynom in Macaulay-Style

Private Member Functions

int getIndex (const short x_exp, const short y_exp) const

Private Attributes

short maxDegree
 max possible degree of a contained (x,y)-monom
short maxDegreePlusOne
TIndex idefs
short size
 monom coefficients count
TNum * koeff
 koeff[x_exp*(maxDegree+1)+y_exp] = value;
string name

Detailed Description

template<class TNum, class TIndex>
class polynomXY< TNum, TIndex >

eventuell auch einen Ring hier speichern, da im Programm nicht allzuviele Polynome verwendet werden. soweit Verallgemeinern, dass die Klasse mit einer getIndex-Fkt parametrisiert werden kann. Dann kannste fast_polynom wegwerfen.

Definition at line 119 of file polynom.h.


Member Typedef Documentation

template<class TNum, class TIndex>
typedef TNum polynomXY< TNum, TIndex >::CoefficientType

Definition at line 134 of file polynom.h.


Constructor & Destructor Documentation

template<class TNum , class TIndex >
polynomXY< TNum, TIndex >::polynomXY (  )  [inline]

Definition at line 10 of file polynom.cpp.

References polynomXY< TNum, TIndex >::name.

template<class TNum , class TIndex >
polynomXY< TNum, TIndex >::polynomXY ( const short  _maxDegree  )  [inline]
template<class TNum , class TIndex >
polynomXY< TNum, TIndex >::polynomXY ( string  _name,
const short  _maxDegree 
) [inline]
template<class TNum , class TIndex >
polynomXY< TNum, TIndex >::polynomXY ( const polynomXY< TNum, TIndex > &  pxy  )  [inline]
template<class TNum , class TIndex >
polynomXY< TNum, TIndex >::~polynomXY (  )  [inline]

Definition at line 172 of file polynom.cpp.

References polynomXY< TNum, TIndex >::koeff.


Member Function Documentation

template<class TNum , class TIndex >
void polynomXY< TNum, TIndex >::clear (  )  [inline]
template<class TNum , class TIndex >
void polynomXY< TNum, TIndex >::clear ( short  maxDegree  )  [inline]

Definition at line 374 of file polynom.cpp.

References polynomXY< TNum, TIndex >::getIndex(), polynomXY< TNum, TIndex >::koeff, and polynomXY< TNum, TIndex >::maxDegree.

Here is the call graph for this function:

template<class TNum , class TIndex >
TNum polynomXY< TNum, TIndex >::getCoeff ( const short  x_exp,
const short  y_exp 
) const [inline]
template<class TNum , class TIndex >
TNum * polynomXY< TNum, TIndex >::getCoeffAddr ( const short  x_exp,
const short  y_exp 
) [inline]

Definition at line 90 of file polynom.cpp.

References polynomXY< TNum, TIndex >::getIndex(), polynomXY< TNum, TIndex >::koeff, and polynomXY< TNum, TIndex >::testBounds().

Here is the call graph for this function:

template<class TNum , class TIndex >
TNum const polynomXY< TNum, TIndex >::getCoeffConst ( const short  x_exp,
const short  y_exp 
) const [inline]

Definition at line 339 of file polynom.cpp.

References polynomXY< TNum, TIndex >::getIndex(), polynomXY< TNum, TIndex >::koeff, and polynomXY< TNum, TIndex >::testBounds().

Here is the call graph for this function:

template<class TNum , class TIndex >
TNum const * polynomXY< TNum, TIndex >::getCoeffConstAddr ( const short  x_exp,
const short  y_exp 
) const [inline]

Definition at line 81 of file polynom.cpp.

References polynomXY< TNum, TIndex >::getIndex(), polynomXY< TNum, TIndex >::koeff, and polynomXY< TNum, TIndex >::testBounds().

Here is the call graph for this function:

template<class TNum , class TIndex >
const TNum & polynomXY< TNum, TIndex >::getCoeffConstRef ( const int  x_exp,
const int  y_exp 
) const [inline]

Definition at line 348 of file polynom.cpp.

References polynomXY< TNum, TIndex >::getIndex(), polynomXY< TNum, TIndex >::koeff, and polynomXY< TNum, TIndex >::testBounds().

Here is the call graph for this function:

template<class TNum , class TIndex >
TNum & polynomXY< TNum, TIndex >::getCoeffRef ( const short  x_exp,
const short  y_exp 
) [inline]

Definition at line 358 of file polynom.cpp.

References polynomXY< TNum, TIndex >::getIndex(), polynomXY< TNum, TIndex >::koeff, and polynomXY< TNum, TIndex >::testBounds().

Here is the call graph for this function:

template<class TNum , class TIndex >
short polynomXY< TNum, TIndex >::getDegree (  )  const [inline]

Definition at line 368 of file polynom.cpp.

References polynomXY< TNum, TIndex >::maxDegree.

template<class TNum , class TIndex >
int polynomXY< TNum, TIndex >::getIndex ( const short  x_exp,
const short  y_exp 
) const [inline, private]
template<class TNum , class TIndex >
short polynomXY< TNum, TIndex >::getMaxDegree (  )  const [inline]

Definition at line 128 of file polynom.cpp.

References polynomXY< TNum, TIndex >::maxDegree.

template<class TNum, class TIndex>
string polynomXY< TNum, TIndex >::getName (  )  const [inline]

Definition at line 180 of file polynom.h.

References polynomXY< TNum, TIndex >::name.

template<class TNum , class TIndex >
polynomXY< TNum, TIndex > & polynomXY< TNum, TIndex >::operator= ( const polynomXY< TNum, TIndex > &  pxy  )  [inline]
template<class TNum , class TIndex >
bool polynomXY< TNum, TIndex >::operator== ( const polynomXY< TNum, TIndex > &  pxy  )  const [inline]

Definition at line 134 of file polynom.cpp.

References polynomXY< TNum, TIndex >::getCoeff(), and polynomXY< TNum, TIndex >::maxDegree.

Here is the call graph for this function:

template<class TNum , class TIndex >
void polynomXY< TNum, TIndex >::output ( std::ostream &  os  )  const [inline]

Definition at line 182 of file polynom.cpp.

References polynomXY< TNum, TIndex >::getCoeff(), and polynomXY< TNum, TIndex >::maxDegree.

Here is the call graph for this function:

template<class TNum , class TIndex >
void polynomXY< TNum, TIndex >::outputMatrix (  )  const [inline]

Definition at line 240 of file polynom.cpp.

References polynomXY< TNum, TIndex >::getCoeff(), polynomXY< TNum, TIndex >::maxDegree, and polynomXY< TNum, TIndex >::name.

Here is the call graph for this function:

template<class TNum , class TIndex >
void polynomXY< TNum, TIndex >::OutputPureCoefficients ( ostream &  datei,
int  maxDegree,
bool  mitKomma 
) const [inline]

Definition at line 263 of file polynom.cpp.

References polynomXY< TNum, TIndex >::getCoeff().

Here is the call graph for this function:

template<class TNum , class TIndex >
void polynomXY< TNum, TIndex >::print ( std::ostream &  os  )  const [inline]

Definition at line 200 of file polynom.cpp.

References polynomXY< TNum, TIndex >::getCoeff(), and polynomXY< TNum, TIndex >::maxDegree.

Referenced by polynomXY< TNum, TIndex >::printInMacaulayStyle().

Here is the call graph for this function:

template<class TNum , class TIndex >
void polynomXY< TNum, TIndex >::printInMacaulayStyle ( std::ostream &  os  )  const [inline]

Definition at line 230 of file polynom.cpp.

References polynomXY< TNum, TIndex >::name, and polynomXY< TNum, TIndex >::print().

Here is the call graph for this function:

template<class TNum , class TIndex >
void polynomXY< TNum, TIndex >::setCoeff ( const short  x_exp,
const short  y_exp,
const TNum  value 
) [inline]

Definition at line 318 of file polynom.cpp.

References polynomXY< TNum, TIndex >::getIndex(), polynomXY< TNum, TIndex >::koeff, and polynomXY< TNum, TIndex >::testBounds().

Here is the call graph for this function:

template<class TNum , class TIndex >
void polynomXY< TNum, TIndex >::setDegree ( short  maxDegree  )  [inline]
template<class TNum , class TIndex >
void polynomXY< TNum, TIndex >::testBounds ( const short  x_exp,
const short  y_exp 
) const [inline]

Member Data Documentation

template<class TNum, class TIndex>
TIndex polynomXY< TNum, TIndex >::idefs [private]
template<class TNum, class TIndex>
TNum* polynomXY< TNum, TIndex >::koeff [private]
template<class TNum, class TIndex>
short polynomXY< TNum, TIndex >::maxDegree [private]
template<class TNum, class TIndex>
short polynomXY< TNum, TIndex >::maxDegreePlusOne [private]
template<class TNum, class TIndex>
string polynomXY< TNum, TIndex >::name [private]
template<class TNum, class TIndex>
short polynomXY< TNum, TIndex >::size [private]

The documentation for this class was generated from the following files:
Generated on Tue Nov 23 13:10:53 2010 for centerfocus by  doxygen 1.6.3