⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 loadtime.cpp

📁 不错的国外的有限元程序代码,附带详细的manual,可以节省很多的底层工作.
💻 CPP
字号:
//   file LOADTIME.CXX
 
#include "loadtime.hxx"
#include "constant.hxx"
#include "peak.hxx"
#include "piecewis.hxx"
#include "domain.hxx"
#include <stdlib.h>
#include <stdio.h>


LoadTimeFunction*  LoadTimeFunction :: ofType (char* aClass)
   // Returns a new function, which has the same number than the receiver,
   // but which also is typed (ConstantFunction, PeakFunction,...).
{
   LoadTimeFunction* newLTF ;

   if (! strncmp(aClass,"ConstantFunction",5))
      newLTF = new ConstantFunction(number,domain) ;
   else if (! strncmp(aClass,"PeakFunction",5))
      newLTF = new PeakFunction(number,domain) ;
   else if (! strncmp(aClass,"PiecewiseLinFunction",5))
      newLTF = new PiecewiseLinFunction(number,domain) ;
   else {
      printf("%s : unknown type of load-time function \n",aClass) ;
      exit(0) ;}

   return newLTF ;
}


LoadTimeFunction*  LoadTimeFunction :: typed ()
   // Returns a new load, which has the same number than the receiver,
   // but is typed.
{
   LoadTimeFunction*  newLTF ;
   char               type[32] ;

   this -> readString("class",type) ;
   newLTF = this -> ofType(type) ;

   return newLTF ;
}











⌨️ 快捷键说明

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