Blockstructured Adaptive Mesh Refinement in object-oriented C++
00001 #ifndef AMROC_BOUNDARYCONDITIONS_H 00002 #define AMROC_BOUNDARYCONDITIONS_H 00003 00011 #include "BoundaryConditionsInterface.h" 00012 00013 #ifndef BoundaryConditionsName 00014 #define BoundaryConditions(dim) name2(BoundaryConditions,dim) 00015 #define BoundaryConditionsName 00016 #endif 00017 00024 template <class VectorType> 00025 class BoundaryConditions(DIM) : public BoundaryConditionsInterface(DIM)<VectorType> { 00026 typedef GridFunction(DIM)<VectorType> vec_grid_fct_type; 00027 public: 00028 BoundaryConditions(DIM)(const int gh) : 00029 _Equations(VectorType::Length()), _Ghosts(gh) { 00030 _Hierarchy = (GridHierarchy*) 0; 00031 } 00032 00033 virtual void register_at(ControlDevice&) {} 00034 virtual void register_at(ControlDevice& Ctrl,const string& prefix) {} 00035 virtual void init() {} 00036 virtual void update() {} 00037 virtual void finish() {} 00038 00039 void SetGridHierarchy(GridHierarchy* gh) { _Hierarchy = gh; } 00040 GridHierarchy& GH() { return *_Hierarchy; } 00041 const GridHierarchy& GH() const { return *_Hierarchy; } 00042 00043 const int& NEquations() const { return _Equations; } 00044 const int& NGhosts() const { return _Ghosts; } 00045 00046 private: 00047 int _Equations; 00048 int _Ghosts; 00049 GridHierarchy* _Hierarchy; 00050 }; 00051 00052 00053 #endif
Quickstart Users Guide Programmers Reference Installation Examples Download
AMROC Main Home Contactlast update: 06/01/04