HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
GAS_ProjectNonDivergentMultigrid.h
Go to the documentation of this file.
1 /*
2  * PROPRIETARY INFORMATION. This software is proprietary to
3  * Side Effects Software Inc., and is not to be reproduced,
4  * transmitted, or disclosed in any way without written permission.
5  *
6  * NAME: GAS_ProjectNonDivergentMultigrid.h ( GAS Library, C++)
7  *
8  * COMMENTS:
9  */
10 
11 #ifndef __GAS_ProjectNonDivergentMultigrid_h__
12 #define __GAS_ProjectNonDivergentMultigrid_h__
13 
14 #include "GAS_SubSolver.h"
15 #include "GAS_Utils.h"
16 
18 {
19 public:
20  /// These macros are used to create the accessors
21  /// getFieldDstName and getFieldSrcName functions we'll use
22  /// to access our data options.
23  GET_DATA_FUNC_S(GAS_NAME_FIELDDEST, FieldDstName);
25  GET_DATA_FUNC_F("reltol", RelTol);
26  GET_DATA_FUNC_F("abstol", AbsTol);
27  GET_DATA_FUNC_I("miniter", MinIter);
28  GET_DATA_FUNC_I("maxiter", MaxIter);
29  GET_DATA_FUNC_B(SIM_NAME_OPENCL, UseOpenCL);
30  GET_DATA_FUNC_B("internalfacesclosed", InternalFacesClosed);
31 
32 protected:
33  explicit GAS_ProjectNonDivergentMultigrid(const SIM_DataFactory *factory);
35 
36  /// The overloaded callback that GAS_SubSolver will invoke to
37  /// perform our actual computation. We are giving a single object
38  /// at a time to work on.
39  virtual bool solveGasSubclass(SIM_Engine &engine,
40  SIM_Object *obj,
41  SIM_Time time,
42  SIM_Time timestep);
43 
44  /// Performs the projection using OpenCL devices
45  bool projectOpenCL(SIM_Engine &engine,
46  SIM_Object *obj,
47  SIM_Time time,
48  SIM_Time timestep);
49 private:
50  /// We define this to be a DOP_Auto node which means we do not
51  /// need to implement a DOP_Node derivative for this data. Instead,
52  /// this description is used to define the interface.
53  static const SIM_DopDescription *getDopDescription();
54 
55  /// These macros are necessary to bind our node to the factory and
56  /// ensure useful constants like BaseClass are defined.
60  "Gas ProjectNonDivergent Multigrid",
61  getDopDescription());
62 };
63 
64 
65 #endif
66 
#define DECLARE_STANDARD_GETCASTTOTYPE()
Definition: SIM_DataUtils.h:45
#define GAS_API
Definition: GAS_API.h:10
virtual bool solveGasSubclass(SIM_Engine &engine, SIM_Object *obj, SIM_Time time, SIM_Time timestep)=0
#define DECLARE_DATAFACTORY(DataClass, SuperClass, Description, DopParms)
Definition: SIM_DataUtils.h:58
#define GET_DATA_FUNC_I(DataName, FuncName)
#define GAS_NAME_FIELDSOURCE
Definition: GAS_Utils.h:27
#define GAS_NAME_FIELDDEST
Definition: GAS_Utils.h:26
#define GET_DATA_FUNC_B(DataName, FuncName)
#define GET_DATA_FUNC_F(DataName, FuncName)
#define SIM_NAME_OPENCL
Definition: SIM_Names.h:221
#define GET_DATA_FUNC_S(DataName, FuncName)