polymtrx.hxx

来自「不错的国外的有限元程序代码,附带详细的manual,可以节省很多的底层工作.」· HXX 代码 · 共 47 行

HXX
47
字号
//   *******************************
//   *** CLASS POLYNOMIAL MATRIX ***
//   *******************************
 

#include "matrix.hxx"
#include "debug.def"
class Polynomial ; class FloatMatrix ; class FloatArray ;


class PolynomialMatrix : public Matrix
/*
   This class implements a matrix which contains polynomials. These matrices
   are typically used as jacobian matrices of finite elements.
 DESCRIPTION :
   The matrix stores its nRows*nColumns polynomials column by column.
 TASKS :
   - storing and returing coefficients (i.e., polynomials), in method 'at' ;
   - evaluating itself at a given point (method 'EvaluatedAt'). This prod-
     uces a matrix of the same size, containing numbers.
*/
{
   protected :
      Polynomial**  values ;

   public :
      PolynomialMatrix (int,int) ;           // constructor
      ~PolynomialMatrix () ;                 // destructor

#     ifdef DEBUG
	Polynomial*&     at (int,int) ;
#     else
	Polynomial*&     at (int i,int j) {return values[(j-1)*nRows+i-1] ;}
#     endif
      FloatMatrix*       EvaluatedAt (FloatArray*) ;
      PolynomialMatrix*  initialized () ;
      void               printYourself () ;
} ;








⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?