constant.hxx

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

HXX
36 行
字号
//   *******************************
//   *** CLASS CONSTANT FUNCTION ***
//   *******************************

 
#include "loadtime.hxx"


class ConstantFunction : public LoadTimeFunction
/*
   This class implement a function  y = f(t)  that is constant in time.
 DESCRIPTION
   'value' is the constant value of the function. It is a pointer, rather
   than a number, so that its state (initialized or not) can be checked.
*/
{
   private :
      double*  value ; 

   public :
      ConstantFunction (int i,Domain* d) : LoadTimeFunction(i,d) {value=0 ;}
      ~ConstantFunction ()                       { delete value ;}

      double  at (double)             { return this->giveValue();}
      double  giveValue () ;
      void    instanciateYourself ()  { this->giveValue() ;}
} ;








⌨️ 快捷键说明

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