CFDEMcoupling  2.4
 All Classes
probeModel.H
1 /*---------------------------------------------------------------------------*\
2  CFDEMcoupling - Open Source CFD-DEM coupling
3 
4  CFDEMcoupling is part of the CFDEMproject
5  www.cfdem.com
6  Christoph Goniva, christoph.goniva@cfdem.com
7  Copyright 2009-2012 JKU Linz
8  Copyright 2012- DCS Computing GmbH, Linz
9 -------------------------------------------------------------------------------
10 License
11  This file is part of CFDEMcoupling.
12 
13  CFDEMcoupling is free software; you can redistribute it and/or modify it
14  under the terms of the GNU General Public License as published by the
15  Free Software Foundation; either version 3 of the License, or (at your
16  option) any later version.
17 
18  CFDEMcoupling is distributed in the hope that it will be useful, but WITHOUT
19  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
20  FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
21  for more details.
22 
23  You should have received a copy of the GNU General Public License
24  along with CFDEMcoupling; if not, write to the Free Software Foundation,
25  Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
26 
27 Description
28  This code is designed to realize coupled CFD-DEM simulations using LIGGGHTS
29  and OpenFOAM(R). Note: this code is not part of OpenFOAM(R) (see DISCLAIMER).
30 
31 Class
32  probeModel
33 
34 SourceFiles
35  probeModel.C
36 
37 \*---------------------------------------------------------------------------*/
38 
39 #ifndef probeModel_H
40 #define probeModel_H
41 
42 #include "fvCFD.H"
43 #include "cfdemCloud.H"
44 #include <vector>
45 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
46 
47 namespace Foam
48 {
49 
50 /*---------------------------------------------------------------------------*\
51  Class probeModel Declaration
52 \*---------------------------------------------------------------------------*/
53 
55 {
56 
57 protected:
58 
59  // Protected data
60  const dictionary& dict_;
61 
62  cfdemCloud& particleCloud_;
63 
64  //- Class used for grouping field types
65  template<class Type>
66  class fieldGroup
67  :
68  public DynamicList<word>
69  {
70  public:
71  //- Construct null
72  fieldGroup()
73  :
74  DynamicList<word>(0)
75  {}
76 
77  };
78 
79 
80 public:
81 
82  // Variables
83  //- Categorized scalar/vector/tensor vol fields
84  mutable fieldGroup<scalar> scalarFields_;
85  mutable fieldGroup<vector> vectorFields_;
86 
87  //- Runtime type information
88  TypeName("probeModel");
89 
90  // Declare runtime constructor selection table
91 
92  declareRunTimeSelectionTable
93  (
94  autoPtr,
95  probeModel,
96  dictionary,
97  (
98  const dictionary& dict,
99  cfdemCloud& sm,
100  word typeName,
101  char* logFileName
102  ),
103  (dict,sm,typeName,logFileName)
104  );
105 
106 
107  // Constructors
108 
109  //- Construct from components
110  probeModel
111  (
112  const dictionary& dict,
113  cfdemCloud& sm,
114  word typeName,
115  char* logFileName
116  );
117 
118 
119  // Destructor
120 
121  virtual ~probeModel();
122 
123 
124  // Selector
125 
126  static autoPtr<probeModel> New
127  (
128  const dictionary& dict,
129  cfdemCloud& sm,
130  word typeName,
131  char* logFileName
132  );
133 
134  // Member Functions
135 
136  virtual void initialize(word typeName, word logFileName) const {};
137  virtual void setOutputFile() const {};
138  virtual void writeHeader() const {};
139  virtual void writeProbe(int index, Field<scalar> sValues, Field<vector> vValues) const {};
140  virtual bool checkIDForPrint(int) const {return false;};
141  virtual void setCounter() const {};
142  virtual bool active() const {return true;};
143  virtual std::vector< std::vector<double*> >* getVprobe() {return NULL;};
144  virtual std::vector< std::vector<double> >* getSprobe() {return NULL;};
145  virtual void clearProbes() const {};
146  const char* wordToChar(word&) const;
147 
148 
149  // Access
150 
151 };
152 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
153 
154 } // End namespace Foam
155 
156 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
157 
158 #endif
159 
160 // ************************************************************************* //
Definition: probeModel.H:66
Definition: cfdemCloud.H:81
Definition: probeModel.H:54