00001 //************************************************************************************// 00002 // Module : siforce.hpp 00003 // Date : 12/4/02 (DLR) 00004 // Copyright : 2002-2006 Copyright University Corporation for Atmospheric 00005 // Research 00006 // Description : Encapsulates the methods and data associated with 00007 // defining a (collocated) forcing function. This 00008 // is the base class for all such forcing funtions. 00009 // Derived From : none 00010 // Modifications: 00011 //************************************************************************************// 00012 #if !defined(SIFORCE_HPP) 00013 #define SIFORCE_HPP 00014 00015 #include "gtvector.hpp" 00016 #include "elem2d.hpp" 00017 00018 00019 class SIForce 00020 { 00021 00022 public: 00023 SIForce(); 00024 SIForce(Elem2D *e); 00025 ~SIForce(); 00026 00027 virtual GVector Accel (GDOUBLE time, GINT idir)=0 ; 00028 virtual GBOOL Accel(GDOUBLE time, GINT idir, GVector &ret)=0 ; 00029 virtual GBOOL Initialize(){return TRUE;} ; 00030 virtual void SetElem(Elem2D *e); 00031 void SetTimeStep(const GDOUBLE t); 00032 void SetDensity(const GDOUBLE d) ; 00033 00034 protected: 00035 00036 GINT rank_; 00037 GINT idims_[3]; 00038 GINT NN_; 00039 GDOUBLE dt_; 00040 GDOUBLE rho_; 00041 Elem2D *elem; 00042 }; 00043 00044 #endif